Open dylanparry opened 5 years ago
What GPU and driver version are you using?
GPU is GeForce GTX 1050, and driver version is 430.40
Hmm, wouldn't be surprised if something has changed in the Nvidia driver since I implemented this - for instance on my machine nvidia-settings
doesn't even expose GPUGraphicsClockOffset
or GPUMemoryTransferRateOffset
anymore.
What happens when you run gamemoded -t
? I get this when I check now, on a laptop GPU (perhaps part of the problem).
::: Verifying GPU Optimisations
ERROR: Failed to parse output for "[gpu:0]/GPUGraphicsClockOffset[3]" output was ""!
ERROR: External process failed with exit code 1
ERROR: Output was:
ERROR: Failed to call gpuclockctl, could not get values!
ERROR: Failed to parse output for "[gpu:0]/GPUGraphicsClockOffset[3]" output was ""!
ERROR: External process failed with exit code 1
ERROR: Output was:
ERROR: Failed to call gpuclockctl, could not get values!
ERROR: Could not get current GPU info, see above!
I get this:
~$ gamemoded -t
: Loading config
Loading config file [/etc/gamemode.ini]
: Running tests
:: Basic client tests
:: Passed
:: Dual client tests
gamemode request succeeded and is active
Quitting by request...
:: Passed
:: Gamemoderun and reaper thread tests
ERROR: gamemode_query_status failed to return other client connected (expected 1)!
...Waiting for child to quit...
...Waiting for reaper thread (reaper_frequency set to 5 seconds)...
:: Supervisor tests
:: Passed
: Client tests failed, skipping feature tests
: Tests Failed!
Not sure what the "other client" it refers to is as there's no games running.
From the reading I did, it looks like GPUGraphicsClockOffset
and GPUMemoryTransferRateOffset
were replaced with GPUGraphicsClockOffsetAllPerformanceLevels
and GPUMemoryTransferRateOffsetAllPerformanceLevels
respectively. I couldn't find anywhere that knew exactly when this change occurred, but it looks like it was some time during the 390.x series of drivers. I also couldn't find any official documentation for this anywhere :\
Not the best log message, but:
ERROR: gamemode_query_status failed to return other client connected (expected 1)!
Is complaining that with an extra fake client connected, gamemode_query_status
didn't return 1
to say that there was a client active. That's strange. Does the issue repeat? If so, the output of journalctl --user --unit=gamemoded --follow
during the same time as running the tests would be interesting to see.
The tests didn't even get to taking a look at the GPU stuff anyway, because of that core failure :(
: Client tests failed, skipping feature tests
From the reading I did, it looks like GPUGraphicsClockOffset and GPUMemoryTransferRateOffset were replaced with GPUGraphicsClockOffsetAllPerformanceLevels and GPUMemoryTransferRateOffsetAllPerformanceLevels respectively. I couldn't find anywhere that knew exactly when this change occurred, but it looks like it was some time during the 390.x series of drivers. I also couldn't find any official documentation for this anywhere :\
Ugh yeah, that's happened before, and now the code would need a special case for each version. I'm starting to think more complicated GPU overclocking should be handled outside of GameMode, using the custom start/end scripts.
This is what I get:
~$ journalctl --user --unit=gamemoded --follow
-- Logs begin at Tue 2019-07-02 15:47:54 BST. --
Aug 26 22:55:19 kratos /usr/bin/gamemoded[1724]: Successfully initialised bus with name [com.feralinteractive.GameMode]...
Aug 26 22:55:19 kratos systemd[1708]: Started gamemoded.
Aug 27 00:20:41 kratos /usr/bin/gamemoded[1724]: Failure when processing the bus: Connection reset by peer
Aug 27 00:20:41 kratos systemd[1708]: gamemoded.service: Main process exited, code=exited, status=1/FAILURE
Aug 27 00:20:41 kratos systemd[1708]: gamemoded.service: Failed with result 'exit-code'.
-- Reboot --
Aug 27 12:12:49 kratos systemd[1675]: Starting gamemoded...
Aug 27 12:12:49 kratos /usr/bin/gamemoded[1690]: v1.4
Aug 27 12:12:49 kratos /usr/bin/gamemoded[1690]: Loading config file [/etc/gamemode.ini]
Aug 27 12:12:49 kratos /usr/bin/gamemoded[1690]: Successfully initialised bus with name [com.feralinteractive.GameMode]...
Aug 27 12:12:49 kratos systemd[1675]: Started gamemoded.
Aug 27 12:21:20 kratos /usr/bin/gamemoded[1690]: Adding game: 6457 [/usr/bin/gamemoded]
Aug 27 12:21:20 kratos /usr/bin/gamemoded[1690]: Entering Game Mode...
Aug 27 12:21:20 kratos /usr/bin/gamemoded[1690]: governor was initially set to [powersave]
Aug 27 12:21:20 kratos /usr/bin/gamemoded[1690]: Requesting update of governor policy to performance
Aug 27 12:21:20 kratos pkexec[6458]: pam_unix(polkit-1:session): session opened for user root by (uid=1000)
Aug 27 12:21:20 kratos gamemoded[1690]: ERROR: Getting Nvidia parameters requires DISPLAY to be set - will likely fail!
Aug 27 12:21:20 kratos gamemoded[1690]: Unable to init server: Could not connect: Connection refused
Aug 27 12:21:20 kratos gamemoded[1690]: ERROR: The control display is undefined; please run `/usr/bin/nvidia-settings --help` for usage information.
Aug 27 12:21:20 kratos gamemoded[1690]: ERROR: External process failed with exit code 1
Aug 27 12:21:20 kratos gamemoded[1690]: ERROR: Output was:
Aug 27 12:21:20 kratos gamemoded[1690]: ERROR: Failed to get [gpu:0]/GPUPerfModes!
Aug 27 12:21:20 kratos gamemoded[1690]: Unable to init server: Could not connect: Connection refused
Aug 27 12:21:20 kratos gamemoded[1690]: ERROR: The control display is undefined; please run `/usr/bin/nvidia-settings --help` for usage information.
Aug 27 12:21:20 kratos gamemoded[1690]: ERROR: External process failed with exit code 1
Aug 27 12:21:20 kratos gamemoded[1690]: ERROR: Output was:
Aug 27 12:21:20 kratos gamemoded[1690]: ERROR: Failed to get [gpu:0]/GPUGraphicsClockOffset[-1]!
Aug 27 12:21:20 kratos /usr/bin/gamemoded[1690]: External process failed with exit code 1
Aug 27 12:21:20 kratos /usr/bin/gamemoded[1690]: Output was:
Aug 27 12:21:20 kratos /usr/bin/gamemoded[1690]: Failed to call gpuclockctl, could not get values!
Aug 27 12:21:20 kratos /usr/bin/gamemoded[1690]: Requesting GPU optimisations on device:1
Aug 27 12:21:20 kratos pkexec[6469]: pam_unix(polkit-1:session): session opened for user root by (uid=1000)
Aug 27 12:21:20 kratos gamemoded[1690]: ERROR: Setting Nvidia parameters requires DISPLAY and XAUTHORITY to be set - will likely fail!
Aug 27 12:21:20 kratos gamemoded[1690]: ERROR: Getting Nvidia parameters requires DISPLAY to be set - will likely fail!
Aug 27 12:21:20 kratos gamemoded[1690]: Unable to init server: Could not connect: Connection refused
Aug 27 12:21:20 kratos gamemoded[1690]: ERROR: The control display is undefined; please run `/usr/bin/nvidia-settings --help` for usage information.
Aug 27 12:21:20 kratos gamemoded[1690]: ERROR: External process failed with exit code 1
Aug 27 12:21:20 kratos gamemoded[1690]: ERROR: Output was:
Aug 27 12:21:20 kratos gamemoded[1690]: ERROR: Failed to get [gpu:0]/GPUPerfModes!
Aug 27 12:21:20 kratos gamemoded[1690]: Unable to init server: Could not connect: Connection refused
Aug 27 12:21:20 kratos gamemoded[1690]: ERROR: The control display is undefined; please run `/usr/bin/nvidia-settings --help` for usage information.
Aug 27 12:21:20 kratos gamemoded[1690]: ERROR: External process failed with exit code 1
Aug 27 12:21:20 kratos gamemoded[1690]: ERROR: Output was:
Aug 27 12:21:20 kratos gamemoded[1690]: ERROR: Failed to set [gpu:0]/GPUPowerMizerMode=1!
Aug 27 12:21:20 kratos /usr/bin/gamemoded[1690]: External process failed with exit code 255
Aug 27 12:21:20 kratos /usr/bin/gamemoded[1690]: Output was:
Aug 27 12:21:20 kratos /usr/bin/gamemoded[1690]: Failed to call gpuclockctl, could not apply optimisations!
I've resorted to running a start/end script that does the overclocking manually for now, and that works just fine.
Describe the bug I get an error when I attempt to overclock my Nvidia card
To Reproduce Steps used to reproduce the behavior:
gamemodrun glxgears
Expected behavior The GPU should be overclocked.
System Info (please complete the following information):
Additional context I've found that the only settings that allow my GPU to be overclocked are:
Which differ slightly from the ones that are trying to be used in the above status log.