From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from lists.gentoo.org ([140.105.134.102] helo=robin.gentoo.org) by nuthatch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1GYPz3-0005gx-IJ for garchives@archives.gentoo.org; Fri, 13 Oct 2006 16:34:06 +0000 Received: from robin.gentoo.org (localhost [127.0.0.1]) by robin.gentoo.org (8.13.8/8.13.6) with SMTP id k9DGUit6012245; Fri, 13 Oct 2006 16:30:44 GMT Received: from qb-out-0506.google.com (qb-out-0506.google.com [72.14.204.237]) by robin.gentoo.org (8.13.8/8.13.6) with ESMTP id k9DGS4mu012326 for ; Fri, 13 Oct 2006 16:28:04 GMT Received: by qb-out-0506.google.com with SMTP id z8so185098qbc for ; Fri, 13 Oct 2006 09:28:01 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:references; b=OM853qW/qYY9mDXvM6dZnDg07C0Dy2xBPZCBX15bbRyXF4JwWZ2OoOPKopTogQWMToEirqKQRXENX/4ewGimlum9spae3iSHEHqus4nrkGJ8A5C+7FmRtt5hUFnamsAt8iPw+AzIDw/vOSltvQy55wuwy/SzQC+Jcqy+SeErNhE= Received: by 10.64.156.1 with SMTP id d1mr5256447qbe; Fri, 13 Oct 2006 09:28:01 -0700 (PDT) Received: by 10.65.218.13 with HTTP; Fri, 13 Oct 2006 09:28:01 -0700 (PDT) Message-ID: <642958cc0610130928o516f5b46x65f6fdd3eceee23c@mail.gmail.com> Date: Fri, 13 Oct 2006 12:28:01 -0400 From: "Mark Shields" To: gentoo-user@lists.gentoo.org Subject: Re: [gentoo-user] [OT] Problem with disk: cannot mount as ext3 but yes as ext2 ??? In-Reply-To: <5e213dd40610052329m7f707624w8da75d2e8d4bdd40@mail.gmail.com> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-user@gentoo.org Reply-to: gentoo-user@lists.gentoo.org MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_60050_17375480.1160756881715" References: <5e213dd40610052329m7f707624w8da75d2e8d4bdd40@mail.gmail.com> X-Archives-Salt: a5631c83-a995-429e-bdb4-2fdd46140644 X-Archives-Hash: eaba6dfe3ca18765ab98182930db47ac ------=_Part_60050_17375480.1160756881715 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline On 10/6/06, Gregory SACRE wrote: > > Hello, > > > I had a hard disk attached on an old RedHat PC formatted and mounted > as ext3 filesystem. > I removed the hard disk from the PC and plugged it in my Gentoo box. I > tried to mount it as ext3 file system and got this error: > > > -------------------------------------------------------------------------------- > | # mount -t ext3 /dev/hdd1 /jukebox > | mount: wrong fs type, bad option, bad superblock on /dev/hdd1, > | missing codepage or other error > | In some cases useful info is found in syslog - try > | dmesg | tail or so > > -------------------------------------------------------------------------------- > > I then tried to see the partition type with fdisk: > > > -------------------------------------------------------------------------------- > | Command (m for help): p > | > | Disk /dev/hdd: 81.9 GB, 81964302336 bytes > | 16 heads, 63 sectors/track, 158816 cylinders > | Units = cylinders of 1008 * 512 = 516096 bytes > | > | Device Boot Start End Blocks Id System > | /dev/hdd1 1 158816 80043232+ 83 Linux > > -------------------------------------------------------------------------------- > > My next step was to try to repair it with fsck.ext3: > > > -------------------------------------------------------------------------------- > | fsck.ext3 -p /dev/hdd > | fsck.ext3: Bad magic number in super-block while trying to open /dev/hdd > | /dev/hdd: > | The superblock could not be read or does not describe a correct ext2 > | filesystem. If the device is valid and it really contains an ext2 > | filesystem (and not swap or ufs or something else), then the superblock > | is corrupt, and you might try running e2fsck with an alternate > superblock: > | e2fsck -b 8193 > > -------------------------------------------------------------------------------- > > I tried what was written with e2fsck: > > > -------------------------------------------------------------------------------- > | e2fsck -b 8193 /dev/hdd > | e2fsck 1.39 (29-May-2006) > | e2fsck: Bad magic number in super-block while trying to open /dev/hdd > | > | The superblock could not be read or does not describe a correct ext2 > | filesystem. If the device is valid and it really contains an ext2 > | filesystem (and not swap or ufs or something else), then the superblock > | is corrupt, and you might try running e2fsck with an alternate > superblock: > | e2fsck -b 8193 > > -------------------------------------------------------------------------------- > > After googling for a while, and not really finding an answer, I tried > to mount it as readonly, and because of a typo, I mounted it as > ext2... and it worked!!! I tried then to mount it normally, not > anymore as read-only with ext2 format... and it worked!!! > So my first question is: how come? > I'm sure the filetype is ext3 as it can be seen in my old fstab: > > > -------------------------------------------------------------------------------- > | [...] > | /dev/hdb5 > swap swap defaults 0 0 > | #/dev/hdc1 /jukebox ext3 defaults > 1 1 --> this is the one ;-) > | [...] > > -------------------------------------------------------------------------------- > > I thought maybe I could try to repair it with the normal fsck: > > > -------------------------------------------------------------------------------- > | fsck /dev/hdd1 > | fsck 1.39 (29-May-2006) > | e2fsck 1.39 (29-May-2006) > | /dev/hdd1: Attempt to read block from filesystem resulted in short > read while reading block 525 > | > | /dev/hdd1: Attempt to read block from filesystem resulted in short > read reading journal superblock > | > | fsck.ext3: Attempt to read block from filesystem resulted in short > read while checking ext3 journal for /dev/hdd1 > > -------------------------------------------------------------------------------- > > Is there anything wrong with my hardware? Is it a super-block problem? > Is there a way to solve it? > > Thank you in advance! > > Greg > -- > gentoo-user@gentoo.org mailing list > > Have you looked into tune2fs? I converted an ext2 to an ext3 with it by running tune2fs -j /dev/sda9, you might want to see if that utility can provide any assistance. -- - Mark Shields ------=_Part_60050_17375480.1160756881715 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline On 10/6/06, Gregory SACRE <gregory.sacre@gmail.com> wrote:
Hello,


