Ubuntu cannot adjust the resolution problem

Reason: Due to the epidemic at home, I need to use the school server, but the school’s intranet is isolated from the network, and it is troublesome to apply for a VPN from the school, so I bought a ToDesk membership directly, but after connecting, I found that the resolution is 1024*768, which is a bit unsightly Going on, the official did not propose a corresponding solution, saying that it cannot be solved? ? ?

1. First use the xrandr command to list the currently detectable resolutions, such as a display, the best resolution is 1920x1080, because it cannot be detected correctly, use the xrandr command:

xiao@dian-smart-group:~$ xrandr                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         
Screen 0: minimum 320 x 200, current 1024 x 768, maximum 1920 x 2048                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   
VGA-1 connected primary 1920x1080+0+0 inverted (normal left inverted right x axis y axis) 0mm x 0mm 

It can be seen that the currently used graphics card is VGA-1 (the subsequent display mode will be added on this graphics card), and there is no resolution of 1920x1080 available in the list.

2. At this time, you can use the xrandr command to add a new display mode. Since the display mode has a certain format, if you don’t know how to configure it, you can get it through cvt.
How to use cvt: cvt XY, X represents the resolution width, Y represents the resolution height. To generate a resolution of 1920x1080, you can use the command:

xiao@dian-smart-group:~$ cvt 1920 1080                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  
# 1920x1080 59.96 Hz (CVT 2.07M9) hsync: 67.16 kHz; pclk: 173.00 MHz                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    
Modeline "1920x1080_60.00"  173.00  1920 2048 2248 2576  1080 1083 1088 1120 -hsync +vsync

3. Use the xrandr command to add the display mode obtained by cvt:

sudo xrandr --newmode "1920x1080" 173.00 1920 2048 2248 2576 1080 1083 1088 1120 -hsync +vsync 
sudo xrandr --addmode VGA-1 1920x1080 
sudo xrandr --output VGA-1 --mode 1920x1080

4. At this time, you can use the resolution of 1920x1080 in the display resolution setting.

But it may not be able to use the set resolution every time it is turned on, use the following command:

sudo gedit ~/.profile

Add the command to modify the resolution at the end of ~/.profile:
copy code

cvt 1920 1080
xrandr --newmode “1920x1080” 173.00 1920 2048 2248 2576 1080 1083 1088 1120 -hsync +vsync
xrandr --addmode VGA-1 1920x1080

Restart the system and then log in. At this time, use the xrandr command to see the newly added resolution.
VGA-1 is obtained by running the xrandr command in the first step.

Guess you like

Origin blog.csdn.net/qq_41318914/article/details/128651701
Recommended