#
from nepi.execution.ec import ExperimentController, ECState
-from nepi.execution.resource import ResourceState, ResourceAction, \
- populate_factory
+from nepi.execution.resource import ResourceState, ResourceAction
from nepi.execution.trace import TraceAttr
import subprocess
ec.set(node, "hostname", host)
ec.set(node, "username", user)
ec.set(node, "identity", ssh_key)
- #ec.set(node, "cleanHome", True)
+ ec.set(node, "cleanHome", True)
ec.set(node, "cleanProcesses", True)
return node
return app
-def add_collector(ec, trace_name, store_dir):
+def add_collector(ec, trace_name):
collector = ec.register_resource("Collector")
ec.set(collector, "traceName", trace_name)
- ec.set(collector, "storeDir", store_dir)
return collector
default_key = default_key if os.path.exists(default_key) else None
pl_ssh_key = os.environ.get("PL_SSHKEY", default_key)
- usage = "usage: %prog -s <pl-user> -m <movie> -e <exp-id> -i <ssh_key> -r <results"
+ usage = "usage: %prog -s <pl-user> -m <movie> -e <exp-id> -i <ssh_key> -r <results>"
parser = OptionParser(usage=usage)
parser.add_option("-s", "--pl-user", dest="pl_user",
( pl_user, movie, exp_id, pl_ssh_key, results_dir ) = get_options()
- # Search for available RMs
- populate_factory()
-
- ec = ExperimentController(exp_id = exp_id)
-
- # hosts in Europe
- #host1 = "planetlab2.u-strasbg.fr"
- #host2 = "planet1.servers.ua.pt"
- #host3 = "planetlab1.cs.uoi.gr"
- #host4 = "planetlab1.aston.ac.uk"
- #host5 = "planetlab2.willab.fi"
- #host6 = "planetlab-1.fokus.fraunhofer.de"
-
- # host in the US
- host1 = "planetlab4.wail.wisc.edu"
- host2 = "planetlab2.cs.columbia.edu"
- host3 = "ricepl-2.cs.rice.edu"
- host4 = "node1.planetlab.albany.edu"
- host5 = "earth.cs.brown.edu"
- host6 = "planetlab2.engr.uconn.edu"
-
- # describe nodes in the central ring
+ ec = ExperimentController(exp_id = exp_id, local_dir = results_dir)
+
+ # hosts in the US
+ #host1 = "planetlab4.wail.wisc.edu"
+ #host2 = "planetlab2.cs.columbia.edu"
+ #host3 = "ricepl-2.cs.rice.edu"
+ #host4 = "node1.planetlab.albany.edu"
+ #host5 = "earth.cs.brown.edu"
+ #host6 = "planetlab2.engr.uconn.edu"
+
+ # hosts in EU
+ host1 = "planetlab2.fct.ualg.pt"
+ host2 = "planet2.unipr.it"
+ host3 = "planetlab1.aston.ac.uk"
+ host4 = "itchy.comlab.bth.se"
+ host5 = "rochefort.infonet.fundp.ac.be"
+ host6 = "planetlab1.u-strasbg.fr"
+
+ # describe nodes in the central ring
ring_hosts = [host1, host2, host3, host4]
ccnds = dict()
app, ResourceState.STARTED, time = "10s")
ec.register_condition(l5d, ResourceAction.STOP,
app, ResourceState.STARTED, time = "10s")
-
+
# Register a collector to automatically collect traces
- collector = add_collector(ec, "stderr", results_dir)
+ collector = add_collector(ec, "stderr")
for ccnd in ccnds.values():
ec.register_connection(collector, ccnd)