DRBD-GRACEFUL-SHUT(7)

πŸ’… DRBD-GRACEFUL-SHUT β€” the page for drbd-graceful-shutdown.service ✨

okay bestie, this is section 7 of the DRBD manual, and it's about the little service that makes your DRBD resources leave the party politely instead of just ghosting everyone. πŸŽ€


πŸ¦‹ NAME πŸ¦‹

drbd-graceful-shutdown.service β€” the attempt to shut down a DRBD resource gracefully when the system itself is shutting down πŸ’–


🌸 SYNOPSIS 🌸

drbd-graceful-shutdown.service

✨ DESCRIPTION ✨

So here's the vibe: this service is the attempt to shut down DRBD resources while they still have a chance to communicate that to their peers, so the resources can "gracefully" leave the DRBD replication. Like, waving goodbye on the way out instead of vanishing mid-sentence. πŸ‘‹

For this reason, this unit is ordered after network-online.target: when the system shuts down, this service gets stopped before the network is torn down. The way that it needs the network still up to say bye? iconic, honestly. 🫢

Resources that are explicitly managed by other systemd services should be stopped there.</purl> So this is also ordered before resource-agents-deps.target and drbd.service and the per-resource drbd@.service templates β€” which means it only gets stopped after those are stopped. Yes, the ordering is doing a whole little choreography. πŸ’…

If you have some other foo.service that starts and stops DRBD resources, you should add a drop-in at /etc/systemd/system/drbd-graceful-shutdown.service.d/foo.conf:

[Unit]
Before=foo.service

(Or the inverse β€” just add After=drbd-graceful-shutdown.service to your foo.service instead. Either direction works, pick your fighter. πŸ₯Š)

If you for some reason want to opt out of this service, you can still systemctl mask it. No hard feelings, bestie. πŸ™ˆ

quick vibe check: the drop-in path is /etc/systemd/system/drbd-graceful-shutdown.service.d/foo.conf β€” copy it exactly, foo.conf and all, or systemd will simply not see you. 😭

πŸ‘‘ AUTHORS πŸ‘‘

LINBIT HA Solutions GmbH β€” https://linbit.com 🌈


and that's the whole page, no cap. This one came out of drbd-utils and it's dated 2026-08-15 β€” thanks for reading all the way to the bottom, you're literally the main character. πŸ’œπŸ¦‹βœ¨

πŸ“¦ where this page comes from