[grub] plusieurs grub.cfg trouvé sur plusieurs partitions (semi-résolu)

Reconnaissance et configuration du matériel / kernel linux
mito77
Daikyu
Messages : 53
Inscription : ven. 04 déc. 2020, 09:35

[grub] plusieurs grub.cfg trouvé sur plusieurs partitions (semi-résolu)

Message par mito77 »

bonjour,

j'aimerais ré-organiser mon grub.cfg, car j'ai des kernel que je ne peux pas booter dessus.
De ce fait j'ai localisé trois grub.cfg sur trois partitions différentes, dont un EFI , Je ne sais donc pas sur quel grub je boot.

voici mes partitions selon gparted :
Voir le Fichier : grub-Screenshot_2021-03-16_05-34-59.png

de plus je ne peux pas editer a la main mon /etc/fstab sinon le secteur ne boot pas dessus : exemple : j'ajoute

Code : Tout sélectionner

rw,user,uid=1000,gid=1000
à cette ligne dans mon /etc/fstab (pour avoir mes droits d'utilisateurs ecriture et lecture sur cette partition monté automatiquement , mais l'ordinateur plante au démarrage :

Code : Tout sélectionner

/dev/sda7               /home/iroh/ssd1 ext4            rw,noatime,discard,data=ordered 0 2
Du coups j'ai du même commenté ces deux lignes pour pas que ça plante :

Code : Tout sélectionner

# /dev/sdb1               /media/usb    vfat            rw,relatime  0      1
# /dev/sdb                /media/usb    vfat            rw,relatime   0      1
Je ne sais pas sur quel grub.cfg , au démarrage il me dit que c'est grub 2.0.4 ;;

Mais comme il en a des .img ou .grub.cfg sur les partitions suivantes : /dev/sda5 (debian)

Code : Tout sélectionner

/media/debian/boot/grub/
, /dev/sda8 (android) puis aussi , sda2 (je ne sais pas c'est quoi cette partition ?)

Code : Tout sélectionner

/media/other/boot/grub/x86_64-efi/
;

Je ne sais pas lequel est pris au compte au démarrage de ma machine ?

edit : j'ai supprimé un paquet j'ai eu ce retour :

Code : Tout sélectionner

$ yay -R grub-imageboot
checking dependencies...

Packages (1) grub-imageboot-0.6-2

Total Removed Size:  0.00 MiB

:: Do you want to remove these packages? [Y/n] y
:: Processing package changes...
(1/1) removing grub-imageboot                                    [####################################] 100%
Generating grub configuration file ...
Found linux image: /boot/vmlinuz-linux-zen-anbox
Found initrd image: /boot/amd-ucode.img /boot/initramfs-linux-zen-anbox.img
Found fallback initrd image(s) in /boot: initramfs-linux-zen-anbox-fallback.img
Found linux image: /boot/vmlinuz-linux-zen
Found initrd image: /boot/amd-ucode.img /boot/initramfs-linux-zen.img
Found fallback initrd image(s) in /boot: initramfs-linux-zen-fallback.img
Found linux image: /boot/vmlinuz-linux-lts
Found initrd image: /boot/amd-ucode.img /boot/initramfs-linux-lts.img
Found fallback initrd image(s) in /boot: initramfs-linux-lts-fallback.img
Found linux image: /boot/vmlinuz-linux
Found initrd image: /boot/amd-ucode.img /boot/initramfs-linux.img
Found fallback initrd image(s) in /boot: initramfs-linux-fallback.img
Found Debian GNU/Linux 10 (buster) on /dev/sda5
Found Debian GNU/Linux 10 (buster) on /dev/sda5
error: syntax error.
error: Incorrect command.
error: syntax error.
Syntax error at line 379
Syntax errors are detected in generated GRUB config file.
Ensure that there are no errors in /etc/default/grub
and /etc/grub.d/* files or please file a bug report with
/boot/grub/grub.cfg.new file attached.
------------------------------------------------------------
> You may want to remove your iso images in /boot/images/
------------------------------------------------------------
[iroh@zeni ~]$
Dernière modification par mito77 le mar. 06 avr. 2021, 22:07, modifié 1 fois.
laurent85
Elfe
Messages : 951
Inscription : mar. 16 oct. 2018, 21:05

Re: [grub] plusieurs grub.cfg trouvé sur plusieurs partitions

Message par laurent85 »

Bonjour,
1er point il faut savoir dans quel mode le pc démarre, UEFI ou BIOS.
2nd point Grub au démarrage accède aux fichiers grub de la partition utilisée lors de l'installation de grub.

Donne les retours commande de :

Code : Tout sélectionner

cat /etc/fstab
ls /sys/firmware
mount | grep '^/'
blkid
grep -Ev '^(#|$)' /etc/default/grub
grep -Ev '^(#|$)' /boot/grub/grub.cfg
mito77
Daikyu
Messages : 53
Inscription : ven. 04 déc. 2020, 09:35

Re: [grub] plusieurs grub.cfg trouvé sur plusieurs partitions

Message par mito77 »

Salut je ne sais pas si toutes ces commandes vont t'aider... Mais pour le moment l'ordinateur boot bien sur les partitions demandés, je n'ai pas de problème à ce priori là, j'insiste que j'ai des noyaux comme "initramfs-linux-zen-anbox.img" ne sont pas rentrés dans le grub.cfg ! Donc je ne sais pas trop.

Code : Tout sélectionner

$ cat /etc/fstab
# Static information about the filesystems.
# See fstab(5) for details.

# <file system> <dir> <type> <options> <dump> <pass>
# UUID=0646ddef-b77b-4782-b28e-7a8462ecb9f3
/dev/sda1           	/         	ext4      	rw,relatime	0 1
/dev/sda7		/home/iroh/ssd1	ext4		rw,user,defaults,noatime,discard,data=ordered 0 2
/swapfile           	none      	swap      	defaults  	0 0
# /dev/sdb1               /media/usb  	vfat    	rw,relatime  0      1
# /dev/sdb 		  /media/usb  	vfat    	rw,relatime   0      1

Code : Tout sélectionner

ls /sys/firmware
acpi  dmi  memmap

Code : Tout sélectionner

mount | grep '^/'
/dev/sda1 on / type ext4 (rw,relatime)
/var/lib/snapd/snaps/core20_634.snap on /var/lib/snapd/snap/core20/634 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/ubports-installer_320.snap on /var/lib/snapd/snap/ubports-installer/320 type squashfs (ro,nodev,relatime,x-gdu.hide)
/dev/sda7 on /home/iroh/ssd1 type ext4 (rw,nosuid,nodev,noexec,noatime,discard,data=ordered,user)
/var/lib/snapd/snaps/snapd_10492.snap on /var/lib/snapd/snap/snapd/10492 type squashfs (ro,nodev,relatime,x-gdu.hide)

Code : Tout sélectionner

grep -Ev '^(#|$)' /etc/default/grub
GRUB_DEFAULT="0"
GRUB_TIMEOUT="5"
GRUB_DISTRIBUTOR="Arch"
GRUB_CMDLINE_LINUX_DEFAULT="loglevel=3 quiet"
GRUB_CMDLINE_LINUX=""
GRUB_PRELOAD_MODULES="part_gpt part_msdos"
GRUB_TIMEOUT_STYLE="menu"
GRUB_TERMINAL_INPUT="console"
GRUB_GFXMODE="auto"
GRUB_GFXPAYLOAD_LINUX="keep"
GRUB_DISABLE_RECOVERY="true"

Code : Tout sélectionner

$ sudo grep -Ev '^(#|$)' /boot/grub/grub.cfg 
insmod part_gpt
insmod part_msdos
if [ -s $prefix/grubenv ]; then
  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,msdos1'
if [ x$feature_platform_search_hint = xy ]; then
  search --no-floppy --fs-uuid --set=root --hint-ieee1275='ieee1275//disk@0,msdos1' --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  0646ddef-b77b-4782-b28e-7a8462ecb9f3
else
  search --no-floppy --fs-uuid --set=root 0646ddef-b77b-4782-b28e-7a8462ecb9f3
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=fr_FR
  insmod gettext
fi
terminal_input console
terminal_output gfxterm
if [ x$feature_timeout_style = xy ] ; then
  set timeout_style=menu
  set timeout=5
else
  set timeout=5
fi
menuentry 'Arch Linux' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-0646ddef-b77b-4782-b28e-7a8462ecb9f3' {
	load_video
	set gfxpayload=keep
	insmod gzio
	insmod part_msdos
	insmod ext2
	set root='hd0,msdos1'
	if [ x$feature_platform_search_hint = xy ]; then
	  search --no-floppy --fs-uuid --set=root --hint-ieee1275='ieee1275//disk@0,msdos1' --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  0646ddef-b77b-4782-b28e-7a8462ecb9f3
	else
	  search --no-floppy --fs-uuid --set=root 0646ddef-b77b-4782-b28e-7a8462ecb9f3
	fi
	echo	'Loading Linux linux-lts ...'
	linux	/boot/vmlinuz-linux-lts root=UUID=0646ddef-b77b-4782-b28e-7a8462ecb9f3 rw  loglevel=3 quiet
	echo	'Loading initial ramdisk ...'
	initrd	/boot/amd-ucode.img /boot/initramfs-linux-lts.img
}
submenu 'Advanced options for Arch Linux' $menuentry_id_option 'gnulinux-advanced-0646ddef-b77b-4782-b28e-7a8462ecb9f3' {
	menuentry 'Arch Linux, with Linux linux-lts' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-lts-advanced-0646ddef-b77b-4782-b28e-7a8462ecb9f3' {
		load_video
		set gfxpayload=keep
		insmod gzio
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-ieee1275='ieee1275//disk@0,msdos1' --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  0646ddef-b77b-4782-b28e-7a8462ecb9f3
		else
		  search --no-floppy --fs-uuid --set=root 0646ddef-b77b-4782-b28e-7a8462ecb9f3
		fi
		echo	'Loading Linux linux-lts ...'
		linux	/boot/vmlinuz-linux-lts root=UUID=0646ddef-b77b-4782-b28e-7a8462ecb9f3 rw  loglevel=3 quiet
		echo	'Loading initial ramdisk ...'
		initrd	/boot/amd-ucode.img /boot/initramfs-linux-lts.img
	}
	menuentry 'Arch Linux, with Linux linux-lts (fallback initramfs)' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-lts-fallback-0646ddef-b77b-4782-b28e-7a8462ecb9f3' {
		load_video
		set gfxpayload=keep
		insmod gzio
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-ieee1275='ieee1275//disk@0,msdos1' --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  0646ddef-b77b-4782-b28e-7a8462ecb9f3
		else
		  search --no-floppy --fs-uuid --set=root 0646ddef-b77b-4782-b28e-7a8462ecb9f3
		fi
		echo	'Loading Linux linux-lts ...'
		linux	/boot/vmlinuz-linux-lts root=UUID=0646ddef-b77b-4782-b28e-7a8462ecb9f3 rw  loglevel=3 quiet
		echo	'Loading initial ramdisk ...'
		initrd	/boot/initramfs-linux-lts-fallback.img
	}
	menuentry 'Arch Linux, with Linux linux' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-advanced-0646ddef-b77b-4782-b28e-7a8462ecb9f3' {
		load_video
		set gfxpayload=keep
		insmod gzio
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-ieee1275='ieee1275//disk@0,msdos1' --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  0646ddef-b77b-4782-b28e-7a8462ecb9f3
		else
		  search --no-floppy --fs-uuid --set=root 0646ddef-b77b-4782-b28e-7a8462ecb9f3
		fi
		echo	'Loading Linux linux ...'
		linux	/boot/vmlinuz-linux root=UUID=0646ddef-b77b-4782-b28e-7a8462ecb9f3 rw  loglevel=3 quiet
		echo	'Loading initial ramdisk ...'
		initrd	/boot/amd-ucode.img /boot/initramfs-linux.img
	}
	menuentry 'Arch Linux, with Linux linux (fallback initramfs)' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-fallback-0646ddef-b77b-4782-b28e-7a8462ecb9f3' {
		load_video
		set gfxpayload=keep
		insmod gzio
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-ieee1275='ieee1275//disk@0,msdos1' --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  0646ddef-b77b-4782-b28e-7a8462ecb9f3
		else
		  search --no-floppy --fs-uuid --set=root 0646ddef-b77b-4782-b28e-7a8462ecb9f3
		fi
		echo	'Loading Linux linux ...'
		linux	/boot/vmlinuz-linux root=UUID=0646ddef-b77b-4782-b28e-7a8462ecb9f3 rw  loglevel=3 quiet
		echo	'Loading initial ramdisk ...'
		initrd	/boot/initramfs-linux-fallback.img
	}
}
menuentry "Debian GNU/Linux 10 (buster) (on /dev/sda5)" --class debian --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-simple-59f02203-21c9-4ece-b2c7-2cfebe537eb4' {
	insmod part_msdos
	insmod ext2
	set root='hd0,msdos5'
	if [ x$feature_platform_search_hint = xy ]; then
	  search --no-floppy --fs-uuid --set=root --hint-ieee1275='ieee1275//disk@0,msdos5' --hint-bios=hd0,msdos5 --hint-efi=hd0,msdos5 --hint-baremetal=ahci0,msdos5  59f02203-21c9-4ece-b2c7-2cfebe537eb4
	else
	  search --no-floppy --fs-uuid --set=root 59f02203-21c9-4ece-b2c7-2cfebe537eb4
	fi
	linux /vmlinuz root=/dev/sda5
	initrd /initrd.img
}
submenu "Advanced options for Debian GNU/Linux 10 (buster) (on /dev/sda5)"{
menuentry "Debian GNU/Linux 10 (buster) (on /dev/sda5)" --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-/vmlinuz--59f02203-21c9-4ece-b2c7-2cfebe537eb4' {
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos5'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-ieee1275='ieee1275//disk@0,msdos5' --hint-bios=hd0,msdos5 --hint-efi=hd0,msdos5 --hint-baremetal=ahci0,msdos5  59f02203-21c9-4ece-b2c7-2cfebe537eb4
		else
		  search --no-floppy --fs-uuid --set=root 59f02203-21c9-4ece-b2c7-2cfebe537eb4
		fi
		linux /vmlinuz root=/dev/sda5
		initrd /initrd.img
}
menuentry "Debian GNU/Linux 10 (buster) (on /dev/sda5)" --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-/vmlinuz--59f02203-21c9-4ece-b2c7-2cfebe537eb4' {
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos5'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-ieee1275='ieee1275//disk@0,msdos5' --hint-bios=hd0,msdos5 --hint-efi=hd0,msdos5 --hint-baremetal=ahci0,msdos5  59f02203-21c9-4ece-b2c7-2cfebe537eb4
		else
		  search --no-floppy --fs-uuid --set=root 59f02203-21c9-4ece-b2c7-2cfebe537eb4
		fi
		linux /vmlinuz root=/dev/sda5
		initrd /initrd.img
}
menuentry "Debian GNU/Linux 10 (buster) (on /dev/sda5)" --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-/vmlinuz--59f02203-21c9-4ece-b2c7-2cfebe537eb4' {
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos5'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-ieee1275='ieee1275//disk@0,msdos5' --hint-bios=hd0,msdos5 --hint-efi=hd0,msdos5 --hint-baremetal=ahci0,msdos5  59f02203-21c9-4ece-b2c7-2cfebe537eb4
		else
		  search --no-floppy --fs-uuid --set=root 59f02203-21c9-4ece-b2c7-2cfebe537eb4
		fi
		linux /vmlinuz root=/dev/sda5
		initrd /initrd.img
}
menuentry "Debian GNU/Linux 10 (buster) (on /dev/sda5)" --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-/vmlinuz--59f02203-21c9-4ece-b2c7-2cfebe537eb4' {
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos5'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-ieee1275='ieee1275//disk@0,msdos5' --hint-bios=hd0,msdos5 --hint-efi=hd0,msdos5 --hint-baremetal=ahci0,msdos5  59f02203-21c9-4ece-b2c7-2cfebe537eb4
		else
		  search --no-floppy --fs-uuid --set=root 59f02203-21c9-4ece-b2c7-2cfebe537eb4
		fi
		linux /vmlinuz root=/dev/sda5
		initrd /initrd.img.old
}
menuentry "Debian GNU/Linux 10 (buster) (on /dev/sda5)" --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-/vmlinuz--59f02203-21c9-4ece-b2c7-2cfebe537eb4' {
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos5'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-ieee1275='ieee1275//disk@0,msdos5' --hint-bios=hd0,msdos5 --hint-efi=hd0,msdos5 --hint-baremetal=ahci0,msdos5  59f02203-21c9-4ece-b2c7-2cfebe537eb4
		else
		  search --no-floppy --fs-uuid --set=root 59f02203-21c9-4ece-b2c7-2cfebe537eb4
		fi
		linux /vmlinuz root=/dev/sda5
		initrd /initrd.img
}
menuentry "Debian GNU/Linux 10 (buster) (on /dev/sda5)" --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-/vmlinuz--59f02203-21c9-4ece-b2c7-2cfebe537eb4' {
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos5'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-ieee1275='ieee1275//disk@0,msdos5' --hint-bios=hd0,msdos5 --hint-efi=hd0,msdos5 --hint-baremetal=ahci0,msdos5  59f02203-21c9-4ece-b2c7-2cfebe537eb4
		else
		  search --no-floppy --fs-uuid --set=root 59f02203-21c9-4ece-b2c7-2cfebe537eb4
		fi
		linux /vmlinuz root=/dev/sda5
		initrd /initrd.img
}
menuentry "Debian GNU/Linux 10 (buster) (on /dev/sda5)" --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-/vmlinuz--59f02203-21c9-4ece-b2c7-2cfebe537eb4' {
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos5'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-ieee1275='ieee1275//disk@0,msdos5' --hint-bios=hd0,msdos5 --hint-efi=hd0,msdos5 --hint-baremetal=ahci0,msdos5  59f02203-21c9-4ece-b2c7-2cfebe537eb4
		else
		  search --no-floppy --fs-uuid --set=root 59f02203-21c9-4ece-b2c7-2cfebe537eb4
		fi
		linux /vmlinuz root=/dev/sda5
		initrd /initrd.img
}
menuentry "Debian GNU/Linux 10 (buster) (on /dev/sda5)" --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-/vmlinuz--59f02203-21c9-4ece-b2c7-2cfebe537eb4' {
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos5'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-ieee1275='ieee1275//disk@0,msdos5' --hint-bios=hd0,msdos5 --hint-efi=hd0,msdos5 --hint-baremetal=ahci0,msdos5  59f02203-21c9-4ece-b2c7-2cfebe537eb4
		else
		  search --no-floppy --fs-uuid --set=root 59f02203-21c9-4ece-b2c7-2cfebe537eb4
		fi
		linux /vmlinuz root=/dev/sda5
		initrd /initrd.img.old
}
menuentry "Debian GNU/Linux 10 (buster) (on /dev/sda5)" --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-/vmlinuz--59f02203-21c9-4ece-b2c7-2cfebe537eb4' {
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos5'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-ieee1275='ieee1275//disk@0,msdos5' --hint-bios=hd0,msdos5 --hint-efi=hd0,msdos5 --hint-baremetal=ahci0,msdos5  59f02203-21c9-4ece-b2c7-2cfebe537eb4
		else
		  search --no-floppy --fs-uuid --set=root 59f02203-21c9-4ece-b2c7-2cfebe537eb4
		fi
		linux /vmlinuz root=/dev/sda5
		initrd /initrd.img
}
}




menuentry "Android"{
	set root='(hd0,8)'
	linux /cm-x86-14.1-r4/kernel quiet root=/dev/ram0 androidboot.selinux=permissive acpi_sleep=s3_bios,s3_mode SRC=/cm-x86-14.1-r4 androidboot.selinux=permissive
	initrd /cm-x86-14.1-r4/initrd.img
}
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
[iroh@zeni firmware]$ 
laurent85
Elfe
Messages : 951
Inscription : mar. 16 oct. 2018, 21:05

Re: [grub] plusieurs grub.cfg trouvé sur plusieurs partitions

Message par laurent85 »

C'est une installation de grub en mode Bios. En réinstallant grub cela permet d'être sûr que grub utilise la partition sda1 (UUID=0646ddef-b77b-4782-b28e-7a8462ecb9f3) et pas une autre :

Code : Tout sélectionner

sudo grub-install --target=i386-pc --no-floppy --recheck /dev/sda
Tu peux ensuite modifier les autres partitions et re-générer le fichier de configuration de grub si nécessaire pour mettre à jour le menu :

Code : Tout sélectionner

sudo grub-mkconfig -o /boot/grub/grub.cfg
Avatar de l’utilisateur
benjarobin
Maître du Kyudo
Messages : 17180
Inscription : sam. 30 mai 2009, 15:48
Localisation : Lyon

Re: [grub] plusieurs grub.cfg trouvé sur plusieurs partitions

Message par benjarobin »

@laurent85 Je ne serais pas aussi sûr. C'est une table de partition legacy/MBR mais avec une partition ESP. Ce qui est tout à fait légal, bien que plus vraiment recommandé...
Donc pour moi c'est une installation de type EFI qu'il faut réaliser. Si j'étais à sa place je ferais ceci :
- Convertirais le tout en table GPT.
- Supprimer toute trace de Grub de partout.
- Installer intégralement Grub dans la partition ESP
Zsh | KDE | PC fixe : core i7, carte nvidia
Titre d'un sujet : [Thème] Sujet (état) / Règles du forum
laurent85
Elfe
Messages : 951
Inscription : mar. 16 oct. 2018, 21:05

Re: [grub] plusieurs grub.cfg trouvé sur plusieurs partitions

Message par laurent85 »

benjarobin a écrit : mer. 17 mars 2021, 19:14 @laurent85 Je ne serais pas aussi sûr.
C'est le retour de ls /sys/firmware qui indique que le pc a été démarré en mode Bios parce qu'il n'y a pas de répertoire efi dans /sys/firmware.
Avatar de l’utilisateur
benjarobin
Maître du Kyudo
Messages : 17180
Inscription : sam. 30 mai 2009, 15:48
Localisation : Lyon

Re: [grub] plusieurs grub.cfg trouvé sur plusieurs partitions

Message par benjarobin »

laurent85 a écrit : jeu. 18 mars 2021, 19:39C'est le retour de ls /sys/firmware ...
Hum, en effet... :oops: :chinois:
Zsh | KDE | PC fixe : core i7, carte nvidia
Titre d'un sujet : [Thème] Sujet (état) / Règles du forum
mito77
Daikyu
Messages : 53
Inscription : ven. 04 déc. 2020, 09:35

Re: [grub] plusieurs grub.cfg trouvé sur plusieurs partitions

Message par mito77 »

benjarobin a écrit : mer. 17 mars 2021, 19:14 @laurent85 Je ne serais pas aussi sûr. C'est une table de partition legacy/MBR mais avec une partition ESP. Ce qui est tout à fait légal, bien que plus vraiment recommandé...
Donc pour moi c'est une installation de type EFI qu'il faut réaliser. Si j'étais à sa place je ferais ceci :
- Convertirais le tout en table GPT.
- Supprimer toute trace de Grub de partout.
- Installer intégralement Grub dans la partition ESP
du coups je ne sais pas quoi faire car j'ai pas envie de casser mon grub, il fonctionne bien en ce moment. J'avais du installer os-prober ou un truc du genre sur AUR? Pour trouver le boot démarrage vers android os : car en effet même avec la détection automatique, il avait trouvé un boot vers cet os , mais j'ai du bidouillé à la main le fichier pour que le fichier comprenne sur quoi booter.

Du coups, je ne sais pas trop, il n'y a pas un iso qui permet de réparer grub sector ? Je ne sais plus un genre de live cd installable sur une clé USB, qui détecte tous les OS ?
laurent85
Elfe
Messages : 951
Inscription : mar. 16 oct. 2018, 21:05

Re: [grub] plusieurs grub.cfg trouvé sur plusieurs partitions

Message par laurent85 »

Dans le grub.cfg de sda1 posté plus haut il y a les choix de menu pour Arch linux et linux-lts, de multiples doublons pour Debian et un choix pour Android. Ce grub.cfg a été édité manuellement, ce n'est pas un fichier de configuration généré automatiquement.

Et maintenant que l'on sait que le pc démarre en mode bios legacy, il suffit pour blinder le truc de réinstaller grub dans le mbr de sda :

Code : Tout sélectionner

sudo grub-install --target=i386-pc --no-floppy --recheck /dev/sda
Cela permet d'être sûr que le grub.cfg de sda1 est utilisé au démarrage.
mito77
Daikyu
Messages : 53
Inscription : ven. 04 déc. 2020, 09:35

Re: [grub] plusieurs grub.cfg trouvé sur plusieurs partitions

Message par mito77 »

laurent85 a écrit : lun. 22 mars 2021, 13:34 Dans le grub.cfg de sda1 posté plus haut il y a les choix de menu pour Arch linux et linux-lts, de multiples doublons pour Debian et un choix pour Android. Ce grub.cfg a été édité manuellement, ce n'est pas un fichier de configuration généré automatiquement.

Et maintenant que l'on sait que le pc démarre en mode bios legacy, il suffit pour blinder le truc de réinstaller grub dans le mbr de sda :

Code : Tout sélectionner

sudo grub-install --target=i386-pc --no-floppy --recheck /dev/sda
Cela permet d'être sûr que le grub.cfg de sda1 est utilisé au démarrage.
et bien caporal laurent, j'ai rentré votre commande dans le terminal, rien à signaler de particulier il m'avait un message du type " i386 " que je vais copier coller :

Code : Tout sélectionner

$ sudo grub-install --target=i386-pc --no-floppy --recheck /dev/sda
[sudo] password for iroh: 
Installing for i386-pc platform.
Installation finished. No error reported.
et encore une fois bug de syntaxe sur la ligne 275 :

Code : Tout sélectionner

 $ sudo grub-mkconfig -o /boot/grub/grub.cfg
Generating grub configuration file ...
Found linux image: /boot/vmlinuz-linux-zen-anbox
Found initrd image: /boot/amd-ucode.img /boot/initramfs-linux-zen-anbox.img
Found fallback initrd image(s) in /boot: initramfs-linux-zen-anbox-fallback.img
Found linux image: /boot/vmlinuz-linux-zen
Found initrd image: /boot/amd-ucode.img /boot/initramfs-linux-zen.img
Found fallback initrd image(s) in /boot: initramfs-linux-zen-fallback.img
Found linux image: /boot/vmlinuz-linux-lts
Found initrd image: /boot/amd-ucode.img /boot/initramfs-linux-lts.img
Found fallback initrd image(s) in /boot: initramfs-linux-lts-fallback.img
Found linux image: /boot/vmlinuz-linux
Found initrd image: /boot/amd-ucode.img /boot/initramfs-linux.img
Found fallback initrd image(s) in /boot: initramfs-linux-fallback.img
error: syntax error.
error: Incorrect command.
error: syntax error.
Syntax error at line 275
Syntax errors are detected in generated GRUB config file.
Ensure that there are no errors in /etc/default/grub
and /etc/grub.d/* files or please file a bug report with
/boot/grub/grub.cfg.new file attached
laurent85
Elfe
Messages : 951
Inscription : mar. 16 oct. 2018, 21:05

Re: [grub] plusieurs grub.cfg trouvé sur plusieurs partitions

Message par laurent85 »

Quel est le retour de :

Code : Tout sélectionner

for fichier in $(find /etc/grub.d | sort); do pacman -Qo $fichier; done
pacman -Qkk grub
mito77
Daikyu
Messages : 53
Inscription : ven. 04 déc. 2020, 09:35

Re: [grub] plusieurs grub.cfg trouvé sur plusieurs partitions

Message par mito77 »

laurent85 a écrit : jeu. 25 mars 2021, 15:17 Quel est le retour de :

Code : Tout sélectionner

for fichier in $(find /etc/grub.d | sort); do pacman -Qo $fichier; done
pacman -Qkk grub
/etc/grub.d/ is owned by grub 2:2.04-10
/etc/grub.d/00_header is owned by grub 2:2.04-10
/etc/grub.d/10_linux is owned by grub 2:2.04-10
/etc/grub.d/20_linux_xen is owned by grub 2:2.04-10
/etc/grub.d/30_os-prober is owned by grub 2:2.04-10
/etc/grub.d/40_custom is owned by grub 2:2.04-10
/etc/grub.d/41_custom is owned by grub 2:2.04-10
/etc/grub.d/README is owned by grub 2:2.04-10
sudo pacman -Qkk grub
[sudo] password for iroh:
backup file: grub: /etc/default/grub (Modification time mismatch)
backup file: grub: /etc/default/grub (Size mismatch)
backup file: grub: /etc/grub.d/40_custom (Modification time mismatch)
backup file: grub: /etc/grub.d/40_custom (Size mismatch)
grub: 1092 total files, 0 altered files
laurent85
Elfe
Messages : 951
Inscription : mar. 16 oct. 2018, 21:05

Re: [grub] plusieurs grub.cfg trouvé sur plusieurs partitions

Message par laurent85 »

Maintenant qu'il y a tous les éléments la raison du problème doit se trouver dans un de ces fichiers. Re-génère le grub.cfg avec grub-mkconfig et donne les contenus de :

Code : Tout sélectionner

cat /boot/grub/grub.cfg.new
cat /etc/default/grub
cat /etc/grub.d/40_custom
mito77
Daikyu
Messages : 53
Inscription : ven. 04 déc. 2020, 09:35

Re: [grub] plusieurs grub.cfg trouvé sur plusieurs partitions

Message par mito77 »

Code : Tout sélectionner

#
# 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 ###
insmod part_gpt
insmod part_msdos
if [ -s $prefix/grubenv ]; then
  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,msdos1'
if [ x$feature_platform_search_hint = xy ]; then
  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  0646ddef-b77b-4782-b28e-7a8462ecb9f3
else
  search --no-floppy --fs-uuid --set=root 0646ddef-b77b-4782-b28e-7a8462ecb9f3
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_US
  insmod gettext
fi
terminal_input console
terminal_output gfxterm
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
### END /etc/grub.d/00_header ###

### BEGIN /etc/grub.d/06_grub-customizer_menu_color_helper ###
### END /etc/grub.d/06_grub-customizer_menu_color_helper ###

### BEGIN /etc/grub.d/10_linux ###
menuentry 'Arch Linux' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-0646ddef-b77b-4782-b28e-7a8462ecb9f3' {
	load_video
	set gfxpayload=keep
	insmod gzio
	insmod part_msdos
	insmod ext2
	set root='hd0,msdos1'
	if [ x$feature_platform_search_hint = xy ]; then
	  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  0646ddef-b77b-4782-b28e-7a8462ecb9f3
	else
	  search --no-floppy --fs-uuid --set=root 0646ddef-b77b-4782-b28e-7a8462ecb9f3
	fi
	echo	'Loading Linux linux-zen-anbox ...'
	linux	/boot/vmlinuz-linux-zen-anbox root=UUID=0646ddef-b77b-4782-b28e-7a8462ecb9f3 rw  loglevel=3 quiet
	echo	'Loading initial ramdisk ...'
	initrd	/boot/amd-ucode.img /boot/initramfs-linux-zen-anbox.img
}
submenu 'Advanced options for Arch Linux' $menuentry_id_option 'gnulinux-advanced-0646ddef-b77b-4782-b28e-7a8462ecb9f3' {
	menuentry 'Arch Linux, with Linux linux-zen-anbox' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-zen-anbox-advanced-0646ddef-b77b-4782-b28e-7a8462ecb9f3' {
		load_video
		set gfxpayload=keep
		insmod gzio
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  0646ddef-b77b-4782-b28e-7a8462ecb9f3
		else
		  search --no-floppy --fs-uuid --set=root 0646ddef-b77b-4782-b28e-7a8462ecb9f3
		fi
		echo	'Loading Linux linux-zen-anbox ...'
		linux	/boot/vmlinuz-linux-zen-anbox root=UUID=0646ddef-b77b-4782-b28e-7a8462ecb9f3 rw  loglevel=3 quiet
		echo	'Loading initial ramdisk ...'
		initrd	/boot/amd-ucode.img /boot/initramfs-linux-zen-anbox.img
	}
	menuentry 'Arch Linux, with Linux linux-zen-anbox (fallback initramfs)' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-zen-anbox-fallback-0646ddef-b77b-4782-b28e-7a8462ecb9f3' {
		load_video
		set gfxpayload=keep
		insmod gzio
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  0646ddef-b77b-4782-b28e-7a8462ecb9f3
		else
		  search --no-floppy --fs-uuid --set=root 0646ddef-b77b-4782-b28e-7a8462ecb9f3
		fi
		echo	'Loading Linux linux-zen-anbox ...'
		linux	/boot/vmlinuz-linux-zen-anbox root=UUID=0646ddef-b77b-4782-b28e-7a8462ecb9f3 rw  loglevel=3 quiet
		echo	'Loading initial ramdisk ...'
		initrd	/boot/initramfs-linux-zen-anbox-fallback.img
	}
	menuentry 'Arch Linux, with Linux linux-zen' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-zen-advanced-0646ddef-b77b-4782-b28e-7a8462ecb9f3' {
		load_video
		set gfxpayload=keep
		insmod gzio
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  0646ddef-b77b-4782-b28e-7a8462ecb9f3
		else
		  search --no-floppy --fs-uuid --set=root 0646ddef-b77b-4782-b28e-7a8462ecb9f3
		fi
		echo	'Loading Linux linux-zen ...'
		linux	/boot/vmlinuz-linux-zen root=UUID=0646ddef-b77b-4782-b28e-7a8462ecb9f3 rw  loglevel=3 quiet
		echo	'Loading initial ramdisk ...'
		initrd	/boot/amd-ucode.img /boot/initramfs-linux-zen.img
	}
	menuentry 'Arch Linux, with Linux linux-zen (fallback initramfs)' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-zen-fallback-0646ddef-b77b-4782-b28e-7a8462ecb9f3' {
		load_video
		set gfxpayload=keep
		insmod gzio
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  0646ddef-b77b-4782-b28e-7a8462ecb9f3
		else
		  search --no-floppy --fs-uuid --set=root 0646ddef-b77b-4782-b28e-7a8462ecb9f3
		fi
		echo	'Loading Linux linux-zen ...'
		linux	/boot/vmlinuz-linux-zen root=UUID=0646ddef-b77b-4782-b28e-7a8462ecb9f3 rw  loglevel=3 quiet
		echo	'Loading initial ramdisk ...'
		initrd	/boot/initramfs-linux-zen-fallback.img
	}
	menuentry 'Arch Linux, with Linux linux-lts' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-lts-advanced-0646ddef-b77b-4782-b28e-7a8462ecb9f3' {
		load_video
		set gfxpayload=keep
		insmod gzio
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  0646ddef-b77b-4782-b28e-7a8462ecb9f3
		else
		  search --no-floppy --fs-uuid --set=root 0646ddef-b77b-4782-b28e-7a8462ecb9f3
		fi
		echo	'Loading Linux linux-lts ...'
		linux	/boot/vmlinuz-linux-lts root=UUID=0646ddef-b77b-4782-b28e-7a8462ecb9f3 rw  loglevel=3 quiet
		echo	'Loading initial ramdisk ...'
		initrd	/boot/amd-ucode.img /boot/initramfs-linux-lts.img
	}
	menuentry 'Arch Linux, with Linux linux-lts (fallback initramfs)' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-lts-fallback-0646ddef-b77b-4782-b28e-7a8462ecb9f3' {
		load_video
		set gfxpayload=keep
		insmod gzio
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  0646ddef-b77b-4782-b28e-7a8462ecb9f3
		else
		  search --no-floppy --fs-uuid --set=root 0646ddef-b77b-4782-b28e-7a8462ecb9f3
		fi
		echo	'Loading Linux linux-lts ...'
		linux	/boot/vmlinuz-linux-lts root=UUID=0646ddef-b77b-4782-b28e-7a8462ecb9f3 rw  loglevel=3 quiet
		echo	'Loading initial ramdisk ...'
		initrd	/boot/initramfs-linux-lts-fallback.img
	}
	menuentry 'Arch Linux, with Linux linux' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-advanced-0646ddef-b77b-4782-b28e-7a8462ecb9f3' {
		load_video
		set gfxpayload=keep
		insmod gzio
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  0646ddef-b77b-4782-b28e-7a8462ecb9f3
		else
		  search --no-floppy --fs-uuid --set=root 0646ddef-b77b-4782-b28e-7a8462ecb9f3
		fi
		echo	'Loading Linux linux ...'
		linux	/boot/vmlinuz-linux root=UUID=0646ddef-b77b-4782-b28e-7a8462ecb9f3 rw  loglevel=3 quiet
		echo	'Loading initial ramdisk ...'
		initrd	/boot/amd-ucode.img /boot/initramfs-linux.img
	}
	menuentry 'Arch Linux, with Linux linux (fallback initramfs)' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-fallback-0646ddef-b77b-4782-b28e-7a8462ecb9f3' {
		load_video
		set gfxpayload=keep
		insmod gzio
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [ x$feature_platform_search_hint = xy ]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  0646ddef-b77b-4782-b28e-7a8462ecb9f3
		else
		  search --no-floppy --fs-uuid --set=root 0646ddef-b77b-4782-b28e-7a8462ecb9f3
		fi
		echo	'Loading Linux linux ...'
		linux	/boot/vmlinuz-linux root=UUID=0646ddef-b77b-4782-b28e-7a8462ecb9f3 rw  loglevel=3 quiet
		echo	'Loading initial ramdisk ...'
		initrd	/boot/initramfs-linux-fallback.img
	}
}

### 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_os-prober_proxy ###

### END /etc/grub.d/30_os-prober_proxy ###

### 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.
menuentry "Android"{
	set root='(hd0,8)'
	linux /cm-x86-14.1-r4/kernel quiet root=/dev/ram0 androidboot.selinux=permissive acpi_sleep=s3_bios,s3_mode SRC=/cm-x86-14.1-rc1 androidboot.selinux=permissive
	  initrd /cm-x86-14.1-r4/initrd.img
	} 
}
### 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 ###

Code : Tout sélectionner

# GRUB boot loader configuration

GRUB_DEFAULT="0"
GRUB_TIMEOUT="5"
GRUB_DISTRIBUTOR="Arch"
GRUB_CMDLINE_LINUX_DEFAULT="loglevel=3 quiet"
GRUB_CMDLINE_LINUX=""

# Preload both GPT and MBR modules so that they are not missed
GRUB_PRELOAD_MODULES="part_gpt part_msdos"

# Uncomment to enable booting from LUKS encrypted devices
#GRUB_ENABLE_CRYPTODISK="y"

# Set to 'countdown' or 'hidden' to change timeout behavior,
# press ESC key to display menu.
GRUB_TIMEOUT_STYLE="menu"

# Uncomment to use basic console
GRUB_TERMINAL_INPUT="console"

# Uncomment to disable graphical terminal
#GRUB_TERMINAL_OUTPUT="console"

# The resolution used on graphical terminal
# note that you can use only modes which your graphic card supports via VBE
# you can see them in real GRUB with the command `vbeinfo'
GRUB_GFXMODE="auto"

# Uncomment to allow the kernel use the same resolution used by grub
GRUB_GFXPAYLOAD_LINUX="keep"

# Uncomment if you want GRUB to pass to the Linux kernel the old parameter
# format "root=/dev/xxx" instead of "root=/dev/disk/by-uuid/xxx"
#GRUB_DISABLE_LINUX_UUID="true"

# Uncomment to disable generation of recovery mode menu entries
GRUB_DISABLE_RECOVERY="true"

# Uncomment and set to the desired menu colors.  Used by normal and wallpaper
# modes only.  Entries specified as foreground/background.
#GRUB_COLOR_NORMAL="light-blue/black"
#GRUB_COLOR_HIGHLIGHT="light-cyan/blue"

# Uncomment one of them for the gfx desired, a image background or a gfxtheme
#GRUB_BACKGROUND="/path/to/wallpaper"
#GRUB_THEME="/path/to/gfxtheme"

# Uncomment to get a beep at GRUB start
#GRUB_INIT_TUNE="480 440 1"

# Uncomment to make GRUB remember the last selection. This requires
# setting 'GRUB_DEFAULT=saved' above.
#GRUB_SAVEDEFAULT="true"

Code : Tout sélectionner

#!/bin/sh
exec tail -n +3 $0
# 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.
menuentry "Android"{
	set root='(hd0,8)'
	linux /cm-x86-14.1-r4/kernel quiet root=/dev/ram0 androidboot.selinux=permissive acpi_sleep=s3_bios,s3_mode SRC=/cm-x86-14.1-rc1 androidboot.selinux=permissive
	  initrd /cm-x86-14.1-r4/initrd.img
	} 
}
jean_no
yeomen
Messages : 284
Inscription : dim. 09 sept. 2007, 12:19

Re: [grub] plusieurs grub.cfg trouvé sur plusieurs partitions

Message par jean_no »

Salut

Ton erreur se situe dans le fichier /etc/grub.d/40_custom

Code : Tout sélectionner

### 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.
menuentry "Android"{
	set root='(hd0,8)'
	linux /cm-x86-14.1-r4/kernel quiet root=/dev/ram0 androidboot.selinux=permissive acpi_sleep=s3_bios,s3_mode SRC=/cm-x86-14.1-rc1 androidboot.selinux=permissive
	  initrd /cm-x86-14.1-r4/initrd.img
	} 
}
### END /etc/grub.d/40_custom ###
Tu as une accolade } en trop (Dernière ligne de ton fichier) ce qui te génère l'erreur en ligne 275 dans /boot/grub/grub.cfg

A+
mito77
Daikyu
Messages : 53
Inscription : ven. 04 déc. 2020, 09:35

Re: [grub] plusieurs grub.cfg trouvé sur plusieurs partitions

Message par mito77 »

j essaie boot-repair de installation de ubuntu 20.04

le efi semble deconnait il me sort de vieilles installations que j ai supprimer il y a plusieurs mois

voici le probleme https://paste.debian.net/1192458/

si le fichier semble hors ligne je l ai heberger ici et partager ici : https://muratom-drive.mycozy.cloud/publ ... GDUzqKgPwx

voici un resume :

Code : Tout sélectionner

BIOS is EFI-compatible, and is setup in EFI-mode for this live-session.
SecureBoot disabled.

efibootmgr -v
BootCurrent: 0000
Timeout: 0 seconds
BootOrder: 0004,3003,2001,2002,2003
Boot0000* USB Hard Drive (UEFI) - USB DISK 2.0	PciRoot(0x0)/Pci(0x10,0x0)/USB(2,0)/USB(0,0)/HD(1,MBR,0x38b1c112,0x6a4,0x1f40)RC
Boot0001* Notebook Hard Drive	BBS(HD,0ÿ,0x500)................-.T.......T.A.T........................................
Boot0002* USB Hard Drive -         USB DISK 2.0	BBS(7,,0x500).......................................................................
Boot0003* Ubuntu	HD(2,MBR,0xf9af4fcd,0xf278000,0x100800)/File(\EFI\ubuntu\grubx64.efi)RC
Boot0010* Notebook Hard Drive	BBS(HD,,0x500)................-.T.......T.A.T........................................
Boot0011* Network Adapter (IPv4 Legacy)	BBS(128,,0x0)........................&..............................................
Boot0012* Disque dur USB - WDC WD30EZRX-00DC0B0	BBS(7,,0x500).......................................................................
Boot0013* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0014* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0015* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0016* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0017* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0018* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0019* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot001A* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot001B* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot001C* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot001D* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot001E* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot001F* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0020* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0021* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0022* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0023* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0024* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0025* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0026* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0027* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0028* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0029* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot002A* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot002B* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot002C* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot002D* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot002E* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot002F* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0030* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0031* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0032* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0033* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0034* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0035* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0036* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0037* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0038* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0039* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot003A* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot003B* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot003C* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot003D* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot003E* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot003F* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0040* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0041* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0042* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0043* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0044* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0045* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0046* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0047* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0048* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0049* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot004A* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot004B* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot004C* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot004D* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot004E* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot004F* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0050* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0051* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0052* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot0053* Fedora	HD(1,GPT,3b46bc3f-8d15-4103-91ba-50cf884f22d1,0x800,0x12c000)/File(\EFI\fedora\shimx64.efi)
Boot2001* USB Drive (UEFI)	RC
Boot2002* Internal CD/DVD ROM Drive (UEFI)	RC
Boot3003* Internal Hard Disk or Solid State Disk	RC
This session has been detected as 'live' because df -Th / contains overlay

a700a594f446fa62e6291e3bf42fffd1   sda2/Android/bootia32.efi
b5dcc17643cd3fe5a5a5530d410efb6c   sda2/Android/grubx64.efi
78415fb8fb9b909f8029858113f1335f   sda2/BOOT/bkpbootx64.efi
78415fb8fb9b909f8029858113f1335f   sda2/BOOT/bootx64.efi
2895d47544fd587b26c7e29be1295c27   sda2/BOOT/fbx64.efi
8ed07d5ee4e5e1534bcf64037b7589ff   sda2/BOOT/grubx64.efi
dc3c47be2f78a78e5e57d097ae6c5c84   sda2/BOOT/mmx64.efi
1305dac4d07ae01b4b45438e18ff4c9b   sda2/debian/fbx64.efi
f6555c467b8f9b9fcc392e921273beaa   sda2/debian/grubx64.efi
6a71919b8c1f3a6d277fa10b875010dc   sda2/debian/mmx64.efi
8273287f52ffff4624121d2926ef9df4   sda2/debian/shimx64.efi
8ed07d5ee4e5e1534bcf64037b7589ff   sda2/ubuntu/grubx64.efi
dc3c47be2f78a78e5e57d097ae6c5c84   sda2/ubuntu/mmx64.efi
78415fb8fb9b909f8029858113f1335f   sda2/ubuntu/shimx64.efi
6e94c3d33194c89bd327bfaa5871e294   sda2/Android/BOOTx64.efi


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

Disks info: ____________________________________________________________________

sda	: notGPT,	no-BIOSboot,	has---ESP, 	not-usb,	not-mmc, has-os,	2048 sectors * 512 bytes

Partitions info (1/3): _________________________________________________________

sda1	: is-os,	64, pacman,	no-docgrub,	nogrub,	nogrubinstall,	grubenv-ok,	noupdategrub,	farbios
sda2	: no-os,	32, nopakmgr,	no-docgrub,	nogrub,	nogrubinstall,	no-grubenv,	noupdategrub,	farbios
sda5	: is-os,	64, apt-get,	signed grub-efi ,	grub2,	grub-install,	grubenv-ok,	update-grub,	farbios
sda7	: no-os,	32, nopakmgr,	no-docgrub,	nogrub,	nogrubinstall,	no-grubenv,	noupdategrub,	farbios
sda8	: no-os,	32, nopakmgr,	no-docgrub,	nogrub,	nogrubinstall,	no-grubenv,	noupdategrub,	farbios

Partitions info (2/3): _________________________________________________________

sda1	: isnotESP,	fstab-has-goodEFI,	no-nt,	no-winload,	no-recov-nor-hid,	no-bmgr,	notwinboot
sda2	: is---ESP,	part-has-no-fstab,	no-nt,	no-winload,	no-recov-nor-hid,	no-bmgr,	notwinboot
sda5	: isnotESP,	fstab-has-goodEFI,	no-nt,	no-winload,	no-recov-nor-hid,	no-bmgr,	notwinboot
sda7	: isnotESP,	part-has-no-fstab,	no-nt,	no-winload,	no-recov-nor-hid,	no-bmgr,	notwinboot
sda8	: isnotESP,	part-has-no-fstab,	no-nt,	no-winload,	no-recov-nor-hid,	no-bmgr,	notwinboot

Partitions info (3/3): _________________________________________________________

sda1	: not-sepboot,	with-boot,	fstab-without-boot,	not-sep-usr,	with--usr,	fstab-without-usr,	customized,	sda
sda2	: not-sepboot,	no-kernel,	part-has-no-fstab,	not-sep-usr,	no---usr,	part-has-no-fstab,	std-grub.d,	sda
sda5	: not-sepboot,	with-boot,	fstab-without-boot,	not-sep-usr,	with--usr,	fstab-without-usr,	std-grub.d,	sda
sda7	: maybesepboot,	no-boot,	part-has-no-fstab,	not-sep-usr,	no---usr,	part-has-no-fstab,	std-grub.d,	sda
sda8	: maybesepboot,	no-boot,	part-has-no-fstab,	not-sep-usr,	no---usr,	part-has-no-fstab,	std-grub.d,	sda

fdisk -l (filtered): ___________________________________________________________

Disk sda: 223.58 GiB, 240057409536 bytes, 468862128 sectors
Disk identifier: 0xf9af4fcd
      Boot     Start       End   Sectors   Size Id Type
sda1            2048 254246050 254244003 121.2G 83 Linux
sda2  *    254246912 255297535   1050624   513M ef EFI (FAT-12/16/32)
sda3       255299582 468860927 213561346 101.9G  5 Extended
sda5       284598272 371060735  86462464  41.2G 83 Linux
sda6       371062784 373061631   1998848   976M 82 Linux swap / Solaris
sda7       373063680 468860927  95797248  45.7G 83 Linux
sda8       255301632 284594175  29292544    14G 83 Linux
Partition table entries are not in disk order.
Disk sdb: 14.47 GiB, 15525216256 bytes, 30322688 sectors
Disk identifier: 0x38b1c112
      Boot   Start      End  Sectors  Size Id Type
sdb1  *          0  5619583  5619584  2.7G  0 Empty
sdb2          1700     9699     8000  3.9M ef EFI (FAT-12/16/32)
sdb3       5619712 30322687 24702976 11.8G 83 Linux

parted -lm (filtered): _________________________________________________________

sda:240GB:scsi:512:512:msdos:ATA Corsair Force LS:;
1:1049kB:130GB:130GB:ext4::;
2:130GB:131GB:538MB:fat32::boot, esp;
3:131GB:240GB:109GB:::;
8:131GB:146GB:15.0GB:ext4::;
5:146GB:190GB:44.3GB:ext4::;
6:190GB:191GB:1023MB:linux-swap(v1)::;
7:191GB:240GB:49.0GB:ext4::;
sdb:15.5GB:scsi:512:512:unknown: USB DISK 2.0:;

blkid (filtered): ______________________________________________________________

NAME   FSTYPE   UUID                                 PARTUUID                             LABEL                      PARTLABEL
sda                                                                                                                  
├─sda1 ext4     0646ddef-b77b-4782-b28e-7a8462ecb9f3 f9af4fcd-01                                                     
├─sda2 vfat     0D53-E9EB                            f9af4fcd-02                                                     
├─sda3                                               f9af4fcd-03                                                     
├─sda5 ext4     59f02203-21c9-4ece-b2c7-2cfebe537eb4 f9af4fcd-05                                                     
├─sda6 swap     f46cd6ed-30c6-4d7c-9d6c-33da2a4e0abb f9af4fcd-06                                                     
├─sda7 ext4     e13df20e-9c82-4f2d-b2a4-13c90c41d149 f9af4fcd-07                                                     
└─sda8 ext4     033e8fc7-4cfe-9454-bc59-df7329ca862d f9af4fcd-08                          Android-x86                
sdb    iso9660  2021-02-09-19-06-26-00                                                    Ubuntu 20.04.2.0 LTS amd64 
├─sdb1 iso9660  2021-02-09-19-06-26-00               38b1c112-01                          Ubuntu 20.04.2.0 LTS amd64 
├─sdb2 vfat     54C5-9C6C                            38b1c112-02                                                     
└─sdb3 ext4     f00f28cc-abd3-4a81-ab74-1f1f13a486e8 38b1c112-03                          writable                   

df (filtered): _________________________________________________________________

                                                          Avail Use% Mounted on
disk/by-label/writable[/install-logs-2021-04-06.1/crash]  10.9G   0% /var/crash
disk/by-label/writable[/install-logs-2021-04-06.1/log]    10.9G   0% /var/log
sda1                                                      57.7G  46% /mnt/boot-sav/sda1
sda2                                                     493.3M   4% /mnt/boot-sav/sda2
sda5                                                        27G  28% /mnt/boot-sav/sda5
sda7                                                      33.6G  20% /mnt/boot-sav/sda7
sda8                                                       9.3G  31% /mnt/boot-sav/sda8
sdb1                                                          0 100% /cdrom

Mount options: __________________________________________________________________

disk/by-label/writable[/install-logs-2021-04-06.1/crash] rw,relatime
disk/by-label/writable[/install-logs-2021-04-06.1/log]   rw,relatime
sda1                                                     rw,relatime
sda2                                                     rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro
sda5                                                     rw,relatime
sda7                                                     rw,relatime
sda8                                                     rw,relatime
sdb1                                                     ro,noatime,nojoliet,check=s,map=n,blocksize=2048

====================== sda1/boot/grub/grub.cfg (filtered) ======================

Arch Linux   0646ddef-b77b-4782-b28e-7a8462ecb9f3
Arch Linux, with Linux linux-lts   0646ddef-b77b-4782-b28e-7a8462ecb9f3
Arch Linux, with Linux linux-lts (fallback initramfs)   gnulinux-linux-lts-fallback-0646ddef-b77b-4782-b28e-7a8462ecb9f3
Arch Linux, with Linux linux   0646ddef-b77b-4782-b28e-7a8462ecb9f3
Arch Linux, with Linux linux (fallback initramfs)   gnulinux-linux-fallback-0646ddef-b77b-4782-b28e-7a8462ecb9f3
Debian GNU/Linux 10 (buster) (on sda5)   59f02203-21c9-4ece-b2c7-2cfebe537eb4
Debian GNU/Linux 10 (buster) (on sda5)   59f02203-21c9-4ece-b2c7-2cfebe537eb4
Debian GNU/Linux 10 (buster) (on sda5)   59f02203-21c9-4ece-b2c7-2cfebe537eb4
Debian GNU/Linux 10 (buster) (on sda5)   59f02203-21c9-4ece-b2c7-2cfebe537eb4
Debian GNU/Linux 10 (buster) (on sda5)   59f02203-21c9-4ece-b2c7-2cfebe537eb4
Debian GNU/Linux 10 (buster) (on sda5)   59f02203-21c9-4ece-b2c7-2cfebe537eb4
Debian GNU/Linux 10 (buster) (on sda5)   59f02203-21c9-4ece-b2c7-2cfebe537eb4
Debian GNU/Linux 10 (buster) (on sda5)   59f02203-21c9-4ece-b2c7-2cfebe537eb4
Debian GNU/Linux 10 (buster) (on sda5)   59f02203-21c9-4ece-b2c7-2cfebe537eb4
Debian GNU/Linux 10 (buster) (on sda5)   59f02203-21c9-4ece-b2c7-2cfebe537eb4
### END /etc/grub.d/30_os-prober_proxy ###
Android"{

========================== sda1/etc/fstab (filtered) ===========================

# <file system> <dir> <type> <options> <dump> <pass>
/dev/sda1           	/         	ext4      	rw,relatime	0 1
/dev/sda7		/home/iroh/ssd1	ext4		rw,user,defaults,noatime,discard,data=ordered 0 2
/swapfile           	none      	swap      	defaults  	0 0
UUID=0D53-E9EB  /boot/efi       vfat    defaults      0       1

================== sda1/boot/syslinux/syslinux.cfg (filtered) ==================

# Config file for Syslinux -
# /boot/syslinux/syslinux.cfg
#
# Comboot modules:
#   * menu.c32 - provides a text menu
#   * vesamenu.c32 - provides a graphical menu
#   * chain.c32 - chainload MBRs, partition boot sectors, Windows bootloaders
#   * hdt.c32 - hardware detection tool
#   * reboot.c32 - reboots the system
#
# To Use: Copy the respective files from /usr/lib/syslinux to /boot/syslinux.
# If /usr and /boot are on the same file system, symlink the files instead
# of copying them.
#
# If you do not use a menu, a 'boot:' prompt will be shown and the system
# will boot automatically after 5 seconds.
#
# Please review the wiki: https://wiki.archlinux.org/index.php/Syslinux
# The wiki provides further configuration examples
DEFAULT arch
PROMPT 0        # Set to 1 if you always want to display the boot: prompt
TIMEOUT 50
# You can create syslinux keymaps with the keytab-lilo tool
#KBDMAP de.ktl
# Menu Configuration
# Either menu.c32 or vesamenu32.c32 must be copied to /boot/syslinux
UI menu.c32
#UI vesamenu.c32
# Refer to http://syslinux.zytor.com/wiki/index.php/Doc/menu
MENU TITLE Arch Linux
#MENU BACKGROUND splash.png
MENU COLOR border       30;44   #40ffffff #a0000000 std
MENU COLOR title        1;36;44 #9033ccff #a0000000 std
MENU COLOR sel          7;37;40 #e0ffffff #20ffffff all
MENU COLOR unsel        37;44   #50ffffff #a0000000 std
MENU COLOR help         37;40   #c0ffffff #a0000000 std
MENU COLOR timeout_msg  37;40   #80ffffff #00000000 std
MENU COLOR timeout      1;37;40 #c0ffffff #00000000 std
MENU COLOR msg07        37;40   #90ffffff #a0000000 std
MENU COLOR tabmsg       31;40   #30ffffff #00000000 std
# boot sections follow
#
# TIP: If you want a 1024x768 framebuffer, add "vga=773" to your kernel line.
#
#-*
LABEL arch
    MENU LABEL Arch Linux
    LINUX ../vmlinuz-linux
    APPEND root=/dev/sda3 rw
    INITRD ../initramfs-linux.img
LABEL archfallback
    MENU LABEL Arch Linux Fallback
    LINUX ../vmlinuz-linux
    APPEND root=/dev/sda3 rw
    INITRD ../initramfs-linux-fallback.img
#LABEL windows
#        MENU LABEL Windows
#        COM32 chain.c32
#        APPEND hd0 1
LABEL hdt
        MENU LABEL HDT (Hardware Detection Tool)
        COM32 hdt.c32
LABEL reboot
        MENU LABEL Reboot
        COM32 reboot.c32
LABEL poweroff
        MENU LABEL Poweroff
        COM32 poweroff.c32

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

           GiB - GB             File                                 Fragment(s)
 111.875988007 = 120.125927424  boot/grub/grub.cfg                             1
  62.480678558 = 67.088117760   boot/grub/i386-pc/core.img                     1
  71.376926422 = 76.640391168   boot/vmlinuz-linux                             1
  71.368160248 = 76.630978560   boot/vmlinuz-linux-lts                         2
  71.391597748 = 76.656144384   boot/vmlinuz-linux-zen                         2
  70.770771027 = 75.989536768   boot/vmlinuz-linux-zen-anbox                   2
  71.452064514 = 76.721070080   boot/initramfs-linux-fallback.img              2
  62.109508514 = 66.689576960   boot/initramfs-linux.img                       1
  71.415035248 = 76.681310208   boot/initramfs-linux-lts-fallback.img          2
  62.102077484 = 66.681597952   boot/initramfs-linux-lts.img                   1
  71.484066010 = 76.755431424   boot/initramfs-linux-zen-anbox-fallback.img    1
  71.430316925 = 76.697718784   boot/initramfs-linux-zen-anbox.img             1
  71.515319824 = 76.788989952   boot/initramfs-linux-zen-fallback.img          1
  62.116977692 = 66.697596928   boot/initramfs-linux-zen.img                   1

================== sda1: Location of files loaded by Syslinux ==================

           GiB - GB             File                                 Fragment(s)
  60.237789154 = 64.679833600   boot/syslinux/syslinux.cfg                     1

===================== sda1: ls -l /etc/grub.d/ (filtered) ======================

-rwxr-xr-x 1 root root  270 Dec  7 03:10 01_grub-customizer_menu_color_helper
-rwxr-xr-x 1 root root  840 Apr  6 04:32 30_os-prober_proxy
-rwxr-xr-x 1 root root  459 Dec 16 14:17 40_custom.pacsave
drwxr-xr-x 4 root root 4096 Dec  7 03:10 backup
drwxr-xr-x 2 root root 4096 Dec  7 11:04 bin
drwxr-xr-x 2 root root 4096 Apr  6 04:32 proxifiedScripts

============= sda1/etc/grub.d/01_grub-customizer_menu_color_helper =============

#!/bin/sh
	
	if [ "x${GRUB_BACKGROUND}" != "x" ] ; then
		if [ "x${GRUB_COLOR_NORMAL}" != "x" ] ; then
		echo "set color_normal=${GRUB_COLOR_NORMAL}"
		fi
	
		if [ "x${GRUB_COLOR_HIGHLIGHT}" != "x" ] ; then
		echo "set color_highlight=${GRUB_COLOR_HIGHLIGHT}"
		fi
	fi
	

====================== sda1/etc/grub.d/40_custom.pacsave =======================

#!/bin/sh
exec tail -n +3 $0
# 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.
menuentry "Android"{
	set root='(hd0,8)'
	linux /cm-x86-14.1-r4/kernel quiet root=/dev/ram0 androidboot.selinux=permissive acpi_sleep=s3_bios,s3_mode SRC=/cm-x86-14.1-rc1 androidboot.selinux=permissive
	  initrd /cm-x86-14.1-r4/initrd.img
	} 
}

===================== sda2/efi/debian/grub.cfg (filtered) ======================

search.fs_uuid 59f02203-21c9-4ece-b2c7-2cfebe537eb4 root hd0,msdos5 
set prefix=($root)'/boot/grub'
configfile $prefix/grub.cfg

===================== sda2/efi/ubuntu/grub.cfg (filtered) ======================

search.fs_uuid c97b9039-b2da-4975-b42f-9d1871a2a00a root hd0,msdos5 
set prefix=($root)'/boot/grub'
configfile $prefix/grub.cfg

====================== sda5/boot/grub/grub.cfg (filtered) ======================

Debian GNU/Linux   59f02203-21c9-4ece-b2c7-2cfebe537eb4
Debian GNU/Linux, with Linux 4.19.0-13-amd64   59f02203-21c9-4ece-b2c7-2cfebe537eb4
Arch Linux (rolling) (on sda1)   0646ddef-b77b-4782-b28e-7a8462ecb9f3
Arch Linux (on sda1)   0646ddef-b77b-4782-b28e-7a8462ecb9f3
Arch Linux, with Linux linux-lts (on sda1)   0646ddef-b77b-4782-b28e-7a8462ecb9f3
Arch Linux, with Linux linux-lts (fallback initramfs) (on sda1)   0646ddef-b77b-4782-b28e-7a8462ecb9f3
Arch Linux, with Linux linux (on sda1)   0646ddef-b77b-4782-b28e-7a8462ecb9f3
Arch Linux, with Linux linux (fallback initramfs) (on sda1)   0646ddef-b77b-4782-b28e-7a8462ecb9f3
### END /etc/grub.d/30_os-prober ###
System setup   uefi-firmware
### END /etc/grub.d/30_uefi-firmware ###

========================== sda5/etc/fstab (filtered) ===========================

# <file system> <mount point>   <type>  <options>       <dump>  <pass>
# / was on /dev/sda8 during installation
UUID=59f02203-21c9-4ece-b2c7-2cfebe537eb4 /               ext4    errors=remount-ro 0       1
# swap was on /dev/sda9 during installation
UUID=f46cd6ed-30c6-4d7c-9d6c-33da2a4e0abb none            swap    sw              0       0
/dev/sr0        /media/cdrom0   udf,iso9660 user,noauto     0       0
UUID=0D53-E9EB  /boot/efi       vfat    defaults      0       1

======================= sda5/etc/default/grub (filtered) =======================

GRUB_DEFAULT=0
GRUB_TIMEOUT=10
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
GRUB_CMDLINE_LINUX_DEFAULT="quiet"
GRUB_CMDLINE_LINUX=""

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

           GiB - GB             File                                 Fragment(s)
 151.958503723 = 163.164200960  boot/grub/grub.cfg                             1
 136.028354645 = 146.059333632  boot/vmlinuz-4.19.0-13-amd64                   1
 136.028354645 = 146.059333632  vmlinuz                                        1
 136.028354645 = 146.059333632  vmlinuz.old                                    1
 141.744709015 = 152.197222400  boot/initrd.img-4.19.0-13-amd64                2
 141.744709015 = 152.197222400  initrd.img                                     2
 141.744709015 = 152.197222400  initrd.img.old                                 2

===================== sda5: ls -l /etc/grub.d/ (filtered) ======================

-rwxr-xr-x 1 root root 12444 Jul 30  2020 10_linux
-rwxr-xr-x 1 root root 11497 Jul 30  2020 20_linux_xen
-rwxr-xr-x 1 root root 12059 Jul 30  2020 30_os-prober
-rwxr-xr-x 1 root root  1418 Jul 30  2020 30_uefi-firmware
-rwxr-xr-x 1 root root   214 Jul 30  2020 40_custom
-rwxr-xr-x 1 root root   216 Jul 30  2020 41_custom


======================== Unknown MBRs/Boot Sectors/etc =========================

Unknown BootLoader on sdb

00000000  45 52 08 00 00 00 90 90  00 00 00 00 00 00 00 00  |ER..............|
00000010  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
00000020  33 ed fa 8e d5 bc 00 7c  fb fc 66 31 db 66 31 c9  |3......|..f1.f1.|
00000030  66 53 66 51 06 57 8e dd  8e c5 52 be 00 7c bf 00  |fSfQ.W....R..|..|
00000040  06 b9 00 01 f3 a5 ea 4b  06 00 00 52 b4 41 bb aa  |.......K...R.A..|
00000050  55 31 c9 30 f6 f9 cd 13  72 16 81 fb 55 aa 75 10  |U1.0....r...U.u.|
00000060  83 e1 01 74 0b 66 c7 06  f3 06 b4 42 eb 15 eb 02  |...t.f.....B....|
00000070  31 c9 5a 51 b4 08 cd 13  5b 0f b6 c6 40 50 83 e1  |1.ZQ....[...@P..|
00000080  3f 51 f7 e1 53 52 50 bb  00 7c b9 04 00 66 a1 b0  |?Q..SRP..|...f..|
00000090  07 e8 44 00 0f 82 80 00  66 40 80 c7 02 e2 f2 66  |..D.....f@.....f|
000000a0  81 3e 40 7c fb c0 78 70  75 09 fa bc ec 7b ea 44  |.>@|..xpu....{.D|
000000b0  7c 00 00 e8 83 00 69 73  6f 6c 69 6e 75 78 2e 62  ||.....isolinux.b|
000000c0  69 6e 20 6d 69 73 73 69  6e 67 20 6f 72 20 63 6f  |in missing or co|
000000d0  72 72 75 70 74 2e 0d 0a  66 60 66 31 d2 66 03 06  |rrupt...f`f1.f..|
000000e0  f8 7b 66 13 16 fc 7b 66  52 66 50 06 53 6a 01 6a  |.{f...{fRfP.Sj.j|
000000f0  10 89 e6 66 f7 36 e8 7b  c0 e4 06 88 e1 88 c5 92  |...f.6.{........|
00000100  f6 36 ee 7b 88 c6 08 e1  41 b8 01 02 8a 16 f2 7b  |.6.{....A......{|
00000110  cd 13 8d 64 10 66 61 c3  e8 1e 00 4f 70 65 72 61  |...d.fa....Opera|
00000120  74 69 6e 67 20 73 79 73  74 65 6d 20 6c 6f 61 64  |ting system load|
00000130  20 65 72 72 6f 72 2e 0d  0a 5e ac b4 0e 8a 3e 62  | error...^....>b|
00000140  04 b3 07 cd 10 3c 0a 75  f1 cd 18 f4 eb fd 00 00  |.....<.u........|
00000150  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
*
000001b0  80 b6 05 00 00 00 00 00  12 c1 b1 38 00 00 80 00  |...........8....|
000001c0  01 00 00 ab e0 fc 00 00  00 00 80 bf 55 00 00 fe  |............U...|
000001d0  ff ff ef fe ff ff a4 06  00 00 40 1f 00 00 00 ce  |..........@.....|
000001e0  72 5d 83 7f e0 5f 00 c0  55 00 00 f0 78 01 00 00  |r]..._..U...x...|
000001f0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 55 aa  |..............U.|
00000200


=============================== StdErr Messages ================================

File descriptor 63 (pipe:[148699]) leaked on lvs invocation. Parent PID 57300: /bin/bash

Suggested repair: ______________________________________________________________

The default repair of the Boot-Repair utility would reinstall the grub-efi-amd64-signed of
sda5,
using the following options:        sda2/boot/efi,
Additional repair would be performed: unhide-bootmenu-10s  use-standard-efi-file  restore-efi-backups  

Final advice in case of suggested repair: ______________________________________


Please do not forget to make your UEFI firmware boot on the Debian GNU/Linux 10 (buster) entry (sda2/efi/****/shim****.efi (**** will be updated in the final message) file) !
paste.ubuntu.com ko ()
paste.debian.net ko ()
mito77
Daikyu
Messages : 53
Inscription : ven. 04 déc. 2020, 09:35

Re: [grub] plusieurs grub.cfg trouvé sur plusieurs partitions (semi-résolu)

Message par mito77 »

Quelqu'un peut m'aider pour effacer ou faire un EFI normal par rapport à ce qu'il y a d'installer en ce moment sur le pc ?

Code : Tout sélectionner

$ lsblk -f
NAME   FSTYPE   FSVER LABEL       UUID                                 FSAVAIL FSUSE% MOUNTPOINT
loop0  squashfs 4.0                                                          0   100% /var/lib/snapd/snap/ubports-installer/320
loop1  squashfs 4.0                                                          0   100% /var/lib/snapd/snap/snapd/10492
loop2  squashfs 4.0                                                          0   100% /var/lib/snapd/snap/core20/634
sda                                                                                   
├─sda1 ext4     1.0               0646ddef-b77b-4782-b28e-7a8462ecb9f3   57.8G    46% /
├─sda2 vfat     FAT32             0D53-E9EB                             493.3M     4% /boot/efi
├─sda3                                                                                
├─sda5 ext4     1.0               59f02203-21c9-4ece-b2c7-2cfebe537eb4                
├─sda6 swap     1                 f46cd6ed-30c6-4d7c-9d6c-33da2a4e0abb                
├─sda7 ext4     1.0               e13df20e-9c82-4f2d-b2a4-13c90c41d149     33G    21% /home/iroh/ssd1
└─sda8 ext4     1.0   Android-x86 033e8fc7-4cfe-9454-bc59-df7329ca862d

Code : Tout sélectionner

$ efibootmgr -v
EFI variables are not supported on this system.
laurent85
Elfe
Messages : 951
Inscription : mar. 16 oct. 2018, 21:05

Re: [grub] plusieurs grub.cfg trouvé sur plusieurs partitions (semi-résolu)

Message par laurent85 »

Le pc démarre en mode bios legacy pour lancer Arch, pas en mode uefi. Le bootloader de grub est installé dans le mbr du disque. Les entrées uefi de la liste doivent dater de l'époque ou le pc était configuré en mode uefi. Ou bien il est configuré en mode hybride et il semble qu'il démarre en mode bios legacy parce que les entrées de l'uefi ne fonctionnent pas. D'ailleurs il n'y a pas d'entrée pour Arch.
mito77
Daikyu
Messages : 53
Inscription : ven. 04 déc. 2020, 09:35

Re: [grub] plusieurs grub.cfg trouvé sur plusieurs partitions (semi-résolu)

Message par mito77 »

mais il est où ce dossier UEFI ? Pour qu'il retrouve cet historique d'ancienne installation sur le disque dur via une distro Ubuntu live CD et le logiciel boot-repair ? Il y a bien un fichier qui regroupe ces éléments quelque part, ça doit bien être accessible, dans /boot/ je ne vois rien de ce genre.
laurent85
Elfe
Messages : 951
Inscription : mar. 16 oct. 2018, 21:05

Re: [grub] plusieurs grub.cfg trouvé sur plusieurs partitions (semi-résolu)

Message par laurent85 »

mito77 a écrit : mar. 13 avr. 2021, 08:14 mais il est où ce dossier UEFI ?
Les entrées sont enregistrées dans la NVRAM de la carte mère https://wiki.archlinux.fr/Processus_de_boot

Ce pc n'a pas besoin de l'uefi, désactive l'uefi dans le bios c'est tout.
Répondre