1、centos6的网卡重启方法:service network restart
centos7的网卡重启方法:systemctl restart network

2、centos重启网口方法:
关闭网卡口:ifdown eth0 或 ifconfig eth0 down
启动网卡口:ifup eth0 或 ifconfig eth0 up

3、配置网卡ip
增加ip:ifcfg eth0 add 192.168.1.251/24
删除ip:ifcfg eth0 del 192.168.1.251/24  或 ifcfg eth0 stop

Logo

为开发者提供学习成长、分享交流、生态实践、资源工具等服务,帮助开发者快速成长。

更多推荐