For routing protocols that decide which configured IP address identifies the device, such as OSPF and BGP4, an IP address that you apply under global configuration takes precedence.
Note
If you change the router ID, all current BGP4 sessions are cleared.device# configure terminal
device(config)# ip router-id 10.11.12.13
Note
You can specify an IP address that is also assigned to an interface on that device. But make sure that the router-ID IP address is not assigned on another network device.