Directly connected interface redistribution problem
I am using a config a little like the one below to import routes directed at interfaces into bird (by which I mean a /32 routed out of an interface with a static route) and then redistribute them into OSPF. The configuration in general works. If I a) start bird (assume an empty routing table) b) pause for several seconds / minutes c) add the interface d) add the /32 static route to the interface then all is well. If I omit step (b) above, then the route appears to get imported into the evrospf protocol (i.e. 'show protocols all evrospf' shows the same thing) but it never makes it to the OSPF peer (Quagga in this case). A "restart evrospf" fixes it. It /seems/ that if kernel routes are added whilst bird is starting up (or perhaps whilst the adjacency is being formed), then those changes are lost. Any ideas on this, or how to debug it further? I suppose I can work around it with a sleep(), but it is a bit arbitrary as I have no idea how long to sleep for. -- Alex Bligh # Import kernel routes. These come in with RTS_INHERIT protocol kernel evrkernel { persist; # Don't remove routes on bird shutdown scan time 10; # Scan kernel routing table every 20 seconds import all; export all; learn; # Learn all alien routes from the kernel } # This pseudo-protocol watches all interface up/down events. protocol device { scan time 10; # Scan interfaces every 10 seconds } # Import all directly connected routes. These come in with RTS_DEVICE protocol direct evrdirect { interface "-evrr-000000", "evrr-*"; export all; } protocol ospf evrospf { area 0.0.0.0 { interface "evrr-000000" { cost 20; priority 1; }; }; export filter { # RTS_INHERIT means routes from the kernel if net = 0.0.0.0/0 then reject; if (source = RTS_INHERIT) || (source = RTS_DEVICE) then { accept; } reject; }; }
On Wed, Sep 28, 2011 at 10:43:20PM +0100, Alex Bligh wrote:
I am using a config a little like the one below to import routes directed at interfaces into bird (by which I mean a /32 routed out of an interface with a static route) and then redistribute them into OSPF. The configuration in general works.
If I a) start bird (assume an empty routing table) b) pause for several seconds / minutes c) add the interface d) add the /32 static route to the interface
then all is well.
If I omit step (b) above, then the route appears to get imported into the evrospf protocol (i.e. 'show protocols all evrospf' shows the same thing) but it never makes it to the OSPF peer (Quagga in this case). A "restart evrospf" fixes it.
Could you send me outputs of 'show ospf state' and 'show ospf neighbors' with and without the problem? -- Elen sila lumenn' omentielvo Ondrej 'SanTiago' Zajicek (email: santiago@crfreenet.org) OpenPGP encrypted e-mails preferred (KeyID 0x11DEADC3, wwwkeys.pgp.net) "To err is human -- to blame it on a computer is even more so."
participants (2)
-
Alex Bligh -
Ondrej Zajicek