Ubuntu 22.04 installing CUDA changes nvidia drivers and breaks suspend

On a fresh install of Ubuntu 22.04, using the system’s “additional drivers” it runs nvidia driver 510.x and suspend works fine on my i9-7940x and GTX 3090. When I install Cuda 11.7 from the repo here, it automatically switches to the 515.x driver and suspend no longer works.

With the original 510.x driver the nvidia-suspend.service, resume and hibernate all show as available. After installing Cuda (which switches to 515.x) these services are now showing as “masked” (which means they point to /dev/null). I’m assuming this is the issue. Is there a simple fix for this?

There are a number of post about similar issues with previous Ubuntu versions but my system worked fine as Ubuntu 20.04 and cuda 11.3 so it seems odd that Nvidia would re-introduce an old bug in a newer version of their install package.


Same experience here. Suspend and resume helps save energy…

Edit: I found a solution
a) Ubuntu 22.04, Nvidia Driver v515, Cuda 11.7

sudo rm /etc/systemd/system/systemd-hibernate.service.requires/nvidia-resume.service
sudo rm /etc/systemd/system/systemd-hibernate.service.requires/nvidia-hibernate.service
sudo rm /etc/systemd/system/systemd-suspend.service.requires/nvidia-resume.service
sudo rm /etc/systemd/system/systemd-suspend.service.requires/nvidia-suspend.service


Same Issue here , every time i install CUDA 11.7 , change the installed driver from 510 to 520.
and i still not found any solution.

Note : I have WIndows on my PC installed with driver 520 and it works very well , But its dont work on Ubuntu 22.04.

Removing these files worked! Thank you. Suspend working again. 520.x driver upgrade for Cuda. Suspend did not work at all and gnome was crashing. Systemd symbolic links should be removed as part of cleanup script while package manager removes the old conflicting driver.