IPv6 tunneling - IPv6IP
This is a pretty simple and straightforward manual method of tunneling IPv6 packets over an IPv4 network. IP protocol type 41 is used to tell the router that the packet inside of the IP packet is and IPv6 packet.
Here is the network:
[R1]---[R2]---[R3]---[R4]
R1-R2: IPv6 network 2002:1:0:12::/64
R2-R3: IPv4 network 172.12.23.0/24
R3-R4: IPv6 network 2002:1:0:34::/64
Make sure you enable ipv6 unicast routing on R2 and R3:
R2(config)#ipv6 unicast-routing
R3(config)#ipv6 unicast-routing
Let's create the tunnels:
R2(config)#int tunnel 0
R2(config-if)#ipv6 address 2002:1:0:23::2/64
R2(config-if)#tunnel source 172.12.23.2
R2(config-if)#tunnel destination 172.12.23.3
R2(config-if)#tunnel mode ipv6ip
R3(config)#int tun 0
R3(config-if)#ipv6 address 2002:1:0:23::3/64
R3(config-if)#tunnel source 172.12.23.3
R3(config-if)#tunnel destination 172.12.23.2
R3(config-if)#tunnel mode ipv6ip
Next we need tell the router when to use the tunnel by making some static routes. The following route tells R2 that whenever a packet comes in destined for the R3-R4 network, encapsulate it in IP and tunnel it to the tunnel destination, R3 in this case. The second route does the opposite on R3.
R2(config)#ipv6 route 2002:1:0:34::/64 tunnel 0
R3(config)#ipv6 route 2002:1:0:12::/64 tunnel 0
Let's verify:
R1#ping 2002:1:0:34::4
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 2002:1:0:34::4, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 56/76/124 ms
This is a pretty simple and straightforward manual method of tunneling IPv6 packets over an IPv4 network. IP protocol type 41 is used to tell the router that the packet inside of the IP packet is and IPv6 packet.
Here is the network:
[R1]---[R2]---[R3]---[R4]
R1-R2: IPv6 network 2002:1:0:12::/64
R2-R3: IPv4 network 172.12.23.0/24
R3-R4: IPv6 network 2002:1:0:34::/64
Make sure you enable ipv6 unicast routing on R2 and R3:
R2(config)#ipv6 unicast-routing
R3(config)#ipv6 unicast-routing
Let's create the tunnels:
R2(config)#int tunnel 0
R2(config-if)#ipv6 address 2002:1:0:23::2/64
R2(config-if)#tunnel source 172.12.23.2
R2(config-if)#tunnel destination 172.12.23.3
R2(config-if)#tunnel mode ipv6ip
R3(config)#int tun 0
R3(config-if)#ipv6 address 2002:1:0:23::3/64
R3(config-if)#tunnel source 172.12.23.3
R3(config-if)#tunnel destination 172.12.23.2
R3(config-if)#tunnel mode ipv6ip
Next we need tell the router when to use the tunnel by making some static routes. The following route tells R2 that whenever a packet comes in destined for the R3-R4 network, encapsulate it in IP and tunnel it to the tunnel destination, R3 in this case. The second route does the opposite on R3.
R2(config)#ipv6 route 2002:1:0:34::/64 tunnel 0
R3(config)#ipv6 route 2002:1:0:12::/64 tunnel 0
Let's verify:
R1#ping 2002:1:0:34::4
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 2002:1:0:34::4, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 56/76/124 ms
Comment