mdadm/mdmonitor.service

25 lines
746 B
SYSTEMD
Raw Permalink Normal View History

2020-01-11 15:03:43 +08:00
# This file is part of mdadm.
#
# mdadm is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
2019-12-31 22:19:03 +08:00
[Unit]
2020-01-11 15:03:43 +08:00
Description=MD array monitor
DefaultDependencies=no
Wants=systemd-tmpfiles-setup.service
After=systemd-tmpfiles-setup.service
ConditionPathExistsGlob=/dev/md*
2019-12-31 22:19:03 +08:00
[Service]
Type=forking
2020-03-03 16:08:39 +08:00
PIDFile=/run/mdadm/mdadm.pid
Environment= MDADM_MONITOR_ARGS="--scan --syslog"
2020-01-11 15:03:43 +08:00
EnvironmentFile=-/etc/sysconfig/mdadm
2020-09-24 09:56:59 +08:00
ExecStartPre= mkdir -p /run/mdadm
ExecStart=/sbin/mdadm --monitor $MDADM_MONITOR_ARGS -f --pid-file=/run/mdadm/mdadm.pid
2019-12-31 22:19:03 +08:00
[Install]
WantedBy=multi-user.target