IPV6 in Redhat Enterprise Linux

IPv6 in Redhat Enterprise Linux



In my previous post about IPV6- Solution for IPv4 Exhaustion , we have already discussed about the purpose and basic features of IPv6. In this post we will get discuss about basic IPv6 commands used in Redhat Enterprise Linux.






IPV6 Related tools in Redhat Enterprise Linux

To view IPv6 address  – >                                                          

#  ip -6 address show

To view NDP table in IPV6 ->

#  ip -6 neighbor show

To view IPV6 connections to Local Interfaces ->

 # netstat –A inet6 –rn

To Ping ->

# ping6 –l eth0 fe80::a00:27ef:fea3:3abc

To use sniffing tools ->

# tcpdump ip6 ,  #snmp inet6  or #  icmp6

Config Temporarily ->

# ifconfig eth0 inet6 add 2002:db6::2/64 (or) ip addr add 2002:db6::2/64 dev eth0

Config default route ->

# route –A inet6 add default 2002:db6::1


# ip -6 route add default via 2002:db6::1

To view routes  ->

# route –n –A inet6 (shows routes set for your network interfaces)

To view traceroute ->

# traceroute -6 <Address>

To check the configuration use ->

# ifconfig eth0 or ip -6 addr show eth0

# route –A inet6 or ip route show.


For making the changes permanent you’ll have to put them in the config files.


Stateless Address Auto configuration

Just having IPv6 enabled and IPv4 configured on the interface should normally.  Security and privacy concerns regarding EUI-64 interface IDs enable and prefer temporary addresses over other public addresses with:

# sudo sysctl net.ipv6.conf.eth0.use_tempaddr = 2

# sudo sysctl net.ipv6.conf.default.use_tempaddr=2

To make these settings boot proof put them into /etc/sysctl.conf. Change valid and preferred lifetime Of temporary addresses by editing temp_valid_lft and temp_prefered_lft values (defaults are  604800 (7d) and 86400 (1d) seconds) for the interface.


Example IPv6 setup

Example setup where eth0 is connected to an IPv6 enabled network and receiving multiple IPv6 addresses from the local router. The eth0 & eth1 interfaces have both an IPv4 & IPv6 address. This is known as Dual Stack.

ifconfig is IPv6 enabled and will show you the IPv6 address or addresses associated with an interface. For example – IPv6 information is highlighted in RED.

$ ifconfig
eth0 Link encap:Ethernet HWaddr 08:00:27:A4:4A:BC
inet addr: Bcast: Mask:
inet6 addr: 2605:6000:100e:8046:a00:27ff:fea4:4abc/64 Scope:Global
inet6 addr: fd1a:94d9:d04e:0:a00:27ff:fea4:4abc/64 Scope:Global
inet6 addr: fe80::a00:27ff:fea4:4abc/64 Scope:Link
RX packets:3223 errors:0 dropped:0 overruns:0 frame:0
TX packets:2576 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:3231356 (3.0 MiB) TX bytes:486164 (474.7 KiB)
eth1 Link encap:Ethernet HWaddr 08:00:27:F3:6B:A4
inet addr: Bcast: Mask:
inet6 addr: fe80::a00:27ff:fef3:6ba4/64 Scope:Link
RX packets:102 errors:0 dropped:0 overruns:0 frame:0
TX packets:33 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:13880 (13.5 KiB) TX bytes:5775 (5.6 KiB)
lo Link encap:Local Loopback
inet addr: Mask:
inet6 addr: ::1/128 Scope:Host
RX packets:8 errors:0 dropped:0 overruns:0 frame:0
TX packets:8 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:480 (480.0 b) TX bytes:480 (480.0 b)




  • For IPV6 DNS records are AAAA records
  • For IPV4 DNS records are AA records


Use dig with à dig aaaa <DNS name>

For example yahoo.com:



yahoo.com. 300 IN AAAA 2076:f8b0:4004:802::1007


You do not need to connect to the DNS server via IPv6 to get the AAAA record. Meaning the DNS server does not need to have an IPv6 address to give out IPv6 DNS records.



Using wget you get a since of the search order and which address it uses the IPv6 address over the IPv4 addresses.

wget yahoo.com
–2013-12-18 22:38:44– http://www.yahoo.com/
Resolving www.yahoo.com (www.yahoo.com)… 2076:f8b0:4000:806::1014,,, …
Connecting to www.yahoo.com (www.yahoo.com)| 2076:f8b0:4000:806::1014|:80… connected.
HTTP request sent, awaiting response… 200 OK
Length: unspecified [text/html]
Saving to: `index.html.2′
[ <=> ] 10,746 –.-K/s in 0.002s
2013-04-18 22:38:44 (4.97 MB/s) – `index.html.2′ saved [10746]

Srinivas G

Srinivas G

Srinivas having multiple years of experience in IBM AIX and LINUX administration, and currently supporting an enterprise UNIX network for a Major multinational Firm. He has completed his formal certifications for AIX(100 & 223) & Linux(RHCE). And very passionate to share his everyday learning with his peers and unixadminschool.com readers.

1 Response

  1. September 16, 2015

    […] Read – IPV6 for Beginners Guide […]

What is in your mind, about this post ? Leave a Reply

  Our next learning article is ready, subscribe it in your email

What is your Learning Goal for Next Six Months ? Talk to us