From 2af62f01892c2b89e8420c7985233388bf06667d Mon Sep 17 00:00:00 2001 From: Fabio Erculiani Date: Sat, 31 Aug 2013 12:19:36 +0200 Subject: [PATCH] gen_initramfs: provide /bin/dmesg as well --- defaults/initrd.d/00-nfs.sh | 6 ++---- gen_initramfs.sh | 2 +- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/defaults/initrd.d/00-nfs.sh b/defaults/initrd.d/00-nfs.sh index 9e8aed3..d3e4269 100755 --- a/defaults/initrd.d/00-nfs.sh +++ b/defaults/initrd.d/00-nfs.sh @@ -19,8 +19,7 @@ find_nfs() { if [ -z "${NFSROOT}" ]; then # Obtain NFSIP # TODO: this is bogus, because dmesg is a circular buffer... - # TODO: provide dmesg as symlink (see gen_initramfs.sh) - options=$(busybox dmesg | grep rootserver | sed -e "s/,/ /g") + options=$(dmesg | grep rootserver | sed -e "s/,/ /g") local opt= optn= @@ -33,8 +32,7 @@ find_nfs() { # Obtain NFSPATH # TODO: this is bogus, because dmesg is a circular buffer... - # TODO: provide dmesg as symlink (see gen_initramfs.sh) - options=$(busybox dmesg | grep rootpath | sed -e "s/,/ /g") + options=$(dmesg | grep rootpath | sed -e "s/,/ /g") for opt in ${options}; do optn=$(echo $opt | sed -e "s/=/ /g" | cut -d " " -f 1) diff --git a/gen_initramfs.sh b/gen_initramfs.sh index f136614..4424214 100755 --- a/gen_initramfs.sh +++ b/gen_initramfs.sh @@ -131,7 +131,7 @@ append_busybox() { # Set up a few default symlinks local default_applets="[ ash sh mount uname ls echo cut cat flock stty" - default_applets+=" readlink mountpoint" + default_applets+=" readlink mountpoint dmesg" for i in ${BUSYBOX_APPLETS:-${default_applets}}; do rm -f ${TEMP}/initramfs-busybox-temp/bin/$i ln -s busybox ${TEMP}/initramfs-busybox-temp/bin/$i ||