dev-resources.site
for different kinds of informations.
How to change the Screen Resolution of a Guest-OS (Ubuntu) in Hyper-V with PowerShell on Windows 11
Published at
6/6/2024
Categories
hyperv
powershell
vm
windows11
Author
Diego Carrasco Gubernatis
TL;DR
To change the screen resolution of a VM in Hyper-V, use PowerShell. The command requires the VM name and the desired resolution.
Context
Unlike in VirtualBox, in Hyper-V I could not find a GUI option to change the screen resolution directly. Instead, I had to use PowerShell to adjust the display settings of your virtual machine.
Steps
- Identify the VM Name
Find the name of your VM in Hyper-V Manager. (Search for Hyper-V Manager in the start menu to access it)
- Open PowerShell
Open a PowerShell terminal on your host machine.
- Execute the Command
Use the following PowerShell command, replacing "Ubuntu 22.04 LTS2"
with your VM's name and adjusting the resolution as needed:
Set-VMVideo -VMName "Ubuntu 22.04 LTS2" -HorizontalResolution 1920 -VerticalResolution 1080 -ResolutionType Single
- HorizontalResolution : The width of the screen in pixels (e.g., 1920).
- VerticalResolution : The height of the screen in pixels (e.g., 1080).
-
ResolutionType : Set to
Single
for a single monitor setup.
References
Articles
12 articles in total
How to Install Tailscale in a Proxmox CE 8.2 LXC Container (AlmaLinux 9)
read article
How to recover and update Proxmox 8 firewall configuration in SQLite when you locked yourself out
read article
How to manage multiple AsciiDoc Chapter Files: Copy, Merge, and Customize
read article
(Quick-note) Troubleshooting Dual Monitor Issues on KDE on Ubuntu/ Linux Mint
read article
Introducing the FlexSearch Plugin for Nikola
read article
How to fix incrementing mount names on reboot in Ubuntu/Linux Mint
read article
Introducing the GitHub Widget Plugin for Nikola
read article
How to Optimize and Free Up Disk Space on Debian/Ubuntu Servers with Docker Containers
read article
Exciting News: My Upcoming Book "The Digital Marketerโs Playbook" is about to launch
read article
Quick and simple Local WordPress Setup for Lazy Developers
read article
How to change the Screen Resolution of a Guest-OS (Ubuntu) in Hyper-V with PowerShell on Windows 11
currently reading
How to set up a Nikola-powered blog with multi-markup support
read article
Featured ones: