|
|
|
|
|
|
|
|
|
|
xen-users
Re: [Xen-users] Reset or restart a VM
Java code... public void startVM(String vm) { try { System.out.println("Starting replica " + vm);
Runtime rt = Runtime.getRuntime(); Process pr = rt.exec("xm create " + vm);
pr.waitFor(); pr.destroy(); rt.freeMemory();
rt.gc();
} catch (Exception e) { System.out.println(e.toString());
e.printStackTrace(); } }
Change "create" to any command you want to do with your vm.
-- Luciano Barreto
_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-users
|
|
|
|
|