filtering out OSPF default route?

Hi

I’m trying to stop a router from receiving a default route via OSPF…my syntax is as follows:

/routing filter
add action=discard chain=ospf-in comment=“” disabled=no invert-match=no prefix=0.0.0.0 protocol=ospf

But it does not work? What is the correct syntax

thanks

Fixed it:

Solution: 0.0.0.0/0 instead of 0.0.0.0

There is a better solution for this: set distribute-default=never

There are cases where you want to have a router distribute default routes to other routers, but you end up with a router on the network that already has a desirable default route.

Just keep in mind you could create routing loops (in some cases)..! Be carefull with filtering OSPF routes on some devices and not doing this on other boxes…

There is no need to filter default route in this case, too. Set distance lower than 110 to other default route and it will be active.