Bug#793375: /etc/grub.d/10_linux: useless boot menu duplicates on systems running sysvinit
Thorsten Glaser
tg at mirbsd.de
Thu Jul 23 11:54:03 UTC 2015
Package: grub-common
Version: 2.02~beta2-26
Severity: wishlist
Hi,
my boot menu contains three entries per kernel: the regular and rescue one
and a new entry '(sysvinit)'. My system only has sysvinit installed though,
so this is kinda misleading as it’s actually the same as the regular entry.
I think that on systems with only one init system installed those entries
should not be generated, to not confuse less versed users.
-- Package-specific info:
*********************** BEGIN /proc/mounts
/dev/sda4 / ext4 rw,relatime,errors=remount-ro,stripe=256,data=ordered 0 0
/dev/sda2 /boot ext4 rw,sync,noatime,stripe=1024 0 0
*********************** END /proc/mounts
*********************** BEGIN /boot/grub/device.map
(hd0) /dev/disk/by-id/ata-INTEL_SSDSA2M160G2HP_CVPO04540184160AGN
*********************** 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
set have_grubenv=true
load_env
fi
if [ "${next_entry}" ] ; then
set default="${next_entry}"
set next_entry=
save_env next_entry
set boot_once=true
else
set default="0"
fi
if [ x"${feature_menuentry_id}" = xy ]; then
menuentry_id_option="--id"
else
menuentry_id_option=""
fi
export menuentry_id_option
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 {
if [ x$feature_all_video_module = xy ]; then
insmod all_video
else
insmod efi_gop
insmod efi_uga
insmod ieee1275_fb
insmod vbe
insmod vga
insmod video_bochs
insmod video_cirrus
fi
}
if [ x$feature_default_font_path = xy ] ; then
font=unicode
else
insmod part_msdos
insmod ext2
set root='hd0,msdos4'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos4 --hint-efi=hd0,msdos4 --hint-baremetal=ahci0,msdos4 --hint='hd0,msdos4' 399fb17d-a949-4f53-bdfd-5d5a8693e98b
else
search --no-floppy --fs-uuid --set=root 399fb17d-a949-4f53-bdfd-5d5a8693e98b
fi
font="/usr/share/grub/unicode.pf2"
fi
if loadfont $font ; then
set gfxmode=1024x768
load_video
insmod gfxterm
fi
terminal_output gfxterm
if [ "${recordfail}" = 1 ] ; then
set timeout=30
else
if [ x$feature_timeout_style = xy ] ; then
set timeout_style=menu
set timeout=5
# Fallback normal timeout code in case the timeout_style feature is
# unavailable.
else
set timeout=5
fi
fi
### END /etc/grub.d/00_header ###
### BEGIN /etc/grub.d/05_debian_theme ###
insmod part_msdos
insmod ext2
set root='hd0,msdos4'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos4 --hint-efi=hd0,msdos4 --hint-baremetal=ahci0,msdos4 --hint='hd0,msdos4' 399fb17d-a949-4f53-bdfd-5d5a8693e98b
else
search --no-floppy --fs-uuid --set=root 399fb17d-a949-4f53-bdfd-5d5a8693e98b
fi
insmod png
if background_image /usr/share/images/desktop-base/spacefun-grub.png; then
set color_normal=white/black
set color_highlight=black/white
else
set menu_color_normal=cyan/blue
set menu_color_highlight=white/blue
fi
### END /etc/grub.d/05_debian_theme ###
### BEGIN /etc/grub.d/10_linux ###
function gfxmode {
set gfxpayload="${1}"
}
set linux_gfx_mode=
export linux_gfx_mode
menuentry 'Debian GNU/Linux, with Linux 4.0.0-2-amd64' --class debian --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.0.0-2-amd64-advanced-399fb17d-a949-4f53-bdfd-5d5a8693e98b' {
load_video
insmod gzio
if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
insmod part_msdos
insmod ext2
set root='hd0,msdos2'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos2 --hint-efi=hd0,msdos2 --hint-baremetal=ahci0,msdos2 --hint='hd0,msdos2' 3827f24c-e309-47f0-a25e-ae50ff9e893b
else
search --no-floppy --fs-uuid --set=root 3827f24c-e309-47f0-a25e-ae50ff9e893b
fi
echo 'Loading Linux 4.0.0-2-amd64 ...'
linux /vmlinuz-4.0.0-2-amd64 root=/dev/sda4 ro rootdelay=5 syscall.x32=y pcie_aspm=force
echo 'Loading initial ramdisk ...'
initrd /initrd.img-4.0.0-2-amd64
}
menuentry 'Debian GNU/Linux, with Linux 4.0.0-2-amd64 (sysvinit)' --class debian --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.0.0-2-amd64-init-sysvinit-399fb17d-a949-4f53-bdfd-5d5a8693e98b' {
load_video
insmod gzio
if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
insmod part_msdos
insmod ext2
set root='hd0,msdos2'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos2 --hint-efi=hd0,msdos2 --hint-baremetal=ahci0,msdos2 --hint='hd0,msdos2' 3827f24c-e309-47f0-a25e-ae50ff9e893b
else
search --no-floppy --fs-uuid --set=root 3827f24c-e309-47f0-a25e-ae50ff9e893b
fi
echo 'Loading Linux 4.0.0-2-amd64 ...'
linux /vmlinuz-4.0.0-2-amd64 root=/dev/sda4 ro rootdelay=5 syscall.x32=y pcie_aspm=force init=/lib/sysvinit/init
echo 'Loading initial ramdisk ...'
initrd /initrd.img-4.0.0-2-amd64
}
menuentry 'Debian GNU/Linux, with Linux 4.0.0-2-amd64 (recovery mode)' --class debian --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.0.0-2-amd64-recovery-399fb17d-a949-4f53-bdfd-5d5a8693e98b' {
load_video
insmod gzio
if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
insmod part_msdos
insmod ext2
set root='hd0,msdos2'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos2 --hint-efi=hd0,msdos2 --hint-baremetal=ahci0,msdos2 --hint='hd0,msdos2' 3827f24c-e309-47f0-a25e-ae50ff9e893b
else
search --no-floppy --fs-uuid --set=root 3827f24c-e309-47f0-a25e-ae50ff9e893b
fi
echo 'Loading Linux 4.0.0-2-amd64 ...'
linux /vmlinuz-4.0.0-2-amd64 root=/dev/sda4 ro single rootdelay=5 syscall.x32=y
echo 'Loading initial ramdisk ...'
initrd /initrd.img-4.0.0-2-amd64
}
menuentry 'Debian GNU/Linux, with Linux 4.0.0-1-amd64' --class debian --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.0.0-1-amd64-advanced-399fb17d-a949-4f53-bdfd-5d5a8693e98b' {
load_video
insmod gzio
if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
insmod part_msdos
insmod ext2
set root='hd0,msdos2'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos2 --hint-efi=hd0,msdos2 --hint-baremetal=ahci0,msdos2 --hint='hd0,msdos2' 3827f24c-e309-47f0-a25e-ae50ff9e893b
else
search --no-floppy --fs-uuid --set=root 3827f24c-e309-47f0-a25e-ae50ff9e893b
fi
echo 'Loading Linux 4.0.0-1-amd64 ...'
linux /vmlinuz-4.0.0-1-amd64 root=/dev/sda4 ro rootdelay=5 syscall.x32=y pcie_aspm=force
echo 'Loading initial ramdisk ...'
initrd /initrd.img-4.0.0-1-amd64
}
menuentry 'Debian GNU/Linux, with Linux 4.0.0-1-amd64 (sysvinit)' --class debian --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.0.0-1-amd64-init-sysvinit-399fb17d-a949-4f53-bdfd-5d5a8693e98b' {
load_video
insmod gzio
if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
insmod part_msdos
insmod ext2
set root='hd0,msdos2'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos2 --hint-efi=hd0,msdos2 --hint-baremetal=ahci0,msdos2 --hint='hd0,msdos2' 3827f24c-e309-47f0-a25e-ae50ff9e893b
else
search --no-floppy --fs-uuid --set=root 3827f24c-e309-47f0-a25e-ae50ff9e893b
fi
echo 'Loading Linux 4.0.0-1-amd64 ...'
linux /vmlinuz-4.0.0-1-amd64 root=/dev/sda4 ro rootdelay=5 syscall.x32=y pcie_aspm=force init=/lib/sysvinit/init
echo 'Loading initial ramdisk ...'
initrd /initrd.img-4.0.0-1-amd64
}
menuentry 'Debian GNU/Linux, with Linux 4.0.0-1-amd64 (recovery mode)' --class debian --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.0.0-1-amd64-recovery-399fb17d-a949-4f53-bdfd-5d5a8693e98b' {
load_video
insmod gzio
if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
insmod part_msdos
insmod ext2
set root='hd0,msdos2'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos2 --hint-efi=hd0,msdos2 --hint-baremetal=ahci0,msdos2 --hint='hd0,msdos2' 3827f24c-e309-47f0-a25e-ae50ff9e893b
else
search --no-floppy --fs-uuid --set=root 3827f24c-e309-47f0-a25e-ae50ff9e893b
fi
echo 'Loading Linux 4.0.0-1-amd64 ...'
linux /vmlinuz-4.0.0-1-amd64 root=/dev/sda4 ro single rootdelay=5 syscall.x32=y
echo 'Loading initial ramdisk ...'
initrd /initrd.img-4.0.0-1-amd64
}
### END /etc/grub.d/10_linux ###
### BEGIN /etc/grub.d/20_linux_xen ###
### END /etc/grub.d/20_linux_xen ###
### BEGIN /etc/grub.d/30_os-prober ###
### END /etc/grub.d/30_os-prober ###
### BEGIN /etc/grub.d/30_uefi-firmware ###
### END /etc/grub.d/30_uefi-firmware ###
### BEGIN /etc/grub.d/40_custom ###
# This file provides an easy way to add custom menu entries. Simply type the
# menu entries you want to add after this comment. Be careful not to change
# the 'exec tail' line above.
### END /etc/grub.d/40_custom ###
### BEGIN /etc/grub.d/41_custom ###
if [ -f ${config_directory}/custom.cfg ]; then
source ${config_directory}/custom.cfg
elif [ -z "${config_directory}" -a -f $prefix/custom.cfg ]; then
source $prefix/custom.cfg;
fi
### END /etc/grub.d/41_custom ###
*********************** END /boot/grub/grub.cfg
*********************** BEGIN /proc/mdstat
cat: /proc/mdstat: No such file or directory
*********************** END /proc/mdstat
*********************** BEGIN /dev/disk/by-id
total 0
lrwxrwxrwx 1 root root 9 Jul 23 13:50 ata-INTEL_SSDSA2M160G2HP_CVPO04540184160AGN -> ../../sda
lrwxrwxrwx 1 root root 10 Jul 23 13:50 ata-INTEL_SSDSA2M160G2HP_CVPO04540184160AGN-part1 -> ../../sda1
lrwxrwxrwx 1 root root 10 Jul 23 13:50 ata-INTEL_SSDSA2M160G2HP_CVPO04540184160AGN-part2 -> ../../sda2
lrwxrwxrwx 1 root root 10 Jul 23 13:50 ata-INTEL_SSDSA2M160G2HP_CVPO04540184160AGN-part3 -> ../../sda3
lrwxrwxrwx 1 root root 10 Jul 23 13:50 ata-INTEL_SSDSA2M160G2HP_CVPO04540184160AGN-part4 -> ../../sda4
lrwxrwxrwx 1 root root 9 Jul 23 13:50 wwn-0x6a4b594751795001 -> ../../sda
lrwxrwxrwx 1 root root 10 Jul 23 13:50 wwn-0x6a4b594751795001-part1 -> ../../sda1
lrwxrwxrwx 1 root root 10 Jul 23 13:50 wwn-0x6a4b594751795001-part2 -> ../../sda2
lrwxrwxrwx 1 root root 10 Jul 23 13:50 wwn-0x6a4b594751795001-part3 -> ../../sda3
lrwxrwxrwx 1 root root 10 Jul 23 13:50 wwn-0x6a4b594751795001-part4 -> ../../sda4
*********************** END /dev/disk/by-id
*********************** BEGIN /dev/disk/by-uuid
total 0
lrwxrwxrwx 1 root root 10 Jul 23 13:50 3827f24c-e309-47f0-a25e-ae50ff9e893b -> ../../sda2
lrwxrwxrwx 1 root root 10 Jul 23 13:50 399fb17d-a949-4f53-bdfd-5d5a8693e98b -> ../../sda4
lrwxrwxrwx 1 root root 10 Jul 23 13:50 a094925c-7820-4c5a-83d0-7c82d977ea01 -> ../../sda1
*********************** END /dev/disk/by-uuid
-- System Information:
Debian Release: stretch/sid
APT prefers unstable
APT policy: (500, 'unstable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386
Kernel: Linux 4.0.0-2-amd64 (SMP w/2 CPU cores)
Locale: LANG=C, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/lksh
Init: sysvinit (via /sbin/init)
Versions of packages grub-common depends on:
ii gettext-base 0.19.4-1
ii libc6 2.19-19
ii libdevmapper1.02.1 2:1.02.99-2
ii libfreetype6 2.5.2-4
ii libfuse2 2.9.4-1
ii liblzma5 5.1.1alpha+20120614-2.1
ii libpng12-0 1.2.50-2+b2
ii zlib1g 1:1.2.8.dfsg-2+b1
Versions of packages grub-common recommends:
ii os-prober 1.66
Versions of packages grub-common suggests:
ii console-setup 2:1
ii desktop-base 8.0.2
pn grub-emu <none>
pn multiboot-doc <none>
pn xorriso <none>
-- no debconf information
More information about the Pkg-grub-devel
mailing list