1 Aug 2004 03:37
Random-ness when booting into single-user
Garance A Drosihn <drosih <at> rpi.edu>
2004-08-01 01:37:15 GMT
2004-08-01 01:37:15 GMT
When I was at the devsummit, a few developers remarked at the
annoying situation one can get into when booting into single-
user mode. Something about various operations which can hang
because they need some random number(s), but at that point
/dev/random (or whatever the key thing is) has not been seeded
with enough entropy to give random numbers. Apparently once
you get into this state, you have to start typing a lot of
random gibberish to get past the problem. Something about
"dancing the fandango", if I remember right.
Happily I have not run into this, and I think I would like to
make sure that I don't run into it -- even though I obviously
don't remember any of the details...
I have been looking at sbin/init/init.c, and I was wondering
if it might be fairly easy to provide a fix to this situation.
Let's say you request single-user mode. If you asked for
single-user mode, init.c is what will ask you which shell you
want use.
Once it knows the shell, couldn't it just do something like
first execute:
${SHELL} -c /etc/rc.d/preseedrandom
(and ignore any failures)
And *then* execute the standard
${SHELL}
for single-user mode?
Or maybe it would execute some other script to seed the
(Continue reading)
RSS Feed