Use /tmp instead of /var/tmp for temporary data.
PATCH 1/1 Use /tmp instead of /var/tmp for temporary data.
/var/tmp is supposed to store temporary data which should be preserved over reboots, wheras /tmp is for short-term temporary data. Moreover /tmp is usually tmpfs which may make generating initramfs a bit faster.
Thanks to Martin von Gagern <[email protected]> for pointing that out.
--- dracut.sh | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-)
dracut.sh +2 -2
@@ -544,8 +544,8 @@ elif [[ -f "$outfile" && ! -w "$outfile" ]]; then exit 1 fi -readonly TMPDIR=/var/tmp -readonly initdir=$(mktemp --tmpdir=/var/tmp/ -d -t initramfs.XXXXXX) +readonly TMPDIR=/tmp +readonly initdir=$(mktemp --tmpdir=$TMPDIR/ -d -t initramfs.XXXXXX) [ -d "$initdir" ] || { dfatal "mktemp failed." exit 1
Signature · 1 line
1.7.8.5