diff options
Diffstat (limited to 'systemd')
-rw-r--r-- | systemd/mdadm-last-resort@.service | 4 | ||||
-rw-r--r-- | systemd/mdadm-last-resort@.timer | 2 | ||||
-rw-r--r-- | systemd/mdmonitor.service | 5 |
3 files changed, 7 insertions, 4 deletions
diff --git a/systemd/mdadm-last-resort@.service b/systemd/mdadm-last-resort@.service index e93d72b2..efeb3f63 100644 --- a/systemd/mdadm-last-resort@.service +++ b/systemd/mdadm-last-resort@.service @@ -1,7 +1,7 @@ [Unit] -Description=Activate md array even though degraded +Description=Activate md array %I even though degraded DefaultDependencies=no -Conflicts=sys-devices-virtual-block-%i.device +ConditionPathExists=!/sys/devices/virtual/block/%i/md/sync_action [Service] Type=oneshot diff --git a/systemd/mdadm-last-resort@.timer b/systemd/mdadm-last-resort@.timer index 52b3f227..45ad2230 100644 --- a/systemd/mdadm-last-resort@.timer +++ b/systemd/mdadm-last-resort@.timer @@ -1,5 +1,5 @@ [Unit] -Description=Timer to wait for more drives before activating degraded array. +Description=Timer to wait for more drives before activating degraded array %I. DefaultDependencies=no Conflicts=sys-devices-virtual-block-%i.device diff --git a/systemd/mdmonitor.service b/systemd/mdmonitor.service index 9aff2f56..46f7b880 100644 --- a/systemd/mdmonitor.service +++ b/systemd/mdmonitor.service @@ -10,4 +10,7 @@ Description=MD array monitor DefaultDependencies=no [Service] -ExecStart=BINDIR/mdadm --monitor --scan +Environment= MDADM_MONITOR_ARGS=--scan +EnvironmentFile=-/run/sysconfig/mdadm +ExecStartPre=-/usr/lib/mdadm/mdadm_env.sh +ExecStart=BINDIR/mdadm --monitor $MDADM_MONITOR_ARGS |