fixes GSO and GRO + get rid of iperf3

Seems that iperf3 is really buggy...
This commit is contained in:
Quentin De Coninck 2020-07-15 18:12:04 +02:00
parent ca59fc4f0e
commit 06825ad36b
3 changed files with 8 additions and 8 deletions

View File

@ -515,13 +515,13 @@ class TopoConfig(object):
def disable_tso(self): def disable_tso(self):
""" """
Disable TSO on all interfaces Disable TSO, GSO and GRO on all interfaces
""" """
logging.info("Disable TSO on all interfaces of all nodes") logging.info("Disable TSO, GSO and GRO on all interfaces of all nodes")
for node in [self.topo.get_host(n) for n in self.topo.topo_builder.net]: for node in [self.topo.get_host(n) for n in self.topo.topo_builder.net]:
for intf in self.topo.get_interface_names(node): for intf in self.topo.get_interface_names(node):
logging.debug("Disable TSO on interface {}".format(intf)) logging.debug("Disable TSO, GSO and GRO on interface {}".format(intf))
cmd = "ethtool -K {} tso off".format(intf) cmd = "ethtool -K {} tso off; ethtool -K {} gso off; ethtool -K {} gro off".format(intf, intf, intf)
logging.debug(cmd) logging.debug(cmd)
self.topo.command_to(node, cmd) self.topo.command_to(node, cmd)

View File

@ -20,7 +20,7 @@ class IPerf(Experiment):
IPERF_LOG = "iperf.log" IPERF_LOG = "iperf.log"
SERVER_LOG = "server.log" SERVER_LOG = "server.log"
IPERF_BIN = "iperf3" IPERF_BIN = "iperf"
PING_OUTPUT = "ping.log" PING_OUTPUT = "ping.log"
def __init__(self, experiment_parameter_filename, topo, topo_config): def __init__(self, experiment_parameter_filename, topo, topo_config):
@ -38,7 +38,7 @@ class IPerf(Experiment):
self.topo.command_to(self.topo_config.server, "rm {}".format(IPerf.SERVER_LOG)) self.topo.command_to(self.topo_config.server, "rm {}".format(IPerf.SERVER_LOG))
def get_client_cmd(self): def get_client_cmd(self):
s = "{} -c {} -t {} -P {} &>{}".format(IPerf.IPERF_BIN, s = "{} -c {} -t {} -P {} -i 1 &>{}".format(IPerf.IPERF_BIN,
self.topo_config.get_server_ip(), self.time, self.parallel, IPerf.IPERF_LOG) self.topo_config.get_server_ip(), self.time, self.parallel, IPerf.IPERF_LOG)
logging.info(s) logging.info(s)
return s return s

View File

@ -20,7 +20,7 @@ class IPerfScenario(Experiment):
IPERF_LOG = "iperf.log" IPERF_LOG = "iperf.log"
SERVER_LOG = "server.log" SERVER_LOG = "server.log"
IPERF_BIN = "iperf3" IPERF_BIN = "iperf"
PING_OUTPUT = "ping.log" PING_OUTPUT = "ping.log"
def __init__(self, experiment_parameter_filename, topo, topo_config): def __init__(self, experiment_parameter_filename, topo, topo_config):
@ -41,7 +41,7 @@ class IPerfScenario(Experiment):
raise Exception("IPerfScenario only runs with MultiInterfaceMultiClientTopo") raise Exception("IPerfScenario only runs with MultiInterfaceMultiClientTopo")
def get_client_iperf_cmd(self, server_ip, time, client_id): def get_client_iperf_cmd(self, server_ip, time, client_id):
s = "{} -c {} -t {} -P 1 &>{}{}".format(IPerfScenario.IPERF_BIN, server_ip, time, IPerfScenario.IPERF_LOG, client_id) s = "{} -c {} -t {} -P 1 -i 5 &>{}{}".format(IPerfScenario.IPERF_BIN, server_ip, time, IPerfScenario.IPERF_LOG, client_id)
logging.info(s) logging.info(s)
return s return s