Configuration of Default Routes OSPF v2 and OSPFv3
OSPF can be configured in many ways. This section explains the propagation and Configuration of default routes in OSPFv2 and OSPFv3. You will learn how to configure default static route with OSPFConfigurationof a default static route in OSPFv2
With OSPF, the router connected to the Internet is used to propagate a default route to other routers in the OSPF routing domain. This router is sometimes called a perimeter, gateway or gateway router .However, in OSPF terminology, the router located between an OSPF routing domain and a non-OSPF network is also called an " autonomous system boundary router " (ASBR). configuration of OSPF Single area
In Image, R2 has a simple connection to a service provider. Therefore, all that is required for the R2 to reach the Internet is a default static route to the service provider.
Note : in this example, to simulate the connection to the service provider, a loopback interface with the IP address 209.165.200.225 is used.
OSPFv2 Default route settings
To propagate a default route, the perimeter router (R2) must be configured with the following:A default static route, using the ip route 0.0.0.0 0.0.0.0 {ip-address | interface-exit} .
The default-information originate command of the router configuration mode. This instructs R2 to be the source of the default route information and propagate the default static route in OSPF updates.
The following shows how to configure a completely specified default static route to the service provider.
R2 (config) # ip route 0.0.0.0 0.0.0.0 209.165.200.226
R2 (config) #
R2 (config) # router ospf 10
R2 (config-router) # default-information originate
R2 (config-router) # end
R2 #Verification of the propagated default route
Verify the default route configuration on R2 using the show ip route command , as shown in Image 2.In following images, it is verified that the default route has been propagated to R1 and R3. Note that the origin of the route is O * E2, which specifies that it was discovered by OSPF. The asterisk indicates that this route is a good candidate for the default route. The designation "E2" indicates that it is an external route.
External routes can be external type 1 or external type 2. The difference between both types is the way in which the cost (metric) of the route is calculated.
The cost of a type 2 route is always the external cost, regardless of the internal cost to reach that route. Type 1 cost is the sum of the external cost and the internal cost necessary to reach that route. For the same destination, a type 1 route is always preferred to a type 2 route.
Configuration of a default static route in OSPFv3
The propagation process of a default static route in OSPFv3 is almost identical to that of OSPFv2.In Image, R2 has a simple connection to a service provider. Therefore, all that is required for the R2 to reach the Internet is a default static route to the service provider.
Note : In this example, to simulate the connection to the service provider, a loopback interface with the IP address 2001: DB8: FEED: 1 :: 1/64 is used.
In following figure, the current IPv6 routing table of R1 is shown. Note that in this table there is no record that the route to the Internet is known.
OSPFv3 default route settings
To propagate a default route, the perimeter router (R2) must be configured with the following:A default static route, using the ipv6 route :: / 0 {ipv6-address | interface-exit} .
The command d efault-information originate from the router configuration mode. This instructs R2 to be the source of the default route information and propagate the default static route in OSPF updates.
Next, a completely specified default static route is configured to the service provider.
R2 (config) # ipv6 route :: / 0 2001: DB8: FEED: 1 :: 2
R2 (config) #
R2 (config) # ipv6 router ospf 10
R2 (config-rtr) # default-information originate
R2 (config-rtr) # end
R2 #
* Jan 10 11: 36: 21.995:% SYS-5-CONFIG_I: Configured from console by console
R2 #
Verification of the propagated IPv6 default route
Verify the default static route configuration on R2 using the show ipv6 route command, as shown in Image 7.In Images, it is verified that the default route has been propagated to R1 and R3. Note that the source of the route is OE2, which specifies that it was discovered using OSPFv3. The designation " E2 " indicates that it is an external route.
Unlike the IPv4 routing table, IPv6 does not use the asterisk to indicate that the route is a good candidate for the default route.
No comments:
Post a Comment