Nothing very complicated. We have here two routers, each with a LAN (here simulated by a loopback interface). The aim is to allow the LAN of R1 to communicate with the LAN of R2.
We will then have to define the IPv6 addressing of the interfaces, and then define the static routing on R1 and R2.
Configuring R1 interfaces:
Let's start by configuring the loopback interface that simulates the LAN of R1. Who will receive the first address of the network 2001: ABCD: 0001 :: / 48 ... i.e. 2001: ABCD: 0001: 0000: 0000: 0000: 0001 that can be written in abbreviated form 2001: ABCD: 1 :: 1
R1 (config) #interface loopback 0
R1 (config-if) #description LAN R1
R1 (config-if) # ipv6 address 2001: ABCD: 1 :: 1/48
Now configure the Serial 0/0 interface of R1 that binds it to R2. It will be configured according to the EUI-64 standard. This means that the last 64 bits of the IPv6 address will be automatically set. Just give the network address and specify the eui-64 format.
The last 64 bits are normally assigned according to the MAC address of an Ethernet interface, however, here we configure a serial interface which of course has no MAC address. The router will then complete the IPv6 address by using the MAC address of an Ethernet interface present on the router.
R1 (config) #interface serial 0/0
R1 (config-if) #clock rate 4000000
R1 (config-if) # ipv6 address 2001: ABCD:: / 48 eui-64
R1 (config-if) #no shutdown
Let's see the result...
R1 # show ipv6 serial interface 0/0
Serial0 / 0 is up, line protocol is down
IPv6 is enabled, link-local address is FE80 :: C200: AFF: FE78: 0 [TEN]
No Virtual link-local address (es):
Global unicast address (es):
2001: ABCD :: C200: AFF: FE78: 0 , subnet is 2001: ABCD :: / 48 [EUI / TEN]
Joined group address (es):
ICMP error messages limited to one every 100 milliseconds
ICMP redirects are enabled
ICMP unreachables are sent
ND DAD is enabled, number of DAD attempts: 1
ND reachable time is 30000 milliseconds
The interface now has the global IPv6 address 2001: ABCD :: C200: AFF: FE78: 0 ... remains to understand where it comes from. To do this, let's analyze the MAC address of the FastEthernet interface that the router used to generate the address in question ...
R1 # show interfaces fastEthernet 0/0 | Include Hardware
Hardware is Gt96k FE, address is c000.0a78.0000 (bia c000.0a78.0000)
Here's how the router dialed the address:
- The 64 first bits are defined by the network address, and if necessary supplemented by 0. Either: 2001: ABCD: 0000: 0000 ...... ..
- The last 64 bits are composed of the MAC address (borrowed from a FastEthernet interface), inserting the hexadecimal value FFFE in the middle of it to go from 48 bits (format of the MAC address) to the 64 bits required ... : 2001: ABCD: 0000: 0000: C000 : 0A FF : FE 78 :0000
- Last step, the 7th bit of the MAC address is set to 1, so we go from C000.0A78.0000 to C200.00A78.0000, which finally gives us the address 2001: ABCD: 0000: 0000: C200: 0AFF: FE78: 0000 which can be written more simply 2001: ABCD :: C200: AFF: FE78: 0
Now you have to configure R2 ...
Configuring R2:
R2 (config) #interface loopback 0
R2 (config-if) # ipv6 address 2001: ABCD: 2 :: 1/48
R2 (config) #interface serial 0/0
R2 (config-if) # ipv6 address 2001: ABCD :: / 48 eui-64
R2 (config-if) #no shutdown
Let's test the connectivity between R1 and R2 ...
For this we start by finding the IPv6 address of the serial interface of R2 ...
R2 # show ipv6 interface brief
FastEthernet0 / 0 [administratively down / down]
FE80 :: C201: AFF: FE78: 0
2001 :: ABCD C201: AFF: FE78: 0
FastEthernet0 / 1 [administratively down / down]
Serial0 / 1 [administratively down / down]
FE80 :: C201: AFF: FE78: 0
Let's now use the ping command in ipv6 to test that the link between R1 and R2 works ...
R1 # ping ipv6 2001: ABCD :: C201: AFF: FE78: 0
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 2001: ABCD :: C201: AFF: FE78: 0, timeout is 2 seconds:
Success rate is 100 percent (5/5), round-trip min / avg / max = 0/12/36 ms
OK, everything looks fine, let's move on to defining static routes.
Defining static routes:
In order for the LAN of R1 to communicate with the LAN of R2, we must define a route on R1 that indicates the next hop to reach the LAN of R2, ... and ... on R2 a route that indicates Next-hop to reach LAN of R1.
But first of all ... you need to enable IPv6 routing! Otherwise, the router would behave like a simple IPv6 machine, capable of sending or receiving traffic but not router!
On R1:
R1 (config) # ipv6 unicast-routing
R1 (config) # ipv6 route 2001: ABCD: 2 :: / 48 2001: ABCD :: C201: AFF: FE78: 0
On R2 :
R2 (config) # ipv6 unicast-routing
R2 (config) # ipv6 route 2001: ABCD: 1 :: / 48 2001: ABCD :: C200: AFF: FE78: 0
Verification:
Let's take a look at the R1 routing table
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
L 2001:ABCD::C200:AFF:FE78:0/128 [0/0]
L 2001:ABCD:1::1/128 [0/0]
via 2001:ABCD::C201:AFF:FE78:0
The road creates is present. Let's test connectivity, by launching an ipv6 ping, from the Loopback interface of R1 to the Loopback interface of R2.
Target IPv6 address: 2001: ABCD: 2 :: 1
Extended commands? [No]: yes
Source address or interface: 2001: ABCD: 1 :: 1
Include hop by hop option? [No]:
Include destination option? [No]:
Sweep range of sizes? [No]:
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 2001: ABCD: 2 :: 1, timeout is 2 seconds:
Packet feeds with a source address of 2001: ABCD: 1 :: 1
Success rate is 100 percent (5/5), round-trip min / avg / max = 0/10/40 ms
Everything seems to be in order!