Configuring 1920x1080 Resolution for Ubuntu Virtual Machine#
Those who have installed Ubuntu on a virtual machine should know that the initial resolution is frustratingly small and makes it difficult to use. Therefore, it is necessary to adjust the resolution. However, some resolutions may not be available in Ubuntu by default, so we need to customize them ourselves.
Customizing the resolution:
-
Enter:
cvt 1920 1080
The result returned is:
-
Check the name of the display:
Enter:xrandr
It can be seen that the name of my display is Virtual1.
-
Set the resolution:
Enter:
sudo xrandr --newmode "1920x1080_60.00" 173.00 1920 2048 2248 2576 1080 1083 1088 1120 -hsync +vsync
sudo xrandr --addmode Virtual1 "1920x1080_60.00"
-
Select the
1920X1080
resolution:
Go toSystem Settings
->Displays
, and choose1920X1080 (16:9)
in theResolution
section, then clickApply
.
-
Save the resolution:
Although the resolution has been set, it will be reset after restarting. To make it permanent, you need to save these two commands:
Enter:sudo gedit /etc/profile
Add the above command at the end of the file.
-
Restart:
Congratulations, you're done! Restart to verify!