bonjour
j’ai trois partitions sur mon disque dur avec chacunes 3 entrées dans grub au demarrage de la machine,je voudrais en supprimer quelques unes.Comment dois-je faire?Faut-il supprimer oû décommenter ces entrées dans /etc/grub.d/30_otheros et faire un update-grub ensuite
merci de me renseigner
Fait gaffe à ne pas supprimer celle qui t’a servi à lancer le système que tu utilise
bonjour.
pourquoi vous ne supprimez pas les os que vous ne voulez plus avoir et allouer ainsi les partitions libérées pour d’autres usages,partitions de données par exemple;sinon ces partitions seront gelées et donc inutilisables.Quoi que vous fassiez faites d’abord des sauvegardes des différentes partitions.
Je reformule :
Je vais supposer que tu n’utilise qu’un seul disque (=> /dev/sda) qui est donc celui sur lequel sont ces trois partitions.
Je ne sais pas comment tu as installé ton chargeur de boot pour les trois partitions de ton disque,
mais je vais supposer que tu a installé le chargeur de boot normalement à chaque fois : sur le MBR de ton disque => en écrasant le chargeur de boot précédent.
Et je vais supposer aussi que tu veux ne garder qu’une seule de ces trois partitions.
=======
D’abord, et important, tu démarre sur la partition que tu veux garder, et tu lance la ré-installation du chargeur de boot dans le MBR de ton disque.
sudo update-grub
sudo grub-install /dev/sda
Apparemment, ça ne changera pas grand chose dans le menu, mais ce n’est qu’une apparence,
car en lançant ces deux commandes, tu viens de mettre à jour et installer le chargeur de boot qui corresponds au système que tu veux garder.
Ensuite, tu re-démarre, (toujours sur celle que tu veux garder) histoire de vérifier que la ré-installation du chargeur de boot fonctionne bien,
et c’est seulement maintenant que tu pourra sans risque supprimer les deux autres partitions, (avec gparted par exemple).
Une fois les deux autres partitions supprimées, il faudra mettre à jour le menu de grub pour qu’il ne reste plus qu’une seule entrée dans le menu de grub au prochain démarrage.
En re-démarrant ta machine, tu pourra constater qu’il ne reste bien qu’une seule entrée dans le menu de grub et qu’elle fonctionne correctement.
Une fois les deux autres partitions supprimées et le menu de grub mis-à jour, tu pourra en recréer d’autre (toujours avec gparted),
ou alors, si tu veux agrandir la seule partition restante,
il te faudra démarrer depuis un CD Live pour lancer gparted et agrandir la seule partition restante (qui sera dé-mountée, puisque tu aura démaré depuis le CD Live)
toujours bien utile de rappeler toutes ces choses pour éviter de perdre trop de temps,mais même si grub saute avec sa partition mère il y aura toujours la possibilité de le remettre avec un live cd.
Oui, il y a pleins de possibilités pour remettre un grub en place,
Mais quand on peut éviter d’avoir à remettre en place un chargeur de boot perdu,
et/ou
de perdre des fichiers personnels importants simplement par une erreur d’interprétation de l’un ou/et de l’autre,
alors, pourquoi s’en priver ?
=======
Si les suppositions que j’ai exposé dans la première partie de mon message précédent
correspondent bien au contexte et au but recherché par jdum,
alors, la méthode que j’ai proposé lui permettra :
de garder le “bon” chargeur de boot
et
d’éviter de supprimer la “bonne” partition par erreur de manipulation,
et donc
de gagner du temps.
bonjour
çi-joint un lien pour mieux comprendre ce que je veux faire
hostingpics.net/viewer.php?i … 061743.jpg
je ne veux pas supprimer de partition, je veux simplement n’avoir qu’une seule entrée par partition,car à l’heure actuelle j’en ai 3 pour sda3,3 pour sda4 et 2 pour sda2
grub est sur wheezy (sda2)
çi-joint le contenu du fichier /etc/grub.d/30_otheros de whezzy
#!/bin/sh
exec tail -n +3 $0
This entry automatically added by the Debian installer for an existing
linux installation on /dev/sda3.
menuentry “Arch Linux (on /dev/sda3)” {
set root=(hd0,gpt3)
search --no-floppy --fs-uuid --set=root 42a94277-ea5d-4e84-9245-0d8087c4ec10
linux /boot/vmlinuz-linux-lts root=UUID=42a94277-ea5d-4e84-9245-0d8087c4ec10 rw quiet
initrd /boot/initramfs-linux-lts.img
}
This entry automatically added by the Debian installer for an existing
linux installation on /dev/sda3.
menuentry “Arch Linux, with Linux linux-lts (on /dev/sda3)” {
set root=(hd0,gpt3)
search --no-floppy --fs-uuid --set=root 42a94277-ea5d-4e84-9245-0d8087c4ec10
linux /boot/vmlinuz-linux-lts root=UUID=42a94277-ea5d-4e84-9245-0d8087c4ec10 rw quiet
initrd /boot/initramfs-linux-lts.img
}
This entry automatically added by the Debian installer for an existing
linux installation on /dev/sda3.
menuentry “Arch Linux, with Linux linux-lts (fallback initramfs) (on /dev/sda3)” {
set root=(hd0,gpt3)
search --no-floppy --fs-uuid --set=root 42a94277-ea5d-4e84-9245-0d8087c4ec10
linux /boot/vmlinuz-linux-lts root=UUID=42a94277-ea5d-4e84-9245-0d8087c4ec10 rw quiet
initrd /boot/initramfs-linux-lts-fallback.img
}
This entry automatically added by the Debian installer for an existing
linux installation on /dev/sda4.
menuentry “Arch Linux (on /dev/sda4)” {
set root=(hd0,gpt4)
search --no-floppy --fs-uuid --set=root 52126031-43f6-4014-879c-49e43df3d833
linux /boot/vmlinuz-linux root=UUID=52126031-43f6-4014-879c-49e43df3d833 rw quiet
initrd /boot/initramfs-linux.img
}
This entry automatically added by the Debian installer for an existing
linux installation on /dev/sda4.
menuentry “Arch Linux, with Linux linux (on /dev/sda4)” {
set root=(hd0,gpt4)
search --no-floppy --fs-uuid --set=root 52126031-43f6-4014-879c-49e43df3d833
linux /boot/vmlinuz-linux root=UUID=52126031-43f6-4014-879c-49e43df3d833 rw quiet
initrd /boot/initramfs-linux.img
}
This entry automatically added by the Debian installer for an existing
linux installation on /dev/sda4.
menuentry “Arch Linux, with Linux linux (fallback initramfs) (on /dev/sda4)” {
set root=(hd0,gpt4)
search --no-floppy --fs-uuid --set=root 52126031-43f6-4014-879c-49e43df3d833
linux /boot/vmlinuz-linux root=UUID=52126031-43f6-4014-879c-49e43df3d833 rw quiet
initrd /boot/initramfs-linux-fallback.img
}
et le contenu de grub.cfg de wheezy
DO NOT EDIT THIS FILE
It is automatically generated by grub-mkconfig using templates
from /etc/grub.d and settings from /etc/default/grub
BEGIN /etc/grub.d/00_header
if [ -s $prefix/grubenv ]; then
load_env
fi
set default=“2"
if [ “${prev_saved_entry}” ]; then
set saved_entry=”${prev_saved_entry}"
save_env saved_entry
set prev_saved_entry=
save_env prev_saved_entry
set boot_once=true
fi
function savedefault {
if [ -z “${boot_once}” ]; then
saved_entry="${chosen}"
save_env saved_entry
fi
}
function load_video {
insmod vbe
insmod vga
insmod video_bochs
insmod video_cirrus
}
insmod part_gpt
insmod ext2
set root=’(hd0,gpt2)‘
search --no-floppy --fs-uuid --set=root dbe0f2b7-0a87-4655-9f54-262c0c6180bc
if loadfont /usr/share/grub/unicode.pf2 ; then
set gfxmode=640x480
load_video
insmod gfxterm
insmod part_gpt
insmod ext2
set root=’(hd0,gpt2)'
search --no-floppy --fs-uuid --set=root dbe0f2b7-0a87-4655-9f54-262c0c6180bc
set locale_dir=($root)/boot/grub/locale
set lang=fr_FR
insmod gettext
fi
terminal_output gfxterm
set timeout=5
END /etc/grub.d/00_header
BEGIN /etc/grub.d/05_debian_theme
insmod part_gpt
insmod ext2
set root=’(hd0,gpt2)'
search --no-floppy --fs-uuid --set=root dbe0f2b7-0a87-4655-9f54-262c0c6180bc
insmod png
if background_image /usr/share/images/tangostudio-artwork/tangostudio-grub.png; then
set color_normal=white/black
set color_highlight=black/white
else
set menu_color_normal=cyan/blue
set menu_color_highlight=white/blue
fi
END /etc/grub.d/05_debian_theme
BEGIN /etc/grub.d/10_linux
menuentry ‘Debian GNU/Linux, avec Linux 3.2.0-4-realtime-amd64’ --class debian --class gnu-linux --class gnu --class os {
load_video
insmod gzio
insmod part_gpt
insmod ext2
set root=’(hd0,gpt2)'
search --no-floppy --fs-uuid --set=root dbe0f2b7-0a87-4655-9f54-262c0c6180bc
echo 'Chargement de Linux 3.2.0-4-realtime-amd64 …'
linux /boot/vmlinuz-3.2.0-4-realtime-amd64 root=UUID=dbe0f2b7-0a87-4655-9f54-262c0c6180bc ro initrd=/install/gtk/initrd.gz quiet quiet
echo 'Chargement du disque mémoire initial …‘
initrd /boot/initrd.img-3.2.0-4-realtime-amd64
}
menuentry ‘Debian GNU/Linux, avec Linux 3.2.0-4-realtime-amd64 (mode de dépannage)’ --class debian --class gnu-linux --class gnu --class os {
load_video
insmod gzio
insmod part_gpt
insmod ext2
set root=’(hd0,gpt2)'
search --no-floppy --fs-uuid --set=root dbe0f2b7-0a87-4655-9f54-262c0c6180bc
echo 'Chargement de Linux 3.2.0-4-realtime-amd64 …'
linux /boot/vmlinuz-3.2.0-4-realtime-amd64 root=UUID=dbe0f2b7-0a87-4655-9f54-262c0c6180bc ro single initrd=/install/gtk/initrd.gz quiet
echo 'Chargement du disque mémoire initial …'
initrd /boot/initrd.img-3.2.0-4-realtime-amd64
}
END /etc/grub.d/10_linux
BEGIN /etc/grub.d/20_linux_xen
END /etc/grub.d/20_linux_xen
BEGIN /etc/grub.d/30_os-prober
END /etc/grub.d/30_os-prober
BEGIN /etc/grub.d/30_otheros
This entry automatically added by the Debian installer for an existing
linux installation on /dev/sda3.
menuentry “Arch Linux (on /dev/sda3)” {
set root=(hd0,gpt3)
search --no-floppy --fs-uuid --set=root 42a94277-ea5d-4e84-9245-0d8087c4ec10
linux /boot/vmlinuz-linux-lts root=UUID=42a94277-ea5d-4e84-9245-0d8087c4ec10 rw quiet
initrd /boot/initramfs-linux-lts.img
}
This entry automatically added by the Debian installer for an existing
linux installation on /dev/sda3.
menuentry “Arch Linux, with Linux linux-lts (on /dev/sda3)” {
set root=(hd0,gpt3)
search --no-floppy --fs-uuid --set=root 42a94277-ea5d-4e84-9245-0d8087c4ec10
linux /boot/vmlinuz-linux-lts root=UUID=42a94277-ea5d-4e84-9245-0d8087c4ec10 rw quiet
initrd /boot/initramfs-linux-lts.img
}
This entry automatically added by the Debian installer for an existing
linux installation on /dev/sda3.
menuentry “Arch Linux, with Linux linux-lts (fallback initramfs) (on /dev/sda3)” {
set root=(hd0,gpt3)
search --no-floppy --fs-uuid --set=root 42a94277-ea5d-4e84-9245-0d8087c4ec10
linux /boot/vmlinuz-linux-lts root=UUID=42a94277-ea5d-4e84-9245-0d8087c4ec10 rw quiet
initrd /boot/initramfs-linux-lts-fallback.img
}
This entry automatically added by the Debian installer for an existing
linux installation on /dev/sda4.
menuentry “Arch Linux (on /dev/sda4)” {
set root=(hd0,gpt4)
search --no-floppy --fs-uuid --set=root 52126031-43f6-4014-879c-49e43df3d833
linux /boot/vmlinuz-linux root=UUID=52126031-43f6-4014-879c-49e43df3d833 rw quiet
initrd /boot/initramfs-linux.img
}
This entry automatically added by the Debian installer for an existing
linux installation on /dev/sda4.
menuentry “Arch Linux, with Linux linux (on /dev/sda4)” {
set root=(hd0,gpt4)
search --no-floppy --fs-uuid --set=root 52126031-43f6-4014-879c-49e43df3d833
linux /boot/vmlinuz-linux root=UUID=52126031-43f6-4014-879c-49e43df3d833 rw quiet
initrd /boot/initramfs-linux.img
}
This entry automatically added by the Debian installer for an existing
linux installation on /dev/sda4.
menuentry “Arch Linux, with Linux linux (fallback initramfs) (on /dev/sda4)” {
set root=(hd0,gpt4)
search --no-floppy --fs-uuid --set=root 52126031-43f6-4014-879c-49e43df3d833
linux /boot/vmlinuz-linux root=UUID=52126031-43f6-4014-879c-49e43df3d833 rw quiet
initrd /boot/initramfs-linux-fallback.img
}
END /etc/grub.d/30_otheros
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 $prefix/custom.cfg ]; then
source $prefix/custom.cfg;
fi
END /etc/grub.d/41_custom
le grub de Archlinux est d’une version plus récente et ne laisserait apparaître que l’entrée principale de chaque distro/partition , les autres étant masquées.
sinon, si tu veux garder le grub de wheezy copie la première entrée de arch (sda3) et arch(sda4) dans 40_custom et désactive 30_osprober.
je te conseille de garder l’entrée de dépannage de wheezy.
je ne sais pas d’où vient 30_otheros. Tu l’as créé manuellement ?
ne pas oublier de faire un
[mono]grub-mkconfig -o /boot/grub/grub.cfg[/mono]
pour prendre en compte les modifications.
Je pense fortement que c’est bien ce satané [mono]30_otheros[/mono] qui est la cause de ces doublons et bégaiements dans les noms des entrées du menu : [mono]30_os-prober[/mono] est déjà là pour faire le travail proprement.
Dans un premier temps, je désactiverais ce [mono]30_otheros[/mono] (en supprimant ses attributs d’exécution) :chmod -x /etc/grub.d/30_otheros
Ensuite, je lancerais un :update-grub
Et je re-jetterai un œil au nouveau fichier [mono]/boot/grub/grub.cfg[/mono] qui devrait être plus propre.
=======
@ misaine :man update-grub
Je crois que ce [mono]30_otheros[/mono] viens de chez Ubuntu ou/et d’un theme…
J’ai un de mes SSD qui te dit bonjour : il se porte comme un charme.
update-grub est un alias qui n’existe pas sur Arch , c’est pour ça que j’ai indiqué la vraie commande:
grub-mkconfig -o /boot/grub/grub.cfg
Alors : Toutes mes plus plates excuses.
Je m’étais juste fié au titre du fil, et au post affichant le contenu du fichier /etc/grub.d/30_otheros de whezzy
[quote]### BEGIN /etc/grub.d/30_otheros ###
This entry automatically added by the Debian installer for an existing
linux installation on /dev/sda3.[/quote]
j’avais sauté cette indication !
c’est donc le debian-intaller qui créé ce fichier quand il détecte un autre linux sur le disque.
ça fait doublon avec os-prober.
bonjour
non j’ai pas crée le fichier 30_otheros,c’est lui d’ailleurs qui m’a mis le bo…el, la wheezy que j’ai c’est une tango studio que j’ai installé suite à un plantage de l’update de la version précédente et si je modifie le fichier 30_otheros et que je fait update-grub le fichier grub.cfg se trouve modifié ,mais à mon avis c’est le live-dvd tango studio qui a un probleme parce que sur la précedente install qui a planté à l’upgrade j’avais pas eu tous ces ennuis
ça c’est le contenu de 30_osprober
#! /bin/sh
set -e
grub-mkconfig helper script.
Copyright © 2006,2007,2008,2009 Free Software Foundation, Inc.
GRUB is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
GRUB is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GRUB. If not, see http://www.gnu.org/licenses/.
prefix="/usr"
exec_prefix="${prefix}“
datarootdir=”${prefix}/share"
. “${datarootdir}/grub/grub-mkconfig_lib”
if [ “x${GRUB_DISABLE_OS_PROBER}” = “xtrue” ]; then
exit 0
fi
if [ -z “which os-prober 2> /dev/null
” -o -z “which linux-boot-prober 2> /dev/null
” ] ; then
missing os-prober and/or linux-boot-prober
exit 0
fi
Try to load the efivars module, in case it’s needed for EFI support
to work below. Hide the errors in case it’s not available, there is
no need to scare people here.
modprobe efivars >/dev/null 2>&1 || true
OSPROBED="os-prober | tr ' ' '^' | paste -s -d ' '
"
if [ -z “${OSPROBED}” ] ; then
empty os-prober output, nothing doing
exit 0
fi
osx_entry() {
cat << EOF
menuentry “${LONGNAME} (${2}-bit) (on ${DEVICE})” --class osx --class darwin --class os {
EOF
save_default_entry | sed -e "s/^/\t/"
prepare_grub_to_access_device ${DEVICE} | sed -e "s/^/\t/"
cat << EOF
load_video
set do_resume=0
if [ /var/vm/sleepimage -nt10 / ]; then
if xnu_resume /var/vm/sleepimage; then
set do_resume=1
fi
fi
if [ $do_resume = 0 ]; then
xnu_uuid ${OSXUUID} uuid
if [ -f /Extra/DSDT.aml ]; then
acpi -e /Extra/DSDT.aml
fi
$1 /mach_kernel boot-uuid=${uuid} rd=*uuid
if [ /System/Library/Extensions.mkext -nt /System/Library/Extensions ]; then
xnu_mkext /System/Library/Extensions.mkext
else
xnu_kextdir /System/Library/Extensions
fi
if [ -f /Extra/Extensions.mkext ]; then
xnu_mkext /Extra/Extensions.mkext
fi
if [ -d /Extra/Extensions ]; then
xnu_kextdir /Extra/Extensions
fi
if [ -f /Extra/devprop.bin ]; then
xnu_devprop_load /Extra/devprop.bin
fi
if [ -f /Extra/splash.jpg ]; then
insmod jpeg
xnu_splash /Extra/splash.jpg
fi
if [ -f /Extra/splash.png ]; then
insmod png
xnu_splash /Extra/splash.png
fi
if [ -f /Extra/splash.tga ]; then
insmod tga
xnu_splash /Extra/splash.tga
fi
fi
}
EOF
}
for OS in ${OSPROBED} ; do
DEVICE="echo ${OS} | cut -d ':' -f 1
“
LONGNAME=”echo ${OS} | cut -d ':' -f 2 | tr '^' ' '
“
LABEL=”echo ${OS} | cut -d ':' -f 3 | tr '^' ' '
“
BOOT=”echo ${OS} | cut -d ':' -f 4
"
if [ -z “${LONGNAME}” ] ; then
LONGNAME="${LABEL}"
fi
echo “Found ${LONGNAME} on ${DEVICE}” >&2
case ${BOOT} in
chain)
cat << EOF
menuentry “${LONGNAME} (on ${DEVICE})” --class windows --class os {
EOF
save_default_entry | sed -e "s/^/\t/"
prepare_grub_to_access_device ${DEVICE} | sed -e “s/^/\t/”
case ${LONGNAME} in
Windows\ Vista*|Windows\ 7*|Windows\ Server\ 2008*)
;;
*)
cat << EOF
drivemap -s (hd0) \${root}
EOF
;;
esac
cat <<EOF
chainloader +1
}
EOF
;;
efi)
EFIPATH=${DEVICE#@}
DEVICE=${DEVICE%@}
cat << EOF
menuentry “${LONGNAME} (UEFI on ${DEVICE})” --class windows --class os {
EOF
save_default_entry | sed -e "s/^/\t/"
prepare_grub_to_access_device ${DEVICE} | sed -e "s/^/\t/“
cat <<EOF
chainloader ${EFIPATH}
}
EOF
;;
linux)
LINUXPROBED=”linux-boot-prober ${DEVICE} 2> /dev/null | tr ' ' '^' | paste -s -d ' '
"
prepare_boot_cache=
for LINUX in ${LINUXPROBED} ; do
LROOT="`echo ${LINUX} | cut -d ':' -f 1`"
LBOOT="`echo ${LINUX} | cut -d ':' -f 2`"
LLABEL="`echo ${LINUX} | cut -d ':' -f 3 | tr '^' ' '`"
LKERNEL="`echo ${LINUX} | cut -d ':' -f 4`"
LINITRD="`echo ${LINUX} | cut -d ':' -f 5`"
LPARAMS="`echo ${LINUX} | cut -d ':' -f 6- | tr '^' ' '`"
if [ -z "${LLABEL}" ] ; then
LLABEL="${LONGNAME}"
fi
if [ "${LROOT}" != "${LBOOT}" ]; then
LKERNEL="${LKERNEL#/boot}"
LINITRD="${LINITRD#/boot}"
fi
cat << EOF
menuentry “${LLABEL} (on ${DEVICE})” --class gnu-linux --class gnu --class os {
EOF
save_default_entry | sed -e "s/^/\t/“
if [ -z “${prepare_boot_cache}” ]; then
prepare_boot_cache=”$(prepare_grub_to_access_device ${LBOOT} | sed -e “s/^/\t/”)"
fi
printf ‘%s\n’ "${prepare_boot_cache}“
cat << EOF
linux ${LKERNEL} ${LPARAMS}
EOF
if [ -n “${LINITRD}” ] ; then
cat << EOF
initrd ${LINITRD}
EOF
fi
cat << EOF
}
EOF
done
;;
macosx)
OSXUUID=”grub-probe --target=fs_uuid --device ${DEVICE} 2> /dev/null
“
osx_entry xnu_kernel 32
osx_entry xnu_kernel64 64
;;
hurd)
cat << EOF
menuentry “${LONGNAME} (on ${DEVICE})” --class hurd --class gnu --class os {
EOF
save_default_entry | sed -e “s/^/\t/“
prepare_grub_to_access_device ${DEVICE} | sed -e “s/^/\t/“
grub_device=”${grub_probe} --device ${DEVICE} --target=drive
“
mach_device=”echo "${grub_device}" | sed -e 's/(\(hd.*\),msdos\(.*\))/\1s\2/'
“
grub_fs=”${grub_probe} --device ${DEVICE} --target=fs
“
case “${grub_fs}” in
*fs) hurd_fs=”${grub_fs}” ;;
*) hurd_fs=”${grub_fs}fs” ;;
esac
cat << EOF
multiboot /boot/gnumach.gz root=device:${mach_device}
module /hurd/${hurd_fs}.static ${hurd_fs} --readonly \
–multiboot-command-line=’${kernel-command-line}’ \
–host-priv-port=’${host-port}’ \
–device-master-port=’${device-port}’ \
–exec-server-task=’${exec-task}’ -T typed ‘${root}’ \
’$(task-create)’ '$(task-resume)'
module /lib/ld.so.1 exec /hurd/exec ‘$(exec-task=task-create)’
}
EOF
;;
*)
echo " ${LONGNAME} is not yet supported by grub-mkconfig.” >&2
;;
esac
done
et en plus quand je fais un update-grub ça ne me detecte pas les autres partitions, avant avec la précedente version de tango studio quand je faisais update-grub j’avais toutes mes partitions d’affichées
voila le résultat de update-grub
jean@debian:~$ sudo update-grub
[sudo] password for jean:
Generating grub.cfg …
Found background image: /usr/share/images/desktop-base/desktop-grub.png
Found linux image: /boot/vmlinuz-3.2.0-4-realtime-amd64
Found initrd image: /boot/initrd.img-3.2.0-4-realtime-amd64
done
jean@debian:~$
[quote=“misaine”]c’est donc le debian-intaller qui créé ce fichier quand il détecte un autre linux sur le disque.
ça fait doublon avec os-prober.[/quote]
Non. On voit dans grub.cfg qu’os-prober n’a rien ajouté. Peut-être parce que son utilisation est désactivée dans /etc/default/grub [Edit] ou qu’il n’est tout simplement pas installé [/EDIT].
Les seuls doublons sont dans le fichier 30_otheros lui-même.
Lance (compte root) :chmod -x /etc/grub.d/30_otheros && grub-mkconfig -o grub.cfg.sansOtheros && chmod +x /etc/grub.d/30_otheros
Et retourne nous le contenu du fichier [mono]grub.cfg.sansOtheros[/mono]
Ton [mono]/boot/grub/grub.cfg[/mono] ne sera pas modifié, et [mono]/etc/grub.d/30_otheros[/mono] se retrouvera comme il était avant la commande.
=======
S’il n’y a plus de doublons dans le fichier [mono]grub.cfg.sansOtheros[/mono],
il faudra simplement faire : chmod -x /etc/grub.d/30_otheros && update-grub
ou plus simplement :rm /etc/grub.d/30_otheros && update-grub
=======
Tu pourra supprimer [mono]grub.cfg.sansOtheros[/mono] quand tu veux.
Quel intérêt ? On sait déjà ce que ça va donner : tout ce qui était entre [mono]### BEGIN /etc/grub.d/30_otheros ###[/mono] et [mono]### END /etc/grub.d/30_otheros ###[/mono] et qui provenait directement du fichier /etc/grub.d/30_otheros va disparaître.
Franchement, vous vous compliquez la vie à tourner autour du pot.
Il est établi que les entrées de menu pour Arch proviennent de ce fichier qui a été généré par l’installateur Debian. Pour supprimer les doublons, il suffit d’éditer ce fichier et de regénérer grub.cfg avec update-grub (peu importe que ça n’existe pas dans Arch, là on est dans Debian).
oui , ce sera équivalent a ce que je proposais de mettre dans 40_custom
Non car dans ta suggestion tu disais de désactiver os-prober pour supprimer les doublons. Or nous avons vu depuis que les doublons ne viennent pas d’os-prober mais de /etc/grub.d/30_otheros. Tant qu’on ne touche pas à ce fichier, il resteront.
Le plus simple :
- édition de /etc/grub.d/30_otheros pour ajouter [mono]#[/mono] devant les doublons (avantage : réversible)
- exécution d’update-grub.
oui , confusion car dans mon esprit c’est os-prober (le programme) qui detecte les OS et pas le debian-installer.
Dans le mien aussi. De mémoire, c’est la première fois que je vois ce fichier 30_otheros créé par l’installateur.