0

We have a hard drive with damaged partitions. In deeper search testdisk found it but wanted to deletd all of the partition (and showed structure OK below):

enter image description here

We tried this one but then it showed the structure is BAD (below):

enter image description here

Another way which we thought was good is choosing all the other partition as delete, except to the last one, and to choose the important partition (the second one) as L and also *-bootable or P(rimary):

enter image description here

We now need to know if that is OK so that we can apply the changes. There is more information if needed in our post on the forums.

It is very important to recover all of our work there.

Takkat
  • 144,580
yinon
  • 1,229

1 Answers1

0

As we do not know what incident damaged your drive, and we also do not know anything on the previous proper partition structure we unfortunately can not give you a reliable answer to your question.

However in case these lost data are really important, and we have no backups, we strongly recommend to run all the restoring commands on an image of the drive only. Alternatively it would also be a good idea to create an image of the whole drive to be able to restore to the previous state in case we further mess up the partition table. We can do so with

sudo dd if=/dev/sda of=<path>/backup.img

Replace <path> with the location of your backup medium (e.g. an external drive).

Running testdisk on an image will save you a lot of headaches if something goes wrong, and it will also allow you to try out what you believe is right without any risk of further data loss. Run testdisk on the image as follows:

sudo testdisk <path>/backup.img
Takkat
  • 144,580