From: Gustavo Zacarias <gustavo@zacarias.com.ar>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH] package/eudev: tweak initscript
Date: Mon, 20 Oct 2014 15:17:10 -0300 [thread overview]
Message-ID: <544551A6.4060807@zacarias.com.ar> (raw)
In-Reply-To: <20141020181045.GL3742@free.fr>
On 10/20/2014 03:10 PM, Yann E. MORIN wrote:
> Mine has no timeout, but from man udevadm, the default is 120s:
>
> udevadm settle [options]
> Watches the udev event queue, and exits if all current events are
> handled.
>
> --timeout=seconds
> Maximum number of seconds to wait for the event queue to
> become empty. The default value is 120 seconds. A value of
> 0 will check if the queue is empty and always return
> immediately.
>
> So, I think 10s are a bit too short, but can not really suggest a better
> default. Maybe we could just keep the default timeout, even though it is
> a bit long?
120s sounds brutal IMHO, you'll have to wait 2 full minutes to see
anything. But yeah we could argue 10s is a bit short, maybe 30s is a
good compromise?
> Whether we wait 10 or 120 seconds, if something's stuck, there's not
> much we can do about it. My distro, however, does this:
>
> # wait for the udevd childs to finish
> log_action_begin_msg "Waiting for /dev to be fully populated"
> if udevadm settle; then
> log_action_end_msg 0
> else
> log_action_end_msg 0 'timeout'
> fi
>
> Which we could actually do (except in a simpler way, like log the
> issue).
Probably something like...
udevadm settle --timeout=30 || echo "udevadm settle timed out!"
> Not only USB mass-storage for root, but eth over USB, too. I've seen a
> USB bus take about 8s to properly initialise and enumerate all the
> devices, and a few seconds more for the USB-eth device to show up, and
> there was an NFS resource to be mounted from /etc/fstab.
>
> Anyway, this is a corner case.
One would hope you don't switch root to nfs until you get the proper
mount too which would mean a valid ip address as well (this without
using the kernel nfsroot/dhcp client).
Using the kernel subsystem i never tried using ethernet over usb but
presumably rootwait would wait until ip negotiation is done? (again
dunno what happens with the internal dhcp client if eth* isn't ready yet).
Regards.
prev parent reply other threads:[~2014-10-20 18:17 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-10-20 17:45 [Buildroot] [PATCH] package/eudev: tweak initscript Gustavo Zacarias
2014-10-20 17:54 ` Yann E. MORIN
2014-10-20 17:57 ` Gustavo Zacarias
2014-10-20 18:10 ` Yann E. MORIN
2014-10-20 18:17 ` Gustavo Zacarias [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=544551A6.4060807@zacarias.com.ar \
--to=gustavo@zacarias.com.ar \
--cc=buildroot@busybox.net \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox