How can I globally delay non-critical systemd services on Ubuntu without modifying each unit individually?
0
votes
0
answers
45
views
I'm trying to improve my boot performance on an Ubuntu system by ensuring that only essential services—like those required for the GNOME UI—start immediately at boot. All other (non-critical) services should be deferred until after the system has settled (for example, 1 minute after boot).
My current method (creating individual timer units or adding sleep commands in each service's unit file) works but requires manual configuration for each service. I’d like a global or automated solution that, regardless of existing or future service units, delays the startup of any service that isn’t critical to the UI.
Is there a way to configure systemd—perhaps using a generator or some global mechanism—to automatically inject a delay (or otherwise postpone startup) for non-essential services without me having to handle each unit by name? What strategies or best practices exist for categorizing essential versus non-essential services in systemd so that the boot process is optimized?
Any insights or recommendations for an automated approach would be greatly appreciated.
Asked by Jan
(121 rep)
Apr 4, 2025, 02:21 PM