Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
ssh: connection refused while installing with minimal cd
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Installing Gentoo
View previous topic :: View next topic  
Author Message
WoodenFish
n00b
n00b


Joined: 05 Feb 2018
Posts: 2

PostPosted: Mon Feb 05, 2018 2:27 pm    Post subject: ssh: connection refused while installing with minimal cd Reply with quote

A newbie in linux, looking for help.
I tried to install Gentoo on my windows 8 machine, using virtual box.
And I want to use ssh in another computer to operate this installation.
I am now sure that this minimal cd contains the sshd and I have started it up. I have also tried to use the minimal CD to ssh itself like 'ssh localhost' and succeeded. And I used the other computer to ping the ipv4 address and also succeeded. And the iptable is stopped. But when I use ssh, it returns 'connection refused'. I have googled but didn't find a proper solution. So I come here to find help. I want to know what the problem might be.
Thank you all very much.
Back to top
View user's profile Send private message
WoodenFish
n00b
n00b


Joined: 05 Feb 2018
Posts: 2

PostPosted: Mon Feb 05, 2018 2:32 pm    Post subject: Reply with quote

Well, I tried putty with my windows 8 system and succeeded...But on another computer, it fails.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 43571
Location: 56N 3W

PostPosted: Mon Feb 05, 2018 2:35 pm    Post subject: Reply with quote

WoodenFish,

Root logins to the liveCD are limited to keys only as that's the default sshd set up these days.

Edit /etc/ssh/sshd_config
Find the line
Code:
#PermitRootLogin prohibit-password

Change it to
Code:
PermitRootLogin yes


Now restart sshd.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Hu
Moderator
Moderator


Joined: 06 Mar 2007
Posts: 14071

PostPosted: Tue Feb 06, 2018 3:25 am    Post subject: Reply with quote

Connection refused precedes authentication. Password versus key may yet be a problem for him, but he has not yet reached the point where he needs to solve that.

OP: what exactly did you type (and on which system) that you got the Connection refused error? On what addresses is sshd listening from the guest? (Check by running netstat -nptl and posting its output.)
Back to top
View user's profile Send private message
bbgermany
Veteran
Veteran


Joined: 21 Feb 2005
Posts: 1792
Location: Oranienburg/Germany

PostPosted: Tue Feb 06, 2018 8:15 am    Post subject: Reply with quote

WoodenFish wrote:
Well, I tried putty with my windows 8 system and succeeded...But on another computer, it fails.


Are you using host-only or nat as connection for your gentoo guest?

greets, bb
_________________
1st: i5-4570, 16GB, 1.75TB
2nd: i5-4570, 16GB, 620GB
3rd: i5-4570, 16GB, 10,5TB
4th: Asus N61VN, 8GB, 240GB
5th: C2D T7200, 2GB, 16GB USB + NFS
Back to top
View user's profile Send private message
P.Kosunen
Guru
Guru


Joined: 21 Nov 2005
Posts: 309
Location: Finland

PostPosted: Tue Feb 06, 2018 1:50 pm    Post subject: Reply with quote

If there is not specific reason for Gentoo minimal cd i would recommend SystemRescueCd instead, it has SSHD enabled by default.

Code:
/boot/grub/grub-*.cfg
/isolinux/isolinux.cfg


You can add "rootpass=password" option to bootloader configs in kernel line, Grub config for UEFI and isolinux.cfg for legacy BIOS boot.

Code:
rootpass=password setkmap=fi ethx=10.0.0.99/24 dns=10.0.0.1 gateway=10.0.0.1


You can add some other usefull options too, ip and default gateway for headless use etc.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Installing Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum