• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer navigation

The Geek Diary

  • OS
    • Linux
    • CentOS/RHEL
    • Solaris
    • Oracle Linux
    • VCS
  • Interview Questions
  • Database
    • oracle
    • oracle 12c
    • ASM
    • mysql
    • MariaDB
  • DevOps
    • Docker
    • Shell Scripting
  • Big Data
    • Hadoop
    • Cloudera
    • Hortonworks HDP

CentOS / RHEL 6 : How to disable IPv6

by admin

Post describes procedure to disable IPv6 on CentOS/RHEL 6. There are 2 ways to do this :
1. Disable IPv6 in kernel module (requires reboot)
2. Disable IPv6 using sysctl settings (no reboot required)

Method 1 : using /etc/modprobe.d/ipv6.conf

1. Check if IPV6 is enabled:

# ifconfig |grep inet6
  inet6 addr: fe80::d6be:d9ff:fe99:5a77/64 Scope:Link
  inet6 addr: fe80::d6be:d9ff:fe99:5a77/64 Scope:Link

2. Create /etc/modprobe.d/ipv6.conf if not already present with below parameter:

options ipv6 disable=1

3. Disable ipt6tables service

# chkconfig ip6tables off

4. Reboot the server

# shutdown -r now

5. Confirm if IPV6 is disabled:

# ifconfig |grep inet6
#

Method 2 : Using /etc/sysctl.conf

1. Append below line to the file /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

2. To make the settings affective, execute :

# sysctl -p
CentOS / RHEL 7 : How to disable IPv6

Filed Under: Linux

Some more articles you might also be interested in …

  1. ifenslave Command Examples in Linux
  2. CentOS / RHEL 7 : How to disable all tty consoles and enable only 1
  3. sa Command Examples in Linux
  4. How to disable “Alt+Ctrl+Del” causing system reboot in CentOS/RHEL 7
  5. mount.cifs: command not found
  6. “su: Authentication failure” – in Docker
  7. fprintd-delete Command Examples in Linux
  8. How to Start and Stop OSWatcher
  9. lastb: command not found
  10. CentOS / RHEL : Managing password ageing for users using chage (with practical Examples)

You May Also Like

Primary Sidebar

Recent Posts

  • pw-cat Command Examples in Linux
  • pvs: command not found
  • pulseaudio: command not found
  • pulseaudio Command Examples in Linux

© 2023 · The Geek Diary

  • Archives
  • Contact Us
  • Copyright