08-19-2008 08:27 PM - edited 03-03-2019 11:12 PM
Hi,
Why is it necessary to create adjacency of OSPF neighbors on primary IPs only?
I have a ptp network type of OSPF & adjacencies cannot build on using secondary IPs. Is there any way around?
Thanks.
Solved! Go to Solution.
08-20-2008 04:05 AM
Farhan
I am a bit puzzled why you would configure a secondary address on a serial link and then want to form the OSPF adjacency on the secondary and not the primary. But that is a side issue to your primary question.
You ask a valid question and it deserves an answer about why OSPF will only form adjacency on the primary address. And the answer is that the router always uses the primary address as the source address in the hello packets. So if your router sends a hello packet with source address of the primary in subnet 10.0.0.0 to a router that wants to use the secondary in 10.0.0.4 then they are not in the same subnet and will not form adjacency.
HTH
Rick
08-19-2008 09:07 PM
Hi ,
Try using loopback interface / IP address for forming the neigbor.
You can advertise same , so that you would be able to ping the loopback for reachability.
08-19-2008 09:11 PM
Did this, but no help. Connectivity should be on primary IPs b/w routers, i read.
Any idea?
08-19-2008 09:39 PM
1.You define the loopback interfaces on both routers.
2.Assign IP addressses like 10.0.0.1 & 10.0.0.2
3.In ospf process these will become the router ID's.
4.Or you can use "router-id" command like
router-id 10.0.0.1
5.Advertise these loopback interface in ospf process
network 10.0.0.1 0.0.0.0 area 0
6.in "show ip ospf neigbors" you should find loopback ip addresses as neigbor, if your connectivity between 2 routers is OK.
08-19-2008 10:16 PM
Yes i did the same, but no luck. See the config & output:
R1
interface Loopback0
ip address 11.0.0.1 255.255.255.255
interface Serial1/0
ip address 10.0.0.5 255.255.255.252 secondary
ip address 10.0.0.1 255.255.255.252
ip ospf network point-to-point
router ospf 1
log-adjacency-changes
router-id 11.0.0.1
network 10.0.0.4 0.0.0.3 area 0
network 11.0.0.1 0.0.0.0 area 0
R2
interface Loopback0
ip address 11.0.0.2 255.255.255.255
interface Serial1/0
ip address 10.0.0.6 255.255.255.252
ip ospf network point-to-point
router ospf 1
router-id 11.0.0.2
log-adjacency-changes
network 10.0.0.4 0.0.0.3 area 0
network 11.0.0.2 0.0.0.0 area 0
On R1
sh ip ospf interface ser1/0
%OSPF: OSPF not enabled on Serial1/0
On R2
R2#sh ip ospf interface ser1/0
Serial1/0 is up, line protocol is up
Internet Address 10.0.0.6/30, Area 0
Process ID 1, Router ID 11.0.0.2, Network Type POINT_TO_POINT, Cost: 64
Transmit Delay is 1 sec, State POINT_TO_POINT,
Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5
oob-resync timeout 40
Hello due in 00:00:03
Index 1/1, flood queue length 0
Next 0x0(0)/0x0(0)
Last flood scan length is 0, maximum is 0
Last flood scan time is 0 msec, maximum is 0 msec
Neighbor Count is 0, Adjacent neighbor count is 0
Suppress hello for 0 neighbor(s)
If i change the ip R2 ser1/0 to 10.0.0.2 (i.e. connection with primary ip) then it works, else not. Why it is?
08-19-2008 10:45 PM
Hi,
OSPF adjancies are formed only on primary networks , not o nsecondary.So you need to use primary network in OSPF process.
Refer following link.
http://www.cisco.com/en/US/tech/tk365/technologies_tech_note09186a0080094050.shtml
HTH..
rate it if ur query is clear..
08-19-2008 10:47 PM
Yes Satish, I read this already & then come to discussion :)
The original question is y this is the behavior? even the reachability is there then what's the real theory.
Thanks anyway!
08-19-2008 11:04 PM
DADA......please advertise the secondry IP in the OSPF Network command then u can form the adjnecies.......
08-19-2008 11:25 PM
Dear!
secondary n/w is in the statement but not the primary one. And i don't want it to advertise (as there is no concern with the next router). There should be a theory behind this lack of feature, i want to know that.
08-20-2008 04:05 AM
Farhan
I am a bit puzzled why you would configure a secondary address on a serial link and then want to form the OSPF adjacency on the secondary and not the primary. But that is a side issue to your primary question.
You ask a valid question and it deserves an answer about why OSPF will only form adjacency on the primary address. And the answer is that the router always uses the primary address as the source address in the hello packets. So if your router sends a hello packet with source address of the primary in subnet 10.0.0.0 to a router that wants to use the secondary in 10.0.0.4 then they are not in the same subnet and will not form adjacency.
HTH
Rick
08-20-2008 07:58 PM
ahan, sounds good. Thanks dear.
Well, this was a scenario i built last week somewhere & got stuck while establishing an adjacency. I have a one port only for multiple purposes & .... a longggg issue.
This behavior surprised me but it is very simple & straight forward, but for me it was a new.
Thanks again.
08-21-2008 06:38 AM
Hi,
It's because OSPF will see the secondary networks as a stub networks. Hence, there will be no Hello sent on the second network. No Hello means no adjancencies can occur.
Regards,
Tomy
08-21-2008 09:28 AM
Farhan
Some people generalize from this issue and believe that OSPF does not work with secondary addresses. This is not the case. OSPF does not have a problem with secondary addresses, other than the fact that it will not establish adjacency on secondary addresses. If OSPF does establish adjacency and if there is a network statement for the secondary subnet(s) then OSPF will advertise them just fine and route to them just fine.
I am glad that my response did resolve your question. Thank you for using the rating system to indicate that your question was resolved (and thanks for the rating). It makes the forum more useful when people can read an issue and can know that there was a response which did resolve the issue.
The forum is an excellent place to learn about Cisco networking. I encourage you to continue your participation in the forum.
HTH
Rick
08-21-2008 10:17 PM
Thanks Rick. I am being part of many tech forums (Cisco, Juniper especially) as a query generator, but not participate in answering unfortunately.
Your active participation is highly appreciable. Keep it up. I'll try to be a part.
FJ
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide