linux下单个网卡设置多IP

cd  /etc/sysconfig/network-scripts

cp ifcfg-eth0 ifcfg-eth0:0

vi  ifcfg-eth0:0

把DEVICE改成 eth0:0

 ifcfg-eth0:0 不要设网关