On Thu, 4 Mar 1999, Chad Robinson wrote:

> We found a number of ways to do that.  It's not always obvious, but
> booting from a ramdrive filesystem is much faster than booting from a
> hard drive, so we set this up on an embedded device.  Next, we removed
> almost everything from the boot scripts.  We used mingetty instead of
> agetty to make the getty process smaller, and only have one running.
> All these things together helped tremendously.

Something else you can do is replace init and init scripts entirely with a
compiled program. Invoking a shell is relatively slow. Launching different
parts of your initialization in parallel may help as well. For instance,
if you don't need the network until after you have X up, launch the
network initialization with a lower priority.

> Then we looked at the kernel.  We wanted to stop short of 'hacking' the
> kernel, but as it turns out, this isn't really necessary.  We removed so
> many device drivers (including the floppy drive) that when we were done,
> the kernel was half its usual size, and booted very quickly (no devices
> to scan, which was taking the most boot time).

If you do decide to hack the kernel, there is quite a bit of detection
that can be speeded up. For instance, hardcoding BOGOMips. If you're using
X, recompiling it to support only your hardware, and configuring it to do
a minimum of autodetection should help a lot as well.

> All in all, we have a P-166 with 32MB RAM and a 4MB flash disk booting
> in around 5 seconds.  I'm sure this could be reduced - our application
> required audio and networking support.

--
 "Love the dolphins," she advised him. "Write by W.A.S.T.E.." 

Reply via email to