Is anyone willing to assist me in changing the screen resolution of my Ubuntu Server.

I'm running virtualbox (ubuntu server guest) on a Windows 10 host.

I've checked every link I could possibly find and no luck.

I've also installed the guest additions for it.

  • By default Ubuntu Server doesn't have a gui interface. Which desktop manager did you install? – L. D. James Aug 18 '15 at 11:49
  • @L.D.James We usually don't install GUI on a server, because of the performance implications. – linux64kb Jun 1 '18 at 4:11
  • @linux64kb I agree. There are lots of things installed on a Desktop installation that are not commonly used or installed on a server. I don't think having the GUI installed on the server has a noticeable impact unless there is an occasion to run the GUI. I've seen some occasions where clients wanted the server installation because of the server applications that were installed by default but also wanted the GUI installed for lack of computer space, to allow the server to also function as a workstation in conjunction as the server. – L. D. James Jun 1 '18 at 4:18

1. Get supported video mode info (to achieve this, I had to install hwinfo)

>sudo apt-get install hwinfo

Then check supported modes (I was interested in setting the resolution to 1280x1024 and set the highest color depth available, so I'm going to check this.)

    sudo hwinfo --framebuffer |grep 1280x1024

The best available mode was shown like this

    > Mode 0x031b: 1280x1024 (+3840), 24 bits
    > Mode 0x0345: 1280x1024 (+5120), 24 bits

Strange as it is, 0x0345 worked from the above two modes only.

2. Edit /etc/default/grub

    sudo nano /etc/default/grub

Uncomment #GRUB_GFXMODE="some value", and change it to your resolution, also add GRUB_GFXPAYLOAD_LINUX line, like in the example below. Also modify GRUB_CMDLINE_LINUX_DEFAULT to reflect the video mode chosen.


Save the changes you have done.

3. Update grub

    sudo update-grub

4. Reboot:

    sudo reboot

If all went smooth, Ubuntu will boot in the resolution you set, for me 1280x1024x24 was fine.

Finally I managed to refine this solution, it's not partial any more.

If connecting with putty, cygwin, you will not experience this issue and the settings above will not change your terminal experience.

  • Worked on Ubuntu 16.04 too. – elbedoit Jan 20 '17 at 1:43
  • Worked on Ubuntu 15.10 too. – elbedoit Jan 21 '17 at 23:23
  • 1
    On Ubuntu 16.04.2 I also had to modify GRUB_CMDLINE_LINUX="video=0x0345" – elbedoit Feb 21 '17 at 21:15
  • You can also get the video modes by running vbeinfo from the grub prompt (but then you have to reboot) - see aboutfase.com/2015/06/… – David Fraser Aug 2 '17 at 9:57
  • 1
    @David Fraser I try to avoid reboot if possible. This is why I've chosen hwinfo. – elbedoit Dec 2 '17 at 18:07

Quick answer:

Go to the control on the top right of the screen -> (click) System Settings -> Displays -> [Click on the Resolution Drop-down option and select your preference].

Another way (which doesn't always work):

Click the View option to have the resolution automatically set by the windows size. This might not work unless you have compatible drivers for your installed system.

Please note: Some of the details will depend on the desktop GUI that you install. None is installed during the initial install.

  • Thank you for taking the time to post. There isn't an option under Settings/Displays (negative). As for the view option, I do see a virtual screen with different resolutions available but they are all grayed out. – user435195 Aug 18 '15 at 1:38
  • I didn't say settings. I don't know what you are looking at when you say settings. But if you click on System Settings at the top right hand corner of the screen (while you're logged in off course), you'll see around 20 icons. Two of them will look like monitors. One of them is titled Displays. If you don't have this, it would appear that you don't have a proper install of Ubuntu. – L. D. James Aug 18 '15 at 2:27
  • Either a) I'm completely oblivious or b) you are speaking of Ubuntu desktop, not server. – user435195 Aug 18 '15 at 2:42
  • @user435195 Sorry. You're right. I was looking at a desktop feature. I'll look for the server equivalent and update my answer. – L. D. James Aug 18 '15 at 2:49

I realize I'm a little late to the party, but...

This is a more native method, but the upside is that you get to skip the Guest Additions stuff. I never got that to work despite the 150 different "guides". The downsides are that you have to do this every time you've ran sudo update-grub and the window doesn't auto-resize.

sudo nano /boot/grub/grub.cfg

Find this entry: menuentry 'Ubuntu' --class ubuntu --class gnu etc.

Below that line, find the indented line that looks something like this: linux /vmlinuz-4.2.0-16-generic root=/dev/mapper/dev--vg-root ro

At the end of that line, append the following: vga=somevaluehere

VGA values here: http://www.pendrivelinux.com/vga-boot-modes-to-set-screen-resolution/

I'm using linux /vmlinuz-4.2.0-16-generic root=/dev/mapper/dev--vg-root ro vga=792 which is large enough for a 24 inch. Any larger than that and it gives you scroll bars in the VM window.


There is no need to run commands nor install guest additions. I just hit shift+ctrl+c so it takes the guest host to scale mode, and then you can adjust the scale factor from settings display and adjust it for larger.

  • This is not guaranteed to work, especially if guest additions were not installed. – Thomas Ward Jan 29 '16 at 15:49
  • Moreover, this does not work with a standard "headless = without GUI" server installation. – linux64kb Jun 5 '18 at 20:02

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.