I have had three problems on a linux host:
If it is not disabled you have to hit Return when VBox asks to go full screen
Mouse de-integration is not automatic (my client nabs the usb mouse directly)
and...
The VBoxControl program in the client savestate command is borked
The following script takes care of all three issues.
It requires you to apt-get wmctrl and xdotool.
Guest additions must be installed.
Change VM_NAME!
Change DISPLAY to whatever monitor you want.
To savestate run "sudo VBoxControl guestproperty set SaveStateNow 1" in a client terminal.
---cut-here---
#!/bin/bash
VM_NAME='My Machine Name'
MAXTRIES=20
export DISPLAY=:0.1
VBoxManage startvm "$VM_NAME" &
i="0"
while [ $i -lt $MAXTRIES ]; do
echo Fullscreen try $i
wmctrl -a "VirtualBox - Information"
if [ $? == 0 ]; then
sleep 1
xdotool key "Return"
break
fi
sleep 1
i=$[$i+1]
done
i="0"
while [ $i -lt $MAXTRIES ]; do
echo Pointer try $i
GUEST_ADDITIONS_ACTIVE=`VBoxManage showvminfo "$VM_NAME" | grep "Additions run level" | cut -d : -f 2`
if [ $GUEST_ADDITIONS_ACTIVE == "1" ]; then
sleep 1
xdotool key "Super_R+i"
break
fi
sleep 1
i=$[$i+1]
done
while true; do
if [ "`VBoxManage guestproperty get "$VM_NAME" SaveStateNow`" != 'No value set!' ]; then
echo Saving...
VBoxManage guestproperty set "$VM_NAME" SaveStateNow
VBoxManage controlvm "$VM_NAME" savestate
break
fi
sleep 1
done
2"Unfortunately, it looks like I have to press Host+I" :'( – John T – 2010-11-24T00:52:50.583
Ok, it sounds whiny, but the point is that I suspect that when mouse integration kicks in, it disrupts my Wacom tablet. But I didn't want to mention that problem because it is irrelevant here, I'll post another question on that :P – UncleZeiv – 2010-11-24T00:55:38.880
Linux or Windows vm? – John T – 2010-11-24T00:56:48.817
I'm using Windows 7 64bit as host and Ubuntu 10.10 64bit as guest. I didn't mention it as I expected it to be a feature of Virtualbox itself... if it exists, that is. – UncleZeiv – 2010-11-24T01:12:40.610
Post your xorg.conf please. – John T – 2010-11-24T23:45:53.380
Yeah I didn't really have any luck with any of the answers here with VirtualBox 6.1.0 and an Ubuntu 18.04 LTS guest on a Windows 10 host; so I filed a bug report, not sure what else to do.
– Jason C – 2020-01-11T16:12:52.587