rip default-route
Use rip default-route to configure a RIP interface to advertise a default route with a specified metric.
Use undo rip default-route to disable a RIP interface from sending a default route.
Syntax
rip default-route { { only | originate } [ cost cost-value | route-policy route-policy-name ] * | no-originate }
undo rip default-route
Default
A RIP interface advertises a default route if the RIP process that the interface runs is enabled to advertise a default route.
Views
Interface view
Predefined user roles
network-admin
Parameters
only: Advertises only a default route.
originate: Advertises both a default route and other routes.
cost-value: Specifies a cost for the default route, in the range of 1 to 15. The default is 1.
route-policy route-policy-name: Specifies a routing policy by its name, a case sensitive string of 1 to 63 characters. If you specify this option, the command advertises a default route only when a route in the routing table matches the routing policy.
no-originate: Advertises only non-default routes.
Usage guidelines
An interface that is enabled to advertise a default route does not receive any default route from RIP neighbors.
Examples
# Configure VLAN-interface 10 to advertise only a default route with a metric of 2.
<Sysname> system-view [Sysname] interface vlan-interface 10 [Sysname-Vlan-interface10] rip default-route only cost 2
# Configure VLAN-interface 10 to advertise a default route with a metric of 2 and other routes.
<Sysname> system-view [Sysname] interface vlan-interface 10 [Sysname-Vlan-interface10] rip default-route originate cost 2
Related commands
default-route