<div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div>Dear Babe-users,</div><div><br></div><div>I have a problem with redistribution default route and any static routes in Babel .</div><div>I have two boxes with OpenWrt and Babel each. I am using pure Babel, no Frr. Box1 has connection to Internet via wan interface and 5Ghz Wi-Fi Ad-Hoc  connection to Box2  Babel working on this Wi-Fi link. Wi-Fi link has ip192.168.4.1 and 192.168.4.2, ping are ok. Box1 need to redistribute default route and specified static routes to Box 2.  All routing and redistribution configuration done according to instructions from  <a href="https://github.com/jech/babeld">https://github.com/jech/babeld</a> and <a href="https://alioth-lists.debian.net/pipermail/babel-users/2008-March/000074.html">https://alioth-lists.debian.net/pipermail/babel-users/2008-March/000074.html</a></div><div>But redistribution still not working. If someone can help me to understand what I am doing wrong and where is mistake I will be very thankful. </div><div>The configuration files,routing tables and  Babel logs for Box1 and Box2 below.. </div><div><br></div><div>Box1 </div><div>ip route show all</div><div>root@OpenWrt:/# ip route show all<br>default via 192.168.2.1 dev eth0.2 proto static<br><a href="http://8.0.0.0/8">8.0.0.0/8</a> via 192.168.2.1 dev eth0.2 proto static<br><a href="http://192.168.1.0/24">192.168.1.0/24</a> dev br-lan proto kernel scope link src 192.168.1.1<br>192.168.1.2 via 192.168.4.2 dev wlan0 proto babel onlink<br><a href="http://192.168.2.0/24">192.168.2.0/24</a> dev eth0.2 proto kernel scope link src 192.168.2.2<br><a href="http://192.168.4.0/24">192.168.4.0/24</a> dev wlan0 proto kernel scope link src 192.168.4.1<br>192.168.4.2 via 192.168.4.2 dev wlan0 proto babel onlink<br>root@OpenWrt:/#</div><div><br></div><div>Box1<br></div><div>root@OpenWrt:/# route<br>Kernel IP routing table<br>Destination     Gateway         Genmask         Flags Metric Ref    Use Iface<br>default         192.168.2.1     0.0.0.0         UG    0      0        0 eth0.2<br>8.0.0.0         192.168.2.1     255.0.0.0       UG    0      0        0 eth0.2<br>192.168.1.0     *               255.255.255.0   U     0      0        0 br-lan<br>192.168.1.2     192.168.4.2     255.255.255.255 UGH   0      0        0 wlan0<br>192.168.2.0     *               255.255.255.0   U     0      0        0 eth0.2<br>192.168.4.0     *               255.255.255.0   U     0      0        0 wlan0<br>192.168.4.2     192.168.4.2     255.255.255.255 UGH   0      0        0 wlan0<br>root@OpenWrt:/#<br></div><div><br></div><div>Box1 Babel config</div><div>package babeld</div><div># Babeld reads options from the following files (the last one takes precedence<br># if an option is defined in several places):<br># - the file defined by the option conf_file (default: /etc/babeld.conf),<br># - *.conf files in the directory defined by conf_dir (default: /tmp/babel.d/),<br># - this UCI configuration file.</div><div># See "man babeld" for all available options ("Global options").<br># Important: remember to use '_' instead of '-' in option names.<br>config general<br>        # option 'random_id' 'true'<br>         option 'debug' '1'<br>        # option 'local_port' '33123'<br>         option 'log_file' '/var/log/babeld.log'<br>        ## Enable ipv6-subtrees by default since OpenWrt should ship with a<br>        ## recent enough kernel for it to work.<br>        option 'ipv6_subtrees' 'true'<br>         list 'import_table' '42'<br>         list 'import_table' '100'<br>        list 'import_table' '3'<br>         ## Alternative configuration file and directory.<br>        ## See comment at the top of this file for more details.<br>        # option 'conf_file' '/c/babeld.conf'<br>        # option 'conf_dir' '/tmp/babel.d/'</div><div>config interface<br>        ## Remove this line to enable babeld on this interface<br>        option 'ignore' 'true'<br>        ## You can use aliases (like lan, wlan) or real names (like eth0.0).<br>        ## If you use an alias, it must be already defined when babeld starts.<br>        ## Otherwise, the name is taken literally and the interface can be<br>        ## brought up later (useful for tunnels for instance).<br>        option 'ifname' 'wlan'<br>        ## You can set options, see babeld man page ("Interface configuration")<br>        # option 'rxcost' '256'<br>        # option 'hello_interval' '1'</div><div>config interface Wlan1<br>        ## Physical interface name<br>        option 'ifname' 'Wlan1'<br>        # option 'max_rtt_penalty' '90'</div><div># A config interface without "option ifname" will set default options<br># for all interfaces.  Interface-specific configuration always overrides<br># default configuration.<br>config interface<br>        # option 'enable_timestamps' 'true'<br>        # option 'update_interval' '30'<br></div><div><br></div><div># A filter consists of a type ('in', 'out' or 'redistribute'), an action<br># ('allow', 'deny' or 'metric xxx') and a set of selectors ('ip', 'eq',<br># etc.).  See babeld man page ("Filtering rules") for more details.<br># Here is a sample filter wich redistributes the default route if its<br># protocol number is "boot", e.g. when it installed by dhcp.  It is<br># disabled by default.<br>config filter<br>        # Type<br>        option 'type'   'redistribute'<br>        # Selectors: ip, eq, le, ge, src_ip, src_eq, src_le, src_ge, neigh, id,<br>        # proto, local, if.<br>        option 'ip'     '<a href="http://0.0.0.0/0">0.0.0.0/0</a>'<br>        #option 'eq'    '0'<br>        option 'proto'  '3'<br>        # Action (one of: allow, deny, metric XXX, src-prefix XXX).<br>        option 'local' 'true'<br>        option 'action' 'metric 128'<br>        optin 'if' 'eth0.2'<br>        option 'action' 'allow'</div><div><br></div><div><br></div><div>config filter<br>        option 'type' 'redistribute'<br>        option 'ip' '<a href="http://8.0.0.0/8">8.0.0.0/8</a>'<br>        option 'proto' '3'<br>        option 'action' 'metric 128'<br>        option 'if' 'eth0.2'</div><div># Notice that the 'local' selector is a boolean.<br>config filter<br>        option 'ignore' 'true'<br>        option 'type'   'redistribute'<br>        option 'local'  'true'<br>        # No action means "allow"<br>- /etc/config/babeld 99/99 100%<br></div><div><br></div><div>Box1 logs:</div><div>Neighbour fe80::6f0:21ff:fe34:16c1 dev wlan0 reach ffff ureach 0000 rxcost 256 txcost 256 rtt 0.000 rttcost 0 chan 36.<br><a href="http://192.168.1.1/32">192.168.1.1/32</a> metric 0 (exported)<br><a href="http://192.168.2.2/32">192.168.2.2/32</a> metric 0 (exported)<br><a href="http://192.168.4.1/32">192.168.4.1/32</a> metric 0 (exported)<br>fd78:117c:4808::1/128 metric 0 (exported)<br>fd48:a6f0:7e4::6f0:21ff:fe40:614/128 metric 0 (exported)<br><a href="http://192.168.1.2/32">192.168.1.2/32</a> from <a href="http://0.0.0.0/0">0.0.0.0/0</a> metric 256 (261) refmetric 0 id 06:f0:21:ff:fe:40:06:10 seqno 51257 age 6 via wlan0 neigh fe80::6f0:21ff:fe34:16c1 nexthop 192.168.4.2 (installed)<br><a href="http://192.168.4.2/32">192.168.4.2/32</a> from <a href="http://0.0.0.0/0">0.0.0.0/0</a> metric 256 (261) refmetric 0 id 06:f0:21:ff:fe:40:06:10 seqno 51257 age 6 via wlan0 neigh fe80::6f0:21ff:fe34:16c1 nexthop 192.168.4.2 (installed)<br>fd48:a6f0:7e4::1/128 metric 256 (261) refmetric 0 id 06:f0:21:ff:fe:40:06:10 seqno 51257 age 6 via wlan0 neigh fe80::6f0:21ff:fe34:16c1 (installed)<br>root@OpenWrt:/#<br></div><div><br></div><div>Box2</div><div>ip route show all</div><div>root@OpenWrt:/# ip route show all<br><a href="http://192.168.1.0/24">192.168.1.0/24</a> dev br-lan scope link  src 192.168.1.2<br>192.168.1.1 via 192.168.4.1 dev wlan0 onlink<br>192.168.2.2 via 192.168.4.1 dev wlan0 onlink<br><a href="http://192.168.4.0/24">192.168.4.0/24</a> dev wlan0 scope link  src 192.168.4.2<br>192.168.4.1 via 192.168.4.1 dev wlan0 onlink<br>root@OpenWrt:/#<br></div><div><br></div><div>Box2 <br></div><div>root@OpenWrt:/# route<br>Kernel IP routing table<br>Destination     Gateway         Genmask         Flags Metric Ref    Use Iface<br>192.168.1.0     *               255.255.255.0   U     0      0        0 br-lan<br>192.168.1.1     192.168.4.1     255.255.255.255 UGH   0      0        0 wlan0<br>192.168.2.2     192.168.4.1     255.255.255.255 UGH   0      0        0 wlan0<br>192.168.4.0     *               255.255.255.0   U     0      0        0 wlan0<br>192.168.4.1     192.168.4.1     255.255.255.255 UGH   0      0        0 wlan0<br>root@OpenWrt:/#<br></div><div><br></div><div>Box2</div><div>Babel config</div><div>root@OpenWrt:/# cat /etc/config/babeld<br>package babeld</div><div># Babeld reads options from the following files (the last one takes precedence<br># if an option is defined in several places):<br># - the file defined by the option conf_file (default: /etc/babeld.conf),<br># - *.conf files in the directory defined by conf_dir (default: /tmp/babel.d/),<br># - this UCI configuration file.</div><div># See "man babeld" for all available options ("Global options").<br># Important: remember to use '_' instead of '-' in option names.<br>config general<br>        # option 'random_id' 'true'<br>         option 'debug' '1'<br>        # option 'local_port' '33123'<br>         option 'log_file' '/var/log/babeld.log'<br>        ## Enable ipv6-subtrees by default since OpenWrt should ship with a<br>        ## recent enough kernel for it to work.<br>        option 'ipv6_subtrees' 'true'<br>         list 'import_table' '42'<br>         list 'import_table' '100'<br>        ## Alternative configuration file and directory.<br>        ## See comment at the top of this file for more details.<br>        # option 'conf_file' '/etc/babeld.conf'<br>        # option 'conf_dir' '/tmp/babel.d/'</div><div>config interface Wlan1<br>        ## Remove this line to enable babeld on this interface</div><div>        ## You can use aliases (like lan, wlan) or real names (like eth0.0).<br>        ## If you use an alias, it must be already defined when babeld starts.<br>        ## Otherwise, the name is taken literally and the interface can be<br>        ## brought up later (useful for tunnels for instance).<br>        option 'ifname' 'Wlan1'<br>        ## You can set options, see babeld man page ("Interface configuration")<br>        # option 'rxcost' '256'<br>        # option 'hello_interval' '1'</div><div>config interface<br>        option 'ignore' 'true'<br>        ## Physical interface name<br>        option 'ifname' 'tun-example'<br>        # option 'max_rtt_penalty' '90'</div><div># A config interface without "option ifname" will set default options<br># for all interfaces.  Interface-specific configuration always overrides<br># default configuration.<br>config interface<br>        # option 'enable_timestamps' 'true'<br>        # option 'update_interval' '30'</div><div><br># A filter consists of a type ('in', 'out' or 'redistribute'), an action<br># ('allow', 'deny' or 'metric xxx') and a set of selectors ('ip', 'eq',<br># etc.).  See babeld man page ("Filtering rules") for more details.<br># Here is a sample filter wich redistributes the default route if its<br># protocol number is "boot", e.g. when it installed by dhcp.  It is<br># disabled by default.<br></div><div># Notice that the 'local' selector is a boolean.<br>config filter<br>        option 'ignore' 'true'<br>        option 'type'   'redistribute'<br>        option 'local'  'true'<br>        # No action means "allow"<br>root@OpenWrt:/#<br></div><div><br></div><div>Box2</div><div>Neighbour fe80::6f0:21ff:fe3f:f632 dev wlan0 reach ffff ureach 0000 rxcost 256 txcost 256 rtt 0.000 rttcost 0 chan 36.<br><a href="http://192.168.1.2/32">192.168.1.2/32</a> metric 0 (exported)<br><a href="http://192.168.4.2/32">192.168.4.2/32</a> metric 0 (exported)<br>fd48:a6f0:7e4::1/128 metric 0 (exported)<br><a href="http://192.168.1.1/32">192.168.1.1/32</a> from <a href="http://0.0.0.0/0">0.0.0.0/0</a> metric 256 (256) refmetric 0 id 06:f0:21:ff:fe:40:06:14 seqno 30976 age 3 via wlan0 neigh fe80::6f0:21ff:fe3f:f632 nexthop 192.168.4.1 (installed)<br><a href="http://192.168.2.2/32">192.168.2.2/32</a> from <a href="http://0.0.0.0/0">0.0.0.0/0</a> metric 256 (256) refmetric 0 id 06:f0:21:ff:fe:40:06:14 seqno 30976 age 3 via wlan0 neigh fe80::6f0:21ff:fe3f:f632 nexthop 192.168.4.1 (installed)<br><a href="http://192.168.4.1/32">192.168.4.1/32</a> from <a href="http://0.0.0.0/0">0.0.0.0/0</a> metric 256 (256) refmetric 0 id 06:f0:21:ff:fe:40:06:14 seqno 30976 age 3 via wlan0 neigh fe80::6f0:21ff:fe3f:f632 nexthop 192.168.4.1 (installed)<br>fd48:a6f0:7e4::6f0:21ff:fe40:614/128 metric 256 (256) refmetric 0 id 06:f0:21:ff:fe:40:06:14 seqno 30976 age 3 via wlan0 neigh fe80::6f0:21ff:fe3f:f632 (installed)<br>fd78:117c:4808::1/128 metric 256 (256) refmetric 0 id 06:f0:21:ff:fe:40:06:14 seqno 30976 age 3 via wlan0 neigh fe80::6f0:21ff:fe3f:f632 (installed)<br>root@OpenWrt:/#<br></div><div><br></div><div>Thank you.</div><div><br></div><div>Best regards,</div><div>Volodymyr<br></div></div></div></div></div></div></div></div></div></div></div></div></div></div>