Hi,
I am running a few Windows guest in headless mode (as build machines). I basically launch them from a Linux host in headless mode. A startup script on the Windows machines subsequently performs the app build. Question is; is there a way to detect on the Windows guest, if the guest has been started in headless mode vs normal mode?
I need to determine this as I need to perform an action within the script based on the mode I started the guest in.
Cheerio,
Luuk
[Solved] Detect if running headless
[Solved] Detect if running headless
Last edited by socratis on 26. Jun 2018, 01:53, edited 1 time in total.
Reason: Marked as [Solved].
Reason: Marked as [Solved].
-
- Site Moderator
- Posts: 27329
- 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: Detect if running headless
That's an interesting question. And the answer might be to parse the output of:
VBoxManage showvminfo "<YourVM>"
(Starting "normal") ... Session name: GUI/Qt (Starting "headless") ... Session name: headless
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.
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.
Re: Detect if running headless
That assumes the 'VboxManage' command is available on the Windows guest. Which I believe it isn't.
The only command one might have avail on the Windows guest, through the guest additions ISO is vboxcontrol.exe. The latter doesn't provide any useful options to interogate what I need from the VM. Well I couldn't find any
The only command one might have avail on the Windows guest, through the guest additions ISO is vboxcontrol.exe. The latter doesn't provide any useful options to interogate what I need from the VM. Well I couldn't find any
-
- Site Moderator
- Posts: 27329
- 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: Detect if running headless
Oh, you want to know from the guest side, sorry...
You can set a property for the guest, if the guest has Guest Additions installed. See 4.7 Guest properties. If not, a shared file (like a flag) on a shared network location.
You can set a property for the guest, if the guest has Guest Additions installed. See 4.7 Guest properties. If not, a shared file (like a flag) on a shared network location.
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.
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.
Re: Detect if running headless
Thanks, that might work indeed
I thought there would be a more straight forward way to get that info. But hey I should be able to get it to work that way.
Thanks again,
Luuk
I thought there would be a more straight forward way to get that info. But hey I should be able to get it to work that way.
Thanks again,
Luuk
-
- Site Moderator
- Posts: 27329
- 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: Detect if running headless
Glad to have helped. Marking as [Solved].
You're right though, the VBoxControl within the guest could be expanded to include all the information of the "VBoxManage showvminfo" from the host...
You're right though, the VBoxControl within the guest could be expanded to include all the information of the "VBoxManage showvminfo" from the host...
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.
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.