I had a hard disk attached on an old RedHat PC formatted and mounted
as ext3 filesystem.
I removed the hard disk from the PC and plugged it in my Gentoo box. I
tried to mount it as ext3 file system and got this error:

--------------------------------------------------------------------------------
| # mount -t ext3 /dev/hdd1 /jukebox
| mount: wrong fs type, bad option, bad superblock on /dev/hdd1,
|        missing codepage or other error
|        In some cases useful info is found in syslog - try
|        dmesg | tail  or so
--------------------------------------------------------------------------------

I then tried to see the partition type with fdisk:

--------------------------------------------------------------------------------
| Command (m for help): p
|
| Disk /dev/hdd: 81.9 GB, 81964302336 bytes
| 16 heads, 63 sectors/track, 158816 cylinders
| Units = cylinders of 1008 * 512 = 516096 bytes
|
|    Device Boot      Start         End      Blocks   Id  System
| /dev/hdd1               1      158816    80043232+  83  Linux
--------------------------------------------------------------------------------

My next step was to try to repair it with fsck.ext3:

--------------------------------------------------------------------------------
| fsck.ext3 -p /dev/hdd
| fsck.ext3: Bad magic number in super-block while trying to open /dev/hdd
| /dev/hdd:
| The superblock could not be read or does not describe a correct ext2
| filesystem.  If the device is valid and it really contains an ext2
| filesystem (and not swap or ufs or something else), then the superblock
| is corrupt, and you might try running e2fsck with an alternate superblock:
|     e2fsck -b 8193 <device>
--------------------------------------------------------------------------------

I tried what was written with e2fsck:

--------------------------------------------------------------------------------
| e2fsck -b 8193 /dev/hdd
| e2fsck 1.39 (29-May-2006)
| e2fsck: Bad magic number in super-block while trying to open /dev/hdd
|
| The superblock could not be read or does not describe a correct ext2
| filesystem.  If the device is valid and it really contains an ext2
| filesystem (and not swap or ufs or something else), then the superblock
| is corrupt, and you might try running e2fsck with an alternate superblock:
|     e2fsck -b 8193 <device>
--------------------------------------------------------------------------------

After googling for a while, and not really finding an answer, I tried
to mount it as readonly, and because of a typo, I mounted it as
ext2... and it worked!!! I tried then to mount it normally, not
anymore as read-only with ext2 format... and it worked!!!
So my first question is: how come?
I'm sure the filetype is ext3 as it can be seen in my old fstab:

--------------------------------------------------------------------------------
| [...]
| /dev/hdb5               swap                    swap    defaults        0 0
| #/dev/hdc1               /jukebox               ext3    defaults
   1 1    --> this is the one ;-)
| [...]
--------------------------------------------------------------------------------

I thought maybe I could try to repair it with the normal fsck:

--------------------------------------------------------------------------------
| fsck /dev/hdd1
| fsck 1.39 (29-May-2006)
| e2fsck 1.39 (29-May-2006)
| /dev/hdd1: Attempt to read block from filesystem resulted in short
read while reading block 525
|
| /dev/hdd1: Attempt to read block from filesystem resulted in short
read reading journal superblock
|
| fsck.ext3: Attempt to read block from filesystem resulted in short
read while checking ext3 journal for /dev/hdd1
--------------------------------------------------------------------------------

Is there anything wrong with my hardware? Is it a super-block problem?
Is there a way to solve it?

Thank you in advance!

Greg
--
gentoo-user@gentoo.org mailing list


Have you looked into tune2fs?  I converted an ext2 to an ext3 with it by running tune2fs -j /dev/sda9, you might want to see if that utility can provide any assistance.

--
- Mark Shields ------=_Part_60050_17375480.1160756881715-- -- gentoo-user@gentoo.org mailing list