Centos开机启动修改IP、DNS、默认网关

echo -e "ifconfie eth1 192.168.20.159 netmask 255.255.255.0\nroute add default gw 192.168.20.254\n">>/etc/rc.d/rc.local

echo "echo servername 192.168.20.254>/etc/resolv.conf"

猜你喜欢

转载自yizhaorong.iteye.com/blog/2101902