Pages

Sunday, January 9, 2011

Automatic IPv6 Tunnel 6to4

Automatic IPv6 Tunnel

This tunnel mode allows connecting IPv6 clouds with IPv4 network in the middle. Automatic IPv6 tunnel is point-to-multipoint nature. It automatically determines the destination address by using the combination between IPv6 prefix and border router IPv4 address. 

The example is in the diagram below. The IPv6 prefix in this case is 2002::/48. Border router ip address is converted to hexadecimal number in order to serve this purpose. C0:A8:0101 is a hexadecimal version of 192.168.1.1. Therefore, when combining the IPv6 prefix and the router address, the tunnel address will be 2002:C0A8:0101::/48. Using tunnel mode ipv6v4 6to4 to enable automatic ipv6 tunnel.

Note:  Automatic Tunnel 6to4 does not require the destination address for the tunnel interface

Example

Establish the 6to4 tunnel betwee R1 and R2 and configure the IGP to allow 2 separated IPv6 network to talk to each other. The configurations are as followings.


R1

interface Tunnel0
 no ip address
 no ip redirects
 ipv6 address 2002:C0A8:0101::1/40  
      // adjust ipv6 mask a bit in order to have both ipv6 address in the same network
 tunnel source FastEthernet0/0
 tunnel mode ipv6ip 6to4
!
interface FastEthernet0/0
 ip address 192.168.1.1 255.255.255.0
 duplex auto
 speed auto
!

ipv6 route 3001::/64 2002:C0A8:102::2


R2

interface Tunnel0
 no ip address
 no ip redirects
 ipv6 address 2002:C0A8:0102::2/40
 tunnel source FastEthernet0/0
 tunnel mode ipv6ip 6to4
!
interface FastEthernet0/0
 ip address 192.168.1.2 255.255.255.0
 duplex auto
 speed auto
!
ipv6 route 2001::/64 2002:C0A8:101::1

Verify configuration

R2#sh ipv6 route
IPv6 Routing Table - 6 entries
Codes: C - Connected, L - Local, S - Static, R - RIP, B - BGP
       U - Per-user Static route, M - MIPv6
       I1 - ISIS L1, I2 - ISIS L2, IA - ISIS interarea, IS - ISIS summary
       O - OSPF intra, OI - OSPF inter, OE1 - OSPF ext 1, OE2 - OSPF ext 2
       ON1 - OSPF NSSA ext 1, ON2 - OSPF NSSA ext 2
       D - EIGRP, EX - EIGRP external
S   2001::/64 [1/0]
     via 2002:C0A8:101::1
C   2002:C0A8:100::/40 [0/0]
     via ::, Tunnel0
L   2002:C0A8:102::2/128 [0/0]
     via ::, Tunnel0
C   3001::/64 [0/0]
     via ::, Loopback0
L   3001::1/128 [0/0]
     via ::, Loopback0
L   FF00::/8 [0/0]
     via ::, Null0
R2#

R2#ping 2001::1

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 2001::1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 168/221/248 ms
R2#

R1#ping 3001::1

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 3001::1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 152/208/256 ms
R1#

No comments:

Post a Comment