change set from mininet
Signed-off-by: Benjamin Hesmans <benjamin.hesmans@uclouvain.be>
This commit is contained in:
parent
304938c381
commit
56c7196245
@ -28,10 +28,6 @@ class MpConfig:
|
||||
def configureInterfaces(self):
|
||||
pass
|
||||
|
||||
def configureNetwork(self):
|
||||
pass
|
||||
|
||||
|
||||
def getClientInterfaceCount(self):
|
||||
raise Exception("To be implemented")
|
||||
|
||||
|
@ -17,10 +17,12 @@ class MpExperience:
|
||||
def prepare(self):
|
||||
self.setupSysctl()
|
||||
self.runTcpDump()
|
||||
self.runNetemAt()
|
||||
pass
|
||||
|
||||
def runNetemAt(self):
|
||||
if not self.mpTopo.changeNetem == "yes":
|
||||
print("I don't need to change netem")
|
||||
return
|
||||
print("Will change netem config on the fly")
|
||||
links = self.mpTopo.getLinkCharacteristics()
|
||||
|
@ -29,10 +29,11 @@ class MpLinkCharacteristics:
|
||||
cmd = cmd + " && "
|
||||
cmd = cmd + " echo " + n.cmd + " && "
|
||||
cmd = cmd + " true &"
|
||||
return cmd
|
||||
|
||||
def asDict(self):
|
||||
d = {}
|
||||
d['bw'] = int(self.bandwidth)
|
||||
d['bw'] = float(self.bandwidth)
|
||||
d['delay'] = self.delay + "ms"
|
||||
d['max_queue_size'] = int(self.queueSize)
|
||||
return d
|
||||
|
@ -20,7 +20,7 @@ class MpTopo:
|
||||
self.logFile = open(MpTopo.cmdLog, 'w')
|
||||
|
||||
def getLinkCharacteristics(self):
|
||||
return topoParam.linkCharacteristics()
|
||||
return self.topoParam.linkCharacteristics
|
||||
|
||||
def commandTo(self, who, cmd):
|
||||
self.logFile.write(who.__str__() + " : " + cmd + "\n")
|
||||
|
Loading…
Reference in New Issue
Block a user