service file docs?
Michael Meskes
meskes at debian.org
Fri Jun 6 12:56:17 BST 2014
Hi Michael,
> I think it’d be better if you posted what you already have and what
> problem you are trying to solve.
Sure, no problem. Here's what I have:
---
[Unit]
Description=Check And Enable File System Quotas
Documentation=man:quotaon(8)
DefaultDependencies=no
After=systemd-readahead-collect.service systemd-readahead-replay.service systemd-remount-fs.service
Before=local-fs.target shutdown.target
ConditionPathExists=/usr/share/quota/quotaon.sh
[Service]
Type=oneshot
RemainAfterExit=yes
ExecStart=/usr/share/quota/quotaon.sh
ExecStop=/usr/share/quota/quotaoff.sh
StandardOutput=journal+console
[Install]
WantedBy=sysinit.target
---
AFAICT this works nicely on boot and on manual invocation after deactivating
the systemd provided quotaon.service. What I'm trying to figure out is how to
make sure my stop script gets called upon rebooting or halting.
Also I have to figure out whether to integrate the logic of the systemd
provided quotacheck.service and if so, how to. But first I got to get it
running.
Michael
--
Michael Meskes
Michael at Fam-Meskes dot De, Michael at Meskes dot (De|Com|Net|Org)
Michael at BorussiaFan dot De, Meskes at (Debian|Postgresql) dot Org
Jabber: michael.meskes at gmail dot com
VfL Borussia! Força Barça! Go SF 49ers! Use Debian GNU/Linux, PostgreSQL
More information about the Pkg-systemd-maintainers
mailing list