Hyper-V

Ubuntu in Hyper-V

Whilst running Ubuntu 20.04 in a Windows 10 Hyper-V VM, I found that I could not change the screen resolution. I am not sure what the root cause of the issue was but the following fixed it!

Change Screen Resolution

It defaulted to 1024x768, but 1440x900 works better as some dialogs are no longer cropped and it uses more of my monitor, to make the change, do the following:

  • Start VM and login
  • Open a terminal session
  • Execute: sudoedit /etc/default/grub
    this prompts for password, to sudo, so enter it
  • Use the arrow keys to navigate to the line that says:
    GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
    and change it to
    GRUB_CMDLINE_LINUX_DEFAULT="quiet splash video=hyperv_fb:1440x900"
  • Press Ctrl+X to exit, press Y to save and press Enter to accept the odd-looking filename
  • Execute: sudo update-grub
  • Execute: sudo reboot
  • Done!