Contenu | Rechercher | Menus

Annonce

Si vous avez des soucis pour rester connecté, déconnectez-vous puis reconnectez-vous depuis ce lien en cochant la case
Me connecter automatiquement lors de mes prochaines visites.

À propos de l'équipe du forum.

#1 Le 11/11/2007, à 15:51

tubaman

Problème Grub : error 2

je viens d'installer ubuntu7.04 sur une partition windows, en formatant cette dernière à  l'aide du live CD.
mais à  chaque démarrage grub ne peut pas être chargé :

GRUG Loading 1.5


GRUB loadin, please wait...
error 2


que faire??

merci d'avance.

Hors ligne

#2 Le 11/11/2007, à 16:23

denis_aec

Re : Problème Grub : error 2

2 : Bad file or directory type
    Cette erreur est retournée si un fichier n'est pas un fichier régulier, mais quelque chose comme un lien symbolique, un répertoire ou un tube FIFO.
22 : No such partition
    Cette erreur est retournée si une partition demandée n'existe pas sur le disque sélectionné.

Erreur 2 : rare, c'est pourquoi je t'ai donné aussi la 22, plus fréquente wink

Boote en live cd, et donne nous le résultat de :
sudo fdisk -l
cat /media/xxxxxxx/boot/grub/menu.lst

(le xxxxx dépend de là où a été montée la partition / du disque dur, vu qu'on est en livecd), tu peux la trouver en tapant :
mount
et en cherchant dans le résultat

Hors ligne

#3 Le 11/11/2007, à 16:34

tubaman

Re : Problème Grub : error 2

je confirme c'est bien l'erreur 2... à la base j'ai deux DD, j'avais sur le premier windows, j'ai voulu installer sur le deuxième ubuntu, à partir de ce moment là plus rien de fonctionnait, le grub plantait, error 25.
J'en ai eu marre j'ai formater la partition windows et installer ubuntu à la place.
Il y a donc deux fois ubuntu... est-ce un problème?

ubuntu@ubuntu:~$ sudo fdisk -l

Disk /dev/sda: 250.0 GB, 250000000000 bytes
255 heads, 63 sectors/track, 30394 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1       29638   238067203+  83  Linux
/dev/sda2           29639       30394     6072570    5  Extended
/dev/sda5           29639       30394     6072538+  82  Linux swap / Solaris

Disk /dev/sdb: 250.0 GB, 250000000000 bytes
255 heads, 63 sectors/track, 30394 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1   *           1       29638   238067203+  83  Linux
/dev/sdb2           29639       30394     6072570    5  Extended
/dev/sdb5           29639       30394     6072538+  82  Linux swap / Solaris
ubuntu@ubuntu:~$

que dois-je récuperer comme information de la commande mount?
mount
proc on /proc type proc (rw)
sysfs on /sys type sysfs (rw)
tmpfs on /lib/modules/2.6.20-15-generic/volatile type tmpfs (rw,mode=0755)
tmpfs on /lib/modules/2.6.20-15-generic/volatile type tmpfs (rw,mode=0755)
/dev/bus/usb on /proc/bus/usb type none (rw,bind)
fusectl on /sys/fs/fuse/connections type fusectl (rw)
varrun on /var/run type tmpfs (rw,noexec,nosuid,nodev,mode=0755)
varlock on /var/lock type tmpfs (rw,noexec,nosuid,nodev,mode=1777)
udev on /dev type tmpfs (rw,mode=0755)
devshm on /dev/shm type tmpfs (rw)
devpts on /dev/pts type devpts (rw,gid=5,mode=620)
tmpfs on /tmp type tmpfs (rw,nosuid,nodev)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw)
/dev/sdb1 on /media/disk type ext3 (rw,noexec,nosuid,nodev)
/dev/sda1 on /media/disk-1 type ext3 (rw,noexec,nosuid,nodev)

merci smile

Hors ligne

#4 Le 11/11/2007, à 16:57

denis_aec

Re : Problème Grub : error 2

25 : Disk read error
    Cette erreur est retournée si une erreur de lecture se produit lors d'une tentative de test ou de lecture depuis un disque particulier.
mauvais signe !

Tes disques sont là  :
/dev/sdb1 on /media/disk type ext3 (rw,noexec,nosuid,nodev)
/dev/sda1 on /media/disk-1 type ext3 (rw,noexec,nosuid,nodev)

2 ubuntu ou + ne posent pas de problème ... quand tout est bien configuré !;)

sur quel disque démarre ton système ? sda, sdb ???

Que donnent :
cat /media/disk/boot/grub/menu.lst
cat /media/disk-1/boot/grub/menu.lst

(mets les résultats entre balises "code" : bouton code de la fenêtre de réponse)

Hors ligne

#5 Le 11/11/2007, à 17:18

tubaman

Re : Problème Grub : error 2

ubuntu@ubuntu:~$ cat /media/disk/boot/grub/menu.lst
# menu.lst - See: grub(8), info grub, update-grub(8)
#            grub-install(8), grub-floppy(8),
#            grub-md5-crypt, /usr/share/doc/grub
#            and /usr/share/doc/grub-doc/.

## default num
# Set the default entry to the entry number NUM. Numbering starts from 0, and
# the entry number 0 is the default if the command is not used.
#
# You can specify 'saved' instead of a number. In this case, the default entry
# is the entry saved with the command 'savedefault'.
# WARNING: If you are using dmraid do not change this entry to 'saved' or your
# array will desync and will not let you boot your system.
default         0

## timeout sec
# Set a timeout, in SEC seconds, before automatically booting the default entry
# (normally the first entry defined).
timeout         3

## hiddenmenu
# Hides the menu by default (press ESC to see the menu)
hiddenmenu

# Pretty colours
#color cyan/blue white/blue

## password ['--md5'] passwd
# If used in the first section of a menu file, disable all interactive editing
# control (menu entry editor and command-line)  and entries protected by the
# command 'lock'
# e.g. password topsecret
#      password --md5 $1$gLhU0/$aW78kHK1QfV3P2b2znUoe/
# password topsecret

#
# examples
#
# title         Windows 95/98/NT/2000
# root          (hd0,0)
# makeactive
# chainloader   +1
#
# title         Linux
# root          (hd0,1)
# kernel        /vmlinuz root=/dev/hda2 ro
#

#
# Put static boot stanzas before and/or after AUTOMAGIC KERNEL LIST

### BEGIN AUTOMAGIC KERNELS LIST
## lines between the AUTOMAGIC KERNELS LIST markers will be modified
## by the debian update-grub script except for the default options below

## DO NOT UNCOMMENT THEM, Just edit them to your needs

## ## Start Default Options ##
## default kernel options
## default kernel options for automagic boot options
## If you want special options for specific kernels use kopt_x_y_z
## where x.y.z is kernel version. Minor versions can be omitted.
## e.g. kopt=root=/dev/hda1 ro
##      kopt_2_6_8=root=/dev/hdc1 ro
##      kopt_2_6_8_2_686=root=/dev/hdc2 ro
# kopt=root=UUID=c0193a2e-5df7-4e30-bd49-4abd067671df ro

## Setup crashdump menu entries
## e.g. crashdump=1
# crashdump=0

## default grub root device
## e.g. groot=(hd0,0)
# groot=(hd1,0)

## should update-grub create alternative automagic boot options
## e.g. alternative=true
##      alternative=false
# alternative=true

## should update-grub lock alternative automagic boot options
## e.g. lockalternative=true
##      lockalternative=false
# lockalternative=false

## additional options to use with the default boot option, but not with the
## alternatives
## e.g. defoptions=vga=791 resume=/dev/hda5
# defoptions=quiet splash

## should update-grub lock old automagic boot options
## e.g. lockold=false
##      lockold=true
# lockold=false

## Xen hypervisor options to use with the default Xen boot option
# xenhopt=

## Xen Linux kernel options to use with the default Xen boot option
# xenkopt=console=tty0

## altoption boot targets option
## multiple altoptions lines are allowed
## e.g. altoptions=(extra menu suffix) extra boot options
##      altoptions=(recovery) single
# altoptions=(recovery mode) single

## controls how many kernels should be put into the menu.lst
## only counts the first occurence of a kernel, not the
## alternative kernel options
## e.g. howmany=all
##      howmany=7
# howmany=all

## should update-grub create memtest86 boot option
## e.g. memtest86=true
##      memtest86=false
# memtest86=true

## should update-grub adjust the value of the default booted system
## can be true or false
# updatedefaultentry=false

## ## End Default Options ##

title           Ubuntu, kernel 2.6.20-15-generic
root            (hd1,0)
kernel          /boot/vmlinuz-2.6.20-15-generic root=UUID=c0193a2e-5df7-4e30-bd49-4abd067671df ro quiet splash
initrd          /boot/initrd.img-2.6.20-15-generic
quiet
savedefault

title           Ubuntu, kernel 2.6.20-15-generic (recovery mode)
root            (hd1,0)
kernel          /boot/vmlinuz-2.6.20-15-generic root=UUID=c0193a2e-5df7-4e30-bd49-4abd067671df ro single
initrd          /boot/initrd.img-2.6.20-15-generic

title           Ubuntu, memtest86+
root            (hd1,0)
kernel          /boot/memtest86+.bin
quiet

### END DEBIAN AUTOMAGIC KERNELS LIST
ubuntu@ubuntu:~$ cat /media/disk-1/boot/grub/menu.lst
# menu.lst - See: grub(8), info grub, update-grub(8)
#            grub-install(8), grub-floppy(8),
#            grub-md5-crypt, /usr/share/doc/grub
#            and /usr/share/doc/grub-doc/.

## default num
# Set the default entry to the entry number NUM. Numbering starts from 0, and
# the entry number 0 is the default if the command is not used.
#
# You can specify 'saved' instead of a number. In this case, the default entry
# is the entry saved with the command 'savedefault'.
# WARNING: If you are using dmraid do not change this entry to 'saved' or your
# array will desync and will not let you boot your system.
default         0

## timeout sec
# Set a timeout, in SEC seconds, before automatically booting the default entry
# (normally the first entry defined).
timeout         10

## hiddenmenu
# Hides the menu by default (press ESC to see the menu)
#hiddenmenu

# Pretty colours
#color cyan/blue white/blue

## password ['--md5'] passwd
# If used in the first section of a menu file, disable all interactive editing
# control (menu entry editor and command-line)  and entries protected by the
# command 'lock'
# e.g. password topsecret
#      password --md5 $1$gLhU0/$aW78kHK1QfV3P2b2znUoe/
# password topsecret

#
# examples
#
# title         Windows 95/98/NT/2000
# root          (hd0,0)
# makeactive
# chainloader   +1
#
# title         Linux
# root          (hd0,1)
# kernel        /vmlinuz root=/dev/hda2 ro
#

#
# Put static boot stanzas before and/or after AUTOMAGIC KERNEL LIST

### BEGIN AUTOMAGIC KERNELS LIST
## lines between the AUTOMAGIC KERNELS LIST markers will be modified
## by the debian update-grub script except for the default options below

## DO NOT UNCOMMENT THEM, Just edit them to your needs

## ## Start Default Options ##
## default kernel options
## default kernel options for automagic boot options
## If you want special options for specific kernels use kopt_x_y_z
## where x.y.z is kernel version. Minor versions can be omitted.
## e.g. kopt=root=/dev/hda1 ro
##      kopt_2_6_8=root=/dev/hdc1 ro
##      kopt_2_6_8_2_686=root=/dev/hdc2 ro
# kopt=root=UUID=9027a7f1-9d9b-4269-8ec5-86499a14a615 ro

## Setup crashdump menu entries
## e.g. crashdump=1
# crashdump=0

## default grub root device
## e.g. groot=(hd0,0)
# groot=(hd0,0)

## should update-grub create alternative automagic boot options
## e.g. alternative=true
##      alternative=false
# alternative=true

## should update-grub lock alternative automagic boot options
## e.g. lockalternative=true
##      lockalternative=false
# lockalternative=false

## additional options to use with the default boot option, but not with the
## alternatives
## e.g. defoptions=vga=791 resume=/dev/hda5
# defoptions=quiet splash

## should update-grub lock old automagic boot options
## e.g. lockold=false
##      lockold=true
# lockold=false

