Last Updated:

Change the screen resolution in Debian Linux.

 

Debian
 

Today I installed Debian OS 8 on a computer with a 24 inch monitor and encountered the problem of the maximum screen resolution (1920x1080).

Alas, Linux without drivers supported (1024x768) screen resolution. As a result, my desktop was the size of a small window against the background of a large monitor.

Scratching your head, I found the following solution to the problem:

Open the terminal and run the command xrandr:


After executing the command, you should see the result, which will indicate the supported screen resolutions.
I didn't see the permission I needed.
The result of the xrandr command:
xrandr
Screen 0: minimum 320 x 200, current 1920 x 1080, maximum 8192 x 8192
DVI-I-1 connected primary 1024x768+0+0 (normal left inverted right x axis y axis) 0mm x 0mm
   1024x768      60.00  
   800x600       60.32    56.25  
   848x480       60.00  
   640x480       59.94  
DVI-I-2 disconnected (normal left inverted right x axis y axis)


From the output of the executed command, it can be seen that the monitor is connected to the DVI-I-1 output of the video card.

The DVI-I-2 port is not involved.

I needed a resolution (1920x1080), but it wasn't among the suggested options, so I added the necessary permission myself.

  • Run the following command in terminal cvt 1920 1080 75:

    Where 1920x1080 is the screen size and
    75 is the refresh rate of the monitor screen.

    Results of the output of the executed command:


    Yes in my case I put 75. I'll explain why.
    Initially, I set the refresh rate of the screen - 60, like modern LCD monitors. But I had black margins around the edges of the screen that really bothered me. Solved this problem by setting the refresh rate of the monitor screen to 75.

  • How the frequency of the screen affected the size of the screen I did not understand, do not understand and will not understand. It works and well!
    So, if you encounter a similar problem, then you can look for a solution in the size of the frequency.

    From the results obtained, copy the text highlighted in red:
    cvt 1920 1080 75
    # 1920x1080 74.91 Hz (CVT 2.07M9) hsync: 84.64 kHz; pclk: 220.75 MHz
    Modeline "1920x1080_75.00"  220.75  1920 2064 2264 2608  1080 1083 1088 1130 -hsync +vsync

    # 1920x1080 74.91 Hz (CVT 2.07M9) hsync: 84.64 kHz; pclk: 220.75 MHz
    Modeline 
    "1920x1080_75.00" 220.75 1920 2064 2264 2608 1080 1083 1088 1130 -hsync +vsync


    And insert it at the end of this command:


    You should get something like the following:


    Now you need to add it to the system:



    Where instead of DVI-I-1 you need to specify the output type of your video card.

    Start this mode:



    When you finish executing these commands, you should change the screen resolution to the required one.
    At least it helped me. Next, you need to make sure that this screen resolution loads along with the system boot.
    To do this, in the terminal, run the command:


    And create a file with the extension sh. To do this, again in the terminal, run the command:


    Then in this file I added some of the already executed code given in this article:
    xrandr --newmode 
    xrandr --newmode "1920x1080_75.00"  220.75  1920 2064 2264 2608  1080 1083 1088 1130 -hsync +vsync
    xrandr --addmode DVI-I-1 1920x1080_75.00
    xrandr --output DVI-I-1 --mode 1920x1080_75.00
    cd /bin
    nano Display.sh


    #!/bin/sh
    xrandr --newmode "1920x1080_75.00"  220.75  1920 2064 2264 2608  1080 1083 1088$
    xrandr --addmode DVI-I-1 1920x1080_75.00
    xrandr --output DVI-I-1 --mode 1920x1080_75.00


    Save (ctrl + o) and close (ctrl + x).

  • Now click the second mouse button on the file and go to the properties and check the box (Properties->Access rights-> Allow the execution of the file as an application).
    Launch the Startup Apps app and add the Display.sh file to the startup app startup.
    All. Now, with each system boot, the screen resolution you configured will also start.