ip router-id

Changes the router ID that is already in configured.

Syntax

ip router-id A.B.C.D
no ip router-id A.B.C.D

Parameters

A.B.C.D
Specifies the IPv4 address that you want as the router ID.

Modes

Global configuration mode

VRF configuration mode

Usage Guidelines

Though a device has IP addresses assigned to various interfaces, some routing protocols identify the device by the router ID rather than the IP addresses assigned to the interfaces connected by the protocol.

The no form of the command removes the configured router ID and restores the default router ID.

Examples

The following example specifies the router ID as 192.158.1.2.

device# configure terminal
device(config)# ip router-id 192.158.1.2