Date: Mon, 25 May 2009 10:06:53 GMT From: Stanislav Svirid <count@211.ru> To: freebsd-gnats-submit@FreeBSD.org Subject: kern/134931: [route] [fib] Route messages sent to all socket listeners regardless of setfib Message-ID: <200905251006.n4PA6rxE094638@www.freebsd.org> Resent-Message-ID: <200905251010.n4PAA1AT045339@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 134931 >Category: kern >Synopsis: [route] [fib] Route messages sent to all socket listeners regardless of setfib >Confidential: no >Severity: serious >Priority: medium >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Mon May 25 10:10:01 UTC 2009 >Closed-Date: >Last-Modified: >Originator: Stanislav Svirid >Release: FreeBSD vrf01.211.ru 7.2-RELEASE FreeBSD 7.2-RELEASE #3: Wed May 20 14:24:58 NOVST 2009 root@vrf01.211.ru:/usr/obj/usr/src/sys/VRFSPLITER amd64 >Organization: >Environment: FreeBSD vrf01.211.ru 7.2-RELEASE FreeBSD 7.2-RELEASE #3: Wed May 20 14:24:58 NOVST 2009 root@vrf01.211.ru:/usr/obj/usr/src/sys/VRFSPLITER amd64 >Description: I have one router with 2 quagga running with different setfib. First without setfib (0 i sdefault), second with setfib 1. When quagga receive route from OSPF/BGP its install it into kernel. Route installed in right FIB. When route installed in FIB, kernel sends message into route socket. Quagga listen routing socket and see ADD message and add route into internal tables as 'Kernel'. For example, quagga1# sh ip route 10.0.5.0 Routing entry for 10.0.5.0/24 Known via "kernel", distance 0, metric 0, best * 89.189.190.185, via inet Quagga1 see route as 'kernel', but there are no route in kernel default rt. root@vrf01 ttyp4:~#netstat -rn | grep 10.0.5 root@vrf01 ttyp4:~# But in FIB 1 route is present: root@vrf01 ttyp4:~#setfib 1 netstat -rn | grep 10.0.5 10.0.5.0/24 89.189.190.185 UG1 0 0 inet root@vrf01 ttyp4:~# I think the problem is in listening routing socket, because 'route -n monitor' see all routing events regardless of setfib. Experiment: Run: root@vrf01 ttyp4:~#setfib 1 route -n monitor than in another session add route '192.168.0.0/24 via 127.0.0.1' root@vrf01 ttyp5:~#route add 192.168.0.0/24 127.0.0.1 add net 192.168.0.0: gateway 127.0.0.1 And see, in "monitor" session appears: got message of size 192 on Mon May 25 16:58:39 2009 RTM_ADD: Add Route: len 192, pid: 24923, seq 1, errno 0, flags:<UP,GATEWAY,DONE,STATIC> locks: inits: sockaddrs: <DST,GATEWAY,NETMASK> 192.168.0.0 127.0.0.1 (0) 0 ffff ff I think it's wrong, when route see messages from another fib ;) >How-To-Repeat: You must have compiled kernel with more than 1 FIB. options ROUTETABLES=2 buildkernel; install; reload. In one session run: setfib 1 route -n monitor In another add route, for example: route add 192.168.0.0/24 127.0.0.1 In monitor session you must see something like this: got message of size 192 on Mon May 25 16:58:39 2009 RTM_ADD: Add Route: len 192, pid: 24923, seq 1, errno 0, flags:<UP,GATEWAY,DONE,STATIC> locks: inits: sockaddrs: <DST,GATEWAY,NETMASK> 192.168.0.0 127.0.0.1 (0) 0 ffff ff And its wrong ;) >Fix: >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200905251006.n4PA6rxE094638>