Table of Contents
The message “A stop job is running” means systemd is waiting for a shutdown task to finish. The task may be a service, user session, mount, device, container, or virtual machine. An occasional short wait is usually harmless; the same unit delaying every shutdown deserves investigation.
Write down the unit name shown on screen. It is the most useful clue and may look like example.service, home.mount, or user@1000.service.

Why systemd waits instead of stopping immediately
A systemd service can define its own stop command. Systemd then waits for that command and the service processes to exit. Depending on the unit's kill settings, remaining processes normally receive a termination signal and may later be killed when the configured stop timeout expires. This delay gives databases, file systems, network mounts, and other programs time to flush data and close cleanly.
The limit is not guaranteed to be 90 seconds on every system. A distribution, unit file, or local override can set a different value. The systemd manager configuration reference documents the global DefaultTimeoutStopSec= setting, while a service can override it with TimeoutStopSec=.
Find the job that delayed the previous shutdown
After the computer starts again, inspect messages from the previous boot:
journalctl -b -1 -e
-b -1 selects the preceding boot and -e jumps to the end. Look for the unit name displayed during shutdown and terms such as timed out, stop-sigterm, failed, or unmount.

To show warnings and more severe messages from that boot, run:
journalctl -b -1 -p warning

Once you know the exact unit, narrow the log instead of reading the entire journal:
journalctl -b -1 -u example.service
systemctl status example.service
systemctl cat example.service
Replace example.service with the displayed unit. systemctl cat shows the vendor unit and any local drop-ins, which helps reveal a custom stop command or timeout. If the delay belongs to your desktop session rather than a system service, also inspect the user journal:
journalctl --user -b -1 -e
For more background, see TipsMake's guides to managing Linux services with systemd and the Linux Fundamentals course.
Fix the cause that matches the unit
- Network mounts: confirm the server is reachable before shutdown and review the related
/etc/fstabentry. A stale NFS or SMB connection can leave an unmount job waiting. - External drives: close programs using the drive and unmount it before disconnecting it. Check the file system if the journal reports I/O errors.
- Containers and virtual machines: stop guests cleanly before shutting down the host. Review the container or hypervisor service log if its own stop operation times out.
- Databases: investigate recovery, locks, large checkpoints, or storage errors. Shortening the timeout can interrupt a necessary flush and increase recovery time at the next start.
- User sessions: close applications with unsaved work and check whether a user service is stuck. Do not assume the desktop itself is the cause just because the message mentions a user unit.
- A faulty service: update or reconfigure the package, then test its stop operation while the system is still running with
sudo systemctl stop UNIT. Do this only when stopping that service will not disrupt a remote connection or an important workload.
systemd-analyze blame ranks startup time, so it does not identify which unit was slow to stop. A service that starts slowly may shut down normally, and the reverse is also possible.
Change a timeout only after diagnosing the unit
If a service shuts down safely but waits longer than necessary, prefer a unit-specific override. This limits the change to the service you have tested:
sudo systemctl edit example.service
Add an override such as:
[Service]
TimeoutStopSec=30s
The value above is an example, not a universal recommendation. It must be long enough for that service's documented shutdown procedure. Save the file, then reload unit definitions:
sudo systemctl daemon-reload
Test a normal stop and start before relying on the change during shutdown. To remove the override later, use sudo systemctl revert example.service after confirming that no other local changes should be retained.
Global timeout: a last resort
A global limit affects services that do not define their own stop timeout. If you have verified the consequences and still need one, use a drop-in instead of editing the main configuration file:
sudo mkdir -p /etc/systemd/system.conf.d
sudo nano /etc/systemd/system.conf.d/50-stop-timeout.conf
For example:
[Manager]
DefaultTimeoutStopSec=30s
Reboot to use the new manager configuration. Do not set a very short value merely to hide the message: systemd may terminate services before they finish writing data. Setting a timeout to zero can mean no timeout, which can make the wait indefinite.
What to avoid
Do not edit /usr/lib/systemd or /lib/systemd unit files directly, because package updates can replace them. Do not invent a DefaultDeviceTimeoutSec= setting in system.conf; device waits and mount units use different controls. Most of all, do not reduce every timeout until you have recorded the exact job and checked its journal. Fixing the failing mount, service, or application produces a reliable shutdown without sacrificing clean data handling.
Reader Comments 0
Sign in with email or Google to join the discussion.