Bug#592076: zz-update-grub not available during upgrade
Bas Zoetekouw
bas at debian.org
Sat Aug 7 12:55:40 UTC 2010
Package: grub-pc
Version: 1.98+20100804-1
Severity: serious
During upgrade of the kernel, the kernel postrm runs stuff in
/etc/kernel/postrm.d. This directory contains a symlink
zz-update-grub to ../postinst.d/zz-update-grub
However, if grub is also being updated during the same apt run, this
file ../postinst.d/zz-update-grub is renamed to
zz-update-grub.dpkg-new, so the run-parts in the kernel's postrm
fails:
Preparing to replace linux-image-2.6.32-5-amd64 2.6.32-18 (using .../linux-image-2.6.32-5-amd64_2.6.32-19_amd64.deb) ...
Examining /etc/kernel/preinst.d/
Unpacking replacement linux-image-2.6.32-5-amd64 ...
Examining /etc/kernel/postrm.d .
run-parts: executing /etc/kernel/postrm.d/initramfs-tools 2.6.32-5-amd64 /boot/vmlinuz-2.6.32-5-amd64
run-parts: failed to stat component /etc/kernel/postrm.d/zz-update-grub: No such file or directory
Failed to process /etc/kernel/postrm.d at /var/lib/dpkg/info/linux-image-2.6.32-5-amd64.postrm line 234.
dpkg: warning: subprocess old post-removal script returned error exit status 1
So either grub-pc needs to make sure that the symlink is updated during
upgrades, or run-parts needs to ignore symlinks with a non-existing target.
-- Package-specific info:
*********************** BEGIN /proc/mounts
/dev/disk/by-uuid/baaec030-c0e7-45db-a0cf-61e3f340cae2 / ext3 rw,noatime,errors=remount-ro,data=ordered 0 0
/dev/sda9 /boot ext3 rw,noatime,errors=continue,data=ordered 0 0
/dev/mapper/eleanor-usr /usr ext3 rw,noatime,errors=continue,data=ordered 0 0
/dev/mapper/eleanor-local /usr/local ext3 rw,noatime,errors=continue,data=ordered 0 0
/dev/mapper/eleanor-home /home ext3 rw,noatime,errors=continue,data=ordered 0 0
/dev/mapper/eleanor-var /var ext3 rw,noatime,errors=continue,data=ordered 0 0
/dev/mapper/eleanor-aptcache /var/cache/apt ext3 rw,noatime,errors=continue,data=ordered 0 0
/dev/mapper/eleanor-pbuilder /var/cache/pbuilder ext3 rw,noatime,errors=continue,data=ordered 0 0
/dev/mapper/eleanor-ccache /var/cache/ccache ext3 rw,noatime,errors=continue,data=ordered 0 0
/dev/mapper/eleanor-usercache /var/cache/users ext3 rw,noatime,errors=continue,data=ordered 0 0
/dev/mapper/eleanor-scratch /scratch ext3 rw,noatime,errors=continue,data=ordered 0 0
/dev/mapper/eleanor-aptcache /var/cache/pbuilder/aptcache ext3 rw,noatime,errors=continue,data=ordered 0 0
/dev/sr0 /media/DragonAge_ iso9660 ro,nosuid,nodev,relatime,uid=1000,gid=1000,iocharset=utf8,mode=0400,dmode=0500 0 0
*********************** END /proc/mounts
*********************** BEGIN /boot/grub/device.map
(hd0) /dev/disk/by-id/ata-ST3160023AS_3JS3Q4W2
(hd1) /dev/disk/by-id/ata-ST3250820A_5QE5FBB8
*********************** END /boot/grub/device.map
*********************** BEGIN /boot/grub/grub.cfg
#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#
### BEGIN /etc/grub.d/00_header ###
if [ -s $prefix/grubenv ]; then
load_env
fi
set default="0"
if [ "${prev_saved_entry}" ]; then
set saved_entry="${prev_saved_entry}"
save_env saved_entry
set prev_saved_entry=
save_env prev_saved_entry
set boot_once=true
fi
function savedefault {
if [ -z "${boot_once}" ]; then
saved_entry="${chosen}"
save_env saved_entry
fi
}
function load_video {
insmod vbe
insmod vga
insmod video_bochs
insmod video_cirrus
}
terminal_input console
terminal_output console
set timeout=5
### END /etc/grub.d/00_header ###
### BEGIN /etc/grub.d/05_debian_theme ###
set menu_color_normal=cyan/blue
set menu_color_highlight=white/blue
### END /etc/grub.d/05_debian_theme ###
### BEGIN /etc/grub.d/10_linux ###
menuentry 'Debian GNU/Linux, with Linux 2.6.30-rc3' --class debian --class gnu-linux --class gnu --class os {
insmod part_msdos
insmod ext2
set root='(hd0,msdos9)'
search --no-floppy --fs-uuid --set f7e3eb59-64b2-4c2c-b124-a9914a5a48be
echo 'Loading Linux 2.6.30-rc3 ...'
linux /vmlinuz-2.6.30-rc3 root=/dev/sda5 ro resume=swap:/dev/sda8 quiet
}
menuentry 'Debian GNU/Linux, with Linux 2.6.30-rc3 (recovery mode)' --class debian --class gnu-linux --class gnu --class os {
insmod part_msdos
insmod ext2
set root='(hd0,msdos9)'
search --no-floppy --fs-uuid --set f7e3eb59-64b2-4c2c-b124-a9914a5a48be
echo 'Loading Linux 2.6.30-rc3 ...'
linux /vmlinuz-2.6.30-rc3 root=/dev/sda5 ro single resume=swap:/dev/sda8
}
### END /etc/grub.d/10_linux ###
### BEGIN /etc/grub.d/20_linux_xen ###
### END /etc/grub.d/20_linux_xen ###
### BEGIN /etc/grub.d/20_memtest86+ ###
menuentry "Memory test (memtest86+)" {
insmod part_msdos
insmod ext2
set root='(hd0,msdos9)'
search --no-floppy --fs-uuid --set f7e3eb59-64b2-4c2c-b124-a9914a5a48be
linux16 /memtest86+.bin
}
menuentry "Memory test (memtest86+, serial console 115200)" {
insmod part_msdos
insmod ext2
set root='(hd0,msdos9)'
search --no-floppy --fs-uuid --set f7e3eb59-64b2-4c2c-b124-a9914a5a48be
linux16 /memtest86+.bin console=ttyS0,115200n8
}
menuentry "Memory test (memtest86+, experimental multiboot)" {
insmod part_msdos
insmod ext2
set root='(hd0,msdos9)'
search --no-floppy --fs-uuid --set f7e3eb59-64b2-4c2c-b124-a9914a5a48be
multiboot /memtest86+_multiboot.bin
}
menuentry "Memory test (memtest86+, serial console 115200, experimental multiboot)" {
insmod part_msdos
insmod ext2
set root='(hd0,msdos9)'
search --no-floppy --fs-uuid --set f7e3eb59-64b2-4c2c-b124-a9914a5a48be
multiboot /memtest86+_multiboot.bin console=ttyS0,115200n8
}
### END /etc/grub.d/20_memtest86+ ###
### BEGIN /etc/grub.d/30_os-prober ###
menuentry "Windows 7 (loader) (on /dev/sdb1)" {
insmod part_msdos
insmod ntfs
set root='(hd1,msdos1)'
search --no-floppy --fs-uuid --set dce813bae813923e
chainloader +1
}
### END /etc/grub.d/30_os-prober ###
### BEGIN /etc/grub.d/40_custom ###
### END /etc/grub.d/40_custom ###
### BEGIN /etc/grub.d/41_custom ###
if [ -f $prefix/custom.cfg ]; then
source $prefix/custom.cfg;
fi
### END /etc/grub.d/41_custom ###
*********************** END /boot/grub/grub.cfg
-- System Information:
Debian Release: squeeze/sid
APT prefers unstable
APT policy: (990, 'unstable'), (1, 'experimental')
Architecture: amd64 (x86_64)
Kernel: Linux 2.6.32-5-amd64 (SMP w/2 CPU cores)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Versions of packages grub-pc depends on:
ii debconf [debconf-2.0] 1.5.34 Debian configuration management sy
ii grub-common 1.98+20100804-1 GRand Unified Bootloader, version
ii libc6 2.11.2-2 Embedded GNU C Library: Shared lib
ii libdevmapper1.02.1 2:1.02.48-2 The Linux Kernel Device Mapper use
ii ucf 3.0025 Update Configuration File: preserv
grub-pc recommends no packages.
Versions of packages grub-pc suggests:
ii desktop-base 5.0.5 common files for the Debian Deskto
-- debconf information excluded
More information about the Pkg-grub-devel
mailing list