def reset(self):
        ''' Reset to initial state.
        '''
        self.nodemap_lock.acquire()
        self.nodemap.clear()
        for server in self.nodecounts:
            if self.nodecounts[server] < 1:
                self.delserver(server)
        self.nodecounts.clear()
        self.bootcount = 0
        self.nodemap_lock.release()
        del self.nets[:]
        del self.phys[:]
        while len(self.tunnels) > 0:
            (key, gt) = self.tunnels.popitem()
            gt.shutdown()
dataset/ETHPy150Open coreemu/core/daemon/core/broker.py/CoreBroker.reset/original