How to disable IPv6 protocol in kickstart installation?

Solution Verified - Updated

Environment

  • Red Hat Enterprise Linux 9
  • Red Hat Enterprise Linux 8
  • Red Hat Enterprise Linux 7
  • Red Hat Enterprise Linux 6
  • kickstart

Issue

  • How to disable IPv6 protocol in kickstart installation.?

Resolution

To disable IPv6 protocol in kickstart installation, following two settings must be set.

  • Set "--noipv6" in ks.cfg file:
network --onboot yes --device eth0 --bootproto dhcp --noipv6       

Above setting will add "IPV6INIT=no" in /etc/sysconfig/network-scripts/ifcfg-eth0.

To disable IPv6 during the installation

Red Hat Enterprise Linux 6

  • Pass "noipv6" parameter to the kernel. This setting will create /etc/modprobe.d/ipv6.conf file and set "options ipv6 disable=1" in it.
kernel vmlinuz
append ks=http://192.168.122.xxx/ks.cfg noipv6 initrd=initrd.img

Red Hat Enterprise Linux 7

  • Pass "ipv6.disable=1" parameter to the kernel.
vmlinuz initrd=initrd.img inst.stage2=hd:LABEL=RHEL-7.3\x20Server.x86_64 ks=http://192.168.122.xxx/ks.cfg ipv6.disable=1

Red Hat Enterprise Linux 8

  • Pass "ipv6.disable=1" parameter to the kernel.
vmlinuz initrd=initrd.img inst.stage2=hd:LABEL=RHEL-8-4-0-BaseOS-x86_64 ks=http://192.168.122.xxx/ks.cfg ipv6.disable=1

Red Hat Enterprise Linux 9

  • Pass "ipv6.disable=1" parameter to the kernel.
vmlinuz initrd=initrd.img inst.stage2=hd:LABEL=RHEL-9-1-0-BaseOS-x86_64 ks=http://192.168.122.xxx/ks.cfg ipv6.disable=1

Please note that both the above settings are necessary, otherwise IPv6 protocol won't be disabled after the installation.

Components
Category

This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.