When building rescue disks, it is not uncommon that the first few tries will not boot. The general approach to building a root disk is to assemble components from your existing system, and try and get the diskette-based system to the point where it displays messages on the console. Once it starts talking to you, the battle is half over, because you can see what it is complaining about, and you can fix individual problems until the system works smoothly. If the system just hangs with no explanation, finding the cause can be difficult. To get a system to boot to the stage where it will talk to you requires several components to be present and correctly configured. The recommended procedure for investigating the problem where the system will not talk to you is as follows:
Once these general aspects have been covered, here are some more specific files to check:
ldd init
to check init's libraries. Usually this is just libc.so, but check anyway. Make sure you included the libraries.
file
on the library(ies) reported by ldd to see
what type they are. Make sure you have the right loader file on the
root disk. The loader file is either ld.so (for a.out libraries) or
ld-linux.so (for ELF libraries).
/etc/inittab
on your bootdisk filesystem
for the calls to *getty*
/etc/inittab
has a
system initialisation entry. This should contain a command of the form
/etc/rc.x, to execute one of the /etc/rc scripts. The specific script
in the inittab must exist.
init
, run ldd on getty (or agetty) to see what
it needs, and make sure the necessary library files and loaders were
included in your root filesystem.
/etc/ld.so.cache
file on your rescue
disk, remake it.
If init starts, but you get a message like:
Id xxx respawning too fast: disabled for n minutes
it's coming from init, usually indicating that your *getty* or login
is dying as soon as it starts up. Check the *getty* and login
executables, and the libraries they depend upon. Make sure the
invocations in /etc/inittab are correct. If you get strange messages
from *getty*, it may mean the calling form in /etc/inittab
is
wrong. The options of the *getty* programs are variable; even
different versions of agetty are reported to have different
incompatible calling forms. If you're using a different call and/or
program from what you use in your hard disk /etc/inittab
,
double check it.
If you try to run some executable, such as df
, which is on your
rescue disk but you yields a message like: df: not found
,
check two things:
ldd file
to see what libraries are needed, and make sure
those libraries exist. See the section above on /lib