I am trying to run a script on a Windows Vista virtual machine with vmrun but I get an error.
Here is my command:
vmrun -gu *** -gp *** runProgramInGuest /path/to/Vista.vmwarevm "C:\windows\system32\cmd.exe" "/c Z:\deploy\windows\ExtractFile.bat"
Nothing was done and the result is:
Guest program exited with non-zero exit code: 1
I tried to execute directly in Vista this and it works fine:
C:\windows\system32\cmd.exe /c Z:\deploy\windows\ExtractFile.bat
Any idea ?
I finally found the right syntax that works:
It seems that the
-interactiveis mandatory for the script to work.And if you want to pass parameters to your script just append them after the script name and add an extra space (important):