1

I have two pcs on a LAN. I can connect from one to the other using ssh, but not the other way. I get

ssh -vv 192.168.1.2
OpenSSH_4.7p1 Debian-8ubuntu1.2, OpenSSL 0.9.8g 19 Oct 2007
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: Applying options for *
debug2: ssh_connect: needpriv 0
debug1: Connecting to 192.168.1.2 [192.168.1.2] port 22.
debug1: connect to address 192.168.1.2 port 22: Connection refused

ssh: connect to host 192.168.1.2 port 22: Connection refused

3 Answers 3

4

You have to install openssh-server on the machine you want connect to. If 192.168.1.2 is also an Debian or Ubuntu, this can be done like this: aptitude install openssh-server (you have to be root for this, or do: sudo aptitude install openssh-server if you use an ubuntu without root-account). If you are using a firewall on 192.168.1.2, open port 22.

Then try it again.

1

Install open-ssh on 192.168.1.2. Open 22 port, if it is closed.

0

what tdeutsch have said +

Remember to check /etc/hosts.{allow,deny} files.

Not the answer you're looking for? Browse other questions tagged .