1、 临时添加(重启系统后失效)
#ifconfig、route 命令
/sbin/ifconfig eth0:1 192.168.8.43 broadcast 192.168.8.255 netmask 255.255.255.0 up
/sbin/route add -host 192.168.8.43 dev eth0:1
2、开机自运行(重启不失效)
编辑 /etc/rc.local 文件,在文件最后增加以上两行命令,保存即可;
1、 临时添加(重启系统后失效)
#ifconfig、route 命令
/sbin/ifconfig eth0:1 192.168.8.43 broadcast 192.168.8.255 netmask 255.255.255.0 up
/sbin/route add -host 192.168.8.43 dev eth0:1
2、开机自运行(重启不失效)
编辑 /etc/rc.local 文件,在文件最后增加以上两行命令,保存即可;