https://www.open-mesh.org/https://www.open-mesh.org/favicon.ico?16699090422019-06-02T07:49:34ZOpen Meshbatman-adv - Bug #380: Too high number of OGMs after interface up->down->uphttps://www.open-mesh.org/issues/380?journal_id=15552019-06-02T07:49:34ZSven Eckelmann
<ul></ul><p>It can be reproduced in <a class="wiki-page" href="https://www.open-mesh.org/projects/open-mesh/wiki/Emulation_Environment">Emulation Environment</a> setup with kernel 4.4.180. The commands to run in the virtual machine are:</p>
<pre>
rmmod batman-adv || true
insmod /host/batman-adv/net/batman-adv/batman-adv.ko
/host/batctl/batctl if add dummy0
/host/batctl/batctl it 5000
/host/batctl/batctl if add enp0s3
ip link set up dev enp0s3
ip link set up dev bat0
ip link set down dev dummy0
sleep 2
ip link set up dev dummy0
</pre>
<p>A wireshark process was attached to the tap interface to analyze the interval. A third ogm (beside the 2 expected ones for the two interfaces) appeared when I ran the lower part (down + sleep + up).</p>
<p>This behavior was introduced with commit 0d8468553c3c ("batman-adv: remove ogm_emit and ogm_schedule API calls")</p> batman-adv - Bug #380: Too high number of OGMs after interface up->down->uphttps://www.open-mesh.org/issues/380?journal_id=15562019-06-02T08:43:58ZSven Eckelmann
<ul></ul><p>Problem is in the patch that bat_iface_activate is used to start the sending of OGMs - directly via batadv_iv_ogm_schedule from batadv_hardif_activate_interface. It was done in the past by batadv_schedule_bat_ogm which was called from batadv_hardif_enable_interface.</p>
<p>One difference here is that batadv_hardif_activate_interface is only called by batadv_hardif_enable_interface when batadv_hardif_is_iface_up is true. <strong>BUT</strong> this dependency to IFF_UP also requires that the function batadv_hardif_activate_interface is called again when we are notified about an interface which goes up via NETDEV_UP. Thus everytime we receive a NETDEV_UP event, a new OGM is scheduled :(</p> batman-adv - Bug #380: Too high number of OGMs after interface up->down->uphttps://www.open-mesh.org/issues/380?journal_id=15572019-06-02T08:47:35ZSven Eckelmann
<ul><li><strong>Status</strong> changed from <i>New</i> to <i>In Progress</i></li><li><strong>Assignee</strong> changed from <i>Linus Lüssing</i> to <i>Sven Eckelmann</i></li><li><strong>Target version</strong> set to <i>2019.3</i></li></ul> batman-adv - Bug #380: Too high number of OGMs after interface up->down->uphttps://www.open-mesh.org/issues/380?journal_id=15582019-06-02T09:55:35ZSven Eckelmann
<ul><li><strong>Status</strong> changed from <i>In Progress</i> to <i>Resolved</i></li></ul><p>Patch was proposed at <a class="external" href="https://patchwork.open-mesh.org/project/b.a.t.m.a.n./patch/20190602095135.15604-1-sven@narfation.org/">https://patchwork.open-mesh.org/project/b.a.t.m.a.n./patch/20190602095135.15604-1-sven@narfation.org/</a></p>
<ul>
<li>2019.2 backport: <a class="external" href="https://github.com/openwrt-routing/packages/pull/475">https://github.com/openwrt-routing/packages/pull/475</a></li>
<li>2018.1 backport: <a class="external" href="https://github.com/openwrt-routing/packages/pull/474">https://github.com/openwrt-routing/packages/pull/474</a></li>
<li>2016.5 backport: <a class="external" href="https://github.com/openwrt-routing/packages/pull/473">https://github.com/openwrt-routing/packages/pull/473</a></li>
</ul> batman-adv - Bug #380: Too high number of OGMs after interface up->down->uphttps://www.open-mesh.org/issues/380?journal_id=15592019-06-02T12:06:34ZSven Eckelmann
<ul><li><strong>Status</strong> changed from <i>Resolved</i> to <i>Closed</i></li><li><strong>% Done</strong> changed from <i>0</i> to <i>100</i></li></ul><p>Thanks for the test and the ack. It is now queued up for 2019.3</p>