memo.xight.org

日々のメモ

Debian - grub

grub-install を実行

# grub-install /dev/hda
Probing devices to guess BIOS drives. This may take a long time.
Installation finished. No error reported.
This is the contents of the device map /boot/grub/device.map.
Check if this is correct or not. If any of the lines is incorrect,
fix it and re-run the script `grub-install'.

(fd0) /dev/fd0
(hd0) /dev/hda


update-grub を実行

# update-grub
Searching for GRUB installation directory ... found: /boot/grub .
Testing for an existing GRUB menu.list file...

Could not find /boot/grub/menu.lst file. Would you like
/boot/grub/menu.lst generated for you? (y/N) y
Searching for splash image... none found, skipping...
Found kernel: /vmlinuz-2.4.18-bf2.4
Updating /boot/grub/menu.lst ... done


/boot/grub/menu.lst を編集


再度 update-grub を実行

# update-grub
Searching for GRUB installation directory ... found: /boot/grub .
Testing for an existing GRUB menu.list file... found: /boot/grub/menu.lst
.
Searching for splash image... none found, skipping...
Found kernel: /vmlinuz-2.4.18-bf2.4
Updating /boot/grub/menu.lst ... done

LILOの問い合わせを無くし,update-grubを自動的に実行させる

/etc/kernel-img.conf を作成

postinst_hook = /sbin/update-grub
postrm_hook = /sbin/update-grub
do_bootloader = no

Reference

Iwatani Electronics - Debian GNU/Linux で利用する GNU GRUB
http://www2.i-e-c.co.jp/grubindex.html