Monday 7 October 2019

IPV6 Static Routes Configure on Cisco Router

IPV6 Static Routes Configure on Cisco Router

This article is about the IPV6 Static Routes Configure on Cisco Router. Static routes configuration with IPv6 address is almost similar to IPv4 static routing configuration on Cisco router. Static routes are simple way to configure routing,this link will help you understanding the difference between static & dynamic routing.
Static routes for IPv6 are configured with the ipv6 route global configuration command . The simplified version of the command syntax is shown below.
Router (config) # ipv6 route ipv6-prefix / ipv6-mask {ipv6-address | exit-intf}

IPV6 Static Routes Configure on Cisco Router
Syntax of the ipv6 route command.
ParameterDescription
ipv6-prefixAddress of the destination network of the remote network that will be added to the routing table
ipv6-prefixPrefix length of the remote network that will be added to the routing table
ipv6-address
  • Called the IP address of the router of the next hop.
  • Usually used for connection to a broadcast medium (ethernet) and usually create a recursive search.
exit-intf
  • Named static route directly connected.
  • Use the outbound interface to forward packets to the destination network.
  • It is usually used to connect in a point-to-point configuration.
Most of the parameters are identical to the IPv4 version of the command. An IPv6 static route can also be implemented as:

  • IPv6 standard static route
  • IPv6 default static route
  • IPv6 summary static route
  • IPv6 floating static route

As with IPv4, these routes can be configured as recursive, directly connected or fully specified.
The global ipv6 unicast-routing configuration command must be configured to enable the router to resend IPv6 packets.
R1 (config) # ipv6 unicast-routing

IPV6 NEXT HOP OPTIONS

Let's look at another example: Note in the code below, that each router has inputs only for directly connected networks and their associated local addresses. None of the routers have knowledge of the networks that are outside the directly connected interfaces.

R1 router routing table:
R1 # show ipv6 route 
 
<The result was omitted>

C 2001: DB8: ACAD: 1 :: / 64 [0/0]
 via GigabitEthernet0 / 0, directly connected
L 2001: DB8: ACAD: 1 :: 1/128 [0/0]
 via GigabitEthernet0 / 0, receive
C 2001: DB8: ACAD: 4 :: / 64 [0/0]
 via Serial0 / 0/0, directly connected
L 2001: DB8: ACAD: 4 :: 1/128 [0/0]
 via Serial0 / 0/0, receive
L FF00 :: / 8 [0/0]
 via Null0, receive
R1 #
Router table of router R2:
R2 # show ipv6 route

<The result was omitted>

C 2001: DB8: ACAD: 2 :: / 64 [0/0]
 via GigabitEthernet0 / 0, directly connected
L 2001: DB8: ACAD: 2 :: 1/128 [0/0]
 via GigabitEthernet0 / 0, receive
C 2001: DB8: ACAD: 4 :: / 64 [0/0]
 via Serial0 / 0/0, directly connected
L 2001: DB8: ACAD: 4 :: 2/128 [0/0]
 via Serial0 / 0/0, receive
C 2001: DB8: ACAD: 5 :: / 64 [0/0]
 via Serial0 / 0/1, directly connected
L 2001: DB8: ACAD: 5 :: 2/128 [0/0]
 via Serial0 / 0/1, receive
L FF00 :: / 8 [0/0]
 via Null0, receive
R2 #
R3 router routing table:
R3 # show ipv6 route

<The result was omitted>

C 2001: DB8: ACAD: 3 :: / 64 [0/0]
 via GigabitEthernet0 / 0, directly connected
L 2001: DB8: ACAD: 3 :: 1/128 [0/0]
 via GigabitEthernet0 / 0, receive
C 2001: DB8: ACAD: 5 :: / 64 [0/0]
 via Serial0 / 0/1, directly connected
L 2001: DB8: ACAD: 5 :: 1/128 [0/0]
 via Serial0 / 0/1, receive
