I had a power failure while using two of my hard drives (two WD Red 4 TB, each one nearly full, HFS+ data only, no OS on the drives) in a dock.
Since then I was able to recover almost all my files with DiskDrill but some are corrupted, some have lost their name and directory.
Since I have nothing more to lose here, I put my hands in it.
I am trying to rebuild the GPT with testdisk, but I failed several times. So I've already written few times on gpt with testdisk, I've also tried the method using testdisk to find sectors of partition and pdisk to write them, but it failed.
Now I am trying again with testdisk and wxhexeditor.
I am looking at every occurrence of "HFSJ", the first one match the sector testdisk had found 529400 (271430664 in hex).
But I can't find any EFI partition. Is there a way I can fix that? And rebuild GUID partition scheme?
Here is the result of
sudo gpt -r show disk2:
start size index contents 0 1 PMBR 1 1 Pri GPT header 2 32 Pri GPT table 34 529366 529400 7812357952 1 GPT part - 48465300-0000-11AA-AA11-00306543ECAC 7812887352 1149783 7814037135 32 Sec GPT table 7814037167 1 Sec GPT header
Follow-up: I tried what you recommend with the following result:
diskutil unmountDisk /dev/disk2 Unmount of all volumes on disk2 was successful sudo gpt remove -i 1 disk2 disk2s1 removed sudo gpt add -i 1 -b 40 -s 409600 -t C12A7328-F81F-11D2-BA4B-00A0C93EC93B disk2 disk2s1 added sudo gpt add -i 2 -b 409640 -s 7813365344 -t 48465300-0000-11AA-AA11-00306543ECAC disk2 disk2s2 added diskutil verifyVolume disk2s2 Started file system verification on disk2s2 Verifying file system File system check exit code is 8 Error: -69845: File system verify or repair failed Underlying error: 8: POSIX reports: Exec format error
this is beyond my understanding!