OSPF area range doesn't seem to do anything.

I’m not sure if I found a bug in my thinking or RouterOS, but I can’t seem to get OSPF to work the way I think it should.

I have a PPPOE server that uses static ip addresses from radius, static networks from radius, and a local dynamic pool. I would like to originate the static ip addresses, the static networks, and the entire block of dynamic addresses.

By default the routeros originates every /32 address assigned to a pppoe interface when “/routing ospf instance set 0 redistribute-connected=as-type-1” is set, and originates the static netblocks from radius when “/routing ospf instance set 0 redistribute-static=as-type-1” is set. So far so good.

The problem is I can’t get it to summarize the dynamic pool and stop originating each pppoe dynamic address as a /32. I see this article: http://wiki.mikrotik.com/wiki/OSPF_and_Area_summaries and it shows that you need to define the dynamic pool as an ospf area network like this:

(public changed to 111.111.111.250, pool changed to 111.111.112.32/27, and some filters added to not originate private ip space in the routing table)

/routing ospf area
add area-id=1.1.1.1 name=pppoepool
/routing ospf instance
set [ find default=yes ] redistribute-connected=as-type-1 redistribute-static=as-type-1 router-id=111.111.111.250
/routing filter
add action=discard chain=ospf-out prefix=172.16.0.0/12
add action=discard chain=ospf-out prefix=192.168.0.0/16
/routing ospf network
add area=backbone comment="public interface" network=111.111.111.250/28
add area=pppoepool network=111.111.112.32/27

This does effectively stop routeros from originating /32 addresses from the dynamic pool as the pool is part of the area network, but when I add:

/routing ospf area range
add area=pppoepool range=111.111.112.32/27

Nothing happens. Shouldn’t I see it originate 111.111.112.32/27 now? This command doesn’t see to do anything.

Furthermore, this config causes routeros to bind ospf to pppoe interfaces which isn’t what I want. So I’m forced to filter ospf in the OUTPUT chain in the firewall.

How I would expect this to work is something like this:

/routing ospf instance
set [ find default=yes ] redistribute-connected=as-type-1 redistribute-static=as-type-1 router-id=111.111.111.250
/routing filter
add action=discard chain=ospf-out prefix=172.16.0.0/12
add action=discard chain=ospf-out prefix=192.168.0.0/16
/routing ospf network
add area=backbone comment="public interface" network=111.111.111.250/28
/routing ospf area range
add area=backbone range=111.111.112.32/27 advertise=yes

That only binds ospf to the public interface, avoids needing another area, and adds an additional summary so that the dynamic pool is originated as a complete /27 instead of each /32.

Why can’t I do it this way? And why does /routing ospf area range seem to be ignored? I can set it to advertise=yes then advertise=no and back and forth and it makes no difference to what ospf originates.

Take a look at this old thread discussion…

http://forum.mikrotik.com/t/ospf-and-pppoe-nightmare/10849/8


Make note of the … ’ pppoe server needs to be in it’s own ABR and not backbone ’ for route summary to work.