L FF00 :: / 8 [0/0]
 via Null0, receive
R3 #
For example, R1 has no knowledge of networks:
  • 2001: DB8: ACAD: 2 :: / 64: LAN on R2
  • 2001: DB8: ACAD: 5 :: / 64: serial network between R2 and R3
  • 2001: DB8: ACAD: 3 :: / 64: LAN on R3
If we try to ping R1 through R2 we will see that it performs correctly.
R1 # ping ipv6 2001: DB8: ACAD: 4 :: 2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 2001: DB8: ACAD: 4 :: 2,
timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), 
round-trip min / avg / max = 12/30/96 ms
R1 #
Now, let's try a ping from R1 to the R3 LAN. Incorrect? This is because R1 does not have an entry in its routing table for the R3 LAN.
R1 # ping ipv6 2001: DB8: ACAD: 3 :: 1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 2001: DB8: ACAD: 3 :: 1, 
timeout is 2 seconds:

% No valid route for destination
Success rate is 0 percent (0/1)
R1 #
The next hop can be identified by an IPv6 address, an outgoing interface, or both. The way in which the destination is specified generates one of the following three types of route:
  • Next hop IPv6 static route : only the next jump IPv6 address is specified
  • IPv6 static route directly connected : only the router's output interface is specified
  • IPv6 static route fully specified : the IPv6 address of the next hop and the output interface are specified

Configuring A Static IPV6 Next HOP Route

On a static next hop route, only the IPv6 address of the next hop is specified. The output interface is derived from the next jump. Continuing with the previous example:

We will configure three static routes of next jump in R1:

R1 (config) # ipv6 route 2001: DB8: ACAD: 2 :: / 64 2001: DB8: ACAD: 4 :: 2
R1 (config) # ipv6 route 2001: DB8: ACAD: 5 :: / 64 2001: DB8: ACAD: 4 :: 2
R1 (config) # ipv6 route 2001: DB8: ACAD: 3 :: / 64 2001: DB8: ACAD: 4 :: 2

As with IPv4, before a router resends a packet, the routing table process must resolve the route to determine which output interface will be used to resend the packet. The route resolution process varies depending on the type of forwarding mechanism used by the router. CEF (Cisco Express Forwarding) is the default behavior on most platforms running IOS 12.0 or later.
Next, we detail the basic route resolution process for packet forwarding in the routing table for R1 without the use of CEF.

R1 # show ipv6 route
IPv6 Routing Table - default - 8 entries

 Codes:
 C - Connected, L - Local, S - Static,
 U - Per-user Static route 
 B - BGP, R - RIP, H - NHRP, I1 - ISIS L1 
 I2 - ISIS L2, IA - ISIS interarea, 
 IS - ISIS summary, D - EIGRP 
 EX - EIGRP external, ND - ND Default, 
 NDp - ND Prefix, DCE - Destination
 NDr - Redirect, O - OSPF Intra, OI - OSPF Inter, 
 OE1 - OSPF ext 1
 OE2 - OSPF ext 2, ON1 - OSPF NSSA ext 1, 
 ON2 - OSPF NSSA ext 2
 C 2001: DB8: ACAD: 1 :: / 64 [0/0]
 via GigabitEthernet0 / 0, directly connected
 L 2001: DB8: ACAD: 1 :: 1/128 [0/0]
 via GigabitEthernet0 / 0, receive
 S 2001: DB8: ACAD: 2 :: / 64 [1/0]
 via 2001: DB8: ACAD: 4 :: 2
 S 2001: DB8: ACAD: 3 :: / 64 [1/0] 
via 2001: DB8: ACAD: 4 :: 2 
C 2001: DB8: ACAD: 4 :: / 64 [0/0] 
via Serial0 / 0 / 0, directly connected
 L 2001: DB8: ACAD: 4 :: 1/128 [0/0]
 via Serial0 / 0/0, receive

<Omitted>
 
