linux - ssh: connect to host localhost port 2222: Connection refused -


i installed virtual box on linux os, in virtual box, created linux os, has user called "dvader", want ssh local linux os linux os on virtual box, used command below:

$ ssh -p 2222 dvader@localhost 

but got error:

ssh: connect host localhost port 2222: connection refused 

anyone knows how solve problem? thank in advance.

cuestion: ¿are using nat?... ssh listen p22 default, if want connection on p2222 edit ssh_config placed in /etc/ of vm guest... find line (assuming in *buntu os family)

 39 #   port 22 

and change to

 39    port 2222 

and there have on p2222

btw, host could'nt see guest name "dvader@localhost", because "localhost" it's indeed host & guest maybe ip, give more details vnetwork config...

sorry english :)


Comments

Popular posts from this blog

apache - Remove .php and add trailing slash in url using htaccess not loading css -

javascript - jQuery show full size image on click -