LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Hardware (http://www.linuxquestions.org/questions/linux-hardware-18/)
-   -   Hard disk issue (http://www.linuxquestions.org/questions/linux-hardware-18/hard-disk-issue-757931/)

man0v 09-26-2009 11:32 AM

Hard disk issue
 
Hello,

I used to have 250GB Seagate hard disk with a lot of information. After power supply fail the motherboard has failed and, as it looks like, there is file system error on that disk. Before a few days I installed on another machine, on another hard disk Fedora 11 and now I want get my data back, but I cannot mount the disk. When I run
Code:

mount /dev/sdb /mnt/sdb -t ext2
I get
Code:

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

I cannot make fsck, because I get

Code:

fsck 1.41.4 (27-Jan-2009)
e2fsck 1.41.4 (27-Jan-2009)
fsck.ext2: Superblock invalid, trying backup blocks...
fsck.ext2: Bad magic number in super-block while trying to open /dev/sdb

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>


saikee 09-26-2009 12:10 PM

Let us see the output of
Code:

fdisk -l
Normally we only mount a partition. /dev/sdb is confusing as it can have many partitions each with different filing type.

man0v 09-26-2009 12:25 PM

it returned that

Code:

Disk /dev/sda: 251.0 GB, 251000193024 bytes
255 heads, 63 sectors/track, 30515 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xd0330960

  Device Boot      Start        End      Blocks  Id  System
/dev/sda1  *          1      29863  239868826  83  Linux
/dev/sda2          29863      30515    5242880  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: 0x22767688

  Device Boot      Start        End      Blocks  Id  System
/dev/sdb1              1          43      345366  82  Linux swap / Solaris
/dev/sdb2  *          44        1288    10000462+  83  Linux
/dev/sdb3            1289        3172    15133230  83  Linux
/dev/sdb4            3173      30401  218716942+  83  Linux


ajlewis2 09-26-2009 12:57 PM

You have to mount one of the partitions. For example:

Code:

mount -t ext2 /dev/sdb4 /mnt/sdb
Be sure you have /mnt/sdb created.

man0v 09-26-2009 01:08 PM

the same error is returned when I mount specific partition, no matter which one...

ajlewis2 09-26-2009 01:20 PM

fsck /dev/sdb4 - does that give an error too?

I'm assuming you are doing the mounting as root or with sudo, because I think the error would be different if it was as simple as that.

Also, I would try the mount without expressing the type of filesystem.

man0v 09-26-2009 01:33 PM

yes, it does the following
Code:

fsck: Error 2 while executing fsck.reiserfs for /dev/sdb4
And yes I use root only. Why should I use simple user account, anyway?

But DUDE!!!!
THE ONLY THING I HAVE NOT TRIED IS WHAT JUST SAVED MY LIFE!
THANK YOU MAN, YOU HAVE A BEER FROM ME!

jiml8 09-26-2009 01:41 PM

Quote:

Originally Posted by man0v (Post 3697856)
yes, it does the following
Code:

fsck: Error 2 while executing fsck.reiserfs for /dev/sdb4
And yes I use root only. Why should I use simple user account, anyway?

Security.

The fundamental aspect of *nix security is having users use limited accounts except for system-level work. All *nix makes it easy to do that and easy to become root when necessary.

Also, using a limited account protects the system when you make a mistake. For instance, rm -r / does not wipe out the system if you are a limited user, but will pretty well finish you off if you do that as root.

Quote:

But DUDE!!!!
THE ONLY THING I HAVE NOT TRIED IS WHAT JUST SAVED MY LIFE!
THANK YOU MAN, YOU HAVE A BEER FROM ME!
And that was...what, exactly?

man0v 09-26-2009 02:00 PM

Well, I simply did not express the file system... and it worked.
And about the root - I prefer to be the root user myself. Cannot explain why, but maybe the feeling to be just an user in my computer is depressing me...

ajlewis2 09-26-2009 03:55 PM

Yes, it worked without the type specified, because you have reiserfs. Note the fsck output. At least I'm guessing that is why 'fsck' used 'fsck.reiserfs', but I don't know why there was an error on it.

Anyway, I'm glad the mount idea without type worked. You were specifying ext2; so it couldn't mount - wrong fs type.

Not a dude, but a dudette, btw.


All times are GMT -5. The time now is 02:23 PM.