Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

[ Solved ]Multi OS Grub Issues with Debian

New to Debian (Or Linux in general)? Ask your questions here!
Post Reply
Message
Author
remus
Posts: 85
Joined: 2008-06-03 02:39

[ Solved ]Multi OS Grub Issues with Debian

#1 Post by remus »

Greeting Debian Community

Hardware : HP elitebook 9470m

I have been dual booting Windows 8.1 and ParrotOS 4.11.2 for a while. After installing ParrotOS I rebooted and observed no grub menu. The system loaded Win 8.1 as per usual.

After a bit of research I discovered that my particular laptop boots from
/EFI/Boot/bootx64.efi
located at /dev/sda2

The ParrotOS installer created boot files at /EFI/parrot
located at /dev/sda2

So I backed up /EFI/Boot/bootx64.efi
And replaced that file with /EFI/parrot/grubx64.efi

This gets me the ParrotOS themed grub menu with Windows and Parrot booting up fine.

So after Installing Debian Bullseye I did the following.
Made a backup of /EFI/Boot/bootx64.efi
And replaced it with And replaced that file with /EFI/debian/grubx64.efi

This gets the debian themed grub menu to work, however there is no sign of ParrotOS in the menu, just Debian and Windows 8.1

Here's a bit of stuff in the hopes it helps

Code: Select all

$ sudo fdisk -l
Disk /dev/sda: 931.51 GiB, 1000204886016 bytes, 1953525168 sectors
Disk model: CT1000MX500SSD1 
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier: 837D8A1C-8D6F-435A-B8C4-2F68138BD425

Device          Start        End    Sectors   Size Type
/dev/sda1        2048     821247     819200   400M Windows recovery environment
/dev/sda2      821248    1353727     532480   260M EFI System
/dev/sda3     1353728    1615871     262144   128M Microsoft reserved
/dev/sda4     1615872  240389405  238773534 113.9G Microsoft basic data
/dev/sda5   240389408 1674294299 1433904892 683.7G Microsoft basic data
/dev/sda6  1674295296 1779150847  104855552    50G Linux filesystem
/dev/sda7  1779150848 1884024831  104873984    50G Linux filesystem
/dev/sda8  1884024832 1916907519   32882688  15.7G Linux swap
/dev/sda9  1916907520 1953523711   36616192  17.5G Microsoft basic data

Code: Select all

$ sudo os-prober
/dev/sda2@/EFI/Microsoft/Boot/bootmgfw.efi:Windows Boot Manager:Windows:efi
Please let me know if there is any other info I can supply that would be of help.

Thanks for your comments and advice.
Last edited by remus on 2021-10-26 23:08, edited 1 time in total.

p.H
Global Moderator
Global Moderator
Posts: 3049
Joined: 2017-09-17 07:12
Has thanked: 5 times
Been thanked: 132 times

Re: Multi OS Grub Issues with Debian

#2 Post by p.H »

Where is ParrotOS installed ?

You can install the package boot-info-script and run the command bootinfoscript. It will produce a report about the boot setup and installed systems.

Note that you did not have to replace ParrotOS's GRUB with Debian's GRUB ; you could just boot ParrotOS and run update-grub to update ParrotOS GRUB menu and add Debian.

CwF
Global Moderator
Global Moderator
Posts: 2625
Joined: 2018-06-20 15:16
Location: Colorado
Has thanked: 41 times
Been thanked: 190 times

Re: Multi OS Grub Issues with Debian

#3 Post by CwF »

p.H wrote: 2021-08-25 13:49 You can install the package boot-info-script and run the command bootinfoscript
That is a nicer report, or simply run #os-prober itself and get the simple response in the terminal.

remus
Posts: 85
Joined: 2008-06-03 02:39

Re: Multi OS Grub Issues with Debian

#4 Post by remus »

Note that you did not have to replace ParrotOS's GRUB with Debian's GRUB ; you could just boot ParrotOS and run update-grub to update ParrotOS GRUB menu and add Debian
.
Sorry I forgot to mention that I did that from within ParrotOS.
If I use put /EFI/debian/grubx64.efi to /EFI/Boot/bootx64.efi then the grub menu only offers Debian and Windows. Even after loading debian and running os-prober and grub-update

running update-grub from debian outputs

Code: Select all

$  sudo update-grub
[sudo] password for user: 
Generating grub configuration file ...
Found background image: /usr/share/images/desktop-base/desktop-grub.png
Found linux image: /boot/vmlinuz-5.10.0-8-amd64
Found initrd image: /boot/initrd.img-5.10.0-8-amd64
Found Windows Boot Manager on /dev/sda2@/EFI/Microsoft/Boot/bootmgfw.efi
Adding boot menu entry for EFI firmware configuration
done
bootinfoscript output

Code: Select all

$ sudo bootinfoscript

Boot Info Script 0.78      [09 October 2019]

Identifying MBRs...
Computing Partition Table of /dev/sda...
Searching sda1 for information... 
Searching sda2 for information... 
Searching sda3 for information... 
Searching sda4 for information... 
Searching sda5 for information... 
Searching sda6 for information... 
Searching sda7 for information... 
Searching sda8 for information... 
Searching sda9 for information... 

Finished. The results are in the file "RESULTS.txt"
located in "/root/".
/root/RESULTS.txt output

Code: Select all

                 Boot Info Script 0.78      [09 October 2019]


============================= Boot Info Summary: ===============================

 => Grub2 (v1.99-2.00) is installed in the MBR of /dev/sda and looks at sector 
    874371712 of the same hard drive for core.img, but core.img can not be 
    found at this location.

sda1: __________________________________________________________________________

    File system:       ntfs
    Boot sector type:  Windows 8/2012: NTFS
    Boot sector info:  No errors found in the Boot Parameter Block.
    Operating System:  
    Boot files:        

sda2: __________________________________________________________________________

    File system:       vfat
    Boot sector type:  Windows 8/2012: FAT32
    Boot sector info:  No errors found in the Boot Parameter Block.
    Operating System:  
    Boot files:        /efi/Boot/bootx64.efi /efi/Boot.works/bootx64.efi 
                       /efi/debian/fbx64.efi /efi/debian/grubx64.efi 
                       /efi/debian/mmx64.efi /efi/debian/shimx64.efi 
                       /efi/Parrot/grubx64.efi /efi/debian/grub.cfg 
                       /efi/HP/BIOSUpdate/CryptRSA32.efi 
                       /efi/HP/BIOSUpdate/CryptRSA.efi 
                       /efi/HP/BIOSUpdate/HpBiosUpdate32.efi 
                       /efi/HP/BIOSUpdate/HpBiosUpdate.efi 
                       /efi/HP/boot/bootmgfw.efi /efi/HP/boot/bootmgr.efi 
                       /efi/HP/boot/bootx64.efi /efi/HP/boot/memtest.efi 
                       /efi/HP/SystemDiags/CryptRSA32.efi 
                       /efi/HP/SystemDiags/CryptRSA.efi 
                       /efi/HP/SystemDiags/SystemDiags32.efi 
                       /efi/HP/SystemDiags/SystemDiags.efi 
                       /efi/Microsoft/Boot/bootmgfw.efi 
                       /efi/Microsoft/Boot/bootmgr.efi 
                       /efi/Microsoft/Boot/memtest.efi

sda3: __________________________________________________________________________

    File system:       
    Boot sector type:  -
    Boot sector info: 

sda4: __________________________________________________________________________

    File system:       ntfs
    Boot sector type:  Windows 8/2012: NTFS
    Boot sector info:  No errors found in the Boot Parameter Block.
    Operating System:  
    Boot files:        /bootmgr /Windows/System32/winload.exe

sda5: __________________________________________________________________________

    File system:       ntfs
    Boot sector type:  Windows 8/2012: NTFS
    Boot sector info:  No errors found in the Boot Parameter Block.
    Operating System:  
    Boot files:        

sda6: __________________________________________________________________________

    File system:       btrfs
    Boot sector type:  -
    Boot sector info: 
    Operating System:  
    Boot files:        

sda7: __________________________________________________________________________

    File system:       ext4
    Boot sector type:  -
    Boot sector info: 
    Operating System:  Debian GNU/Linux 11 (bullseye)
    Boot files:        /boot/grub/grub.cfg /etc/fstab

sda8: __________________________________________________________________________

    File system:       swap
    Boot sector type:  -
    Boot sector info: 

sda9: __________________________________________________________________________

    File system:       ntfs
    Boot sector type:  Windows 8/2012: NTFS
    Boot sector info:  No errors found in the Boot Parameter Block.
    Operating System:  
    Boot files:        /bootmgr /boot/BCD

============================ Drive/Partition Info: =============================

Drive: sda _____________________________________________________________________
Disk /dev/sda: 931.51 GiB, 1000204886016 bytes, 1953525168 sectors
Disk model: CT1000MX500SSD1 
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes

Partition  Boot  Start Sector    End Sector  # of Sectors  Id System

/dev/sda1                   1 1,953,525,167 1,953,525,167  ee GPT


GUID Partition Table detected.

Partition  Attrs   Start Sector    End Sector  # of Sectors System
/dev/sda1      R          2,048       821,247       819,200 Windows Recovery Environment (Windows)
/dev/sda2               821,248     1,353,727       532,480 EFI System partition
/dev/sda3             1,353,728     1,615,871       262,144 Microsoft Reserved Partition (Windows)
/dev/sda4             1,615,872   240,389,405   238,773,534 Data partition (Windows/Linux)
/dev/sda5           240,389,408 1,674,294,299 1,433,904,892 Data partition (Windows/Linux)
/dev/sda6         1,674,295,296 1,779,150,847   104,855,552 Data partition (Linux)
/dev/sda7         1,779,150,848 1,884,024,831   104,873,984 Data partition (Linux)
/dev/sda8         1,884,024,832 1,916,907,519    32,882,688 Swap partition (Linux)
/dev/sda9      R  1,916,907,520 1,953,523,711    36,616,192 Data partition (Windows/Linux)

Attributes: R=Required, N=No Block IO, B=Legacy BIOS Bootable, +=More bits set

"blkid" output: ________________________________________________________________

Device           UUID                                   TYPE       LABEL

/dev/sda1        EC7E67FE7E67BFC6                       ntfs       WINRE
/dev/sda2        DC4A-157D                              vfat       
/dev/sda3                                                          
/dev/sda4        B2AEE1B1AEE16DF3                       ntfs       Windows
/dev/sda5        C010FA5F10FA5BBA                       ntfs       Storage
/dev/sda6        cf3ae080-c432-4c75-a130-dd4fe0dbd2ea   btrfs      
/dev/sda7        965c27e4-78b1-4270-bef1-aa0be2e5f290   ext4       
/dev/sda8        4e2d62fb-52f3-4338-9059-80842992b69b   swap       
/dev/sda9        4EE064CBE064BB3B                       ntfs       RECOVERY

========================= "ls -l /dev/disk/by-id" output: ======================

total 0
lrwxrwxrwx 1 root root  9 Aug 25 05:14 ata-CT1000MX500SSD1_1947E228D244 -> ../../sda
lrwxrwxrwx 1 root root 10 Aug 25 05:14 ata-CT1000MX500SSD1_1947E228D244-part1 -> ../../sda1
lrwxrwxrwx 1 root root 10 Aug 25 05:14 ata-CT1000MX500SSD1_1947E228D244-part2 -> ../../sda2
lrwxrwxrwx 1 root root 10 Aug 25 05:14 ata-CT1000MX500SSD1_1947E228D244-part3 -> ../../sda3
lrwxrwxrwx 1 root root 10 Aug 25 05:14 ata-CT1000MX500SSD1_1947E228D244-part4 -> ../../sda4
lrwxrwxrwx 1 root root 10 Aug 25 05:14 ata-CT1000MX500SSD1_1947E228D244-part5 -> ../../sda5
lrwxrwxrwx 1 root root 10 Aug 25 05:14 ata-CT1000MX500SSD1_1947E228D244-part6 -> ../../sda6
lrwxrwxrwx 1 root root 10 Aug 25 05:14 ata-CT1000MX500SSD1_1947E228D244-part7 -> ../../sda7
lrwxrwxrwx 1 root root 10 Aug 25 05:14 ata-CT1000MX500SSD1_1947E228D244-part8 -> ../../sda8
lrwxrwxrwx 1 root root 10 Aug 25 05:14 ata-CT1000MX500SSD1_1947E228D244-part9 -> ../../sda9
lrwxrwxrwx 1 root root  9 Aug 25 05:14 wwn-0x500a0751e228d244 -> ../../sda
lrwxrwxrwx 1 root root 10 Aug 25 05:14 wwn-0x500a0751e228d244-part1 -> ../../sda1
lrwxrwxrwx 1 root root 10 Aug 25 05:14 wwn-0x500a0751e228d244-part2 -> ../../sda2
lrwxrwxrwx 1 root root 10 Aug 25 05:14 wwn-0x500a0751e228d244-part3 -> ../../sda3
lrwxrwxrwx 1 root root 10 Aug 25 05:14 wwn-0x500a0751e228d244-part4 -> ../../sda4
lrwxrwxrwx 1 root root 10 Aug 25 05:14 wwn-0x500a0751e228d244-part5 -> ../../sda5
lrwxrwxrwx 1 root root 10 Aug 25 05:14 wwn-0x500a0751e228d244-part6 -> ../../sda6
lrwxrwxrwx 1 root root 10 Aug 25 05:14 wwn-0x500a0751e228d244-part7 -> ../../sda7
lrwxrwxrwx 1 root root 10 Aug 25 05:14 wwn-0x500a0751e228d244-part8 -> ../../sda8
lrwxrwxrwx 1 root root 10 Aug 25 05:14 wwn-0x500a0751e228d244-part9 -> ../../sda9

================================ Mount points: =================================

Device           Mount_Point              Type       Options

/dev/sda2        /boot/efi                vfat       (rw,relatime,fmask=0077,dmask=0077,codepage=437,iocharset=ascii,shortname=mixed,utf8,errors=remount-ro)
/dev/sda2        /mnt                     vfat       (rw,relatime,fmask=0077,dmask=0077,codepage=437,iocharset=ascii,shortname=mixed,utf8,errors=remount-ro)
/dev/sda7        /                        ext4       (rw,relatime,errors=remount-ro)


========================== sda2/efi/debian/grub.cfg: ===========================

--------------------------------------------------------------------------------
search.fs_uuid 965c27e4-78b1-4270-bef1-aa0be2e5f290 root hd0,gpt7 
set prefix=($root)'/boot/grub'
configfile $prefix/grub.cfg
--------------------------------------------------------------------------------

=========================== sda7/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_gpt
insmod ext2
set root='hd0,gpt7'
if [ x$feature_platform_search_hint = xy ]; then
  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt7 --hint-efi=hd0,gpt7 --hint-baremetal=ahci0,gpt7  965c27e4-78b1-4270-bef1-aa0be2e5f290
else
  search --no-floppy --fs-uuid --set=root 965c27e4-78b1-4270-bef1-aa0be2e5f290
fi
    font="/usr/share/grub/unicode.pf2"
fi

if loadfont $font ; then
  set gfxmode=auto
  load_video
  insmod gfxterm
  set locale_dir=$prefix/locale
  set lang=en_AU
  insmod gettext
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_gpt
insmod ext2
set root='hd0,gpt7'
if [ x$feature_platform_search_hint = xy ]; then
  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt7 --hint-efi=hd0,gpt7 --hint-baremetal=ahci0,gpt7  965c27e4-78b1-4270-bef1-aa0be2e5f290
else
  search --no-floppy --fs-uuid --set=root 965c27e4-78b1-4270-bef1-aa0be2e5f290
fi
insmod png
if background_image /usr/share/desktop-base/homeworld-theme/grub/grub-4x3.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' --class debian --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-965c27e4-78b1-4270-bef1-aa0be2e5f290' {
	load_video
	insmod gzio
	if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
	insmod part_gpt
	insmod ext2
	set root='hd0,gpt7'
	if [ x$feature_platform_search_hint = xy ]; then
	  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt7 --hint-efi=hd0,gpt7 --hint-baremetal=ahci0,gpt7  965c27e4-78b1-4270-bef1-aa0be2e5f290
	else
	  search --no-floppy --fs-uuid --set=root 965c27e4-78b1-4270-bef1-aa0be2e5f290
	fi
	echo	'Loading Linux 5.10.0-8-amd64 ...'
	linux	/boot/vmlinuz-5.10.0-8-amd64 root=UUID=965c27e4-78b1-4270-bef1-aa0be2e5f290 ro  quiet
	echo	'Loading initial ramdisk ...'
	initrd	/boot/initrd.img-5.10.0-8-amd64
}
submenu 'Advanced options for Debian GNU/Linux' $menuentry_id_option 'gnulinux-advanced-965c27e4-78b1-4270-bef1-aa0be2e5f290' {
	menuentry 'Debian GNU/Linux, with Linux 5.10.0-8-amd64' --class debian --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-5.10.0-8-amd64-advanced-965c27e4-78b1-4270-bef1-aa0be2e5f290' {
		load_video
		insmod gzio
		if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
		insmod part_gpt
		insmod ext2
		set root='hd0,gpt7'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt7 --hint-efi=hd0,gpt7 --hint-baremetal=ahci0,gpt7  965c27e4-78b1-4270-bef1-aa0be2e5f290
		else
		  search --no-floppy --fs-uuid --set=root 965c27e4-78b1-4270-bef1-aa0be2e5f290
		fi
		echo	'Loading Linux 5.10.0-8-amd64 ...'
		linux	/boot/vmlinuz-5.10.0-8-amd64 root=UUID=965c27e4-78b1-4270-bef1-aa0be2e5f290 ro  quiet
		echo	'Loading initial ramdisk ...'
		initrd	/boot/initrd.img-5.10.0-8-amd64
	}
	menuentry 'Debian GNU/Linux, with Linux 5.10.0-8-amd64 (recovery mode)' --class debian --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-5.10.0-8-amd64-recovery-965c27e4-78b1-4270-bef1-aa0be2e5f290' {
		load_video
		insmod gzio
		if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
		insmod part_gpt
		insmod ext2
		set root='hd0,gpt7'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt7 --hint-efi=hd0,gpt7 --hint-baremetal=ahci0,gpt7  965c27e4-78b1-4270-bef1-aa0be2e5f290
		else
		  search --no-floppy --fs-uuid --set=root 965c27e4-78b1-4270-bef1-aa0be2e5f290
		fi
		echo	'Loading Linux 5.10.0-8-amd64 ...'
		linux	/boot/vmlinuz-5.10.0-8-amd64 root=UUID=965c27e4-78b1-4270-bef1-aa0be2e5f290 ro single 
		echo	'Loading initial ramdisk ...'
		initrd	/boot/initrd.img-5.10.0-8-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 ###
menuentry 'Windows Boot Manager (on /dev/sda2)' --class windows --class os $menuentry_id_option 'osprober-efi-DC4A-157D' {
	insmod part_gpt
	insmod fat
	set root='hd0,gpt2'
	if [ x$feature_platform_search_hint = xy ]; then
	  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt2 --hint-efi=hd0,gpt2 --hint-baremetal=ahci0,gpt2  DC4A-157D
	else
	  search --no-floppy --fs-uuid --set=root DC4A-157D
	fi
	chainloader /EFI/Microsoft/Boot/bootmgfw.efi
}
### END /etc/grub.d/30_os-prober ###

### BEGIN /etc/grub.d/30_uefi-firmware ###
menuentry 'System setup' $menuentry_id_option 'uefi-firmware' {
	fwsetup
}
### 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 ###
--------------------------------------------------------------------------------

=============================== sda7/etc/fstab: ================================

--------------------------------------------------------------------------------
# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a
# device; this may be used with UUID= as a more robust way to name devices
# that works even if disks are added and removed. See fstab(5).
#
# systemd generates mount units based on this file, see systemd.mount(5).
# Please run 'systemctl daemon-reload' after making changes here.
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
# / was on /dev/sda7 during installation
UUID=965c27e4-78b1-4270-bef1-aa0be2e5f290 /               ext4    errors=remount-ro 0       1
# /boot/efi was on /dev/sda2 during installation
UUID=DC4A-157D  /boot/efi       vfat    umask=0077      0       1
# swap was on /dev/sda8 during installation
UUID=4e2d62fb-52f3-4338-9059-80842992b69b none            swap    sw              0       0
--------------------------------------------------------------------------------

