[Olsr-dev] Patch for dyn_gw plugin

Sven-Ola Tuecke (spam-protected)
Wed Feb 3 18:20:37 CET 2010


Hey,

a new daemon for BRDP will blurb up size and may not be a practical solution 
in a mesh network. That also sounds like some extra work - I have only a 
limited time to spare currently. You may be interested on my approach, coded 
for a small firmware project of mine a couple of years ago. That beast is 
located here:
 
http://ff-firmware.cvs.sourceforge.net/viewvc/ff-firmware/ff-devel/freifunk-olsrd/usr/sbin/cron.minutely?view=markup

Strategy (every minute):

traceroute to one-of-root-dns (max 4 hops)
if (two times fail) {
  remove default route (from table main)
  put default route (in table 'local only')
}
elsif (two times succeed) {
  remove default route (from table 'local only')
  put default route (to table main)
}

Traceroute is part of busybox, hence no binary overhead. The dyn_gw_plain 
monitors only main routing table and announces HNA based on that. 
dyn_gw_plain does not need libpthread - saves more space. Traceroute uses UDP 
(some gateway owners tend to block that which is non-inet IMO).

There are some pitfalls, e.g. "ip rule add from ip" does not work with a 
changeing DSL-IP when pppoe reconnects. So I've used "ip rule add iif lo" 
which means "rule for local iface". That in turn requires "ip route add 
throw" to the background table otherwise completely everything will go to  
default. Ah yes - theres a really ugly RTFM out there, google for "LARTC".

HTH,
// Sven-Ola

Am Mittwoch 03 Februar 2010 17:39:26 schrieben Sie:
> Hi Sven-Ola,
>
> I had some thoughts on the policy routing beast.
> How to check inet when not sure if it works, and
> use another node inet link for user traffic?
>
> I played with host routes to test inet nodes.
> But I think this all is dangerous, what happens if
> inet test node is renumbered or disappeared?
>
> Some nodes will stay for a moment, e.g. Google DNS
> (8.8.8.8). But what if icmp echo filter or rate limit?
>
> I am interested in the new tunnel mechanism. Then, the border
> router is selected by ingress manet router, not by the
> hop-by-hop routers in the path.
>
> And a better approach: border router discovery protocol,
> I've written an Internet draft. Mostly IPv6, IPv4
> support is doable with short lived DHCP leases.
> Links:
> http://www.inf-net.nl/brdp.html
> Interested?
>
> Regards, Teco




More information about the Olsr-dev mailing list