Problem
Several users have reported that systems with NVIDIA graphics adapters may suspend again shortly after resuming, when they initially suspended after an inactivity timeout or similar.
Cause
This seems to be caused by systemd 258, somehow. Testers have reported that downgrading to systemd 257 avoids the problem (although this is not necessarily a practical workaround, see below). We don’t yet have a detailed analysis.
Related Issues
Upstream report: #39259
Workarounds
You could try downgrading systemd to 257 or pinning it there, but other packages may well depend on newer systemd versions, so this will probably not work well for long.
This post on a related bug reports that the issue can be worked around by disabling GNOME’s suspend-after-timeout features and using systemd’s instead. You can disable GNOME’s auto suspend by opening Settings, going to Power, going to Power Saving (on the right-hand side next to General), and disabling both ‘Automatic Suspend’ sliders. If you also need to modify auto-suspend for the login screen, look here. If you’re fine with having no automatic suspend at all, this is all you need to do.
Otherwise, you can additionally create the drop-in configuration file recommended by Cédric. A file /etc/systemd/logind.conf.d/50-sleep-on-idle.conf with this content:
[Login]
IdleAction=sleep
IdleActionSec=15min
should cause automatic suspend after 15 minutes of inactivity (regardless of power source). This should not trigger the multiple suspend bug.
Note: The other suggested drop-in file should cause automatic hibernation (suspend-to-disk) after 60 minutes of suspend, if systemd’s suspend-then-hibernate feature is enabled. See the systemd docs for more on this. Note this goes beyond GNOME’s default behavior, and hibernation does not always work with default Fedora installs (especially with Secure Boot enabled). So you might want to skip that one.