diff options
author | Lorenz Hüdepohl <[email protected]> | 2021-01-21 21:59:24 +0100 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2021-01-23 15:47:06 -0800 |
commit | db83b3abe9087e15e14acd5269c5bbebb52098aa (patch) | |
tree | d44d9e9a5e38e164f232ca25eae0a8b3e34c4c46 /contrib | |
parent | 55fd8ceab6ce239cc11f881236a6ac52ecd08849 (diff) |
dracut: Support /usr/bin as 'systemctl' path
On openSUSE the initrd has systemctl in /usr/bin, check this path as
well.
Reviewed-by: Brian Behlendorf <[email protected]>
Reviewed-by: Richard Laager <[email protected]>
Signed-off-by: Lorenz Hüdepohl <[email protected]>
Closes #11487
Diffstat (limited to 'contrib')
-rw-r--r-- | contrib/dracut/90zfs/zfs-env-bootfs.service.in | 2 | ||||
-rwxr-xr-x | contrib/dracut/90zfs/zfs-load-key.sh.in | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/contrib/dracut/90zfs/zfs-env-bootfs.service.in b/contrib/dracut/90zfs/zfs-env-bootfs.service.in index 3cdf69100..2bc43482c 100644 --- a/contrib/dracut/90zfs/zfs-env-bootfs.service.in +++ b/contrib/dracut/90zfs/zfs-env-bootfs.service.in @@ -8,7 +8,7 @@ Before=zfs-import.target [Service] Type=oneshot -ExecStart=/bin/sh -c "/bin/systemctl set-environment BOOTFS=$(@sbindir@/zpool list -H -o bootfs | grep -m1 -v '^-$')" +ExecStart=/bin/sh -c "systemctl set-environment BOOTFS=$(@sbindir@/zpool list -H -o bootfs | grep -m1 -v '^-$')" [Install] WantedBy=zfs-import.target diff --git a/contrib/dracut/90zfs/zfs-load-key.sh.in b/contrib/dracut/90zfs/zfs-load-key.sh.in index 85e55c51b..90afc7900 100755 --- a/contrib/dracut/90zfs/zfs-load-key.sh.in +++ b/contrib/dracut/90zfs/zfs-load-key.sh.in @@ -1,7 +1,7 @@ #!/bin/sh # only run this on systemd systems, we handle the decrypt in mount-zfs.sh in the mount hook otherwise -[ -e /bin/systemctl ] || return 0 +[ -e /bin/systemctl ] || [ -e /usr/bin/systemctl ] || return 0 # This script only gets executed on systemd systems, see mount-zfs.sh for non-systemd systems |