VBoxHeadless VM process remains running after stop

Discussions related to using VirtualBox on Windows hosts.

VBoxHeadless VM process remains running after stop

Postby Tom79 » 28. Sep 2021, 11:14

I was looking the forum entries for similar issues/problems but I didn't find something.

I'm using VirtualBox on Windows10 (Version 1909 Build 18363.1734).
I updated VirtualBox from 6.1.22 to 6.1.26.

I use VirtualBox VMs in headless mode via VBoxMangage for a longer time with different VirtualBox versions. But with VirtualBox 6.1.26 I have following problem.

step1: I start a debian buster x64 VM from command in headless mode with "VBoxManage.exe startvm <vm-name> --type headless". This is ok.
step2: Also stopping the VM seems to be ok, the command "VBoxManage.exe controlvm <vm-name> acpipowerbutton" doesn't show an error, the result code is ok.
step3: Trying to start the VM again leads to following output:

Waiting for VM "SimSvc_VBox6-1-26-Test" to power on...
VBoxManage.exe: error: The VM session was closed before any attempt to power it on
VBoxManage.exe: error: Details: code E_FAIL (0x80004005), component SessionMachine, interface ISession
Error Starting VM

I deleted the VM and I repeated the steps and there I saw after step2 by means of Windows ProcessExplorer that the Window-Process "VBoxHeadless.exe" is still running although the VM-stop command was ok.

After step2 I tried again to stop the VM - this leads to following command output:
VBoxManage.exe: error: Machine 'SimSvc_VBox6-1-26-Test' is not currently running
Error Stopping VM, errorcode 1

I attached the VM directory content (with logs) after step2 and after step3.
Attachments
SimSvc_VBox6-1-26-Test-after-2nd-start.zip
This is the VM directory content after step3.
(107.27 KiB) Downloaded 2 times
SimSvc_VBox6-1-26-Test-after-stop.zip
This is the VM directory content after step2.
(92.84 KiB) Downloaded 2 times
Tom79
 
Posts: 2
Joined: 6. Dec 2018, 14:53

Re: VBoxHeadless VM process remains running after stop

Postby scottgus1 » 28. Sep 2021, 14:29

'Tis a known bug, see https://www.virtualbox.org/ticket/20574. Workaround for now is to roll Virtualbox back to a version that worked. The Bugtracker poster restored proper headless operation with 6.1.22.
scottgus1
Site Moderator
 
Posts: 13389
Joined: 30. Dec 2009, 20:14
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Windows, Linux

Re: VBoxHeadless VM process remains running after stop

Postby fth0 » 28. Sep 2021, 15:02

Tom79 wrote:I repeated the steps and there I saw after step2 by means of Windows ProcessExplorer that the Window-Process "VBoxHeadless.exe" is still running although the VM-stop command was ok.

How many Windows processes named "VBoxHeadless.exe" were running before (3) and after step2 (1|2|3)?
fth0
Volunteer
 
Posts: 2502
Joined: 14. Feb 2019, 03:06
Location: Germany
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Linux, Windows 10, ...

Re: VBoxHeadless VM process remains running after stop

Postby Tom79 » 29. Sep 2021, 08:25

Yes, after step1 (start-VM) there are 3 VBoxHeadless Windows processes running and after step2 (stop-VM) there is 1 VBoxHeadless process.
Tom79
 
Posts: 2
Joined: 6. Dec 2018, 14:53

Re: VBoxHeadless VM process remains running after stop

Postby fth0 » 12. Oct 2021, 19:40

This issue should be fixed in the VirtualBox test builds 6.1.27r147422 and newer.
fth0
Volunteer
 
Posts: 2502
Joined: 14. Feb 2019, 03:06
Location: Germany
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Linux, Windows 10, ...


Return to VirtualBox on Windows Hosts

Who is online

Users browsing this forum: No registered users and 52 guests