* [PATCH] Allow fstab-based remount to be controlled by modules
@ 2010-11-08 19:41 Daniel Drake
[not found] ` <20101108194128.EBFEB9D401B-k/4jFdqg8LLlyo9zxV8I99HuzzzSOjJt@public.gmane.org>
0 siblings, 1 reply; 3+ messages in thread
From: Daniel Drake @ 2010-11-08 19:41 UTC (permalink / raw)
To: initramfs-u79uwXL29TY76Z2rM5mHXA
OLPC would like to be able to disable this behaviour through
a custom dracut module. Add a "no_fstab_remount" flag which can be
set by modules that want to disable this functionality.
(Background: having the correct rootfs info in /etc/fstab is a bit of a
challenge for OLPC, because this info is not known at build time.)
---
modules.d/95rootfs-block/mount-root.sh | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/modules.d/95rootfs-block/mount-root.sh b/modules.d/95rootfs-block/mount-root.sh
index ff64209..7602731 100755
--- a/modules.d/95rootfs-block/mount-root.sh
+++ b/modules.d/95rootfs-block/mount-root.sh
@@ -73,6 +73,7 @@ if [ -n "$root" -a -z "${root%%block:*}" ]; then
rootopts=
if getargbool 1 rd.fstab -n rd_NO_FSTAB \
&& ! getarg rootflags \
+ && [ -z "$no_fstab_remount" ] \
&& [ -f "$NEWROOT/etc/fstab" ] \
&& ! [ -L "$NEWROOT/etc/fstab" ]; then
# if $NEWROOT/etc/fstab contains special mount options for
--
1.7.3.2
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] Allow fstab-based remount to be controlled by modules
[not found] ` <20101108194128.EBFEB9D401B-k/4jFdqg8LLlyo9zxV8I99HuzzzSOjJt@public.gmane.org>
@ 2010-11-10 14:32 ` Harald Hoyer
[not found] ` <4CDAACE6.8040108-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
0 siblings, 1 reply; 3+ messages in thread
From: Harald Hoyer @ 2010-11-10 14:32 UTC (permalink / raw)
To: Daniel Drake; +Cc: initramfs-u79uwXL29TY76Z2rM5mHXA
On 11/08/2010 08:41 PM, Daniel Drake wrote:
> OLPC would like to be able to disable this behaviour through
> a custom dracut module. Add a "no_fstab_remount" flag which can be
> set by modules that want to disable this functionality.
>
> (Background: having the correct rootfs info in /etc/fstab is a bit of a
> challenge for OLPC, because this info is not known at build time.)
> ---
> modules.d/95rootfs-block/mount-root.sh | 1 +
> 1 files changed, 1 insertions(+), 0 deletions(-)
>
> diff --git a/modules.d/95rootfs-block/mount-root.sh b/modules.d/95rootfs-block/mount-root.sh
> index ff64209..7602731 100755
> --- a/modules.d/95rootfs-block/mount-root.sh
> +++ b/modules.d/95rootfs-block/mount-root.sh
> @@ -73,6 +73,7 @@ if [ -n "$root" -a -z "${root%%block:*}" ]; then
> rootopts=
> if getargbool 1 rd.fstab -n rd_NO_FSTAB \
> && ! getarg rootflags \
> +&& [ -z "$no_fstab_remount" ] \
> && [ -f "$NEWROOT/etc/fstab" ] \
> && ! [ -L "$NEWROOT/etc/fstab" ]; then
> # if $NEWROOT/etc/fstab contains special mount options for
Why don't you reuse rd.fstab then? You could add preset kernel cmdline options
in /etc/cmdline in the initramfs.
Just add for your dracut module in install:
mkdir -p ${initdir}/etc
echo " rd.fstab=0 " >> ${initdir}/etc/cmdline
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] Allow fstab-based remount to be controlled by modules
[not found] ` <4CDAACE6.8040108-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
@ 2010-11-10 18:55 ` Daniel Drake
0 siblings, 0 replies; 3+ messages in thread
From: Daniel Drake @ 2010-11-10 18:55 UTC (permalink / raw)
To: Harald Hoyer; +Cc: initramfs-u79uwXL29TY76Z2rM5mHXA
On 10 November 2010 14:32, Harald Hoyer <harald-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org> wrote:
> Just add for your dracut module in install:
>
> mkdir -p ${initdir}/etc
> echo " rd.fstab=0 " >> ${initdir}/etc/cmdline
Thanks!
Wasn't aware that you could do this. It was exactly what I was looking
for, no patch needed.
Daniel
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2010-11-10 18:55 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-11-08 19:41 [PATCH] Allow fstab-based remount to be controlled by modules Daniel Drake
[not found] ` <20101108194128.EBFEB9D401B-k/4jFdqg8LLlyo9zxV8I99HuzzzSOjJt@public.gmane.org>
2010-11-10 14:32 ` Harald Hoyer
[not found] ` <4CDAACE6.8040108-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2010-11-10 18:55 ` Daniel Drake
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.