=================== sda7: Location of files loaded by Grub: ====================

           GiB - GB             File                                 Fragment(s)

 876.992992401 = 941.664055296  boot/grub/grub.cfg                             2
 860.496810913 = 923.951415296  boot/vmlinuz-5.10.0-8-amd64                    1
 860.496810913 = 923.951415296  vmlinuz                                        1
 860.496810913 = 923.951415296  vmlinuz.old                                    1
 855.253295898 = 918.321233920  boot/initrd.img-5.10.0-8-amd64                 1
 855.253295898 = 918.321233920  initrd.img                                     1
 855.253295898 = 918.321233920  initrd.img.old                                 1

=============================== StdErr Messages: ===============================

mdadm: No arrays found in config file or automatically
Wow, this script gets a lot of details.

p.H
Global Moderator
Global Moderator
Posts: 3049
Joined: 2017-09-17 07:12
Has thanked: 5 times
Been thanked: 132 times

Re: Multi OS Grub Issues with Debian

#5 Post by p.H »

remus wrote: 2021-08-25 21:46 I forgot to mention that I did that from within ParrotOS.
What exactly did you do from within Parrot OS ?

I repeat my question : where is Parrot OS supposed to be installed ?

The only part of Parrot OS's detected by bootinfoscript is GRUB in the EFI partition sda2. Debian uses partitions sda7 (ext4) and sda8 (swap). The contents of partition sda6 (btrfs) is unknown. The other partitions are NTFS/Windows.

If Parrot OS is in sda6 (btrfs), it is not installed the usual way, or maybe it uses subvolumes which may not be parsed by os-prober and bootinfoscript.

I think you have two options :
a) Reinstall Parrot OS grubx64.efi as bootx64.efi and add Debian to Parrot OS boot menu with update-grub.
b) Or add a custom entry in Debian boot menu to chainload Parrot OS grubx64.efi. Create a file /boot/grub/custom.cfg containing

Code: Select all

menuentry 'Parrot OS' {
	insmod part_gpt
	insmod fat
	set root='hd0,gpt2'
	if [ x$feature_platform_search_hint = xy ]; then
	  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt2 --hint-efi=hd0,gpt2 --hint-baremetal=ahci0,gpt2  DC4A-157D
	else
	  search --no-floppy --fs-uuid --set=root DC4A-157D
	fi
	chainloader /EFI/Parrot/grubx64.efi
}
EDIT : Mention of Parrot OS in the the subject may attract people who know this distribution.

remus
Posts: 85
Joined: 2008-06-03 02:39

Re: Multi OS Grub Issues with Debian

#6 Post by remus »

I repeat my question : where is Parrot OS supposed to be installed ?
sorry, /dev/sda6
What exactly did you do from within Parrot OS ?
After installing Debian, Debian was not present in the boot menu, so I booted into ParrotOS and run

os-prober

and

update-grub

I rebooted and was all set to go

remus
Posts: 85
Joined: 2008-06-03 02:39

Re: Multi OS Grub Issues with Debian

#7 Post by remus »

If Parrot OS is in sda6 (btrfs), it is not installed the usual way, or maybe it uses subvolumes which may not be parsed by os-prober and bootinfoscript.
p.H
After reading that line I did a little research and discovered that there are many other's finding problems getting grub2 to work with btrfs.
I appreciate your posted solution, which is how most people try to deal with it...

For the sake of stability I have reinstalled ParrotOS using ext4 fs

Booted into Debian

ran update-grub

And everything worked fine.

Thanks for your help

User avatar
zarathustra-f90
Posts: 35
Joined: 2020-10-26 14:37
Has thanked: 19 times
Been thanked: 2 times
Contact:

Re: Multi OS Grub Issues with Debian

#8 Post by zarathustra-f90 »

Would be nice to mark the post as [SOLVED] please so it can be considered closed.

Post Reply