diff options
author | Sander Vrijders <sander.vrijders@ugent.be> | 2017-04-20 17:12:34 +0200 |
---|---|---|
committer | Sander Vrijders <sander.vrijders@ugent.be> | 2017-04-21 11:28:35 +0200 |
commit | 009c8ff7570105a79278559202fdd46616b83a92 (patch) | |
tree | 06fc2bafc26683c82795db750187ff7cefdcc43e /rumba/prototypes/ouroboros.py | |
parent | 06b3694633bd8315d55b5d75a2ca6c20afc54651 (diff) | |
download | rumba-009c8ff7570105a79278559202fdd46616b83a92.tar.gz rumba-009c8ff7570105a79278559202fdd46616b83a92.zip |
model: Split experiment run()
This splits experiment.run() into 4 different operations: swap_in,
install_prototype, bootstrap_prototype and swap_out.
Diffstat (limited to 'rumba/prototypes/ouroboros.py')
-rw-r--r-- | rumba/prototypes/ouroboros.py | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/rumba/prototypes/ouroboros.py b/rumba/prototypes/ouroboros.py index 4fdacd6..4ebeea8 100644 --- a/rumba/prototypes/ouroboros.py +++ b/rumba/prototypes/ouroboros.py @@ -28,18 +28,22 @@ class Experiment(mod.Experiment): mod.Experiment.__init__(self, testbed, nodes) def setup_ouroboros(self): + for node in self.nodes: + ssh.execute_command(self.testbed, node.ssh_config, + "sudo nohup irmd > /dev/null &", + time_out=None) + + def install_ouroboros(self): cmds = list() cmds.append("sudo apt-get update") cmds.append("sudo apt-get install cmake protobuf-c-compiler git --yes") cmds.append("sudo rm -r ~/ouroboros/build") cmds.append("cd ~/ouroboros; sudo ./install_debug.sh /") - cmds.append("sudo nohup irmd > /dev/null &") for node in self.nodes: ssh.execute_commands(self.testbed, node.ssh_config, cmds, time_out=None) - return def bind_names(self): for node in self.nodes: @@ -131,8 +135,13 @@ class Experiment(mod.Experiment): cmds, time_out = None) time.sleep(2) - def run_prototype(self): - print("Setting up Ouroboros...") + def install_prototype(self): + print("Installing Ouroboros...") + self.install_ouroboros() + print("Installed on all nodes...") + + def bootstrap_prototype(self): + print("Starting IRMd on all nodes...") self.setup_ouroboros() print("Binding names...") self.bind_names() |