System.map - what to do when I have multiple kernels in LILO?
Linux - KernelThis forum is for all discussion relating to the Linux kernel.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
System.map - what to do when I have multiple kernels in LILO?
When I compile a new kernel, I get a System.map file that I'm supposed to move into my /boot directory. This is according to the Slackware docs, but I'm assuming this applies to all distros which is why I'm posting here. Anyway...
I configure LILO to be able to boot from the new kernel(s) as well as the old one, but shouldn't each kernel require the System.map file that was made for when that kernel was compiled? If I'm reading this right, then I'll have to rename/copy System.map every time I want to boot a different kernel? I would think that sort of defeats the purpose of what LILO is supposed to do.
The manpage for lilo.conf didn't specify any options for a different System.map filename per image entry (the same way you can use a different kernel name in the 'image=' stmt.), so I guess I'm a little confused here.
What really is System.map doing that is getting changed each time I compile a kernel? And can I just keep using the same one for different kernels (even different kernel versions)?
If each kernel does require its own, custom System.map file, is there a way via LILO to specify this in that image's lilo.conf entry?
I don't know if this is the right thing to do but here is what I have done when having more than one kernel on my system.
Suppose I have multiple kernels in the /boot directory called, say, vmlinuz, vmlinuz.old, and vmlinuz.veryold. Each has its own System file called System.map, System.old, and System.veryold, respectively. (I just rename everything including the current kernel and System.map file before installing the new kernel. Then I install by running "make install" which places the new kernel and System.map file in the /boot directory, and automatically runs lilo).
lilo.conf has the following entries:
image = /boot/vmlinuz
root = /dev/hda1
label = Linux
read-only
That seems to do the trick -- enabling me to boot all three kernels. Again, I do not know if this approach is theoretically correct, but maybe someone else will jump in here and educate us about the mysteries of the System.map file....
If I have multiple kernels of the same version, each with different features enabled, how does the system determine which System.map to use?
Use the extra version variable to give each kernel a unique version number. With 2.4, edit the Makefile (before runing make dep), with 2.6 just use the "local version" option in the config.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.