* [PATCH 1/2] add --tmpdir option to cmd line args and tmpdir to config file
@ 2012-03-26 12:28 Amadeusz Żołnowski
[not found] ` <1332764916-22282-1-git-send-email-aidecoe-2qtfh70TtYba5EbDDlwbIw@public.gmane.org>
0 siblings, 1 reply; 3+ messages in thread
From: Amadeusz Żołnowski @ 2012-03-26 12:28 UTC (permalink / raw)
To: initramfs-u79uwXL29TY76Z2rM5mHXA; +Cc: Amadeusz Żołnowski
Default temporary directory used by Dracut is /var/tmp, but users might
want to change it to /tmp.
---
dracut.conf | 2 ++
dracut.sh | 9 +++++++--
2 files changed, 9 insertions(+), 2 deletions(-)
diff --git a/dracut.conf b/dracut.conf
index a502066..1ee563e 100644
--- a/dracut.conf
+++ b/dracut.conf
@@ -38,3 +38,5 @@ lvmconf="yes"
# inhibit installation of any fsck tools
#nofscks="yes"
+
+tmpdir=/tmp
diff --git a/dracut.sh b/dracut.sh
index 1bf8ad9..5887131 100755
--- a/dracut.sh
+++ b/dracut.sh
@@ -80,6 +80,8 @@ Creates initial ramdisk images for preloading modules
Default: /etc/dracut.conf
--confdir [DIR] Specify configuration directory to use *.conf files
from. Default: /etc/dracut.conf.d
+ --tmpdir [DIR] Temporary directory to be used instead of default
+ /var/tmp.
-l, --local Local mode. Use modules from the current working
directory instead of the system-wide installed in
/usr/lib/dracut/modules.d.
@@ -225,6 +227,7 @@ while (($# > 0)); do
-k|--kmoddir) read_arg drivers_dir_l "$@" || shift;;
-c|--conf) read_arg conffile "$@" || shift;;
--confdir) read_arg confdir "$@" || shift;;
+ --tmpdir) read_arg tmpdir_l "$@" || shift;;
-L|--stdlog) read_arg stdloglvl_l "$@" || shift;;
--compress) read_arg compress_l "$@" || shift;;
--prefix) read_arg prefix_l "$@" || shift;;
@@ -411,6 +414,8 @@ stdloglvl=$((stdloglvl + verbosity_mod_l))
[[ $lvmconf_l ]] && lvmconf=$lvmconf_l
[[ $dracutbasedir ]] || dracutbasedir=/usr/lib/dracut
[[ $fw_dir ]] || fw_dir="/lib/firmware/updates /lib/firmware"
+[[ $tmpdir_l ]] && tmpdir="$tmpdir_l"
+[[ $tmpdir ]] || tmpdir=/var/tmp
[[ $do_strip ]] || do_strip=no
[[ $compress_l ]] && compress=$compress_l
[[ $show_modules_l ]] && show_modules=$show_modules_l
@@ -544,8 +549,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="$tmpdir"
+readonly initdir=$(mktemp --tmpdir="$TMPDIR/" -d -t initramfs.XXXXXX)
[ -d "$initdir" ] || {
dfatal "mktemp failed."
exit 1
--
1.7.8.5
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [PATCH 2/2] document --tmpdir option
[not found] ` <1332764916-22282-1-git-send-email-aidecoe-2qtfh70TtYba5EbDDlwbIw@public.gmane.org>
@ 2012-03-26 12:28 ` Amadeusz Żołnowski
2012-03-26 12:42 ` [PATCH 1/2] add --tmpdir option to cmd line args and tmpdir to config file Harald Hoyer
1 sibling, 0 replies; 3+ messages in thread
From: Amadeusz Żołnowski @ 2012-03-26 12:28 UTC (permalink / raw)
To: initramfs-u79uwXL29TY76Z2rM5mHXA; +Cc: Amadeusz Żołnowski
---
dracut.8.asc | 6 ++++++
dracut.conf.5.asc | 3 +++
2 files changed, 9 insertions(+), 0 deletions(-)
diff --git a/dracut.8.asc b/dracut.8.asc
index 10cccc0..7c53314 100644
--- a/dracut.8.asc
+++ b/dracut.8.asc
@@ -217,6 +217,12 @@ Default:
Default:
_/etc/dracut.conf.d_
+**--tmpdir** _<temporary directory>_::
+ specify temporary directory to use.
++
+Default:
+ _/var/tmp_
+
**--sshkey** _<sshkey file>_:: ssh key file used with ssh-client module.
**-l, --local**::
diff --git a/dracut.conf.5.asc b/dracut.conf.5.asc
index 8709617..017a221 100644
--- a/dracut.conf.5.asc
+++ b/dracut.conf.5.asc
@@ -67,6 +67,9 @@ line are not interpreted.
*hostonly=*"__{yes|no}__"::
Host-Only mode: Install only what is needed for booting the local host instead of a generic host.
+*tmpdir=*"__<temporary directory>__"::
+ Specify temporary directory to use.
+
[WARNING]
====
If chrooted to another root other than the real root device, use --fstab and provide a valid _/etc/fstab_.
--
1.7.8.5
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH 1/2] add --tmpdir option to cmd line args and tmpdir to config file
[not found] ` <1332764916-22282-1-git-send-email-aidecoe-2qtfh70TtYba5EbDDlwbIw@public.gmane.org>
2012-03-26 12:28 ` [PATCH 2/2] document --tmpdir option Amadeusz Żołnowski
@ 2012-03-26 12:42 ` Harald Hoyer
1 sibling, 0 replies; 3+ messages in thread
From: Harald Hoyer @ 2012-03-26 12:42 UTC (permalink / raw)
To: Amadeusz Żołnowski; +Cc: initramfs-u79uwXL29TY76Z2rM5mHXA
Am 26.03.2012 14:28, schrieb Amadeusz Żołnowski:
> Default temporary directory used by Dracut is /var/tmp, but users might
> want to change it to /tmp.
> ---
> dracut.conf | 2 ++
> dracut.sh | 9 +++++++--
> 2 files changed, 9 insertions(+), 2 deletions(-)
>
> diff --git a/dracut.conf b/dracut.conf
> index a502066..1ee563e 100644
> --- a/dracut.conf
> +++ b/dracut.conf
> @@ -38,3 +38,5 @@ lvmconf="yes"
>
> # inhibit installation of any fsck tools
> #nofscks="yes"
> +
> +tmpdir=/tmp
pushed, but commented in the line above...
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2012-03-26 12:42 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-03-26 12:28 [PATCH 1/2] add --tmpdir option to cmd line args and tmpdir to config file Amadeusz Żołnowski
[not found] ` <1332764916-22282-1-git-send-email-aidecoe-2qtfh70TtYba5EbDDlwbIw@public.gmane.org>
2012-03-26 12:28 ` [PATCH 2/2] document --tmpdir option Amadeusz Żołnowski
2012-03-26 12:42 ` [PATCH 1/2] add --tmpdir option to cmd line args and tmpdir to config file Harald Hoyer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox