1 AUTHOR = "kdlucas (a] google.com (K.D. Lucas)" 2 TIME = "SHORT" 3 NAME = "Netperf Basic" 4 TEST_CATEGORY = "Benchmark" 5 TEST_CLASS = 'Network' 6 TEST_TYPE = "Server" 7 SYNC_COUNT = 2 8 DOC = """ 9 netperf2 is a 2 machine test (server/client) that measures the performance 10 of various network attributes. 11 12 Arguments to run_test: 13 14 test - the list of valid netperf tests that can be run 15 This currently is: 16 TCP_STREAM, TCP_SENDFILE, TCP_RR, TCP_CRR, UDP_STREAM, UDP_RR 17 test_time - Specifies how long each iteration of the test should run for. 18 stream_list - A list containing the number of streams to run the test for. If 19 the list is [1,10,100] then the test will run 3 times. If 20 bidirectional is set then there will be the specified number of 21 bidirectional streams. 22 cycles - The number of times to run each test. 23 """ 24 25 from autotest_lib.server import utils 26 27 28 def run(pair): 29 job.run_test('netperf2', pair=pair, test='TCP_STREAM', time=10, 30 stream_list=[1], cycles=1) 31 32 # grab the pairs (and failures) 33 (pairs, failures) = utils.form_ntuples_from_machines(machines, 2) 34 35 # log the failures 36 for failure in failures: 37 job.record("FAIL", failure[0], "netperf2", failure[1]) 38 39 # now run through each pair and run 40 job.parallel_simple(run, pairs, log=False) 41