Compaq AA-RH99A-TE Remote Starter User Manual


 
text file that describes the hardware and software that will be present on
the running system. Using this information, the bootstrap linker links the
modules that are needed to support this hardware and software. The linker
builds the kernel directly into memory.
You cannot directly debug a bootstrap-linked kernel because you must supply
the name of an image to the kernel debugging tools. Without the image, the
tools have no access to symbol names, variable names, and so on. Therefore,
the first step in any kernel debugging effort is to determine whether your
kernel was linked at bootstrap time. If the kernel was linked at bootstrap
time, you must then build a kernel image file to use for debugging purposes.
The best way to determine whether your system is bootstrap linked or
statically linked is to use the file command to test the type of file from
which your system was booted. If your system is a bootstrap-linked system,
it was booted from an ASCII text file; otherwise, it was booted from an
executable image file. For example, issue the following command to
determine the type of file from which your system was booted:
#/usr/bin/file ‘/usr/sbin/sizer -b‘
/etc/sysconfigtab: ascii text
The sizer -b command returns the name of the file from which the system
was booted. This file name is input to the file command, which determines
that the system was booted from an ASCII text file. The output shown in the
preceeding example indicates that the system is a bootstrap-linked system.
If the system had been booted from an executable image file named vmunix,
the output from the file command would have appeared as follows:
vmunix:COFF format alpha executable or object module
not stripped
If your system is running a bootstrap-linked kernel, build a kernel image
that is identical to the bootstrap-linked kernel your system is running, by
entering the following command:
# /usr/bin/ld -o vmunix.image ‘/usr/sbin/sizer -m‘
The output from the sizer -m command is a list of the exact modules and
linker flags used to build the currently running bootstrap-linked kernel.
This output causes the ld command to create a kernel image that is identical
to the bootstrap-linked kernel running on your system. The kernel image is
written to the file named by the -o flag, in this case the vmunix.image file.
Once you create this image, you can debug the kernel as described in this
manual, using the dbx, kdbx, and kdebug debuggers. When you invoke
the dbx or kdbx debugger, remember to specify the name of the kernel
image file you created with the ld command, such as the vmunix.image
file shown here.
When you are finished debugging the kernel, you can remove the kernel
image file you created for debugging purposes.
1–2 Introduction to Kernel Debugging