Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

After reading last night around 3 hours of articles and tutorials on the internet, and not finding anything, I thought it's time to post here.

I have an external drive of 500 GB where I have a LOT of stuff. Basically what I have since I have my first computer.

I am using linux manjaro right now. I tried to make a bootable usb stick with dd. My external hdd was plugged into the laptop and also the usb stick. After I clicked enter I realised that the external hard disk is also pluged in so I Ctrl+C right away! I've opened a file manager and saw that my external hdd is there, my files there everything cool. Last night, I tried to copy something from it and BUM, not working! So ... here is what I've did:

sudo fdisk -l

..
Disk /dev/sdc: 500.1 GB, 500107862016 bytes, 976773168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk label type: dos
Disk identifier: 0x4ed6f18f

   Device Boot      Start         End      Blocks   Id  System
/dev/sdc1   *           0     1513471      756736   17  Hidden HPFS/NTFS

Disk /dev/sdc1: 774 MB, 774897664 bytes, 1513472 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk label type: dos
Disk identifier: 0x4ed6f18f

Another command:

[root@linux dev]# e2fsck -f /dev/sdc1
e2fsck 1.42.8 (20-Jun-2013)
ext2fs_open2: Bad magic number in super-block
e2fsck: Superblock invalid, trying backup blocks...
e2fsck: Bad magic number in super-block while trying to open /dev/sdc1

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>

So I've tried:

[root@linux dev]# mke2fs -n /dev/sdc1
mke2fs 1.42.8 (20-Jun-2013)
Filesystem label=
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
Stride=0 blocks, Stripe width=0 blocks
47328 inodes, 189184 blocks
9459 blocks (5.00%) reserved for the super user
First data block=0
Maximum filesystem blocks=197132288
6 block groups
32768 blocks per group, 32768 fragments per group
7888 inodes per group
Superblock backups stored on blocks: 
    32768, 98304, 163840

I've tried to backup some blocks with this:

[root@linux dev]# e2fsck -f -b 32768 /dev/sdc1
e2fsck 1.42.8 (20-Jun-2013)
e2fsck: Invalid argument while trying to open /dev/sdc1

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've tried the command with all 3 but, I got the same.

So ... I decided to try it out with testdisk. I've used testdisk analyse on the external hdd, but the analyse gave me no output, so I've tried with the deeper search, but same, no error or warning found.

I've also tried to open Gparted, but it gave me this error.

invalid partition table - recursive partition on /dev/sdc

Do you guys any ideas of what could I do to solve this or can I solve this problem ?

cfdisk /dev/sdc output:

 cfdisk (util-linux 2.23.2)

                                Disk Drive: sdc
                       Size: 500107862016 bytes, 500.1 GB
             Heads: 64   Sectors per Track: 32   Cylinders: 476940

    Name        Flags      Part Type  FS Type          [Label]        Size (MB)
 ------------------------------------------------------------------------------
    sdc1        Boot, NC    Primary   Hidden HPFS/NTFS                   774.90 
                            Pri/Log   Free Space                      499332.97*
share|improve this question

1 Answer 1

Your problem seems to me to be well diagnosed by your very first command, fdisk: I quote

Disk /dev/sdc: 500.1 GB, 500107862016 bytes, 976773168 sectors
....
Disk /dev/sdc1: 774 MB, 774897664 bytes, 1513472 sectors

You have a partition way, way smaller than your disk. It is clear the rest of your stuff is in the un-allocated territory beyond the end of this partition. However, you cannot just use a utility to rebuild the partition table, because you seem to have deleted 774 MB of data; if you had only deleted the partition table it would have been possible to re-construct and your data would have reappeared magically unscathed.

Still, you only lost 1GB, so most of your data are still there. I am a bit puzzled by the fact that testdisk came up empty-handed, in general it is a most powerful isntrument. Are you sure you pointed it to the 'un-allocated' portion of the disk? If you haven't (which I suspect since you state it reported absolutely nothing), testdisk probably only checked the 774 MB of the /dev/sdc1 partition, which, I am ready to bet, is perfectly Ok. Somewhere in testdisk option there is the 'un-allocated part of the disk', you should try it on that.

Also, there are utilities like http://www.cgsecurity.org/wiki/PhotoRec, http://foremost.sourceforge.net/, http://www.sleuthkit.org/autopsy/index.php. For even more utilities, you may try this very informative page of the Arch Linux Wiki.

share|improve this answer
    
I dont' get the right error, meaning that the partition is larger. I get this error: Error: Invalid partition table - recursive partition on /dev/sdc –  icebox19 Oct 28 '13 at 13:04
    
also, from your quote, it's pretty clear that the hard disk is 500 GB, and the partition has only 774 MB. I think 774 MB had the image that I was trying to "burn" on the usb with dd –  icebox19 Oct 28 '13 at 13:10
    
Yes, that's because your partition starts at sector 0, which means you did not leave any room for a partition table. That generally occurs when you use dd ... of=/dev/sdb instead of of=/dev/sdb1. Basically, your disk right now has no partition table. –  MariusMatutiae Oct 28 '13 at 13:12
    
ok ... but how could I solve this ? is it possible ? –  icebox19 Oct 28 '13 at 13:13
    
@icebox19 Edited my post... –  MariusMatutiae Oct 28 '13 at 13:59

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.