## Xen hypervisor options to use with the default Xen boot option
# xenhopt=

## Xen Linux kernel options to use with the default Xen boot option
# xenkopt=console=tty0

## altoption boot targets option
## multiple altoptions lines are allowed
## e.g. altoptions=(extra menu suffix) extra boot options
##      altoptions=(recovery) single
# altoptions=(recovery mode) single

## controls how many kernels should be put into the menu.lst
## only counts the first occurence of a kernel, not the
## alternative kernel options
## e.g. howmany=all
##      howmany=7
# howmany=all

## should update-grub create memtest86 boot option
## e.g. memtest86=true
##      memtest86=false
# memtest86=true

## should update-grub adjust the value of the default booted system
## can be true or false
# updatedefaultentry=false

## ## End Default Options ##

title           Ubuntu, kernel 2.6.20-15-generic
root            (hd0,0)
kernel          /boot/vmlinuz-2.6.20-15-generic root=UUID=9027a7f1-9d9b-4269-8ec5-86499a14a615 ro quiet splash
initrd          /boot/initrd.img-2.6.20-15-generic
quiet
savedefault

title           Ubuntu, kernel 2.6.20-15-generic (recovery mode)
root            (hd0,0)
kernel          /boot/vmlinuz-2.6.20-15-generic root=UUID=9027a7f1-9d9b-4269-8ec5-86499a14a615 ro single
initrd          /boot/initrd.img-2.6.20-15-generic

title           Ubuntu, memtest86+
root            (hd0,0)
kernel          /boot/memtest86+.bin
quiet

### END DEBIAN AUTOMAGIC KERNELS LIST

# This is a divider, added to separate the menu items below from the Debian
# ones.
title           Other operating systems:
root


# This entry automatically added by the Debian installer for an existing
# linux installation on /dev/sdb1.
title           Ubuntu, kernel 2.6.20-15-generic (on /dev/sdb1)
root            (hd1,0)
kernel          /boot/vmlinuz-2.6.20-15-generic root=UUID=c0193a2e-5df7-4e30-bd49-4abd067671df ro quiet splash 
initrd          /boot/initrd.img-2.6.20-15-generic
savedefault
boot


# This entry automatically added by the Debian installer for an existing
# linux installation on /dev/sdb1.
title           Ubuntu, kernel 2.6.20-15-generic (recovery mode) (on /dev/sdb1)
root            (hd1,0)
kernel          /boot/vmlinuz-2.6.20-15-generic root=UUID=c0193a2e-5df7-4e30-bd49-4abd067671df ro single 
initrd          /boot/initrd.img-2.6.20-15-generic
savedefault
boot


# This entry automatically added by the Debian installer for an existing
# linux installation on /dev/sdb1.
title           Ubuntu, memtest86+ (on /dev/sdb1)
root            (hd1,0)
kernel          /boot/memtest86+.bin  
savedefault
boot

voilà  les résultats.

C'est à  dire que je suis un néophyte en la matière (linux), je suis bien conscient que j'ai dû faire des erreurs, mais que malheureusement je n'ai pas toutes les clefs pour les résoudres...

mon système est sensé demarer sur le disque sda.

merci!!

Dernière modification par tubaman (Le 11/11/2007, à 17:53)

Hors ligne

#6 Le 11/11/2007, à 17:39

tubaman

Re : Problème Grub : error 2

je viens de comprendre comment fonctionne les balises code... désolé!

Hors ligne

#7 Le 11/11/2007, à 17:49

denis_aec

Re : Problème Grub : error 2

modifie ton post en conséquence, ça deviendra lisible ! Sinon, c'est galère ...

Apparemment, sdb a été installée en 1er, puis sda (qui voit le permier ubuntu).
le menu.lst de disk-1 (sda1) semble donc correct ...

En live cd, essaie :
sudo grub

l'invite change en "grub>", on continue :
grub> root (hd0,0)
grub> setup (hd0)
grub> quit

puis reboote ...

cf http://doc.ubuntu-fr.org/installation/r … _apres_win à partir de "Restaurer GRUB automatiquement:
Avec votre LiveCD"

Dernière modification par denis_aec (Le 11/11/2007, à 17:51)

