Revision 3df07feb mininet/node.py

View differences:

mininet/node.py
968 968
        if self.listenPort:
969 969
            clist += ' ptcp:%s' % self.listenPort
970 970
        self.cmd( 'ovs-vsctl set-controller', self, clist )
971
        # Set controllers to reconnect quickly
972
        controllers = self.cmd( 'ovs-vsctl --columns=controller find Bridge '
973
                                'name=' + str(self) ).split(':',2)[-1].strip()
974

  
975
        if controllers.startswith('[') and controllers.endswith(']'):
976
            controllers = [c.strip() for c in controllers[1:-1].split(',')]
977
            for uuid in controllers:
978
                if uuid.count('-') != 4:
979
                    # Doesn't look like a UUID
980
                    continue
981
                uuid = uuid.strip()
982
                self.cmd( 'ovs-vsctl set Controller', uuid,
983
                          'max_backoff=1000' )
971 984

  
972 985
    def stop( self ):
973 986
        "Terminate OVS switch."

Also available in: Unified diff