diff --git a/mininet/node.py b/mininet/node.py index 3cd8a1f..131c9f7 100644 --- a/mininet/node.py +++ b/mininet/node.py @@ -1023,7 +1023,6 @@ class IVSSwitch(Switch): def __init__( self, name, **kwargs ): Switch.__init__( self, name, **kwargs ) - self.process = None @classmethod def setup( cls ): @@ -1052,18 +1051,13 @@ class IVSSwitch(Switch): if self.listenPort: args.extend( ['--listen', '127.0.0.1:%i' % self.listenPort] ) - with open( '/tmp/ivs.%s.log' % self.name, 'w' ) as logfile: - with open( '/dev/null', 'w' ) as nullfile: - self.process = Popen( args, stdout=logfile, stderr=STDOUT, - stdin=nullfile, preexec_fn=os.setsid ) - self.execed = False + logfile = '/tmp/ivs.%s.log' % self.name + + self.cmd( ' '.join(args) + ' >' + logfile + ' 2>&1