diff --git a/cts/corolab.py b/cts/corolab.py index 83547de6..340c7512 100755 --- a/cts/corolab.py +++ b/cts/corolab.py @@ -70,6 +70,7 @@ def usage(arg): print "\t [--nodes 'node list'], list of cluster nodes separated by whitespace" print "\t [--limit-nodes max], only use the first 'max' cluster nodes supplied with --nodes" print "\t [--logfile path], where should the test software look for logs from cluster nodes" + print "\t [--rrp-bindaddr addr], extra interface used for rrp, provide the bindaddr" print "\t [--outputfile path], optional location for the test software to write logs to" print "\t [--syslog-facility name], which syslog facility should the test software log to" print "\t [--choose testcase-name], run only the named test" @@ -111,6 +112,7 @@ class CoroLabEnvironment(CtsLab): self["DoBSC"] = 0 self["use_logd"] = 0 self["oprofile"] = [] + self["RrpBindAddr"] = None self["warn-inactive"] = 0 self["ListTests"] = 0 self["benchmark"] = 0 @@ -179,6 +181,10 @@ if __name__ == '__main__': skipthis=1 Environment["OutputFile"] = args[i+1] + elif args[i] == "--rrp-bindaddr": + skipthis=1 + Environment["RrpBindAddr"] = args[i+1] + elif args[i] == "--oprofile": skipthis=1 Environment["oprofile"] = args[i+1].split(' ') diff --git a/cts/corotests.py b/cts/corotests.py index d0a47057..1fbbfa94 100644 --- a/cts/corotests.py +++ b/cts/corotests.py @@ -926,22 +926,24 @@ def CoroTestList(cm, audits): #f['quorum/provider'] = 'corosync_quorum_ykd' #configs.append(f) + if not cm.Env["RrpBindAddr"] is None: + g = {} + g['totem/rrp_mode'] = 'passive' + g['totem/interface[2]/ringnumber'] = '1' + g['totem/interface[2]/bindnetaddr'] = cm.Env["RrpBindAddr"] + g['totem/interface[2]/mcastaddr'] = '226.94.1.2' + g['totem/interface[2]/mcastport'] = '5405' + configs.append(g) - g = {} - g['totem/rrp_mode'] = 'passive' - g['totem/interface[2]/ringnumber'] = '1' - g['totem/interface[2]/bindnetaddr'] = '192.168.200.0' - g['totem/interface[2]/mcastaddr'] = '226.94.1.2' - g['totem/interface[2]/mcastport'] = '5405' - configs.append(g) - - h = {} - h['totem/rrp_mode'] = 'active' - h['totem/interface[2]/ringnumber'] = '1' - h['totem/interface[2]/bindnetaddr'] = '192.168.200.0' - h['totem/interface[2]/mcastaddr'] = '226.94.1.2' - h['totem/interface[2]/mcastport'] = '5405' - configs.append(h) + h = {} + h['totem/rrp_mode'] = 'active' + h['totem/interface[2]/ringnumber'] = '1' + h['totem/interface[2]/bindnetaddr'] = cm.Env["RrpBindAddr"] + h['totem/interface[2]/mcastaddr'] = '226.94.1.2' + h['totem/interface[2]/mcastport'] = '5405' + configs.append(h) + else: + print 'Not including rrp tests. Use --rrp-binaddr to enable them.' num=1 for cfg in configs: