14 Nvidia Undervolting & Display Guide

Table of Contents

Previous Page

Next Page


WHAT FUN I HAD trying to get Nvidia to undervlot.
Once again finding several guides that had to be pieced together.
The first half worked pretty quick, the power limit & frequency part.
Getting offset to work, AND RETAIN, is what took finding a random permission fix.


First, need to do the prereqs and permission fixes:

  1. Install full load “Coolbits”, which allows gpu settings:
sudo nvidia-xconfig -a --cool-bits=31 --allow-empty-initial-configuration
  1. First round of two user permissions
sudo visudo
daddio        ALL = (ALL) NOPASSWD: /usr/bin/nvidia-persistenced
daddio        ALL = (ALL) NOPASSWD: /usr/bin/nvidia-smi
  1. Third user permission to add
sudo nano /etc/X11/Xwrapper.config
allowed_users = anybody
needs_root_rights = yes
sudo chmod 2644 /etc/X11/Xwrapper.config

Nvidia “Undervolting” Steps

  1. Open new shell:
sudo nano /usr/local/bin/gpusettings.sh
  1. Copy into new script; save & close:
    Note this is for RTX 3080 10gb; “user/1000” may need changed per install.
#!/bin/bash

nvidia-smi -pm 1
nvidia-smi -i 0 -pl 270
nvidia-smi -i 0 -lgc 0,1800
DISPLAY=:0 XAUTHORITY=/run/user/1000/gdm/Xauthority nvidia-settings \
 -a [gpu:0]/GPUGraphicsClockOffsetAllPerformanceLevels=200 \
 -a [gpu:0]/GPUMemoryTransferRateOffsetAllPerformanceLevels=1000
  1. Create new service
sudo nano /etc/systemd/system/gpusettings.service
  1. Copy into new service; save & close:
[Unit]
Description=GPU power limiter
After=network.target
After=display-manager.service

[Service]
User=root
ExecStart=/usr/local/bin/gpusettings.sh
Restart=on-failure
RestartSec=1

[Install]
WantedBy=multi-user.target
  1. change permissions on both new files:
sudo chmod 744 /usr/local/bin/gpusettings.sh && 
sudo chmod 644 /etc/systemd/system/gpusettings.service
  1. reload & enable service:
sudo systemctl daemon-reload && sudo systemctl enable gpusettings.service
  1. Make sure it worked with no errors; Reboot after for good measure.
sudo systemctl status gpusettings.service

So what happened?

Nvidia really doesn’t make it easy to change settings for basic overclocks
A day was spent daisy-chaining searching until it came to an answer.

Prints system info if you need to troubleshoot

nvidia-smi -i 0 -q

Prints system info for power & freqs of interest; make intro script for more fun!

#1/bin/bash
nvidia-smi -i 0 -q | grep -A1 'Voltage' && \
nvidia-smi -i 0 -q | grep -m1 'Graphics' && \
nvidia-smi -i 0 -q | grep -m1 'Power Draw'



Nvidia DISPLAY Issues ~~~~~~~~~

Remove Phantom monitor

xrandr -q
sudo nano /etc/X11/xorg.conf.d/10-monitor.conf
Section "Monitor"
    Identifier "None-1-1"
    Option "Ignore" "true"
EndSection

Can’t Save nvidia-settings file

sudo nvidia-settings
sudo chmod u+x /usr/share/screen-resolution-extra/nvidia-polkit

Pop/Gnome resetting monitor settings

nano ~/.config/monitors.xml 
<mode>
    <width>1920</width>
    <height>1080</height>
    <rate>60</rate>
</mode>

Table of Contents

Previous Page

Next Page