- public static Host host0 = null;
- public static Host host1 = null;
- public static Host host2 = null;
+ protected Host host0 = null;
+ protected Host host1 = null;
+ protected Host host2 = null;
- TestHostOnOff(Host host, String name, String[] args) throws NativeException {
- super(host, name, args);
+ TestHostOnOff(String hostname, String name) throws HostNotFoundException, NativeException {
+ super(hostname, name);
- host0 = Host.getByName("host0");
- host1 = Host.getByName("host1");
- host1 = Host.getByName("host2");
+ host0 = Host.getByName("PM0");
+ host1 = Host.getByName("PM1");
+ host2 = Host.getByName("PM2");
}catch (HostNotFoundException e) {
e.printStackTrace(); //To change body of catch statement use File | Settings | File Templates.
}
// Robustness on the SRC node
}catch (HostNotFoundException e) {
e.printStackTrace(); //To change body of catch statement use File | Settings | File Templates.
}
// Robustness on the SRC node
- //for (int i =0 ; i < 55000 ; i++)
- // testVMMigrate(host1, i);
+ for (int i =100 ; i < 55000 ; i+=100)
+ testVMMigrate(host1, i);
- //for (int i =0 ; i < 55000 ; i++)
- // testVMMigrate(host2, i);
+ for (int i =0 ; i < 55000 ; i++)
+ testVMMigrate(host2, i);
Msg.info("**** **** **** ***** ***** Test Migrate with host shutdown ***** ***** **** **** ****");
Msg.info("Turn on one host, assign a VM on this host, launch a process inside the VM, migrate the VM and "
+ "turn off either the SRC or DST");
Msg.info("**** **** **** ***** ***** Test Migrate with host shutdown ***** ***** **** **** ****");
Msg.info("Turn on one host, assign a VM on this host, launch a process inside the VM, migrate the VM and "
+ "turn off either the SRC or DST");
Msg.info("Migrate vm "+args[0]+" to node "+destHost.getName());
VM.getVMByName(args[0]).migrate(destHost);
} catch (HostFailureException e) {
Msg.info("Migrate vm "+args[0]+" to node "+destHost.getName());
VM.getVMByName(args[0]).migrate(destHost);
} catch (HostFailureException e) {
Msg.info("**** **** **** ***** ***** Test shutdown a VM ***** ***** **** **** ****");
Msg.info("Turn on host1, assign a VM on host1, launch a process inside the VM, and turn off the vm, " +
"and check whether you can reallocate the same VM");
Msg.info("**** **** **** ***** ***** Test shutdown a VM ***** ***** **** **** ****");
Msg.info("Turn on host1, assign a VM on host1, launch a process inside the VM, and turn off the vm, " +
"and check whether you can reallocate the same VM");