The default-route-advertise command configures IS-IS devices to generate default routes.
The undo default-route-advertise command disables IS-IS devices from generating default routes.
By default, IS-IS devices do not generate default routes.
default-route-advertise [ always | match default | route-policy route-policy-name ] [ cost cost | tag tag | [ level-1 | level-1-2 | level-2 ] ] * [ avoid-learning ]
undo default-route-advertise
Parameter | Description | Value |
---|---|---|
always | Configures an IS-IS device to unconditionally advertise default routes with itself as the next hop. | - |
match default | Advertises a default route through an LSP if the default route is generated by other routing protocols or other IS-IS processes in the routing table. If this default route is deleted from the routing table, it is not advertised through an LSP. | - |
route-policy route-policy-name | Specifies the name of a route-policy. A Level-1-2 device advertises default routes to the IS-IS routing domain only when there are external routes matching the route-policy in the routing table of the device. This prevents routing blackhole when link faults make some important external routes unavailable but default routes are still advertised. This route-policy does not affect external route import in IS-IS. | The name is a string of 1 to 40 case-sensitive characters, with spaces not supported. When double quotation marks are used around the string, spaces are allowed in the string. |
cost cost | Specifies the cost of default routes. | The value is an integer. The value range varies according to the cost style. When the cost style is narrow, narrow-compatible, or compatible, the value ranges from 0 to 63. When the cost style is wide or wide-compatible, the value ranges from 0 to 4261412864. |
tag tag | Specifies the tag value of advertised default routes. Advertised LSPs carry the tag value only when the IS-IS cost style is wide, wide-compatible, or compatible. | The value is an integer that ranges from 1 to 4294967295. |
level-1 | Sets the level of default routes to Level-1. If no level is specified, Level-2 default routes are generated by default. | - |
level-2 | Sets the level of default routes to Level-2. If no level is specified, Level-2 default routes are generated by default. | - |
level-1-2 | Sets the level of default routes to Level-1-2. If no level is specified, Level-2 default routes are generated by default. | - |
avoid-learning | Prevents an IS-IS process from learning default routes or adding them to the routing table. If existing default routes in the routing table are active, set the default route that needs to be added to the routing table to inactive. | - |
Usage Scenario
Configure a boundary router in the IS-IS domain to advertise default routes to the IS-IS domain.
Configure a boundary router in the IS-IS domain to import routes from the other routing domains to the IS-IS domain.
The first method is simpler, because the routers in the IS-IS domain do not need to learn routes imported form the other routing protocols.
Precautions
If always is configured on multiple devices within the same area, a routing loop may occur.
After this command is run on an IS-IS router, all traffic in an IS-IS domain will be forwarded by this IS-IS router to a destination outside the domain. Compared with configuring a static default route on each router in an IS-IS domain, running this command simplifies configurations, because this command only needs to be run on a boundary router in the IS-IS domain. In addition, you can specify different parameters to allow default routes to be advertised in different ways.
If this command is run on a Level-1 router, the router advertises default routes only to the Level-1 area.
Creating a route-policy before it is referenced is recommended. By default, nonexistent route-policies cannot be referenced using the command. If the route-policy nonexistent-config-check disable command is run in the system view and a nonexistent route-policy is referenced using the current command, an ABR advertises the default route to the IS-IS domain as long as the local routing table contains external routes.