R1 #
When a packet is destined for the 2001 network: DB8: ACAD: 3 :: / 64, R1:
  1. Look for a match in the routing table and find that it must forward packets to the IPv6 2001 address : DB8: ACAD: 4 :: 2 of the next hop.
  2. R1 must determine how to reach the address 2001: DB8: ACAD: 4 :: 2. Therefore, look for a match a second time. In this case, the IPv6 address matches the route for the directly connected network 2001: DB8: ACAD: 4 :: / 64 with the Serial 0/0/0 output interface. This search informs the routing table process that this packet is forwarded outside that interface.
Therefore, in reality, two search processes are required in the routing table to forward any packet to the 2001 network: DB8: ACAD: 3 :: / 64. When the router has to perform multiple searches in the routing table before resending a packet, it performs a process known as recurring search .
A recursive IPv6 static route is valid (that is, it is a candidate to be added to the routing table) only when the next specified hop resolves to a valid output interface, either directly or indirectly.

CONFIGURING A STATIC IPV6 ROUTE DIRECTLY CONNECTED

When configuring a static route in point-to-point networks, an alternative to using the next hop IPv6 address is to specify the output interface. This is an alternative used in older IOS or whenever CEF is disabled, to avoid the problem of recursive searches. Continuing with the example:

Three static routes connected directly on R1 are configured through the output interface:
R1 (config) # ipv6 route 2001: DB8: ACAD: 2 :: / 64 s0 / 0/0
R1 (config) # ipv6 route 2001: DB8: ACAD: 5 :: / 64 s0 / 0/0
R1 (config) # ipv6 route 2001: DB8: ACAD: 3 :: / 64 s0 / 0/0
R1 (config) #
R1 #
The IPv6 routing table for R1 (below) shows that when a packet is destined for the 2001 network: DB8: ACAD: 3 :: / 64, R1 searches for a match in the routing table and finds that it can resend the packet from its serial interface 0/0/0. No other search is needed.
R1 # show ipv6 route
IPv6 Routing Table - default - 8 entries
Codes: C - Connected, L - Local, S - Static, U - Per-
user Static route
 B - BGP, R - RIP, I1 - ISIS L1, I2 - ISIS L2
 IA - ISIS interarea, IS - ISIS summary, D - 
EIGRP, EX - EIGRP external
 ND - ND Default, NDp - ND Prefix, DCE - 
Destination, NDr - Redirect
 O - OSPF Intra, OI - OSPF Inter, OE1 - OSPF ext 
1, OE2 - OSPF ext 2
 ON1 - OSPF NSSA ext 1, ON2 - OSPF NSSA ext 2
C 2001: DB8: ACAD: 1 :: / 64 [0/0]
 via GigabitEthernet0 / 0, directly connected
L 2001: DB8: ACAD: 1 :: 1/128 [0/0]
 via GigabitEthernet0 / 0, receive
S 2001: DB8: ACAD: 2 :: / 64 [1/0] 
via Serial0 / 
0/0 
, directly connected S 2001: DB8: ACAD: 3 :: / 64 [1/0] via Serial0 / 0/0, directly connected
C 2001: DB8: ACAD: 4 :: / 64 [0/0]
 via Serial0 / 0/0, directly connected
L 2001: DB8: ACAD: 4 :: 1/128 [0/0]
 via Serial0 / 0/0, receive
S 2001: DB8: ACAD: 5 :: / 64 [1/0] 
via Serial0 / 0/0, directly connected
L FF00 :: / 8 [0/0]
 via Null0, receive
R1 #
Note that the routing table looks different for the route configured with an output interface than for the route configured with a recursive entry.
The configuration of a static route directly connected to an output interface allows the routing table to solve this interface in a single search , not in two. Remember that with the use of the CEF forwarding mechanism, static routes with an outgoing interface are considered unnecessary. A single search is performed using a combination of the FIB and the adjacency table stored in the data plane.

