Pergunta

Is there way to run specific VMWare-player image (assuming that it was created beforehand, and name is known) from java application? Maybe there exist some libs already, but i wasn't able to find them. Or better if some one could post code snippet.

In other words i want invoke VMware player to run a image from java.

Foi útil?

Solução

If this not for production and realtime systems, it can be done by kicking VMWare commands from java.lang.Runtime
Some thing like: Runtime.getRuntime().exec("cmd /c start abc.bat");

Outras dicas

If you want to simply invoke the VM player then use the following. To invoke the player with vmrun use -T

Runtime rt = Runtime.getRuntime();
rt.exec("<path-of-installation>/vmrun -T player start <name-or-path-of-image-file>");

Or if you want to do any study on the running Vm Player then VMware Infrastructure (vSphere) Java API might be useful.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top