
In this article, we will guide you through the process of resizing the Ubuntu display in Hyper-V on Windows 10 and 15.04. This can be a common issue for users running Ubuntu as a guest operating system (OS) in a Hyper-V virtual machine (VM).
To resize the Ubuntu display in Hyper-V on Windows 10 and 15.04, you need to edit the GRUB file, remove the RemoteFX 3D Video Adapter, install the Hyper-V display driver, and optionally use Enhanced Session Mode for a better display experience.
Prerequisites
Before we start, ensure that you have the following:
- A Windows 10 or 15.04 host OS with Hyper-V installed and running.
- An Ubuntu 15.04 guest OS installed in a Hyper-V VM.
Step 1: Editing the GRUB File
The first step involves editing the GRUB (Grand Unified Bootloader) file in your Ubuntu OS. The GRUB file is responsible for managing the boot process of the OS.
- Open a terminal in Ubuntu. You can do this by pressing
Ctrl+Alt+T
. - Run the following command to open the GRUB file in a text editor with root privileges:
sudo nano /etc/default/grub
- Look for the line that reads
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
. - Change this line to
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash video=hyperv_fb:1920x1080"
. Replace1920x1080
with your desired resolution. - Save the changes and exit the text editor. In nano, you can do this by pressing
Ctrl+X
, thenY
to confirm saving the changes, and finallyEnter
to exit. - Now, you need to update the GRUB configuration. Run the following command in the terminal:
sudo update-grub
- Reboot the Ubuntu guest OS for the changes to take effect. You can do this by running the
reboot
command.
Step 2: Removing the RemoteFX 3D Video Adapter
If you have added the RemoteFX 3D Video Adapter in the VM settings, you need to remove it. This adapter can cause issues with the display resolution in Ubuntu.
- Open the settings of your VM in Hyper-V.
- Navigate to the
Hardware
section. - Locate and remove the RemoteFX 3D Video Adapter.
- Reboot the Ubuntu guest OS for the changes to take effect.
Step 3: Installing the Hyper-V Display Driver
The next step is to install the Hyper-V display driver in your Ubuntu OS. This driver improves the display performance in Hyper-V.
- Open a terminal in Ubuntu.
- Run the following command to install the Hyper-V display driver:
sudo apt-get install linux-image-extra-virtual
- Reboot the Ubuntu guest OS for the changes to take effect.
Step 4: Using Enhanced Session Mode
If you are using Ubuntu 18.04.1 or later, you can use the Enhanced Session Mode for a better display experience. This mode provides a full Linux desktop experience with adjustable window sizes, clipboard sharing, drive redirection, and more.
You can either use the optimized Ubuntu Desktop images available in the Microsoft Hyper-V gallery or manually configure xRDP to support Enhanced Session Mode.
Conclusion
Resizing the Ubuntu display in Hyper-V on Windows 10 and 15.04 can be a bit tricky, but with the right steps, it’s certainly doable. Remember that certain configurations, such as Surface Book or Ubuntu 20.04, might have specific issues, so always check for the latest solutions and updates. We hope this guide has been helpful in resolving your display resolution issues in Ubuntu running on Hyper-V.
Yes, you can resize the Ubuntu display in Hyper-V on Windows 10 and 15.04 by following the steps outlined in this article.
The prerequisites for resizing the Ubuntu display in Hyper-V are a Windows 10 or 15.04 host OS with Hyper-V installed and running, and an Ubuntu 15.04 guest OS installed in a Hyper-V VM.
To edit the GRUB file in Ubuntu, open a terminal and run the command sudo nano /etc/default/grub
. This will open the GRUB file in a text editor with root privileges.
In the GRUB file, you need to change the line GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
to GRUB_CMDLINE_LINUX_DEFAULT="quiet splash video=hyperv_fb:1920x1080"
. Replace 1920x1080
with your desired resolution.
To update the GRUB configuration, run the command sudo update-grub
in the terminal.
Yes, if you have added the RemoteFX 3D Video Adapter in the VM settings, you need to remove it to avoid display resolution issues in Ubuntu.
To install the Hyper-V display driver in Ubuntu, open a terminal and run the command sudo apt-get install linux-image-extra-virtual
.
Enhanced Session Mode provides a better display experience in Ubuntu. If you are using Ubuntu 18.04.1 or later, you can either use the optimized Ubuntu Desktop images available in the Microsoft Hyper-V gallery or manually configure xRDP to support Enhanced Session Mode.
Yes, you need to reboot the Ubuntu guest OS for the changes to take effect after editing the GRUB file, removing the RemoteFX 3D Video Adapter, and installing the Hyper-V display driver.
Certain configurations, such as Surface Book or Ubuntu 20.04, might have specific issues. Always check for the latest solutions and updates to resolve any display resolution issues.