CONFIGURING A FULLY SPECIFIED IPV6 STATIC ROUTE

A completely specified static route has both the output interface and the IPv6 address of the next hop. Similar to the fully specified static routes used with IPv4, this would be used if CEF was not enabled on the router and the output interface was in a multi-access network. With CEF, a static route that only uses an IPv6 address of the next hop would be the preferred method even when the outgoing interface is a multi-access network. Unlike IPv4, there is a situation in IPv6 that occurs when a completely specified static route must be used. If the static IPv6 route uses a link-local IPv6 address as the next hop address, a fully specified static route that includes the output interface must be used. The following image shows an example of a fully specified IPv6 static route that uses a link-local IPv6 address as the next hop address.
The reason why a completely specified static route should be used is that IPv6 link-local addresses are not included in the IPv6 routing table . Link-local addresses are only exclusive on a given network or link. The link-local address of the next hop can be a valid address on several networks connected to the router. Therefore, it is necessary that the output interface be included. Next, a completely specified static route is configured with the link-local address of R2 as the next hop address. Note that the IOS requires an output interface to be specified.
R1 (config) # ipv6 route 2001: db8: acad: 2 :: / 64 fe80 :: 2
 % Interface has to be specified for a link-local nexthop
R1 (config) # ipv6 route 2001: db8: acad: 2 :: / 64 s0 / 0/0 fe80 :: 2
Now, we show the IPv6 routing table entry for this route. Note that the link-local address of the next hop and the output interface are included.
R1 # show ipv6 route static | begin 2001: DB8: ACAD: 2 :: / 64
S 2001: DB8: ACAD: 2 :: / 64 [1/0]
 via FE80 :: 2, Serial0 / 0/0

IPV6 STATIC ROUTE VERIFICATION

In addition to the ping and traceroute commands, other useful commands to verify static routes are the following:
show ipv6 route
show ipv6 route static
show ipv6 route red
An example of the result generated by the show ipv6 route static command is shown below The result reflects the use of static routes with the global unicast addresses of the next hop.
R1 # show ipv6 route static
IPv6 Routing Table - default - 8 entries
Codes: C - Connected, L - Local, S - Static, U - Per-user Static route
 B - BGP, R - RIP, I1 - ISIS L1, I2 - ISIS L2
 IA - ISIS interarea, IS - ISIS summary, D - EIGRP, 
 EX - EIGRP external, ND - ND Default, NDp - ND Prefix, 
 DCE - Destination, NDr - Redirect, O - OSPF Intra,
 OI - OSPF Inter, OE1 - OSPF ext 1, OE2 - OSPF ext 2
 ON1 - OSPF NSSA ext 1, ON2 - OSPF NSSA ext 2
S 2001: DB8: ACAD: 2 :: / 64 [1/0]
 via 2001: DB8: ACAD: 4 :: 2
S 2001: DB8: ACAD: 3 :: / 64 [1/0]
 via 2001: DB8: ACAD: 4 :: 2
S 2001: DB8: ACAD: 5 :: / 64 [1/0]
 via 2001: DB8: ACAD: 4 :: 2
R1 #
More sample examples:
R1 # show ipv6 route 2001: 0DB8: ACAD: 3 ::
Routing entry for 2001: DB8: ACAD: 3 :: / 64
 Known via "static", distance 1, metric 0
 Route count is 1/1, share count 0
 Routing paths:
 2001: DB8: ACAD: 4 :: 2
 Last updated 00:19:11 Aug
R1 #
R1 # show running-config | section ipv6 route
ipv6 route 2001: DB8: ACAD: 2 :: / 64 2001: DB8: ACAD: 4 :: 2
ipv6 route 2001: DB8: ACAD: 3 :: / 64 2001: DB8: ACAD: 4 :: 2
ipv6 route 2001: DB8: ACAD: 5 :: / 64 2001: DB8: ACAD: 4 :: 2
R1 #

No comments:

Post a Comment