aus9 Posted December 24, 2004 Report Share Posted December 24, 2004 hi I started to compile my own kernel. (Not yet a full success) I amended my grub entry and new kernel needs no initrd image I have a standard 10.1 kernel 2.6.8.1-10 that uses vmlinuz and symbolic links to the real kernel and associated System.map file 2) On first attempt with my compiled 2.6.9 kernel I saw a message that my system map was not found and (on reboot) my map file was missing. So I deleted all symbolic links and amended grub for standard mdk kernel to boot and it works ok Then I added my bzImage and its related system map file but called these bzImage-269 and System.map-269 and grub amended etc 3) On reboot I can see its my new bzImage loading but altho my bzImage file remains in folder /boot the map file is gone on reboot. 4) Anyone know which service is playing with my boot directory? Quote Link to comment Share on other sites More sharing options...
aru Posted December 24, 2004 Report Share Posted December 24, 2004 I don't know what steps lead you to this situation, but the System.map file for your kernel is the one generated during the kernel compilation, that you could either place in your boot directory by hand (cp $builddir/System.map /boot/System.map-$kerneltag) or by running make install after the compilation). You don't need to link your brand new System.map-version to default /boot/System.map because that is automated by /etc/rc.sysinit in # Adjust symlinks as necessary in /boot to keep system services from # spewing messages about mismatched System maps and so on. if [ -L /boot/System.map -a -r /boot/System.map-`uname -r` -a \ ! /boot/System.map -ef /boot/System.map-`uname -r` ]; then ln -s -f System.map-`uname -r` /boot/System.map 2>/dev/null fi if [ ! -e /boot/System.map -a -r /boot/System.map-`uname -r` ]; then ln -s -f System.map-`uname -r` /boot/System.map 2>/dev/null fi also the problem you are experiencing could be happening because you wrong linked a System.map of an older/different version of the kernel running. And it gets deleted on every reboot because of /etc/init.d/kheader (not sure 100%); the code that may be acting is: function remove_orphaned { local version= i= for i in /boot/kernel.h-* /boot/System.map-* /boot/config-*; do version=${i#*-} [[ -f /boot/vmlinuz-${version} ]] || rm -f ${i} done } HTH ...and merry christmas to all, see you! Quote Link to comment Share on other sites More sharing options...
aus9 Posted December 25, 2004 Author Report Share Posted December 25, 2004 aru good stuff I will report back after chrissy. the other thought I will check out is my lack of depmod -a in the reading I have done. merry Xmas Quote Link to comment Share on other sites More sharing options...
aus9 Posted December 26, 2004 Author Report Share Posted December 26, 2004 it appears that I cheated, who me? I had not used the correct kernel numbering that I had compiled. I renamed my missing file System.map-269 instead of -2.6.9. 2) instead of cp and rename I used depmod -a and make install then edit my grub so my steps for those interested are mkdir /opt/k and unpack new kernel there eg /opt/k/linux-2.6.9 delete link to /usr/src/linux from the k source add new link.......... ln -s /opt/k/linux-2.6.9 /usr/src/linux cd /opt/k/linuxetc make mrproper make menuconfig (or xconfig) make bzImage; make modules; make modules_install depmod -a make install (make install then attempts to mkinitrd but I have compiled in all I need [i think] so ignore error) check /boot has vmlinuz-2.6.9 and System.map-2.6.9 and config-2.6.9 edit /boot/grub/menu.lst for new kernel and old kernels My kernel is not perfect but it boots proving I do not need initrd.img and can now start to tweak it. thanks for your help Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.