All of lore.kernel.org
 help / color / mirror / Atom feed
From: Saul Wold <sgw@linux.intel.com>
To: Patches and discussions about the oe-core layer
	<openembedded-core@lists.openembedded.org>
Subject: Re: [PATCH] busybox:udhcpc: fix the root_is_nfs() function
Date: Mon, 23 Jul 2012 11:34:22 -0700	[thread overview]
Message-ID: <500D992E.7040408@linux.intel.com> (raw)
In-Reply-To: <1342917963-2253-1-git-send-email-rongqing.li@windriver.com>

On 07/21/2012 05:46 PM, rongqing.li@windriver.com wrote:
> From: Roy.Li <rongqing.li@windriver.com>
>
> [YOCTO #2788]
>
> The system will be hung when udhcpc starts, if nfs is mounted
> at "/" directory and default route is different after starting
> udhcpc.
>
> The cause is that root_is_nfs() does not work after kernel-2.6.37,
> since the device name has been changed from /dev/root to
> ${IPADDR}:${NFSDIR} on /proc/mounts. which leads to remove
> the default routes to nfs server,
>
> Now we use a loose match to check if rootfs is nfs.
>
> Signed-off-by: Roy.Li <rongqing.li@windriver.com>
> ---
>   meta/recipes-core/busybox/files/simple.script |    3 ++-
>   1 files changed, 2 insertions(+), 1 deletions(-)
>
This need a PR bump in the busybox recipe.

Sau!

> diff --git a/meta/recipes-core/busybox/files/simple.script b/meta/recipes-core/busybox/files/simple.script
> index 27368f0..dc2121d 100644
> --- a/meta/recipes-core/busybox/files/simple.script
> +++ b/meta/recipes-core/busybox/files/simple.script
> @@ -10,7 +10,8 @@ RESOLV_CONF="/etc/resolv.conf"
>
>   # return 0 if root is mounted on a network filesystem
>   root_is_nfs() {
> -	grep -qe '^/dev/root.*\(nfs\|smbfs\|ncp\|coda\) .*' /proc/mounts
> +	sed -n 's/^[^ ]* \([^ ]*\) \([^ ]*\) .*$/\1 \2/p' /proc/mounts |
> +	grep -q "^/ \(nfs\|smbfs\|ncp\|coda\)$"
>   }
>
>   have_bin_ip=0
>




      reply	other threads:[~2012-07-23 18:45 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-07-22  0:46 [PATCH] busybox:udhcpc: fix the root_is_nfs() function rongqing.li
2012-07-23 18:34 ` Saul Wold [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=500D992E.7040408@linux.intel.com \
    --to=sgw@linux.intel.com \
    --cc=openembedded-core@lists.openembedded.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.