VirtualBox

Opened 5 years ago

Closed 5 years ago

#19518 closed defect (fixed)

Guest command execution fails if more than 2 environment vars are provided => fixed in svn/6.1.x x>6

Reported by: mskov Owned by: paulson
Component: guest additions Version: VirtualBox 6.1.6
Keywords: Cc:
Guest type: Linux Host type: Windows

Description

If more than 2 environment vars are provided during the guest command execution, we get an error VERR_ENV_INVALID_VAR_NAME:

C:\WINDOWS\system32>"C:\Program Files\Oracle\VirtualBox\VBoxManage.exe" guestcontrol TestVM run --username root --password keins --exe /bin/ls --putenv "test1=test" --putenv "test2=test" --putenv "test3=test" --wait-stdout
VBoxManage.exe: error: VERR_ENV_INVALID_VAR_NAME
VBoxManage.exe: error: Details: code VBOX_E_IPRT_ERROR (0x80bb0005), component GuestProcessWrap, interface IGuestProcess, callee IUnknown
VBoxManage.exe: error: Context: "WaitForArray(ComSafeArrayAsInParam(aWaitStartFlags), gctlRunGetRemainingTime(msStart, cMsTimeout), &waitResult)" at line 1470 of file VBoxManageGuestCtrl.cpp

With 2 vars it works fine:

C:\WINDOWS\system32>"C:\Program Files\Oracle\VirtualBox\VBoxManage.exe" guestcontrol TestVM run --username root --password keins --exe /bin/ls --putenv "test1=test" --putenv "test2=test" --wait-stdout
bin
boot
data
dev
....

The problem happens with a Debian 10 guest with GAs 6.1.6. It does not happen with GAs 6.1.4 (or earlier).

Change History (2)

comment:1 by paulson, 5 years ago

Owner: set to paulson
Status: newassigned

Thanks for the report. The environment variable handling in VBoxService was simplified in VirtualBox revision r83269 in the development branch and these changes were backported to 6.0.20 and 6.1.6. However a regression was introduced in that changeset which broke the handling of environment variables when there are more than two of them. A fix is in progress.

Last edited 5 years ago by paulson (previous) (diff)

comment:2 by paulson, 5 years ago

Resolution: fixed
Status: assignedclosed
Summary: Guest command execution fails if more than 2 environment vars are providedGuest command execution fails if more than 2 environment vars are provided => fixed in svn/6.1.x x>6

This has been addressed in revision r137736 of the development branch of VirtualBox and will be available in any development snapshot Testbuilds of the Guest Additions which includes that revision. The fix has also been backported to the 6.1 branch of VirtualBox as of revision r137747 and will be available in any 6.1.x Testbuilds of the Guest Additions which include that revision. The fix will also be part of the next maintenance release of VirtualBox 6.1.x.

Note: See TracTickets for help on using tickets.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette