18.06.2020 10:07, Kamal Rathi пишет: > > Now I am more eager to know if is it possible to run anything before it > kills users processes at shutdown / reboot / halt. User processes run either as part of user session or as part of user service. The former is session-xxx.scope, the latter is user@UID.service. You could add Before=your.service to user@.service template to make sure your.service is stopped first. Current version of systemd allows creation of drop-ins in session-.scope.d as well to add dependency to all session scopes. Check systemd.unit man page. _______________________________________________ systemd-devel mailing list systemd-devel@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/systemd-devel