Gentoo Logo
Gentoo Spaceship




Note: Due to technical difficulties, the Archives are currently not up to date. GMANE provides an alternative service for most mailing lists.
c.f. bug 424647
List Archive: gentoo-user
Navigation:
Lists: gentoo-user: < Prev By Thread Next > < Prev By Date Next >
Headers:
To: gentoo-user@g.o
From: Helmut Jarausch <jarausch@...>
Subject: InitRAMFS - boot expert sought
Date: Tue, 27 Mar 2012 12:36:44 +0200
Hi,

I've been looking for simple method to create a simple initramfs to  
just mount the /usr partition.

I've found
http://wiki.gentoo.org/wiki/Basic_initramfs_used_to_check_and_mount_/usr

which didn't work for me. So, I've modified it, see

http://www.igpm.rwth-aachen.de/jarausch/Temp/InitRAMFS/

The last lines of the file 'script_init.sh' are

# ====================== end doing stuff

mount -o remount,rw /mnt/root     ### WHY are
cp /proc/mounts /mnt/root/mtab    ### these two lines necessary

# clean up. The init process will remount proc sys and dev later
umount /proc
umount /sys
# umount /dev   # fails, since it's automounted by the kernel

# switch to the real root and execute init
exec switch_root /mnt/root /sbin/init "$@"


I first tried this with the lines marked by '###' removed.
This worked on one machine but not on another one. There I got
'Remounting root filesystem read/write failed'
'mount: / not mounted or bad option'

If I replace line 26 of /etc/init.d/root (openrc-0.9.9.3)
mount -n -o remount,rw /

by

mount /dev/root -n -o remount,rw /

it works, as well, i.e. without the two marked lines above.
The first mount command finds the mount options in /etc/mtab .
Why are the marked lines above necessary on only one of two machines
(both of which run the same version of openrc)?

Many thanks for a hint,
Helmut.


Replies:
Re: InitRAMFS - boot expert sought
-- Mike Edenfield
Navigation:
Lists: gentoo-user: < Prev By Thread Next > < Prev By Date Next >
Previous by thread:
hylafax+
Next by thread:
Re: InitRAMFS - boot expert sought
Previous by date:
Re: hylafax+
Next by date:
Re: Re: Line-In input doesn't get forwarded as output


Updated May 04, 2012

Summary: Archive of the gentoo-user mailing list.

Donate to support our development efforts.

Copyright 2001-2013 Gentoo Foundation, Inc. Questions, Comments? Contact us.