[Solved] VERR_PROC_ELEVATION_REQUIRED (VirtualBox guestcontrol execute)

Discussions related to using VirtualBox on Linux hosts.
Locked
rmnzero
Posts: 2
Joined: 15. Aug 2019, 13:23

[Solved] VERR_PROC_ELEVATION_REQUIRED (VirtualBox guestcontrol execute)

Post by rmnzero »

Hello,

I am trying to run a program inside a Windows 7 Pro 64-bit guest VM from my Linux (Debian 9) host via command-line:

Code: Select all

VBoxManage guestcontrol Win7-64bit-Pro-VM1 run --exe "C:\Program Files\7-Zip\Uninstall.exe" --verbose --username Admin1 --password "123"
However, since the program needs elevation, I get this error:

Code: Select all

Creating guest session as user 'VM1'...
Waiting for guest session to start...
Successfully started guest session (ID 8)
Starting guest process ...
VBoxManage: error: VERR_PROC_ELEVATION_REQUIRED
VBoxManage: error: Details: code VBOX_E_IPRT_ERROR (0x80bb0005), component GuestProcessWrap, interface IGuestProcess, callee nsISupports
VBoxManage: error: Context: "WaitForArray(ComSafeArrayAsInParam(aWaitStartFlags), gctlRunGetRemainingTime(msStart, cMsTimeout), &waitResult)" at line 1470 of file VBoxManageGuestCtrl.cpp
Closing guest session ...
I tried to disable UAC on Windows 7 guest VM, but it didn't work.

Is there a solution for this problem?

I am using VirtualBox 6.0.10

Thank you
Last edited by socratis on 17. Aug 2019, 23:27, edited 1 time in total.
Reason: Marked as [Solved].
socratis
Site Moderator
Posts: 27330
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: VERR_PROC_ELEVATION_REQUIRED (VirtualBox guestcontrol execute)

Post by socratis »

If the program needs elevation, then give the credentials of a user that has the proper access. Don't expect an interactive session where you're going to be asked for a password or any other input. This command should work if there's no feedback required. Makes sense if you think about it; it's a fire-and-forget.
Do NOT send me Personal Messages (PMs) for troubleshooting, they are simply deleted.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
rmnzero
Posts: 2
Joined: 15. Aug 2019, 13:23

Re: VERR_PROC_ELEVATION_REQUIRED (VirtualBox guestcontrol execute)

Post by rmnzero »

Thanks for the input, I managed to solve it by using "start" instead of "run", i.e:

Code: Select all

root@server:~# VBoxManage guestcontrol Win7-64bit-VM1 start --exe "C:\Program Files\7-Zip\Uninstall.exe" --verbose --username Admin1 --password "123"
Creating guest session as user 'VM1'...
Waiting for guest session to start...
Successfully started guest session (ID 3)
Starting guest process ...
[344 - Session 3]
waitResult: 1
Process successfully started!
Guest session detached
Seems that by using "run" it was waiting for the (GUI) program to send stdout, stderr, and stdin to the host:

Code: Select all

run: Executes a guest program, forwarding stdout, stderr, and stdin to and from the host until it completes.
socratis
Site Moderator
Posts: 27330
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: VERR_PROC_ELEVATION_REQUIRED (VirtualBox guestcontrol execute)

Post by socratis »

Interesting, I never realized the subtle differences between the "run" and the "start", never had the need I guess. Thanks for the feedback and the solution. Marking as [Solved].
Do NOT send me Personal Messages (PMs) for troubleshooting, they are simply deleted.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
Locked