removed emane nodes netif install and setaddrs, install was always skipped and setaddrs is done by zebra/quagga

This commit is contained in:
Blake J. Harnden 2018-07-11 09:24:44 -07:00
parent bfbee35a53
commit b03662dbeb
2 changed files with 4 additions and 7 deletions

View file

@ -318,7 +318,7 @@ class EmaneManager(ModelManager):
if self.numnems() > 0:
self.startdaemons()
self.installnetifs(do_netns=False)
self.installnetifs()
for emane_node in self._emane_nodes.itervalues():
for netif in emane_node.netifs():
@ -704,7 +704,7 @@ class EmaneManager(ModelManager):
except CoreCommandError:
logger.exception("error shutting down emane daemons")
def installnetifs(self, do_netns=True):
def installnetifs(self):
"""
Install TUN/TAP virtual interfaces into their proper namespaces
now that the EMANE daemons are running.
@ -712,7 +712,7 @@ class EmaneManager(ModelManager):
for key in sorted(self._emane_nodes.keys()):
emane_node = self._emane_nodes[key]
logger.info("emane install netifs for node: %d", key)
emane_node.installnetifs(do_netns)
emane_node.installnetifs()
def deinstallnetifs(self):
"""

View file

@ -117,7 +117,7 @@ class EmaneNode(EmaneNet):
"""
return sorted(self._netif.values(), key=lambda ifc: ifc.node.objid)
def installnetifs(self, do_netns=True):
def installnetifs(self):
"""
Install TAP devices into their namespaces. This is done after
EMANE daemons have been started, because that is their only chance
@ -129,9 +129,6 @@ class EmaneNode(EmaneNet):
logger.error(warntxt)
for netif in self.netifs():
if do_netns and "virtual" in netif.transport_type.lower():
netif.install()
# netif.setaddrs()
if not self.session.emane.genlocationevents():
netif.poshook = None
continue