Created
May 5, 2020 15:58
-
-
Save mikaelhg/9b6dfbf1ff66b899e6132c808c55e4e9 to your computer and use it in GitHub Desktop.
Ubuntu 20.04 suspend / sleep / wakeup NVidia CUDA / NVENC / NVDEC error
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /bin/sh | |
# Workaround for broken CUDA/NVENC/NVDEC after suspend. | |
# This file now lives in /lib/systemd/system-sleep/nvidia-resume . | |
# Remember to chmod 755 it. | |
PATH=/sbin:/usr/sbin:/bin:/usr/bin | |
case $1 in | |
post) | |
rmmod nvidia_uvm | |
modprobe nvidia_uvm | |
;; | |
esac |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
@tensorfoo check out http://download.nvidia.com/XFree86/Linux-x86_64/460.56/README/powermanagement.html#SystemdConfigur74e29 for a more comprehensive solution.