Centos 關閉 IPv6
看linux上開了哪些port service 與 是否IPv6有開啟 ?
netstat -ntlp
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 127.0.0.1:199 0.0.0.0:* LISTEN 1397/snmpd
tcp 0 0 0.0.0.0:3306 0.0.0.0:* LISTEN 1592/mysqld
tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN 1623/sendmail: acce
tcp 0 0 :::80 :::* LISTEN 1641/httpd
tcp 0 0 :::22 :::* LISTEN 1429/sshd
其中
tcp 0 0 :::80 :::* LISTEN 1641/httpd
tcp 0 0 :::22 :::* LISTEN 1429/sshd
為 IPv6
如不需要該如何關閉 ?
step1
檢查NETWORK是否關閉 ?
vim /etc/sysconfig/network
NETWORK_IPV6=no
step2
modprobe.conf 添加 net-pf-10 ipv6
vim /etc/modprobe.conf
alias net-pf-10 off
alias ipv6 off
step3
關閉ip6tables
/etc/init.d/ip6tables stop
chkconfig ip6tables off
reboot
See also
How to diable IPv6 on Centos 6.x or RHEL 6.x
沒有留言:
張貼留言