Partition Table Recovery ext4, 3TB - wrong size

How to use TestDisk to recover lost partition
Forum rules
When asking for technical support:
- Search for posts on the same topic before posting a new question.
- Give clear, specific information in the title of your post.
- Include as many details as you can, MOST POSTS WILL GET ONLY ONE OR TWO ANSWERS.
- Post a follow up with a "Thank you" or "This worked!"
- When you learn something, use that knowledge to HELP ANOTHER USER LATER.
Before posting, please read
Posts: 2
Joined: 17 Dec 2013, 04:19

Partition Table Recovery ext4, 3TB - wrong size

#1 Post by spacegoat »

A partition table got accidentally overwritten during an OS install. No data has been touched.
Originally the partition was a single primary partition ext4 of maximum size.

Running TestDisk in deep mode , only with the first partition candidate was I able to see files. In all other candidates there was nothing.

Unfortunately the revovered partition does not include the whole disk. Here is what is produced:
Disk /dev/sdb: 2.7 TiB, 3000591900160 bytes, 5860531055 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: dos
Disk identifier: 0x00000000

Device Boot Start End Blocks Id System
/dev/sdb1 2048 4294969342 2147483647+ 83 Linux
Please click here to see the Testdisk log.

Thanks for any advice

User avatar
Site Admin
Posts: 5427
Joined: 18 Feb 2012, 15:08
Location: Le Perreux Sur Marne, France

Re: Partition Table Recovery ext4, 3TB - wrong size

#2 Post by cgrenier »

PC/Intel or "dos" partition table are limited to 2 TB. Your disk is 3TB.
When using TestDisk, choose an EFI GPT partition table. After Analyse and Quick Search, choose Write, confirm.
You may have to reboot.
This time parted should display the correct values.

Posts: 2
Joined: 17 Dec 2013, 04:19

Re: Partition Table Recovery ext4, 3TB - wrong size

#3 Post by spacegoat »

The problem is the HPA. Here is my posting on the Western Digital website:
WD Hidden Protected Area (HPA) is an Extremely High Security Risk I have read of more than one unfortunate person suffer the problem of partitioning a WD disk, copying across user data to then find on reboot that the data on the drive is not accessible!!!!!!!!!!!!!!

The user must hunt down HPA utilities and even compile them for himself, prior to removing to HPA to make the disk usable again!!! He must then apply data recovery procedures to get the data back!!!

How crazy is this? An invitation to trap the users into losing large amounts of data is unforgiveable. The HPA should be disabled by default to prevent this.

I am in the unfortunate position of suffering this fate. Nearly 3 GB of data is currently offline. The WD30EZRX is only showing 2 TB instead of 3 TB.

Perhaps WD could provide unambiguous instructions on how to retrieve this situation. I do not like following instructions posted on blogs. 3 TB of data is at risk.

This problem is not a general software bug, that is of course forgiveable. It is a huge problem by design.

So WD, what do I do to recover from this situation you deliberately created?

(System is an 8 year old Gibabyte motherborad and Arch Linux)
In addition to this, there are severe problems with the excessive Load/Unload cycling due to "intellipark".

HPA and "intellipark", generally useless features but causing severe problems. I still don't know how to deal with the HPA issue.
I will not buy Wesrern Digital again.