Community discussions

MikroTik App
 
User avatar
jprietove
Trainer
Trainer
Topic Author
Posts: 212
Joined: Fri Jun 03, 2016 3:00 pm
Location: Cádiz, Spain
Contact:

v7. OSPF adjacency problems when two neighbor has two different connections: one broadcast and one ptp

Wed May 18, 2022 12:40 pm

Hello, I've been testing OSPF in v7 and I think I've found a bug with adjacency establishment. I've configured the same scenario in GNS3 using x86 images of RouterOS with v.7.3beta40, v7.2.3 and v6.49.6. Results in v7 are not the expected. Results in v6 looks good.

The scenario is this:
Selección_1233.png
And the configuration in v7:
# Configuration for R1 in v7
/interface bridge
add name=loopback
/routing id
add id=10.255.255.1 name=id-ospf
/routing ospf instance
add disabled=no name=ospf-instance-1 router-id=id-ospf
/routing ospf area
add disabled=no instance=ospf-instance-1 name=backbone
/ip address
add address=10.255.255.1 interface=loopback network=10.255.255.1
add address=192.168.1.1/24 interface=ether1 network=192.168.1.0
/routing ospf interface-template
add area=backbone disabled=no networks=192.168.1.0/24
/system identity
set name=R1
For R2:
# Configuration for R2 in v7
/interface bridge
add name=loopback
/routing id
add id=10.255.255.2 name=id-ospf
/routing ospf instance
add disabled=no name=ospf-instance-1 router-id=id-ospf
/routing ospf area
add disabled=no instance=ospf-instance-1 name=backbone
/ip address
add address=10.255.255.2 interface=loopback network=10.255.255.2
add address=10.0.0.1/30 interface=ether2 network=10.0.0.0
add address=192.168.1.2/24 interface=ether1 network=192.168.1.0
/routing ospf interface-template
add area=backbone disabled=no networks=192.168.1.0/24
add area=backbone disabled=no networks=10.0.0.0/30 type=ptp
/system identity
set name=R2
For R3:
# Configuration for R3 in v7
/interface bridge
add name=loopback
/routing id
add id=10.255.255.2 name=id-ospf
/routing ospf instance
add disabled=no name=ospf-instance-1 router-id=id-ospf
/routing ospf area
add disabled=no instance=ospf-instance-1 name=backbone
/ip address
add address=10.255.255.3 interface=loopback network=10.255.255.3
add address=192.168.1.3/24 interface=ether1 network=192.168.1.0
add address=10.0.0.2/30 interface=ether2 network=10.0.0.0
/routing ospf interface-template
add area=backbone disabled=no networks=10.0.0.0/30 type=ptp
add area=backbone disabled=no networks=192.168.1.0/24
/system identity
set name=R3
In v7, routers are unable to get the adjacency. As an example, in v7.3beta40:
[admin@R2] > routing/ospf/neighbor/print 
Flags: V - virtual; D - dynamic 
 0  D instance=ospf-instance-1 area=backbone address=192.168.1.1 priority=128 
      router-id=10.255.255.1 dr=192.168.1.2 bdr=192.168.1.2 state="TwoWay" 
      state-changes=2 timeout=30s 

 1  D instance=ospf-instance-1 area=backbone address=192.168.1.3 priority=128 
      router-id=10.255.255.2 dr=192.168.1.2 bdr=192.168.1.2 state="ExStart" 
      state-changes=3 timeout=34s 

 2  D instance=ospf-instance-1 area=backbone address=10.0.0.2 
      router-id=10.255.255.2 state="ExStart" state-changes=3 timeout=34s 
[admin@R2] > 
But equivalent config in RouterOS v6 works well:
# Config for R2 in v6. Similar config for R1 and R3
/interface bridge
add name=loopback
/routing ospf instance
set [ find default=yes ] router-id=10.255.255.2
/ip address
add address=10.255.255.2 interface=loopback network=10.255.255.2
add address=10.0.0.1/30 interface=ether2 network=10.0.0.0
add address=192.168.1.2/24 interface=ether1 network=192.168.1.0
/routing ospf interface
add interface=ether2 network-type=point-to-point
/routing ospf network
add area=backbone network=192.168.1.0/24
add area=backbone network=10.0.0.0/30
/system identity
set name=R2
The adjacency can be established at OSPF Neighbors:
[admin@R2] > routing ospf neighbor print 
 0 instance=default router-id=10.255.255.3 address=192.168.1.3 interface=ether1 
   priority=1 dr-address=192.168.1.1 backup-dr-address=192.168.1.2 
   state="Full" state-changes=4 ls-retransmits=0 ls-requests=0 db-summaries=0 
   adjacency=15m50s 

 1 instance=default router-id=10.255.255.3 address=10.0.0.2 interface=ether2 
   priority=1 dr-address=0.0.0.0 backup-dr-address=0.0.0.0 state="Full" 
   state-changes=5 ls-retransmits=0 ls-requests=0 db-summaries=0 
   adjacency=16m3s 

 2 instance=default router-id=10.255.255.1 address=192.168.1.1 interface=ether1 
   priority=1 dr-address=192.168.1.1 backup-dr-address=192.168.1.2 
   state="Full" state-changes=5 ls-retransmits=0 ls-requests=0 db-summaries=0 
   adjacency=16m10s 
[admin@R2] > 
I'm going to write to support but it would be nice if someone can test it or just check it is not my mistake.
You do not have the required permissions to view the files attached to this post.
 
User avatar
jprietove
Trainer
Trainer
Topic Author
Posts: 212
Joined: Fri Jun 03, 2016 3:00 pm
Location: Cádiz, Spain
Contact:

Re: v7. OSPF adjacency problems when two neighbor has two different connections: one broadcast and one ptp  [SOLVED]

Thu May 19, 2022 11:39 am

I finally found it was my mistake. R3 and R2 was assigned the same ID. When corrected, everything work as expected.

Who is online

Users browsing this forum: No registered users and 12 guests