Hors ligne

#8 Le 11/11/2007, à 18:12

tubaman

Re : Problème Grub : error 2

je viens de rebouter, toujours la même erreur, j'ai déjà  essayé d'utiliser le le Super Grub..., je suis sensé restaurer Grub à  partir de Super Grub en boutant dessus?

Hors ligne

#9 Le 11/11/2007, à 18:19

denis_aec

Re : Problème Grub : error 2

SuperGrub ???

Tu as fait les manips grub ?

Si oui, on va essayer de booter sur le 1er ubuntu ..., en live cd  :
sudo grub

l'invite change en "grub>", on continue :
grub> root (hd1,0)
grub> setup (hd1)
grub> quit

puis reboote ...

Hors ligne

#10 Le 11/11/2007, à 18:34

tubaman

Re : Problème Grub : error 2

j'ai déjà  fait toutes ces manip... tjs la même erreur.
Quelqu'un pense que mon pc serait tatoué... sad

super grub c'est le lien que tu m'as passé!

en utilisant super grub pour restaurer grub ça ne marche pas, j'ai eu l'erreur 15 : file not found.

Hors ligne

#11 Le 11/11/2007, à 19:27

denis_aec

Re : Problème Grub : error 2

supergrub : vu, ok, tu peux essayer, je ne connais pas. Je voulais surtout que tu regarde là  o๠je t'ai indiqué.

15 : File not found
    Cette erreur est retournée si le fichier n'est pas trouvé, mais le reste est correct (comme les informations du disque et de la partition).

C'est mieux, mais il manque encore qqchose ...

Pour le tatouage, ça gêne plutà´t win ... regarde dans la doc, des fois que ! http://doc.ubuntu-fr.org/windows/pc_tatoue

Regarde http://doc.ubuntu-fr.org/grub, "En cas de soucis", puis "Avec le Live CD Ubuntu" et regarde ce que rend le find ...stage1. Puis continue en conséquence.

Si ça ne marche pas, ça sent la réinstall ...

Dernière modification par denis_aec (Le 11/11/2007, à 19:28)

Hors ligne

#12 Le 11/11/2007, à 19:57

tubaman

Re : Problème Grub : error 2

je crois que je viens de comprendre qqchose, grub est utilisé lorsqu'il y a plusieurs systèmes d'exploitation???

moi j'en ai qu'un seul ubuntu, mais il est installer une fois sur hdb et une fois sur hda...

si je comprends bien je n'ai en principe pas besoin de grub??

Hors ligne

#13 Le 11/11/2007, à 20:26

denis_aec

Re : Problème Grub : error 2

Grub (ou lilo) est toujours utilisé par ubuntu et permet aussi de gérer plusieurs os (win, 1ou + ubuntu, d'autres linux, ...).

Avce un seul OS, grub est configuré pour démarrer par défaut sur ubuntu "normal", sachant qu'on peut aussi démarrer en mode "récupération" ou en mode test de la mémoire.

Hors ligne

#14 Le 11/11/2007, à 20:44

tubaman

Re : Problème Grub : error 2

le find ...stage1 me rend

grub> find /boot/grub/stage1
find /boot/grub/stage1
 (hd0,0)
 (hd1,0)

est-ce normal?

Hors ligne

#15 Le 11/11/2007, à 22:03

denis_aec

Re : Problème Grub : error 2

Oui, puisque tu as bien 2 linux.
tu devrais pouvoir démarrer sur l'un ou l'autre des disques, c'est pour ça que je t'ai fait faire les manips sur hd0, puis hd1.

Dernier essai (option batch) :
En live cd, essaie :
sudo grub --batch

l'invite change en "grub>", on continue :
grub> root (hd0,0)
grub> setup (hd0)
grub> quit

puis reboote ...

Si ça ne marche pas, je ne sais plus ... (il reste une histoire de chroot, mais je n'y connais rien), désolé !:/

Dernière modification par denis_aec (Le 11/11/2007, à 22:03)

Hors ligne

#16 Le 12/11/2007, à 08:45

tubaman

Re : Problème Grub : error 2

je crois que je vais tout réinstaller...

Hors ligne