From: Helmut Wollmersdorfer (helmut.wollmersdorfer_at_gmx.at)
Date: Wed 24 Aug 2005 - 12:23:28 BST
Subhabrata Bhattacharya wrote:
> When I try to ssh to any of the vservers specifying IP, I end up
> getting a shell in the local host machine. What could be the problem?
You need to specify 'ListenAddress', e.g.
xp2400:/# cat /etc/ssh/sshd_config | grep -i 'listenadd'
ListenAddress 192.168.0.21:22
ListenAddress 192.168.0.20:22
xp2400:/# vserver vs27 enter
vs27:/# cat /etc/ssh/sshd_config | grep -i 'listenadd'
ListenAddress 192.168.0.27:22
If you have more than on IP on your host, then use 'IP:Port' notation.
My second IP x.x.x.20 is also an alias switched by heartbeat failover.
Only the first IP allowed ssh-login, until I specified the 'Port'.
BTW this also needs a '/etc/init.d/ssh restart' after a failover.
Similar is true for other daemons or services listening to 0.0.0.0 (=
all or '*')
Helmut Wollmersdorfer
_______________________________________________
Vserver mailing list
Vserver_at_list.linux-vserver.org
http://list.linux-vserver.org/mailman/listinfo/vserver