xrandr
is a tool to modify your X session settings at runtime. The --addmode
option is used to force the Xrandr extension to use an output mode that was not detected at Xorg startup (not save the mode in some configuration file).
It may be that you use xrandr --addmode HDMI-0 1920x1080
unnecessarily. The Xorg server might detect that mode, but not use it as the default one. To change this, you need to edit your Xorg configuration file: /etc/X11/xorg.conf
(see man xorg.conf
before you do). There, you can add an option
Option "PreferredMode" "your-mode-here"
to the Monitor
section. To know what needs to be put in place of "your-mode-here"
, you can read /var/log/Xorg.0.log
. Use less /var/log/Xorg.0.log
, search (by pressing /
) for a line containing 1920x1080 - it should read something like this:
(II) fglrx(0): Modeline "1920x1080_60.0" 148.50 1920 2008 2052 2200 1080 1084 1089 1125 +hsync +vsync (67.5 kHz)
The part starting with Modeline
and ending with vsync
is what you need to copy (select text with mouse) and then paste to the xorg.conf
under monitor section. Then the use name (1920x1080_60.0
in the above ModeLine
) with "PreferredMode" option as descibed earlier. You can name it yourself in both places. The important part is that the ModeLine
has to contain the technical information that Xorg has detected.