|
#1
|
|||
|
|||
VMware Workstation ->"Run Program" Command doesn't work
Hi,
I am a newbie using Visual Build and it works fine. Though I have been trying to do some things with VMware Workstation, I can't find the way. Till now i can "Start" a Virtual machine with an specified snapshot. But when I use "run program" command I get this error: "Error: Unrecognized command: runProgramInGuestProcess completed with exit code -12/26/2008 10:04:11 AM: Step 'VMware Workstation-Connect&Exit' failed" The step as you can see is named "VMware Workstation-Connect&Exit". I really don't know what I am doing bad. The program I want to run is in the virtual machine and in the host machine also, both in the same path. The help that comes with Visual Build it's not enough at least for me to know how to work with this. Could somebody help me please Thanks a lot. <SEB@s> |
#2
|
|||
|
|||
I haven't worked with the Vis Build portion of the VMWare steps, but if you're using the vmrun command from the command line, you need to ensure that the program you want to run is fully pathed out...
ex: notepad.exe will give you an error, but "C:\Winnt\notepad.exe" shouldn't (assuming Win2k). Maybe the same thing is important here... My $0.02. e. |
#3
|
|||
|
|||
The runProgramInGuest command requires VMware Workstation v6.
|
#4
|
|||
|
|||
Quote:
"Error: Command failed: Guest tools is not runningProcess completed with exit code -1 2/26/2008 1:55:36 PM: Step 'VMware Workstation-Connect&Exit' " I don't know which is the probelm. Has anybody used VMware Workstation? Does anybody know if it works? If someone can give me some samples I'll really apreciate that. Thanks <SEB@s> PS: I am also giving the full path. Thanks for ur 2 cents anyway. Last edited by sebainones; 02-26-2008 at 11:05 AM. |
#5
|
|||
|
|||
Quote:
Although, one thing that I have noticed, and I hope kinook can answer, if I do run the Run Program action, I will get the "Guest operations are not allowed for the anonymous user on this virtual machine". When I do the same via VBScript or through the VIX API, I have to perform a LogonInGuest(username, password) command before any other commands will work. Is there a step within Visual Build that will log in the guest? Or will that step have to be done another way? Thanks! Eric. |
#6
|
|||
|
|||
Waiting for Kinook answer
Now I am in the same situtation as you:
Error: Command failed: Guest operations are not allowed for the anonymous user on this virtual machineProcess completed with exit code -1 So, I have to wait for the Kinook answer. Bye and thanks for ur help <SEB@s> |
#7
|
|||
|
|||
From testing here, the command from the CMD Line would be something like:
vmrun -gu <username> -gp <password> runProgramInGuest <path to vmx> <command> <command arguments> From what I've seen (and this is in v6.4), i can't find a way of added the -gu and -gp options just after the vmrun portion of the command (as seen by using the "Log Command Line used"). And when I try to "Override the EXE", I get: "c:\program files\VMware\VMware Workstation\vmrun.exe -gu user -gp qwerty" as the command line...which errors out, since the -gu/gp are included as part of the executable, which is no good. It'd work if it was: "c:\program files\VMware\VMware Workstation\vmrun.exe" -gu user -gp qwerty (note, the quotes are excluding the -gp/-gu portions. So, sebainones, unless Kinook can supply with the solution, I think your best bet would be to use a "Run Program" action to execute your command in the VM. Hope this helps. eric. |
#8
|
|||
|
|||
Sample Run Program Step:
Code:
<step action='Run Program'> <command>"C:\program files\vmware\vmware workstation\vmrun.exe" -gu user -gp password runProgramInGuest "i:\vm images\smoketest win2000\Windows 2000 Professional.vmx" "c:\winnt\notepad.exe"</command> <indent type='3'>1</indent> <name>Run Program</name> <outputfrom type='3'>1</outputfrom> </step> Another note: This command will 'wait' until the program you launch terminates. In this example, by default, visual build will 'wait' until Notepad terminates inside the VM. If you uncheck "Wait for Completion", it'll launch the script, and continue on with the build. |
#9
|
|||
|
|||
The latest v6.7 download adds support for the guest username/password to the VMWare Workstation action.
|
#10
|
|||
|
|||
Nicely done!
Thanks for the quick reply/update. |
#11
|
|||
|
|||
Thanks
Thanks for ur reply/uodate as ericp said. Thanks ericp for ur help too.
Now it works. Just a suggestion. In my case I had a user account in the virtual machine that it doesn't have a password. So when I try to use the "Run Program" command it needs a password although it doesn't need it really. So i had to create a user and actually set it a password. The activate teh autologon and finally i succed doing the "Run program" command. |
|
|