Resolution

Red Hat Enterprise Linux 4, 5 and 6 enable Internet Protocol Version 6 (IPv6) by default. However, in certain situations, some users may find it desirable to disable IPv6 support or to re-enable it after it has been disabled.

For Red Hat Enterprise Linux 6, the tech brief Preparing for IPv6 Networking in Red Hat Enterprise Linux provides a broad introduction to IPv6 networking.

Disabling IPv6 support in Red Hat Enterprise Linux 6
  1. Create a file /etc/modprobe.d/ipv6.conf with the following contents:

    options ipv6 disable=1
  2. For completeness, it is a good idea to configure the ip6tables service not to start at boot by issuing the following command:

    # chkconfig ip6tables off
  3. Edit /etc/sysconfig/network and add the line NETWORKING_IPV6=no

  4. Disable ipv6 support in the kernel through /etc/sysctl.conf :

    # ipv6 support in the kernel, set to 0 by default
    net.ipv6.conf.all.disable_ipv6 = 1
    net.ipv6.conf.default.disable_ipv6 = 1
  5. Optionally to prevent rpc.nfsd setting up IPv6 sockets while NFS server is running, edit /etc/netconfig for the lines starting with udp6 and tcp6; change the "v" in the third column to "-"(hyphen/dash)

  6. Reboot the system to disable IPv6 support.

Note: There is a special case where this might not work, please see The "ipv6 disable=1" option does not seem to work on Red Hat Enterprise Linux 6 system.
Disabling ipv6 in the sysctl.conf will ensure ipv6 isn't used even if the ipv6 module is loaded and can work as a short term solution (until a full reboot)

Re-enabling IPv6 support in Red Hat Enterprise Linux 6
  1. Review the files under /etc/modprobe.d/ and remove (or comment out) any of the following lines:

    options ipv6 disable=1
    install ipv6 /bin/true
    blacklist ipv6
  2. Configure the ip6tables service to start at boot by issuing the following command:

    # chkconfig ip6tables on
  3. Edit /etc/sysconfig/network and add the line NETWORKING_IPV6=yes

  4. Make sure the following options to your /etc/sysctl.conf are

    # ipv6 support in the kernel, set to 0 by default
    net.ipv6.conf.all.disable_ipv6 = 0
    net.ipv6.conf.default.disable_ipv6 = 0
  5. Edit /etc/netconfig for the lines starting with udp6 and tcp6; change the "-"(hyphen/dash) in the third column to "v"

  6. Reboot the system to activate IPv6 support.

Disabling IPv6 support in Red Hat Enterprise Linux 5
  1. Remove the following line (if present) from the /etc/modprobe.conf file:

    alias net-pf-10 ipv6
  2. Add the following line to the /etc/modprobe.conf file:

    alias net-pf-10 off
  3. In versions of Red Hat Enterprise Linux before 5.4, add the following line to the /etc/modprobe.conf file:

    alias ipv6 off
  4. In Red Hat Enterprise Linux 5.4 and later, add the following line to the /etc/modprobe.conf file:

    options ipv6 disable=1
  5. To prevent errors during the network initscript start routine, change the NETWORKING_IPV6 parameter in the /etc/sysconfig/network file to the following:

    NETWORKING_IPV6=no
  6. For completeness, it is a good idea to configure the ip6tables service not to start at boot by issuing the following command:

    # chkconfig ip6tables off
  7. Reboot the system to disable IPv6 support.

Re-enabling IPv6 support in Red Hat Enterprise Linux 5
  1. Remove the following lines (if present) from the /etc/modprobe.conf file:

    alias net-pf-10 off
    alias ipv6 off
    options ipv6 disable=1
  2. Add the following line to the /etc/modprobe.conf file (if not present already):

    alias net-pf-10 ipv6
  3. Change the NETWORKING_IPV6 parameter in the /etc/sysconfig/network file to the following:

    NETWORKING_IPV6=yes
  4. For completeness, it is a good idea to configure the ip6tables service to start at boot by issuing the following command:

    # chkconfig ip6tables on
  5. Reboot the system to re-enable IPv6 support.

Disabling IPv6 support in Red Hat Enterprise Linux 4
  1. Remove the following line (if present) from the /etc/modprobe.conf file:

    alias net-pf-10 ipv6
  2. Add the following line to the /etc/modprobe.conf file:

    alias net-pf-10 off
  3. Reboot the system to disable IPv6 support.

Re-enabling IPv6 support in Red Hat Enterprise Linux 4
  1. Remove the following line from the /etc/modprobe.conf file:

    alias net-pf-10 off
  2. Add the following line to the /etc/modprobe.conf file:

    alias net-pf-10 ipv6
  3. Reboot the system to re-enable IPv6 support.

