GRUB Error 22 sur fraiche installation

Bonjour

Jai ce curieux probleme sur une fraiche installation de Lenny. Le menu GRUB se presente bien mais ne veut demarrer ni en mode normal ni la console ??

Voici mon 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-legacy-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		5

# 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
password --md5 $1$lJHiS/$eoYYnEeUtt1pcb4Nw.TNq.

#
# 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=/dev/sdb2 ro

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

## 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=

## 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=(single-user) single
# altoptions=(single-user 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

## should update-grub add savedefault to the default options
## can be true or false
# savedefault=false

## ## End Default Options ##

title		Debian GNU/Linux, kernel 2.6.26-2-amd64
root		(hd2,1)
kernel		/boot/vmlinuz-2.6.26-2-amd64 root=/dev/sdb2 ro 
initrd		/boot/initrd.img-2.6.26-2-amd64

title		Debian GNU/Linux, kernel 2.6.26-2-amd64 (single-user mode)
root		(hd2,1)
kernel		/boot/vmlinuz-2.6.26-2-amd64 root=/dev/sdb2 ro single
initrd		/boot/initrd.img-2.6.26-2-amd64

### END DEBIAN AUTOMAGIC KERNELS LIST

et le resultat de fdisk -l :

[code]Disk /dev/sda: 400.0 GB, 400088457216 bytes
255 heads, 63 sectors/track, 48641 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xfa5c7e19

Device Boot Start End Blocks Id System
/dev/sda1 * 1 48641 390708801 f W95 Ext’d (LBA)
/dev/sda5 1 23498 188747622 83 Linux
/dev/sda6 23499 48640 201953083+ 83 Linux
/dev/sda7 48641 48641 8001 83 Linux

Disk /dev/sdb: 250.0 GB, 250059350016 bytes
255 heads, 63 sectors/track, 30401 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xf96ef96e

Device Boot Start End Blocks Id System
/dev/sdb1 1 973 7815591 82 Linux swap / Solaris
/dev/sdb2 * 974 3405 19535040 83 Linux
/dev/sdb3 3406 30401 216845370 5 Extended
/dev/sdb5 3406 9484 48829536 83 Linux
/dev/sdb6 9485 30401 168015771 83 Linux

Disk /dev/sdc: 160.0 GB, 160041885696 bytes
16 heads, 63 sectors/track, 310101 cylinders
Units = cylinders of 1008 * 512 = 516096 bytes
Disk identifier: 0x79ad1202

Device Boot Start End Blocks Id System
/dev/sdc1 1 310097 156288856+ 83 Linux

Disk /dev/sdd: 1000.2 GB, 1000204886016 bytes
255 heads, 63 sectors/track, 121601 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xe8900690

Device Boot Start End Blocks Id System
/dev/sdd1 1 121601 976760001 83 Linux

Disk /dev/sde: 2063 MB, 2063597568 bytes
16 heads, 32 sectors/track, 7872 cylinders
Units = cylinders of 512 * 512 = 262144 bytes
Disk identifier: 0x00061f72

Device Boot Start End Blocks Id System
/dev/sde1 * 1 7872 2015216 b W95 FAT32
[/code]

Avec :

sda1 - vieille install de wind95 non uilisee
sda5 - documents
sda6 - music
sda7 - crypt

sdb1 - swap
sdb2 - root debian
sdb5 - databases
sdb6 - home

sdc1 - videos

Le reste, c’est du stockage externe usb.

A priori, tout a l’air normal non ? D’ou peut venir l’erreur ? :confused:

Merci

Salut,

Tu cherches à démarrer sur sdc :slightly_smiling:

grub le voit bien en hd2 a l’install :

grub-install /dev/sdb2 . . (hd2) /dev/sdb2

:unamused:

Salut,

[quote]title Debian GNU/Linux, kernel 2.6.26-2-amd64
root (hd2,1)
kernel /boot/vmlinuz-2.6.26-2-amd64 root=/dev/sdb2 ro
initrd /boot/initrd.img-2.6.26-2-amd64[/quote]

hd2 = sdc

hd1 = sdb

Re,

Oui mais pour grub A=0 :slightly_smiling:

Bon… retour du boulet… :smt003

D’abord merci pour vos reponses !

Je reinstalle la debian en passant la racine en sdb1… : elle demarre pas.

Ok je prends le livecd ubuntu, reinstalle grub :

[code]mount /dev/sdb1 /mnt
mount /dev/sdb5 /mnt/usr
mount -o bind /dev /mnt/dev
mount -t proc none /mnt/proc
mount -t sysfs none /mnt/sys

chroot /mnt /bin/bash
grub-install /dev/sdb1[/code]

Resultat :

