IPv6: Difference between revisions
(Added where to get more information, how to determine and ping a IPv6 address) |
|||
Line 30: | Line 30: | ||
In the above example, the '''IPv6''' address is: "''fe80::20c:29ff:fec9:d51a''". The double colons (::) in the address represent 3 groupings of zeros. Hence, "''fe80::20c:29ff:fec9:d51a''" is the short hand equivalent of: "''fe80:0:0:0:20c:29ff:fec9:d51a''". | In the above example, the '''IPv6''' address is: "''fe80::20c:29ff:fec9:d51a''". The double colons (::) in the address represent 3 groupings of zeros. Hence, "''fe80::20c:29ff:fec9:d51a''" is the short hand equivalent of: "''fe80:0:0:0:20c:29ff:fec9:d51a''". | ||
== Ping | == Ping an IPv6 Address (scope link) == | ||
The following demonstrates how one can ''ping'' a '''IPv6''' address: | The following demonstrates how one can ''ping'' a '''IPv6''' address that has a limited ''link'' scope: | ||
<div class="screen"> | <div class="screen"> | ||
Line 46: | Line 46: | ||
3 packets transmitted, 3 received, 0% packet loss, time 2000ms | 3 packets transmitted, 3 received, 0% packet loss, time 2000ms | ||
rtt min/avg/max/mdev = 0.349/0.548/0.935/0.274 ms | rtt min/avg/max/mdev = 0.349/0.548/0.935/0.274 ms | ||
</pre><div class="userInput"><span class="prompt">[root@taco ~]# </span></div> | |||
</div> | |||
== Ping an IPv6 Address (scope global) == | |||
When a '''IPv6''' address is ''global'' in scope, it indicates that you will ''not'' need to specify the NIC when running commands. The following demonstrates how one can ''ping'' a '''IPv6''' address that has a ''global'' scope: | |||
<div class="screen"> | |||
<div class="screenTitle">Using '''ping6''' to ''ping'' a '''IPv6''' Address</div> | |||
<div class="userInput"><span class="prompt">[root@taco ~]# </span>ping6 -c 3 2001:db8:1:0:a00:27ff:feec:97c5</div> | |||
<pre class="computerOutput"> | |||
PING 2001:db8:1:0:a00:27ff:feec:97c5(2001:db8:1:0:a00:27ff:feec:97c5) 56 data bytes | |||
64 bytes from 2001:db8:1:0:a00:27ff:feec:97c5: icmp_seq=1 ttl=64 time=4.12 ms | |||
64 bytes from 2001:db8:1:0:a00:27ff:feec:97c5: icmp_seq=2 ttl=64 time=205 ms | |||
64 bytes from 2001:db8:1:0:a00:27ff:feec:97c5: icmp_seq=3 ttl=64 time=1.73 ms | |||
--- 2001:db8:1:0:a00:27ff:feec:97c5 ping statistics --- | |||
3 packets transmitted, 3 received, 0% packet loss, time 2004ms | |||
rtt min/avg/max/mdev = 1.731/70.369/205.254/95.383 ms | |||
</pre><div class="userInput"><span class="prompt">[root@taco ~]# </span></div> | |||
</div> | |||
= Router Advertisement Daemon for IPv6 ('''radvd''') = | |||
If you are on a network that has not been set up for '''IPv6''' support, it is likely that you will only find '''IPv6''' addresses which are limited in scope to: ''link''. | |||
<div class="screen"> | |||
<div class="screenTitle">Listing '''IPv6''' Address Before '''radvd'''</div> | |||
<div class="userInput"><span class="prompt">[root@taco ~]# </span>ip -6 addr show p2p1</div> | |||
<pre class="computerOutput"> | |||
2: p2p1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qlen 1000 | |||
inet6 fe80::a00:27ff:feec:97c5/64 scope link | |||
valid_lft forever preferred_lft forever | |||
</pre><div class="userInput"><span class="prompt">[root@taco ~]# </span></div> | |||
</div> | |||
It is difficult to work with '''IPv6''' addresses with a scope of: ''link''. To use these addresses you will need to specify the NIC along with the '''IPv6''' address when running commands (and not all commands support the option of specifying a interface). | |||
One easy method to assign global dynamic '''IPv6''' addresses to the machines on your network is to start the '''radvd''' service on your NST system: | |||
<div class="screen"> | |||
<div class="screenTitle">Starting '''radvd''' Service</div> | |||
<div class="userInput"><span class="prompt">[root@taco ~]# </span>systemctl start radvd</div> | |||
<pre class="computerOutput"> | |||
</pre><div class="userInput"><span class="prompt">[root@taco ~]# </span></div> | |||
</div> | |||
Once the '''radvd''' service has been started, all machines on the LAN will likely be assigned one or more dynamic '''IPv6''' addresses global in scope. | |||
<div class="screen"> | |||
<div class="screenTitle">Listing '''IPv6''' Address After '''radvd'''</div> | |||
<div class="userInput"><span class="prompt">[root@taco ~]# </span>ip -6 addr show p2p1</div> | |||
<pre class="computerOutput"> | |||
2: p2p1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qlen 1000 | |||
inet6 2002:c0a8:12c:1234:a00:27ff:feec:97c5/128 scope global dynamic | |||
valid_lft 292sec preferred_lft 292sec | |||
inet6 2001:db8:1:0:a00:27ff:feec:97c5/128 scope global dynamic | |||
valid_lft 86392sec preferred_lft 86392sec | |||
inet6 fe80::a00:27ff:feec:97c5/64 scope link | |||
valid_lft forever preferred_lft forever | |||
</pre><div class="userInput"><span class="prompt">[root@taco ~]# </span></div> | </pre><div class="userInput"><span class="prompt">[root@taco ~]# </span></div> | ||
</div> | </div> |
Latest revision as of 19:08, 4 February 2014
Resources
Internet Protocol version 6 (IPv6) resources:
- IPv6 - Wikipedia
- Information about IPv6 maintained at the Wikipedia web site.
Usage Notes
Determine IPv6 Address
Use the ifconfig command to show the IPv6 address associated with a particular interface (look for the line labeled: "inet6 addr:").
eth0 Link encap:Ethernet HWaddr 00:0C:29:C9:D5:1A inet addr:192.168.0.138 Bcast:192.168.0.255 Mask:255.255.255.0 inet6 addr: fe80::20c:29ff:fec9:d51a/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:1293164 errors:0 dropped:0 overruns:0 frame:0 TX packets:1878939 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:151619640 (144.5 MiB) TX bytes:642030150 (612.2 MiB) Interrupt:17 Base address:0x1400
In the above example, the IPv6 address is: "fe80::20c:29ff:fec9:d51a". The double colons (::) in the address represent 3 groupings of zeros. Hence, "fe80::20c:29ff:fec9:d51a" is the short hand equivalent of: "fe80:0:0:0:20c:29ff:fec9:d51a".
Ping an IPv6 Address (scope link)
The following demonstrates how one can ping a IPv6 address that has a limited link scope:
PING fe80::20c:29ff:fec9:d51a(fe80::20c:29ff:fec9:d51a) from fe80::20c:29ff:fec9:d51a eth0: 56 data bytes 64 bytes from fe80::20c:29ff:fec9:d51a: icmp_seq=1 ttl=64 time=0.361 ms 64 bytes from fe80::20c:29ff:fec9:d51a: icmp_seq=2 ttl=64 time=0.935 ms 64 bytes from fe80::20c:29ff:fec9:d51a: icmp_seq=3 ttl=64 time=0.349 ms --- fe80::20c:29ff:fec9:d51a ping statistics --- 3 packets transmitted, 3 received, 0% packet loss, time 2000ms rtt min/avg/max/mdev = 0.349/0.548/0.935/0.274 ms
Ping an IPv6 Address (scope global)
When a IPv6 address is global in scope, it indicates that you will not need to specify the NIC when running commands. The following demonstrates how one can ping a IPv6 address that has a global scope:
PING 2001:db8:1:0:a00:27ff:feec:97c5(2001:db8:1:0:a00:27ff:feec:97c5) 56 data bytes 64 bytes from 2001:db8:1:0:a00:27ff:feec:97c5: icmp_seq=1 ttl=64 time=4.12 ms 64 bytes from 2001:db8:1:0:a00:27ff:feec:97c5: icmp_seq=2 ttl=64 time=205 ms 64 bytes from 2001:db8:1:0:a00:27ff:feec:97c5: icmp_seq=3 ttl=64 time=1.73 ms --- 2001:db8:1:0:a00:27ff:feec:97c5 ping statistics --- 3 packets transmitted, 3 received, 0% packet loss, time 2004ms rtt min/avg/max/mdev = 1.731/70.369/205.254/95.383 ms
Router Advertisement Daemon for IPv6 (radvd)
If you are on a network that has not been set up for IPv6 support, it is likely that you will only find IPv6 addresses which are limited in scope to: link.
2: p2p1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qlen 1000 inet6 fe80::a00:27ff:feec:97c5/64 scope link valid_lft forever preferred_lft forever
It is difficult to work with IPv6 addresses with a scope of: link. To use these addresses you will need to specify the NIC along with the IPv6 address when running commands (and not all commands support the option of specifying a interface).
One easy method to assign global dynamic IPv6 addresses to the machines on your network is to start the radvd service on your NST system:
Once the radvd service has been started, all machines on the LAN will likely be assigned one or more dynamic IPv6 addresses global in scope.
2: p2p1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qlen 1000 inet6 2002:c0a8:12c:1234:a00:27ff:feec:97c5/128 scope global dynamic valid_lft 292sec preferred_lft 292sec inet6 2001:db8:1:0:a00:27ff:feec:97c5/128 scope global dynamic valid_lft 86392sec preferred_lft 86392sec inet6 fe80::a00:27ff:feec:97c5/64 scope link valid_lft forever preferred_lft forever