LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Ubuntu (http://www.linuxquestions.org/questions/ubuntu-63/)
-   -   boot & grub... where do I put kernel pointers? (http://www.linuxquestions.org/questions/ubuntu-63/boot-and-grub-where-do-i-put-kernel-pointers-597643/)

aquaboot 11-06-2007 08:37 PM

boot & grub... where do I put kernel pointers?
 
Hi All,

I've just downloaded and configured my first kernel. I've done make modules_install and make install. I've tweaked my menu.lst to list all kernels (instead of using the escape button)and now I need to add grub entrees so it can find the kernel. This is the part that confuses me. The howto I used said that make install would take care of this, but it didn't seem to. This is the grub entry for my working kernel:

title Ubuntu 7.10, kernel 2.6.22-14-generic
root (hd0,0)
kernel /vmlinuz-2.6.22-14-generic root-UUID=my_root_id ro quiet
splash
initrd /initrd.img-2.6.22-14-generic

I'm pretty sure that the important lines here are the last two, but I'm having trouble making sense of what they are.

Also, I believe I need to do something with the System.map file but am not sure what. Anything else that I need to do? I'm sooo close to building and properly installing my first kernel but just need a little help.

Thanks Much,

ab

pixellany 11-06-2007 09:42 PM

The generic format of an entry in menu.lst:

title whatever
root (hdx,y) #the location of /boot directory
kernel /boot/<kernelname> root=/dev/xxxx <other optional arguments)
initrd /boot/<initfilename>
boot

The above assume that there is no separate partition for /boot---ie "/" is mounted at the location equivalent to (hdx,y)

<kernelname> and <initfilename> are the actual names. What I always do is alias them to generic names--eg "vmlinuz" and "initrd". then, my menu.lst entries are always the same.

root=/dev/xxxx is a command passed to the kernel which tells it where to mount "/" Suppose it is /dev/hda3. Then the root (hdx,y) command would be (hd0,2) (Grub counts from zero.)

More in the "booting" link below

aquaboot 11-06-2007 09:57 PM

Thanks Pixellany,

I'll sink my teeth into this and post my success/failure.

Cheers,

ab

aquaboot 11-06-2007 10:10 PM

Sorry, forgot to follow up on System.map. I found this explanation online:

"Every time you compile a new kernel, the addresses of various symbol names are bound to change. When you compile a new kernel, your old System.map has wrong symbol information. A new System.map is generated with each kernel compile and you need to replace the old copy with your new copy."

Indeed, I see that my newly compiled kernel has a System.map in the top of the directory tree. Do I need to replace the older /boot/System.map with this new one?

Thanks for your help and patience,

ab

pixellany 11-07-2007 12:04 PM

Quote:

Do I need to replace the older /boot/System.map with this new one?
The only time I ever made my own kernel, I do not recall having to do this. But---it seems logical. Backup the existing file and try it.

In any event it is a separate issue from setting up grub.


All times are GMT -5. The time now is 01:04 AM.