On Thu, Aug 02, 2012 at 08:56:40PM +0200, Amadeus wrote:
Hello list,
is there any best practise to advertise static routes when interface names change? I have many ppp uplinks running on a server (ppp0, ppp1, ppp2 etc.) with static routes on them which I configure like this:
protocol static { route 10.0.0.0/28 via 169.254.0.1; route 10.0.0.1/28 via 169.254.0.1; route 10.0.0.2/28 via 169.254.0.2; }
On startup, bird recognizes perfectly which interface they belong to but if ppp reconnects, the interface name may change and so does the routing information - so it has to be updated by bird, is that any possible? All I can do right now is "check link on" so routes will disappear at least when interfaces go down. There is no 'scan' option for static routes as far as I understand the documentation, or can this be done any differently?
Hello Static routes depends on 'via' IP address, not on iface names. If there is interface which makes that IP available. I don't have experience with PPP uplink servers, but i guess that when the connection disappears, IP is removed, and when the client reconnects, appropriate IP get assigned to that ppp iface. If PPP works like that, you don't need anything more (even 'check link on' is unnecessary). If client with 10.0.0.0/28 disconnects, 169.254.0.1 would be unaccessible and static protocol removes 10.0.0.0/28 (and 10.0.0.1/28), if that client reconnects, 169.254.0.1 would become accessible and route should reappear (with possibly different iface). At least that should work in theory, unless there are some bugs. -- 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."