Disable or enable the IPv6 protocol in Red Hat Enterprise Linux的更多相关文章

  1. How to disable transparent hugepages (THP) on Red Hat Enterprise Linux 7

    How to disable transparent hugepages (THP) on Red Hat Enterprise Linux 7 $ Solution 已验证 - 已更新2017年六月 ...

  2. How to use, monitor, and disable transparent hugepages in Red Hat Enterprise Linux 6

    Resolution Note: Transparent Huge Pages are not available on the 32-bit version of RHEL 6. Transpare ...

  3. setting up a IPSEC/L2TP vpn on CentOS 6 or Red Hat Enterprise Linux 6 or Scientific Linux

    This is a guide on setting up a IPSEC/L2TP vpn on CentOS 6 or Red Hat Enterprise Linux 6 or Scientif ...

  4. Deploy Oracle 10.2.0.5 DataGuard on Red Hat Enterprise Linux 6.4

    系统:Red Hat Enterprise Linux 6.4 数据库:Oracle 10.2.0.5.0 Patch Set 4 主机:10dg1 192.168.1.91 10dg2192.168 ...

  5. Configure Red Hat Enterprise Linux shared disk cluster for SQL Server——RHEL上的“类”SQL Server Cluster功能

    下面一步一步介绍一下如何在Red Hat Enterprise Linux系统上为SQL Server配置共享磁盘集群(Shared Disk Cluster)及其相关使用(仅供测试学习之用,基础篇) ...

  6. [转] KVM storage performance and cache settings on Red Hat Enterprise Linux 6.2

    Almost one year ago, I checked how different cache settings affected KVM storage subsystem performan ...

  7. Common administrative commands in Red Hat Enterprise Linux 5, 6, and 7

    https://access.redhat.com/articles/1189123 Common administrative commands in Red Hat Enterprise Linu ...

  8. Configure Red Hat Enterprise Linux shared disk cluster for SQL Server

    下面一步一步介绍一下如何在Red Hat Enterprise Linux系统上为SQL Server配置共享磁盘集群(Shared Disk Cluster)及其相关使用(仅供测试学习之用,基础篇) ...

  9. Red Hat Enterprise Linux 7.x新特性

    Red Hat Enterprise Linux 7.x新特性 RHEL7新特性简介 1.      RHEL7目前支持架构 64-bit AMD.64-bit Intel.IBM POWER.IBM ...

随机推荐

  1. Ado访问sqlserver 端口号非1433时 连接串的写法

    Provider=SQLOLEDB.;Persist Security Info=False;Data Source=hostName,Port //注意用 逗号分隔主机名与端口号

  2. 裸机——LCD

    1.先了解显示器们 CRT显示器 原理,使用电子轰击荧光粉实现显示. 特点,主动发光,颜色绚丽,但是大. 等离子显示器(PDP) 原理,在显示屏上排列上千个密封的小低压气体室,通过电流激发使其发出肉眼 ...

  3. easypoi 一行代码搞定excel导入导出

    开发中经常会遇到excel的处理,导入导出解析等等,java中比较流行的用poi,但是每次都要写大段工具类来搞定这事儿,此处推荐一个别人造好的轮子[easypoi],下面介绍下“轮子”的使用. pom ...

  4. Error: Cannot find module 'core-js/fn/array/values' at Function.Module._resolveFilename (module

    E:\codeBase\top605\rescue-master\server\node_modules\_log4js@1.1.1@log4js\lib\log4js.js:321 throw ne ...

  5. 9,K-近邻算法(KNN)

    导引: 如何进行电影分类 众所周知,电影可以按照题材分类,然而题材本身是如何定义的?由谁来判定某部电影属于哪 个题材?也就是说同一题材的电影具有哪些公共特征?这些都是在进行电影分类时必须要考虑的问 题 ...

  6. [工具使用]xshell 中“快速命令集”的使用

    突然看到朋友的xshell比我多一个按钮,且一点,哈哈哈 ,实现了很炫酷的功能,耐不住好奇,问了一句,原来是快速命令集! 1.选择快速命令集(两种方法a&b) a:文件 > 属性 > ...

  7. JavaScript获取时间

    var myDate = new Date();            console.log(myDate.getFullYear()); //获取完整的年份(4位,1970-????)       ...

  8. laravel5.5契约

    无规矩不成方圆, Laravel 的契约是一组定义框架提供的核心服务的接口,规定了实现该接口的规范. 为什么要使用接口 首先,让我们来看一些高耦合缓存实现的代码.如下: <?php namesp ...

  9. 《Cracking the Coding Interview》——第12章:测试——题目2

    2014-04-24 23:15 题目:你有一段程序,运行了十次每次都在不同的地方崩掉了.已知这段程序只用了标准C或C++库函数,请问有什么思路来找出问题所在. 解法:1. 时间戳每次都不同.2. 随 ...

  10. python-isinstance,issubclass

    1 #当存在继承关系时,两个类中存在相同的方法,如何执行父类的方法,通过super 2 class C1: 3 def f1(self): 4 print('c1.f1') 5 6 7 class C ...