Page 1 of 1
OSPF Router ID
Posted: Thu Feb 20, 2014 6:43 pm
by SoundGuyFYI
I can't seem to find any documentation on the Router ID properties. What does it affect within a OSPF link? what is its purposed? Does that IP get involved with the routing information? How is it different from the Address that the neighbor shows?
Any description would be helpful. Thanks!
Re: OSPF Router ID
Posted: Thu Feb 20, 2014 8:48 pm
by onnoossendrijver
See
http://en.wikipedia.org/wiki/Open_Shortest_Path_First
The router ID is a unique number that identifies the router. Although it can look like an IP address it is NOT. It is just a number.
The router ID is used in identifying the Designated Router.
Snippet from Wikipedia:
DR's exist for the purpose of reducing network traffic by providing a source for routing updates. The DR maintains a complete topology table of the network and sends the updates to the other routers via multicast. All routers in a multi-access network segment will form a slave/master relationship with the DR. They will form adjacencies with the DR and BDR only.
Re: OSPF Router ID
Posted: Thu Feb 20, 2014 10:50 pm
by CelticComms
The Router ID appears in all link state advertisements (LSAs) and allows routers to determine who originated the LSAs. A Router ID will be determined automatically if you don't set one but setting one manually gives you complete control and stops the Router ID changing. One common practice is to make the Router ID a distinct /32 IP number which is also attached to a loopback/bridge interface and then include that /32 address in the OSPF networks. An advantage of that approach is that the Router ID provides an IP which you can connect to.
Re: OSPF Router ID
Posted: Fri Aug 03, 2018 11:01 am
by Deantwo
The
https://wiki.mikrotik.com/wiki/Manual:OSPF-examples page suggests making a loopback interface and giving it the router-id as an IP-address.
Does the router-id have to exist as an IP-address on the router? If not then why can we configure the router-id at all?
I assume that if you define a value for the router-id it is used even if the IP-address doesn't exist on the router.
Setting a loopback interface is a very Cisco way of doing it, so I assume is it just if you want to leave the router-id property as "0.0.0.0" and control it as an IP-address like Cisco does it.
Would love it if that example guide was updated a little to say this.
Re: OSPF Router ID
Posted: Fri Aug 03, 2018 11:40 am
by mrz
Router id is just an administrative value. It can be anything and should not necessary be equal to any of IP addresses configured on the router. But keep in mind that it MUST be unique on every device in the network.
It is recommended to let OSPF to choose router id automatically (eliminate human error of not providing unique id) or use loopbacks for easier management.
Re: OSPF Router ID
Posted: Sat Aug 04, 2018 9:21 am
by JimmyNyholm
The Question have been answered but one could put it this way. Say this "number" is just a number. Sure it looks like an IP'adress. BUT for analogy think of it as a Color value. When routers have only few links this is what think and call SIMPLE OSPF network. the reson for this ID is not obvious. But When the network grows and you have multiple paths between Router RED and router BLUE then the reason gets more clear.
Hello I'm Red
Ohhh I see Blue on link 1
And I see Blue on link 2
And I see Blue on link 3
Higher up in the layer cake there is other protocols that need stable loopback. And if you dedicated some of your IPSpace for Loopback why not have that as your Router ID in all essence it is how you expect to talk, manage and reach the unit at all times independent on what links are currently active, and it makes documentation and problem solving easier.
Original Question, FOR OSPF It is just a number that looks like an IP Address Yes! Case Closed. But Depending on all things considered this could be a real IP on the Loopback and give you the stable peering on other protocol (Say BGP) when ospf is converging due to links failing or other reason.
This is ALL up to you and what you think on how fast things will grow.
Re: OSPF Router ID
Posted: Fri Aug 10, 2018 4:58 pm
by sri2007
The Question have been answered but one could put it this way. Say this "number" is just a number. Sure it looks like an IP'adress. BUT for analogy think of it as a Color value. When routers have only few links this is what think and call SIMPLE OSPF network. the reson for this ID is not obvious. But When the network grows and you have multiple paths between Router RED and router BLUE then the reason gets more clear.
Hello I'm Red
Ohhh I see Blue on link 1
And I see Blue on link 2
And I see Blue on link 3
Higher up in the layer cake there is other protocols that need stable loopback. And if you dedicated some of your IPSpace for Loopback why not have that as your Router ID in all essence it is how you expect to talk, manage and reach the unit at all times independent on what links are currently active, and it makes documentation and problem solving easier.
Original Question, FOR OSPF It is just a number that looks like an IP Address Yes! Case Closed. But Depending on all things considered this could be a real IP on the Loopback and give you the stable peering on other protocol (Say BGP) when ospf is converging due to links failing or other reason.
This is ALL up to you and what you think on how fast things will grow.
haha, yes that's true!
btw, for me the best way of setting this is by manually configuring some loopback address, just for management because it will allow me to understand easily the router who is sending the update, if you didn't do that and allow an automatic election for the router id, then it will choose the highest IP address configured at the loopback interface, and if there is no loopbacks, then the router will choose the highest IP address configured at any interface.