[code]Searching for GRUB installation directory … found: /boot/grub
Installation finished. No error reported.
This is the contents of the device map /boot/grub/device.map.
Check if this is correct or not. If any of the lines is incorrect,
fix it and re-run the script `grub-install’.

(hd0) /dev/hdb
(hd1) /dev/sda
(hd2) /dev/sdb[/code]

suivi d’un :

Searching for GRUB installation directory ... found: /boot/grub Searching for default file ... found: /boot/grub/default Testing for an existing GRUB menu.lst file ... found: /boot/grub/menu.lst Searching for splash image ... none found, skipping ... Found kernel: /boot/vmlinuz-2.6.26-2-amd64 Updating /boot/grub/menu.lst ... done

Et donc maintenant, menu.lst :

[code]# kopt=root=/dev/sdb1 ro

default grub root device

e.g. groot=(hd0,0)

groot=(hd1,0)

.
.
.
title Debian GNU/Linux, kernel 2.6.26-2-amd64
root (hd1,0)
kernel /boot/vmlinuz-2.6.26-2-amd64 root=/dev/sdb1 ro
initrd /boot/initrd.img-2.6.26-2-amd64

title Debian GNU/Linux, kernel 2.6.26-2-amd64 (single-user mode)
root (hd1,0)
kernel /boot/vmlinuz-2.6.26-2-amd64 root=/dev/sdb1 ro single
initrd /boot/initrd.img-2.6.26-2-amd64
[/code]

pour le principal, avec fdisk -l :

[code]Disk /dev/sda: 400.1 GB, 400088457216 bytes
255 heads, 63 sectors/track, 48641 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xfa5c7e19

Device Boot Start End Blocks Id System
/dev/sda1 * 1 48641 390708801 f W95 Ext’d (LBA)
/dev/sda5 1 23498 188747622 83 Linux
/dev/sda6 23499 48640 201953083+ 83 Linux
/dev/sda7 48641 48641 8001 83 Linux

Disk /dev/sdb: 250.1 GB, 250059350016 bytes
255 heads, 63 sectors/track, 30401 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xf96ef96e

Device Boot Start End Blocks Id System
/dev/sdb1 * 1 2432 19535008+ 83 Linux
/dev/sdb2 2433 30401 224660992+ 5 Extended
/dev/sdb5 2433 4864 19535008+ 83 Linux
/dev/sdb6 4865 7296 19535008+ 83 Linux
/dev/sdb7 7297 8755 11719386 82 Linux swap / Solaris
/dev/sdb8 8756 9120 2931831 83 Linux
/dev/sdb9 9121 30401 170939601 83 Linux

Disk /dev/sdc: 160.0 GB, 160041885696 bytes
16 heads, 63 sectors/track, 310101 cylinders
Units = cylinders of 1008 * 512 = 516096 bytes
Disk identifier: 0x79ad1202

Device Boot Start End Blocks Id System
/dev/sdc1 1 310097 156288856+ 83 Linux

Disk /dev/sdd: 1000.2 GB, 1000204886016 bytes
255 heads, 63 sectors/track, 121601 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xe8900690

Device Boot Start End Blocks Id System
/dev/sdd1 1 121601 976760001 83 Linux

Disk /dev/sde: 2063 MB, 2063597568 bytes
16 heads, 32 sectors/track, 7872 cylinders
Units = cylinders of 512 * 512 = 262144 bytes
Disk identifier: 0x00061f72

Device Boot Start End Blocks Id System
/dev/sde1 * 1 7872 2015216 b W95 FAT32
[/code]

Donc tout devrait aller… Resultat :

ou :

[quote]17 : Cannot mount selected partition
This error is returned if the partition requested exists, but the filesystem type cannot be recognized by GRUB. [/quote]

:confused:

Et d’ailleurs maintenant : plus de menu, ca plante avant.

salut

sda1 - vieille install de wind95 non uilisee
sda5 - documents
sda6 - music
sda7 - crypt

sdb1 - swap
sdb2 - root debian
sdb5 - databases
sdb6 - home

sdc1 - videos

Le reste, c’est du stockage externe usb.

ta partition linux, c’est toujours sdb2?

Hello. Merci pour ton interet.

Non, c’est sdb1 maintenant : jai faussement cru que ca faciliterait les choses d’installer le boot en debut de disque.

si ta partition linux est sur sdb1 alors root = (hd1,0)et ton menu.lst doit ressembler à ceci:

title Debian GNU/Linux, kernel 2.6.26-2-amd64
root (hd1,0)
kernel /boot/vmlinuz-2.6.26-2-amd64 root=/dev/sdb1 ro
initrd /boot/initrd.img-2.6.26-2-amd64

title Debian GNU/Linux, kernel 2.6.26-2-amd64 (single-user mode)
root (hd1,0)
kernel /boot/vmlinuz-2.6.26-2-amd64 root=/dev/sdb1 ro single
initrd /boot/initrd.img-2.6.26-2-amd64

C’est justement ce qui me preoccupe : parce que c’est deja le cas - cf. message precedent

J’ai meme change le device.map croyant que ca venait de la :

avant:
hd0 hdb
hd1 sda
hd2 sdb

maintenant:
hd0 sda
hd1 sdb
hd2 hdb

rien n’y fait : error 17… :unamused:

Salut,

Dans ces cas récalcitrants j’utilise “SuperGrubDisk” :slightly_smiling:

tu indiques toi même:

sdb1 - swap
sdb2 - root debian

tu dis que linux est sur sdb1 alors que c’est une partition swap.Je repose ma question au risque de passer pour bredin:

SUR QUELLE PARTITION AS TU INSTALLE LINUX quand tu as lancé le cd d’installation? D’après tes infos,pour moi il est clair que ton linux est sur sdb2,et dans ce cas dans menu.lst: root=(hd1,1)

Il s’agit bine de Grub Legacy ?
Grub2 note différemment les partoches.

sdb1 : sdb2 c’etait le premier formatage - cf. le second resultat de “fdisk -l”…

[quote]
Il s’agit bine de Grub Legacy ?
Grub2 note différemment les partoches.[/quote]

Il s’agit bien…

Je vais essayer ca. Merci.

Merci a tous et specialement a ggoodluck47 :

Super grub Disk : c’est super… pedagogue ! Ca marche ! :stuck_out_tongue: grace au live swap menu.

Et donc, sdb1 = hd(0,0)…

[quote=“chaying”]C’est justement ce qui me preoccupe : parce que c’est deja le cas - cf. message precedent

J’ai meme change le device.map croyant que ca venait de la :

avant:
hd0 hdb
hd1 sda
hd2 sdb

maintenant:
hd0 sda
hd1 sdb
hd2 hdb

rien n’y fait : error 17… :unamused:[/quote]

Tu le savais depuis un moment :smiley: