in slackware the default mktemp is not from coreutils. A simply make in test directory mangled my rootfs due to initdir is blank Also mktemp could failed with other reason like ENOSPC or EPERM Signed-off-by: Dave Young <dyoung@xxxxxxxxxx> --- dracut | 4 ++++ 1 files changed, 4 insertions(+), 0 deletions(-) diff --git a/dracut b/dracut index c9329bd..8237f7a 100755 --- a/dracut +++ b/dracut @@ -472,6 +472,10 @@ fi readonly TMPDIR=/var/tmp readonly initdir=$(mktemp --tmpdir=/var/tmp/ -d -t initramfs.XXXXXX) +[ -z $initdir ] && { + dfatal "mktemp failed." + exit 1 +} # clean up after ourselves no matter how we die. trap 'ret=$?;[[ $keep ]] && echo "Not removing $initdir." >&2 || rm -rf "$initdir";exit $ret;' EXIT -- 1.7.4.4 -- To unsubscribe from this list: send the line "unsubscribe initramfs" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html