minitopo: specify the metric for the metric scheduler
This commit is contained in:
parent
588b99865e
commit
30084ffa43
@ -30,11 +30,17 @@ class MpExperience:
|
|||||||
self.setupSysctl()
|
self.setupSysctl()
|
||||||
self.runUserspacePM()
|
self.runUserspacePM()
|
||||||
self.mpConfig.configureNetwork()
|
self.mpConfig.configureNetwork()
|
||||||
|
self.changeMetric()
|
||||||
self.putPriorityOnPaths()
|
self.putPriorityOnPaths()
|
||||||
self.runTcpDump()
|
self.runTcpDump()
|
||||||
self.runNetemAt()
|
self.runNetemAt()
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
def changeMetric(self):
|
||||||
|
metric = self.xpParam.getParam(MpParamXp.METRIC)
|
||||||
|
if int(metric) >= 0:
|
||||||
|
self.mpTopo.notNSCommand("echo " + metric + " > /sys/module/mptcp_sched_metric/parameters/metric")
|
||||||
|
|
||||||
def putPriorityOnPaths(self):
|
def putPriorityOnPaths(self):
|
||||||
# Only meaningful if mpTopo is instance of MpMultiInterfaceTopo
|
# Only meaningful if mpTopo is instance of MpMultiInterfaceTopo
|
||||||
if isinstance(self.mpTopo, MpMultiInterfaceTopo):
|
if isinstance(self.mpTopo, MpMultiInterfaceTopo):
|
||||||
|
@ -53,6 +53,7 @@ class MpParamXp(MpParam):
|
|||||||
PRIOPATH0 = "prioPath0"
|
PRIOPATH0 = "prioPath0"
|
||||||
PRIOPATH1 = "prioPath1"
|
PRIOPATH1 = "prioPath1"
|
||||||
EXPIRATION = "expiration"
|
EXPIRATION = "expiration"
|
||||||
|
METRIC = "metric"
|
||||||
|
|
||||||
|
|
||||||
# global sysctl
|
# global sysctl
|
||||||
@ -88,6 +89,7 @@ class MpParamXp(MpParam):
|
|||||||
defaultValue[AUTOCORK] = "1"
|
defaultValue[AUTOCORK] = "1"
|
||||||
defaultValue[EARLYRETRANS] = "3"
|
defaultValue[EARLYRETRANS] = "3"
|
||||||
defaultValue[EXPIRATION] = "300"
|
defaultValue[EXPIRATION] = "300"
|
||||||
|
defaultValue[METRIC] = "-1"
|
||||||
|
|
||||||
defaultValue[CLIENTPCAP] = "no"
|
defaultValue[CLIENTPCAP] = "no"
|
||||||
defaultValue[SERVERPCAP] = "no"
|
defaultValue[SERVERPCAP] = "no"
|
||||||
|
Loading…
Reference in New Issue
Block a user