LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Recoving Partition (https://www.linuxquestions.org/questions/linux-software-2/recoving-partition-480620/)

eggoz 09-05-2006 10:52 AM

Recoving Partition
 
I have accidently deleted my linux partition. I ran mkfs.ext3 by accident. It only ran for a second, but it was enough time to wipe it out. I used dd to copy my drive over to a spare one. I ran testdisk and here is where I am at. If I let it analyze the disk it will eventually find it, but I get an error message:

Code:

TestDisk 5.8, Data Recovery Utility, May 2005
Christophe GRENIER <grenier@cgsecurity.org>
http://www.cgsecurity.org

Disk /dev/sda - CHS 77520 16 63 - 38154 MB

Check the harddisk size: HD jumpers settings, BIOS detection, OS limitation...
The following partition can't be recovered. The harddisk seems too small!
    Partition              Start        End    Size in sectors
    D Linux                32061  1  1 77570  14 29  45873920 [/]
    [  Quit  ]

    ReiserFS 3.6 with standard journal, need recovery, 22399 MB

Fdisk output. Yes, I have a primary partition, and then an extended with my linux and swap in it. Fdisk -l:
Code:

Disk /dev/hda: 40.0 GB, 40007761920 bytes
16 heads, 63 sectors/track, 77520 cylinders
Units = cylinders of 1008 * 512 = 516096 bytes

  Device Boot      Start        End      Blocks  Id  System
  /dev/hda1              1      31215    15732328+  7  HPFS/NTFS
  /dev/hda2  *      31216      77520    23337720    f  W95 Ext'd (LBA)
  /dev/hda5          31216      32010      400648+  82  Linux swap / Solaris
  /dev/hda6          32011      77520    22937008+  83  Linux

  Disk /dev/sda: 40.0 GB, 40007761920 bytes
  16 heads, 63 sectors/track, 77520 cylinders
  Units = cylinders of 1008 * 512 = 516096 bytes

      Device Boot      Start        End      Blocks  Id  System
      /dev/sda2          31216      77520    23337720    f  W95 Ext'd (LBA)
      /dev/sda5          31216      32010      400648+  82  Linux swap / Solaris
      /dev/sda6          32011      77520    22937008+  83  Linux

And finally, the excert from the /log /dump from testdisk:
Code:

ReiserFS Marker at 32061/1/1

recover_rfs
block_count=5734240
block_size=4096
  D Linux                32061  1  1 77570  14 29  45873920 [/]
    ReiserFS 3.6 with standard journal, need recovery, 22399 MB
  D Linux                32061  1  1 77570  14 29  45873920 [/]
    ReiserFS 3.6 with standard journal, need recovery, 22399 MB
This partition ends after the disk limits. (start=32317551, size=45873920, end=78191470, disk end=78140160)

I am not sure what I can do at this point. Any help would be great. Thanks.

bigrigdriver 09-05-2006 11:35 AM

You can try the instructions here.

http://www.tldp.org/HOWTO/Partition/recovering.html

It does require additional hard disk space to make a new partition as large as or larger than the one you want to fix.


All times are GMT -5. The time now is 02:14 AM.