distance

Use this command to configure the administrative distance for RIP routes.

Syntax

distance weight
no distance [weight]

Parameters

weight Specifies an administrative distance for RIP routes. Valid values are 1-255.

Defaults

None.

Mode

RIP configuration command mode.

Usage

If several routes (coming from different protocols) are presented to the Route Table Manager (RTM), the protocol with the lowest administrative distance will be chosen for route installation. By default, RIP administrative distance is set to 120. The distance command can be used to change this value, resetting RIP‘s route preference in relation to other routes as shown in the table below.

Route Source Default Distance
Connected 0
Static 1
OSPF 110
RIP 120

The “no” form of this command resets RIP administrative distance to the default value of 120.

Example

This example shows how to change the default administrative distance for RIP to 150:

System(rw-config)->router rip
System(rw-config-rip)->distance 150