The router ID, a 32-bit number, uniquely identifies the router within an autonomous system (AS) (see Autonomous systems). In protocols such as OSPF, routing information is exchanged between areas—groups of networks that share routing information. It can be set to be the same as the loopback address. The router ID is used by both OSPF and BGP routing protocols in the routing table manager instance.
There are several ways to obtain the router ID. On each router, the router ID can be obtained in the following ways.
Define the value in the config>router router-id context. The value becomes the router ID.
Configure the system interface with an IP address in the config>router>interface ip-int-name context. If the router ID is not manually configured in the config>router router-id context, the system interface acts as the router ID.
If neither the system interface or router ID are implicitly specified, the router ID is inherited from the last four bytes of the MAC address.
The router can be obtained from the protocol level; for example, BGP.