This option set UDP datagram size for netperf test on client. If this option
is not explicitly specified, default value from netperf is used.
The option accepts integer value describing datagram size, it should be also
concatenated with G/M/K/g/m/k.
In this commit I also added this option to regression_test: simple_netperf test.
Signed-off-by: Kamil Jerabek <kjerabek(a)redhat.com>
---
test_modules/Netperf.py | 11 +++++++++++
1 file changed, 11 insertions(+)
diff --git a/test_modules/Netperf.py b/test_modules/Netperf.py
index 6950bb8..9f98d23 100644
--- a/test_modules/Netperf.py
+++ b/test_modules/Netperf.py
@@ -39,6 +39,7 @@ class Netperf(TestGeneric):
self._cpu_util = self.get_opt("cpu_util")
self._num_parallel = int(self.get_opt("num_parallel", default=1))
self._runs = self.get_opt("runs", default=1)
+ self._udp_size = self.get_opt("udp_size")
self._debug = int_it(self.get_opt("debug", default=0))
self._threshold = self._parse_threshold(self.get_opt("threshold"))
@@ -141,6 +142,16 @@ class Netperf(TestGeneric):
else:
cmd += " -- %s" % self._testoptions
+ if self._udp_size is not None:
+ """
+ udp packets will have this size
+ """
+ if self._is_omni() or self._testoptions:
+ cmd += " -m %s" % self._udp_size
+ else:
+ cms += " -- -m %s" % self._udp_size
+
+
elif self._role == "server":
cmd = "netserver -D"
if self._bind is not None:
--
2.5.5