RHEL 7 & CentOS 7 To disable the IPV6 method and the previous version is not the same, this article sorted out the processing method: The source of this article: http://blog.csdn.net/bluishglc/article/details/ 41390785 prohibit any form of reprint, otherwise will entrust CSDN official safeguard rights and interests.
First, we have to give the most fundamental solution: modify grub to not load the IPV6 module at boot time
After this modification, use the
# Lsmod | grep ipv6
For verification.
Let's look at a way to deal with it, which is not as thorough as the one mentioned above, but also effective.
Verify IPV6 is off
1. By order:
Check to the If you ' re installation are currently set up for IPV6:
# Cat/proc/sys/net/ipv6/conf/all/disable_ipv6
If the output is 0, IPV6 is enabled.
If the output is 1, IPV6 is already disabled.
Specifically: In this way, using # Lsmod | grep ipv6 will still have some related modules listed.
2. Through Ifconfig view the network card information, the following open and close the difference of IPv6:
to disable IPV6 procedures
Step 1:add This rule in/etc/sysctl.conf: net.ipv6.conf.all.disable_ipv6=1
Step 2:add This rule in/etc/sysconfig/network: networking_ipv6=no
Step 3:add This setting to each NIC X (x was the corresponding number for each NIC) in/etc/sysconfig/network-scripts/ifc FG-ETHX: ipv6init=no
Step 4:disable The Ip6tables service: chkconfig ip6tables off
Step 5:reload The Sysctl configuration:
# sysctl-p
Or
# reboot
Note: Disabling IPV6 may cause some services to fail to start, such as Vsftp, and for vsftp, you need to modify the listen and Listen_ipv6 two options in the/etc/vsftpd/vsftpd.conf file:
Listen=yes Listen_ipv6=no