Nvidia-settings not pressisting my refresh rate

grub
deepin
nvidia
xorg

#1

Hi, I’m running Manjaro 18.02 stable with deepin on a single monitor and an NVIDIA GeForce GTX 1060 6GB, I do not have an integrated graphics card. I followed the official guide on how to Configure NVIDIA (non-free) settings and load them on Startup

Jump to: navigation, search
To the letter and everything works fine, except for the Resolution/Refresh Rate part.
Every time I reboot my computer my refresh rate changes back to 60Hz, I’ve been trying to fix this issue for days now but to no avail. This is how my xorg file looks like (/etc/X11/mhwd.d/nvidia.conf):

nvidia-settings: X configuration file generated by nvidia-settings

nvidia-settings: version 415.27

Section “ServerLayout”
Identifier “Layout0”
Screen 0 “Screen0” 0 0
InputDevice “Keyboard0” “CoreKeyboard”
InputDevice “Mouse0” “CorePointer”
Option “Xinerama” “0”
EndSection

Section “Files”
EndSection

Section “InputDevice”
# generated from default
Identifier “Mouse0”
Driver “mouse”
Option “Protocol” “auto”
Option “Device” “/dev/psaux”
Option “Emulate3Buttons” “no”
Option “ZAxisMapping” “4 5”
EndSection

Section “InputDevice”
# generated from default
Identifier “Keyboard0”
Driver “kbd”
EndSection

Section “Monitor”
# HorizSync source: edid, VertRefresh source: edid
Identifier “Monitor0”
VendorName “Unknown”
ModelName “BenQ XL2430T”
HorizSync 30.0 - 160.0
VertRefresh 56.0 - 144.0
Option “DPMS”
EndSection

Section “Device”
Identifier “Device0”
Driver “nvidia”
VendorName “NVIDIA Corporation”
BoardName “GeForce GTX 1060 6GB”
EndSection

Section “Screen”
Identifier “Screen0”
Device “Device0”
Monitor “Monitor0”
DefaultDepth 24
Option “Stereo” “0”
Option “nvidiaXineramaInfoOrder” “DFP-0”
Option “metamodes” “1920x1080_144 +0+0”
Option “SLI” “Off”
Option “MultiGPU” “Off”
Option “BaseMosaic” “off”
SubSection “Display”
Depth 24
EndSubSection
EndSection

Can those grub arguments have anything to do with this issue?

GRUB_GFXMODE=auto
GRUB_GFXPAYLOAD_LINUX=keep

Please help!


#2

Do this


but read also the above comment from that post…


#3

I did save my settings to “.nvidia-settings-rc” file and added it to the “.xinitrc”.
Like I said before I followed the official guide and did everything to the letter.

Also " ForceFullCompositionPipeline is off by default, I did turn it ON just to test it out but that didn’t help either, so I reverted that change.

I looked over stackoverflow, reddit, nvidia and devtalk.nvidia forums and I’ve tried many solutions, but none of them work. I had the same issue a while back on Fedora 24, but back then I used two monitors with different refresh rates, so I was convinced that the dual monitor setup was causing the issue.

Unfortunately either NVIDIA or xorg / desktop environments suck compared to Windows or macOS when it comes down to a simple refresh rate setting. :rage:


#4

Let’s not go there. I can give you countless contra arguments for that, without speculations or personal opinion. But remember the budgets those 2 companies have to be able to test almost everything …
Back to your problem, if you looked in so many places and nothing helped, from where i stand you missed something. What is that, i don’t know, but with or without

when you create a static/absolute Xorg config, the port that the Monitor is connected should be included.
You have:

Should be something like:

Option "nvidiaXineramaInfoOrder" "DFP-0"
Option "metamodes" "DVI-I-1: 1920x1080_144 +0+0"

but depends on what port you are using, can be DVI-D-0: or HDMI-0: or DP-1: - you have to identify that and place the correct one in the config.

I also mentioned this in my other post, above the one i linked:

Since you are using Deepin maybe have a look here (but it will not help you)

Deepin DE uses a very simple configuration for resolution and i don’t see anywhere the refresh rate. The OP from that post created a file to declare the refresh rate but i can’t confirm it does what it was intended or if it should be there.


#5

/etc/X11/mhwd.d/nvidia.conf

# nvidia-settings: X configuration file generated by nvidia-settings
# nvidia-settings:  version 415.27

Section "ServerLayout"
    Identifier     "Layout0"
    Screen      0  "Screen0" 0 0
    InputDevice    "Keyboard0" "CoreKeyboard"
    InputDevice    "Mouse0" "CorePointer"
    Option         "Xinerama" "0"
EndSection

Section "Files"
EndSection

Section "InputDevice"
    # generated from default
    Identifier     "Mouse0"
    Driver         "mouse"
    Option         "Protocol" "auto"
    Option         "Device" "/dev/psaux"
    Option         "Emulate3Buttons" "no"
    Option         "ZAxisMapping" "4 5"
EndSection

Section "InputDevice"
    # generated from default
    Identifier     "Keyboard0"
    Driver         "kbd"
EndSection

Section "Monitor"
    # HorizSync source: edid, VertRefresh source: edid
    Identifier     "Monitor0"
    VendorName     "Unknown"
    ModelName      "BenQ XL2430T"
    HorizSync       30.0 - 160.0
    VertRefresh     56.0 - 144.0
    Option         "DPMS"
EndSection

Section "Device"
    Identifier     "Device0"
    Driver         "nvidia"
    VendorName     "NVIDIA Corporation"
    BoardName      "GeForce GTX 1060 6GB"
EndSection

Section "Screen"
    Identifier     "Screen0"
    Device         "Device0"
    Monitor        "Monitor0"
    DefaultDepth    24
    Option         "Stereo" "0"
    Option         "nvidiaXineramaInfoOrder" "DFP-0"
    Option         "metamodes" "DVI-D-0: 1920x1080_144 +0+0 {ForceCompositionPipeline=On, ForceFullCompositionPipeline=On}"
    Option         "SLI" "Off"
    Option         "MultiGPU" "Off"
    Option         "BaseMosaic" "off"
    SubSection     "Display"
        Depth       24
    EndSubSection
EndSection

/etc/X11/xorg.conf.d/90-mhwd.conf

# nvidia-settings: X configuration file generated by nvidia-settings
# nvidia-settings:  version 415.27

Section "ServerLayout"
    Identifier     "Layout0"
    Screen      0  "Screen0" 0 0
    InputDevice    "Keyboard0" "CoreKeyboard"
    InputDevice    "Mouse0" "CorePointer"
    Option         "Xinerama" "0"
EndSection

Section "Files"
EndSection

Section "InputDevice"
    # generated from default
    Identifier     "Mouse0"
    Driver         "mouse"
    Option         "Protocol" "auto"
    Option         "Device" "/dev/psaux"
    Option         "Emulate3Buttons" "no"
    Option         "ZAxisMapping" "4 5"
EndSection

Section "InputDevice"
    # generated from default
    Identifier     "Keyboard0"
    Driver         "kbd"
EndSection

Section "Monitor"
    # HorizSync source: edid, VertRefresh source: edid
    Identifier     "Monitor0"
    VendorName     "Unknown"
    ModelName      "BenQ XL2430T"
    HorizSync       30.0 - 160.0
    VertRefresh     56.0 - 144.0
    Option         "DPMS"
EndSection

Section "Device"
    Identifier     "Device0"
    Driver         "nvidia"
    VendorName     "NVIDIA Corporation"
    BoardName      "GeForce GTX 1060 6GB"
EndSection

Section "Screen"
    Identifier     "Screen0"
    Device         "Device0"
    Monitor        "Monitor0"
    DefaultDepth    24
    Option         "Stereo" "0"
    Option         "nvidiaXineramaInfoOrder" "DFP-0"
    Option         "metamodes" "DVI-D-0: 1920x1080_144 +0+0 {ForceCompositionPipeline=On, ForceFullCompositionPipeline=On}"
    Option         "SLI" "Off"
    Option         "MultiGPU" "Off"
    Option         "BaseMosaic" "off"
    SubSection     "Display"
        Depth       24
    EndSubSection
EndSection

“~/.config/deepin/startdde/display.json” didn’t exist, so I changed the Display Resolution in deepin and the file was generated. After that I was able to edit the refresh rate in that file, but that didn’t work either.

I looked through the xorg and lightdm logs and I didn’t find any errors.
I also validated that my system is using the non-free nvidia driver that I’ve installed.

Thanks for trying to help me out @ bogdancovaciu I do apprentice it!


#6

Your config looks OK to me.
See output of xrandr for a list of supported refresh rates.
They can also be set with the same tool (xrandr --output name-of-display --rate refresh-rate).

I would also disable ForceFullCompositionPipeline.


#7
Screen 0: minimum 8 x 8, current 1920 x 1080, maximum 32767 x 32767
DVI-D-0 connected primary 1920x1080+0+0 (normal left inverted right x axis y axis) 531mm x 298mm
   1920x1080     60.00*+ 144.00   119.98    99.93  
   1440x900     119.85  
   1280x1024    119.96    75.02    60.02  
   1024x768     119.99    75.03    60.00  
   800x600      119.97    75.00    60.32  
   640x480      120.01    75.00    59.94  

Where would you recommend calling the xrandr --output name-of-display --rate refresh-rate ?
“~/.xinitrc” seems like a good place to me.


#8

Update: It seems to me that the refresh rate is being changed after I log in to my account. Every time after I log in the screen goes black for a second or two, just like it does when you change your resolution / refresh rate.


#9

Well first check that the selected rate does indeed work, e.g.
xrandr --output DVI-D-0 --rate 144
The active rate is marked with an asterisk.


#10
xrandr --output DVI-D-0 --mode 1920x1080 --rate 144

Changes the refresh rate to 144Hz.