From: Harald Hoyer Date: Wed, 5 Feb 2014 12:08:54 +0000 (+0100) Subject: systemd/dracut-pre-pivot: run for /dev/{nfs,root} and cleanup /dev/nfs X-Git-Tag: 037~44 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=751c7de98af289970e4f827245647080cf2595b3;p=thirdparty%2Fdracut.git systemd/dracut-pre-pivot: run for /dev/{nfs,root} and cleanup /dev/nfs dracut-pre-pivot was not cleaning up /dev/nfs and did not run to clean up /dev/root. --- diff --git a/modules.d/98systemd/dracut-pre-pivot.service b/modules.d/98systemd/dracut-pre-pivot.service index dd4e49b44..6db1f2c07 100644 --- a/modules.d/98systemd/dracut-pre-pivot.service +++ b/modules.d/98systemd/dracut-pre-pivot.service @@ -19,6 +19,8 @@ ConditionDirectoryNotEmpty=|/lib/dracut/hooks/cleanup ConditionKernelCommandLine=|rd.break=pre-pivot ConditionKernelCommandLine=|rd.break=cleanup ConditionKernelCommandLine=|rd.break +ConditionPathExists=|/dev/root +ConditionPathExists=|/dev/nfs [Service] Environment=DRACUT_SYSTEMD=1 diff --git a/modules.d/98systemd/dracut-pre-pivot.sh b/modules.d/98systemd/dracut-pre-pivot.sh index 8c7554ead..e62a1cecb 100755 --- a/modules.d/98systemd/dracut-pre-pivot.sh +++ b/modules.d/98systemd/dracut-pre-pivot.sh @@ -24,5 +24,6 @@ getarg rd.break -d rdbreak && emergency_shell -n switch_root "Break before switc # remove helper symlink [ -h /dev/root ] && rm -f -- /dev/root +[ -h /dev/nfs ] && rm -f -- /dev/nfs exit 0