ping 10.112.18.191 PING 10.112.18.191 (10.112.18.191) 56(84) bytes of data. 64 bytes from 10.112.18.191: icmp_req=1 ttl=64 time=0.028 ms
换台机器测试:edward@edward-catamaran:~$ ping 10.112.18.191 PING 10.112.18.191 (10.112.18.191) 56(84) bytes of data. 64 bytes from 10.112.18.191: icmp_req=1 ttl=64 time=0.916 ms 64 bytes from 10.112.18.191: icmp_req=2 ttl=64 time=0.258 ms
删除虚拟IP的方法。
ifconfig eth0:0 down
后面还要做什么?当然是保存配置,保证重启后虚拟IP也还在。
直接在/etc/network/interfaces文件中添加:
auto lo iface lo inet loopback auto eth0:0 iface eth0:0 inet static name Ethernet alias LAN card address 10.112.18.191 netmask 255.255.255.0 broadcast 10.112.18.255 network 10.112.18.0
重新启动网络服务。
/etc/init.d/networking restart