Mercurial > hg > aboriginal
changeset 1054:37c7bd84c777
Updates to init.sh: only mount tmpfs on /home if / isn't writeable, and use /proc/cmdline instead of grepping dmesg to get console info.
author | Rob Landley <rob@landley.net> |
---|---|
date | Mon, 03 May 2010 09:08:27 -0500 |
parents | 44adac49d1b1 |
children | 5cce9954d37f |
files | sources/native-root/sbin/init.sh |
diffstat | 1 files changed, 4 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/sources/native-root/sbin/init.sh Mon May 03 09:06:32 2010 -0500 +++ b/sources/native-root/sbin/init.sh Mon May 03 09:08:27 2010 -0500 @@ -40,7 +40,9 @@ then mount -o noatime $HOMEDEV /home else - mount -t tmpfs /home /home + # Only mount a tmpfs if / isn't writeable. + touch /.temp 2>/dev/null + [ $? -ne 0 ] && mount -t tmpfs /home /home || rm /.temp fi cd /home @@ -51,8 +53,7 @@ mount -o ro $MNTDEV /mnt fi - CONSOLE="$(dmesg | - sed -n '/^Kernel command line:/s@.* console=\(/dev/\)*\([^ ]*\).*@\2@p')" + CONSOLE="$(sed -n 's@.* console=\(/dev/\)*\([^ ]*\).*@\2@p' /proc/cmdline)" if [ -z "$DISTCC_HOSTS" ] then