Centos 7禁用关闭IPv6的方法
1.在/etc/sysctl.conf中添加此规则:
net.ipv6.conf.all.disable_ipv6 = 1
2.在/etc/sysconfig/network中添加此规则:
NETWORKING_IPV6 = no
3.在/etc/sysconfig/network-scripts/ifcfg-ethX中添加此规则:
IPV6INIT = no
4.关闭防火墙的开机自启动服务:
systemctl disable ip6tables.service
5.重新加载sysctl配置或者重启服务器
#sysctl -p
or
#reboot
注:
在/etc/sysconfig/network-scripts/ifcfg-ethX中ethX为网卡名
示例:
vi /etc/sysctl.conf
vi /etc/sysconfig/network
vi /etc/sysconfig/network-scripts/ifcfg-eth0
建议阅读
- Windows系统异常重启以及蓝屏的处理(查看: 10386)
- fsck 命令详解(查看: 1610)
- Windows系统开始后一直是蓝色背景屏幕(非蓝屏crash)的解决方案(查看: 8508)
- Windows10 提示无法使用内置管理员账户打开某应用解决方法(查看: 391)
- Linux下查怎么查看端口进程(查看: 1267)