我已经安装了SSH,并且configuration了UCARP以在两个盒子中的一个出现故障时通过虚拟IP进行故障转移。 我遇到的问题是虚拟机正在运行,并且ucarp接口处于活动状态(eth0:ucarp),我不能使用eth0地址sshlogin虚拟机; 我只能使用eth0:ucarp地址到达它。
我使用本指南来设置UCARP: http ://laurentbel.com/2012/04/04/simple-failover-cluster-on-ubuntu-using-carp/
有没有一种方法来configurationssh只能在eth0上运行,或者让eth0成为ssh的“主要”接口? 现在,如果我尝试SSH到eth0地址,没有响应(连接超时)。
这是我的/ etc / networking / interfaces文件:
# This file describes the network interfaces available on your system # and how to activate them. For more information, see interfaces(5). # The loopback network interface auto lo iface lo inet loopback # The primary network interface auto eth0 iface eth0 inet static ### # standard config ### address 192.168.1.7 netmask 255.255.255.0 gateway 192.168.1.1 network 192.168.1.0 broadcast 192.168.1.255 ### # ucarp config ### # vid: the ID of the virtual server [1-255] ucarp-vid 1 # vip: the virtual IP ucarp-vip 192.168.1.3 # password ucarp-password info322 # advskew: Advertisement skew [1-255] ucarp-advskew 1 # advbase: Interval in seconds that advertisements will occur ucarp-advbase 1 # master: determine if this server is the master ucarp-master yes # The carp network interface, on top of eth1 iface eth0:ucarp inet static address 192.168.1.3 netmask 255.255.255.0