[Olsr-users] OLSR bug on OpenBSD

Markus Kittenberger (spam-protected)
Thu Nov 17 01:47:44 CET 2011


hmm i think i found the bug, and added a ugly bugfix right on your
testsystem
(in /usr/ports/net/olsrd/work/olsrd-0.6.2/)
and did an gmake & gmake install afterwards

infact the bug is not even really in the bsd specific code,.. #1
(but i added (beside many debugoutput on stderr) a fix/workaround there,
until i decided how to really fix this,..)

please test if it really works now,

Markus

#1 it seems that (os_unspecific) olsr_rt_flags() function does not
correctly set the GATEWAY flag,... (it comes to different conslusion if a
route gets deleted as if its added *G)

and as the bsd code not only passes this flag to the kernel (where a wrong
flag would be bad anyways)
but also checks for this flag itself, to decide whether it includes the
gateway ip to the routing socket message or not, it fails to delete the
route,..

as afair the linux specific routing code of olsrd evaluates itself if there
is a gateway, and towards kernel anyways always set RTA_GATEWAY routing
flag (at least since ON_LINK)
so it is not affected by this bug of the olsr_rt_flags() function,..

On Wed, Nov 16, 2011 at 12:10 AM, Michel Blais <(spam-protected)>wrote:

> Hi Markus,
>
> I build a small network with
> 3 OLSR v0.6.1 on OpenWRT (paquage from opkg install)
> 1 OLSR v0.6.1 on FreeBSD 8.2 (paquagee from freebsd install with pkg_add
> -r)
>
> I saw those errors on the FreeBSD with -nofork
>
> Cannot write to routing socket: (rtm_errno= 0x0) (last error message: No
> such process)
>  Failed on Deleting 10.255.255.102/32 via 10.255.255.101
>
> Cannot write to routing socket: (rtm_errno= 0x0) (last error message: No
> such process)
>  Failed on Deleting 10.255.255.103/32 via 10.255.255.102
>
> Cannot write to routing socket: (rtm_errno= 0x0) (last error message: No
> such process)
>  Failed on Deleting 10.255.255.101/32 via 10.255.255.103
>
> If I look at the routing table
>
> olsrtestfbsd# netstat -r
> Routing tables
>
> Internet:
> Destination        Gateway            Flags    Refs      Use  Netif Expire
> 10.255.255.0       link#3             U           1        0    em0
> olsrtestfbsd       10.255.255.103     UGH         0        0    em0 =>
> 10.255.255.101/32  00:30:18:a0:f5:35  U           0        0    em0
> 10.255.255.102     10.255.255.103     UGH         0        0    em0 =>
> 10.255.255.102/32  00:30:18:a0:f5:35  U           0        0    em0
> 10.255.255.103     10.255.255.102     UGH         0        0    em0 =>
> 10.255.255.103/32  00:30:18:a0:f5:35  U           0        0    em0
> 10.255.255.201     link#3             UHS         0        0    lo0
> localhost          link#7             UH          0        2    lo0
> 192.168.3.0        link#1             U           1     1336    re0
> 192.168.3.223      link#1             UHS         0        0    lo0
>
> If I look at http_info :
>
> Destination    Gateway    Metric    ETX    Interface
> 10.255.255.101    10.255.255.101    1    1.000    em0
> 10.255.255.102    10.255.255.102    1    1.000    em0
> 10.255.255.103    10.255.255.103    1    1.000    em0
>
> So the same error happen on FreeBSD. I will try to check if older version
> can be install with pkg_add or build them.
>
> I could give acces tomorrow to the FreeBSD if somebody want to test it.
>
> Michel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.olsr.org/pipermail/olsr-users/attachments/20111117/b2b7c5a1/attachment.html>


More information about the Olsr-users mailing list