I have a windows 7 host and a debian 8 guest. I already installed
virtualbox-guest-utils virtualbox-guest-x11 virtualbox-guest-dkmsas described in . Before installing these packages I was able to select a maximum of 1024*768. After installation 1600*1200 was possible. But I simply want to use 1920*1080 fullscreen on my display.
Pressing Host-G is not possible. I seams this combination is deactivated.How do I increase VirtualBox resolution past 800x600 in Linux?
Is there a way to do this?
6 Answers
I found a solution for that in the meanwhile.
There are two descriptions that show how this works:
1st:How to adjust the screen resolution in Debian?
2nd:
In short:
$ cvt 1920 1080 60
# 1920x1080 59.96 Hz (CVT 2.07M9) hsync: 67.16 kHz; pclk: 173.00 MHz
Modeline "1920x1080_60.00" 173.00 1920 2048 2248 2576 1080 1083 1088 1120 -hsync +vsync
$ xrandr --newmode "1920x1080_60.00" 173.00 1920 2048 2248 2576 1080 1083 1088 1120 -hsync +vsync
$ xrandr --addmode VBOX0 "1920x1080_60.00"
$ xrandr --output VBOX0 --mode 1920x1080_60.00After execution these commands automatically the new resolution appears. Additionally these commands must be executed after each start of the operating system.
In the meantime I wrote a blog post about that topic:
2A straightforward way of achieving that would be to change the specific configuration in the grub2 bootloader directly:
Find out the resolutions supported by your debian guest
- Reboot debian and keep pressing
cuntil you see the grub console. - Press
vbeinfoand hit enter. It will give you a list of supported resolutions.
- Reboot debian and keep pressing
Edit
/etc/grub.d/00_header- Replace
autoin the lineif [ "x${GRUB_GFXMODE}" = "x" ] ; then GRUB_GFXMODE=auto ; fiwith the new resolution. e.g.:if [ "x${GRUB_GFXMODE}" = "x" ] ; then GRUB_GFXMODE=1920x1080 ; fi - Right underneath, make a copy of the line edited and replace
MODEwithPAYLOAD. e.g.:if [ "x${GRUB_GFXPAYLOAD}" = "x" ] ; then GRUB_GFXPAYLOAD=1920x1080 ; fi - Further below, you'll find the following line:
set gfxmode=${GRUB_GFXMODE}. Add the following line below it:set gfxpayload=${GRUB_GFXPAYLOAD}
- Replace
- Reload grub2 configurations by running the command
update-grub2and rebooting afterwardsreboot
[Note]
I've seen many examples in which the default line #GRUB_GFXMODE=640x480 in the file /etc/defaul/grub in uncommented. It was proven to be unnecessary for me but in case you need it, remember to update-grub2 after you've uncommented it.
I know this question realtes to different versions but it might be usefull for someone that has installed the latest version of VirtualBox (5.2)
My setup:
- VirtualBox 5.2.0 r118431
- Host OS: Windows 10
- Guest OS: Linux Debian 9.2.1 with XFCE
- Guest Additions ISO: VBoxGuestAdditions_5.2.1-118447 (please note that this is not the ISO you get with the default installer, there is a note on virtualbox site to download a newer version)
The following commands must be run in super user mode on guest OS rebooted:
mkdir -p /lib/modules/$(uname -r)/build/include/drm
touch /lib/modules/$(uname -r)/build/include/drm/drm_rect.hThe VBoxLinuxAdditions.run must be executed again, and then guest OS need a reboot
There is also a newer Guest Additions ISO in the development downloads which should fix this problem Virtualbox Test builds
Credits:
Check the screen size in Windows:
Control panel -> Sound & Hardware -> Screen
Y the left of the windows select Adjust resolution, and you can see what is the actual resolution of the host screen, use that in your Ubuntu/Debian. In Debian go to Settings -> Displays, choose the display and adjust the resolutions, that's all.
I'm using a Debian 10 image in VirtualBox under Windows 10, and installed Debian with the default GUI.
I found that within the GUI, I was able to select a resolution directly (eg. 1920x1440 in my case, my host machine's max res), avoiding having to wrangle with the CLI.
Settings (app) -> Devices -> Displays -> Resolution
Choosing a resolution caused the VM to assume the selected screen size and the VirtualBox window resized appropriately.
3My issue was that although the 1920x1080 resolution was available and enabled in the VB menu, selecting it didn't change it.
I've tried the sudo apt-get install virtualbox-guest-utils virtualbox-guest-x11 virtualbox-guest-dkms, and the suggestion to correct the Grub-file above, but what seemed to do the trick, was to upgrade Virtualbox to 5.1.20 and install the corresponding version of the guestadditions.