I would like to know how to redistribute /20 network subnetted and internally advertised by OSPF to BGP ?
I have tried to make a configuration but encountered problems in configuration. In fact, BGP works well and I can see more than 150000 routes injected externally.
I can also see a default gateway propagated by BGP but it seems that BGP cann’t “see” the internal OSPF network.
My configuration includes:
MT v2.9.9 + routing test package
BGP and OSPF installed on the same “edge” router (p4, 2.4Ghz, 512Mb)
4 x 10M/100M/1G ethernet cards - 2 for upstreams (“peer’s”) and 2 for a local network
I’ve tried to configure a BGP section as following:
. . .
redistribute-static: no
redistribute-connected: no
redistribute-rip: no
redistribute-ospf: yes
I have also added Null static route for the /20 prefix in the “ip route” section (created Null Bridge, assigned IP and defined a static route) but it seems a redistribution doesn’t work.
Does anybody have a solution how to filter out injected routes from BGP - just to advertise my prefix (x.y.z.w/20) ?
Just to understand the situation, do you want to advertise your /20 or your /20 and the rest of your highier prefixes from your OSPF Network?
One hint for the routing-test setup is. Make sure that you see an ACTIVE route (the one you created with your null interface.) in the “ip route” list this should include an “A” symbol wich denotes an Active route. Then you will actualy be able to advertise it.
Second hint for your /20 is that if you just want to advertise only that route (and should be, unless you are looking for a more complex setup) you just do the following in your BGP setings
redistribute-static: no
redistribute-connected: yes
redistribute-rip: no
redistribute-ospf: no
and create a filter to allow your /20 and deny the rest and apply it outgoing to your external links.
I want to advertise only my /20 network not higher prefixes from OSPF.
My /20 is subnetted and locally advertised through OSPF so I want to “summarize” all those subnets (on my ‘edge’ OSPF/BGP router) and advertise them as a ‘mynetwork/20’ to my BGP peers (upstreams). The only problem is dependant on ‘unused’ subnets so it was the reason why I tried with Null-bridge just to simply prevent routing loops as well as advertising itself. On my router I have 2 network adapters with installed and enabled BGP (two peers) and 2 of them with configured OSPF (connected to my internal network) with subnets from my /20 network.
briefly, the above mentioned scenario seems to work fine though I had to reinstall the basic routing package instead of (routing-test experiences some bugs during a OSPF configuration). “redistribute-ospf” works also well !
But, something weird occurs every time when I open “ip route” in my Winbox - CPU load goes to 100% … and MT also injects a little bit “uncontrollably” default gateways with “S” status - in my case about 10 0.0.0.0/0 routes have been installed … I couldn’t find a reason why it happens.
However, I’d like to thank you for your help so far.
D.