Thread: /boot question
View Single Post

   
  #4 (permalink)  
Old 02-20-2008, 08:10 AM
Eef Hartman
 
Posts: n/a
Default Re: /boot question

"marcusm <\"marcusm7\"@" <"comcast.netWork> wrote:
> Specifically is it necessary to keep/have multiple links for the new
> kernels and System.maps and, must there always be a link named vmlinux


No, the names of the kernel(s) are only needed in the lilo.conf (or the
correspong grub config) file. It might be smart, though, to make the lilo
config look for "vmlinux" and make THAT a symbolic link, then you don't
have to change that file every new release.

> and another one named System.map.


It is better to have that one, yes. Not all programs need it, but often they
will look for that file first when looking for kernel symbols.
Note that the kernel itself doesn't need it anymore, so it IS ok to create
the link after rebooting to that kernel, code like this:
KERNEL=`uname -r`
cd /boot && ln -sf System.map-$KERNEL System.map
(out of a script we run from the rc.local).
If you're using Pat's standard naming, you'll need another * in there (his
maps are named "System.map-ide-2.4.??" cq "System.map-generic-2.6.??").

> The the slackbook also googling are clear when its just one or two
> kernels. But when you start talking three or more its not clear to me.


Here you got one for three kernels:
lrwxrwxrwx 1 root root 19 2005-05-17 14:19 System.map -> System.map-2.6.11.3
-rw-r--r-- 1 root root 623270 2005-01-05 12:05 System.map-2.4.28
-rw-r--r-- 1 root root 624921 2005-04-13 16:02 System.map-2.4.29
-rw-r--r-- 1 root root 885575 2005-03-14 16:11 System.map-2.6.11.3
-rw-r--r-- 1 root root 512 2004-07-02 14:36 boot.0300
lrwxrwxrwx 1 root root 15 2005-05-17 14:19 config -> config-2.6.11.3
-rw-r--r-- 1 root root 37645 2005-01-05 12:06 config-2.4.28
-rw-r--r-- 1 root root 38806 2005-04-13 16:02 config-2.4.29
-rw-r--r-- 1 root root 41765 2005-03-16 16:10 config-2.6.11.3
-rw-r--r-- 1 root root 5032 2004-05-21 09:19 diag1.img
-rw------- 1 root root 60416 2005-05-07 18:46 map
lrwxrwxrwx 1 root root 14 2005-05-01 14:28 vmlinuz -> vmlinuz-2.4.29
-rw-r--r-- 1 root root 1233099 2005-01-05 12:06 vmlinuz-2.4.28
-rw-r--r-- 1 root root 1236680 2005-04-13 16:02 vmlinuz-2.4.29
-rw-r--r-- 1 root root 1699612 2005-03-14 16:13 vmlinuz-2.6.11.3
lrwxrwxrwx 1 root root 16 2005-05-01 10:57 vmlinuz.new -> vmlinuz-2.6.11.3
lrwxrwxrwx 1 root root 14 2005-05-01 18:45 vmlinuz.old -> vmlinuz-2.4.28
The three links, vmlinux and vmlinux.* are in the lilo.conf, the symbolic
links for map and config files are RE-created after every reboot.
As is the one for "/usr/src/linux", by the way, to be able to rebuild drivers
for "the current kernel" with that path.

PS: this is the significant part of the lilo.conf:
# Linux bootable partition config begins
image = /boot/vmlinuz
root = /dev/hda1
label = Linux
read-only # Non-UMSDOS filesystems should be mounted read-only for checking
image = /boot/vmlinuz.new
root = /dev/hda1
label = Newkernel
read-only # Non-UMSDOS filesystems should be mounted read-only for checking
image = /boot/vmlinuz.old
root = /dev/hda1
label = Backup
read-only # Non-UMSDOS filesystems should be mounted read-only for checking
# Linux bootable partition config ends
#
# DOS/Windows bootable partition config begins
other = /dev/hda2
label = Mswin
table = /dev/hda
# DOS/Windows bootable partition config ends
--
************************************************** ******************
** Eef Hartman, Delft University of Technology, dept. EWI/TW **
** e-mail: E.J.M.Hartman@math.tudelft.nl, fax: +31-15-278 7295 **
** snail-mail: P.O. Box 5031, 2600 GA Delft, The Netherlands **
************************************************** ******************
Reply With Quote