Welcome to deBUG.to Community where you can ask questions and receive answers from Microsoft MVPs and other experts in our community.
0 like 0 dislike
48k views
in Linux by 2 2 4

I am a new user of Linux, I am trying to create an Ubuntu 20.04.1 virtual machine using Hyper-V. the Hyper-V Ubuntu virtual machine has created successfully, but when starting the Ubuntu virtual machine, I noticed that the Ubuntu virtual machine is not displayed in full-screen mode.

change ubuntu display resolution in hyperv

I checked the display resolution in Ubuntu virtual machine that set to "1152*864 (4:3)" and I can't change it.

hyperv ubuntu full screen mode

Is there any simple way to change Ubuntu display resolution in Hyper-V?


1 Answer

2 like 0 dislike
by 159 199 383
selected by
 
Best answer

Change Ubuntu Display Resolution in Hyper-V and Virtual Box and VMware

Actually, it's a known issue. by default, the Ubuntu virtual machine display resolution is set to the recommended display resolution, and unfortunately, you can't change this setting from the GUI.

To show Ubuntu virtual machine in Full-Screen Mode by default, you should do the following:

  • Open Hyper-V Manager.
  • Connect to your Ubuntu virtual machine.
  • Click on Start to start it.
  • Once the Ubuntu virtual machine is started, right-click on any desktop, and select Open Terminal.
    start terminal ubuntu
  • Type the below command line

      sudo vi /etc/default/grub
    
  • Provide the password for your superuser.
    open sudo
  • Go to this line GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
  • Press i to edit the file.
    edit sudo file
  • After splash word, click on space from the keyword.
  • Paste this video=hyperv_fb:1920x1080
  • The final line should look like

      GRUB_CMDLINE_LINUX_DEFAULT="quiet splash video=hyperv_fb:1920x1080"
    

    Change Ubuntu Display Resolution in Hyper-V and Virtual Box and VMware

  • Now, type :wq to save your file.
    save sudo file
  • Again type sudo update-grub to apply your changes.
    sudo update grub
  • Finally, reboot your system by typing

      sudo reboot
    

    sudo reboot-min

  • Wait, a moment until the Ubuntu virtual machine is started.
  • Great, you will note that the Ubuntu virtual machine is opened by default in Full-Screen mode.
  • Also, in the Display resolution setting, you will note that the resolution has been changed from "1152*864 (4:3)" to your specified resolution "1920x1080 (9:6)"
    change ubuntu display resolution 1920x1080-min

Hyper-V Ubuntu fullscreen steps

Here, you can also find the detailed steps to display Ubuntu virtual machine in Full Screen mode in Hyper-V

ubuntu full screen hyperv

Applies To

  • Ubuntu 18.04
  • Ubuntu 20.04
  • VMware
  • Virtual Box
  • Hyper-V
by 2 2 4
1 0
Thank @mohamed it's worked like charm, could you please help me on this too https://debug.to/1012/start-hyper-v-failed-to-change-state
by 159 199 383
0 0
Glad to hear it helped you, Sure, I will check your new question :)
by 37 41 48
0 0
What about windows 10??
by
0 0
Thank you for posting this! These instructions work for Hyper-V on Windows 10, also.
by
0 0
Awesome! worked like a charm. many thanks!
by
0 0
what about rhel 8
by
0 0
Great. You solved my prblem. Thanks a lot
by
0 0
Thank you , it helped
If you don’t ask, the answer is always NO!
...