You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
To resolve this, Switch.defaultIntf() could be changed to expect an undefined self.controlIntf and not crash, or self.controlIntf could be set to None in Switch.__init__ if self.inNamespace is False.
EDIT: If the node -> IP translation isn't needed for the command, the user can put the node's name in single quotes as a workaround.
The text was updated successfully, but these errors were encountered:
Expected/Desired Behavior:
Mininet should not crash when a command that is run on a node includes (as an arg) the name of a switch that has
inNamespace
set toFalse
.Actual Behavior:
Mininet crashes.
Detailed Steps to Reproduce the Behavior:
inNamespace=False
.switch1
.<node> echo switch1
where<node>
is the name of any node.Additional Information:
The CLI crashes when it tries to access
self.controlIntf
inside ofSwitch.defaultIntf()
:https://github.com/mininet/mininet/blob/master/mininet/node.py#L919
This happens because
self.controlIntf
may not be defined ifself.inNamespace
is set toFalse
, as can be seen inSwitch.__init__
:https://github.com/mininet/mininet/blob/master/mininet/node.py#L896
The call to
Switch.defaultIntf()
is triggered by the CLI trying to replace node args with their IP addresses here:https://github.com/mininet/mininet/blob/master/mininet/cli.py#L419
To resolve this,
Switch.defaultIntf()
could be changed to expect an undefinedself.controlIntf
and not crash, orself.controlIntf
could be set toNone
inSwitch.__init__
ifself.inNamespace
isFalse
.EDIT: If the node -> IP translation isn't needed for the command, the user can put the node's name in single quotes as a workaround.
The text was updated successfully, but these errors were encountered: