Thursday, October 15, 2015

hard drive - Recover Data on GPT protective partition


For an unknown reason, my laptop's windows 10 stopped booting correctly this week.
after analysing disks, it appear that the first disk with the OS was in a terrible shape (lot of noise when reading/writing,...) and but the second with data (1TB) seems fine... but unreadable !
I plugged it with usb adaptator, but it showed as GPT protective partition in another windows 10 "disk mgmt" console. and nothing can be done, all options grayed out.


I executed gparted to read partitions, mbr,... but not sure on how not screw the data on the drive...


here is the output of gparted when launched on the drive :


c:\temp>gdisk64.exe \\.\physicaldrive1
GPT fdisk (gdisk) version 1.0.1
Partition table scan:
MBR: protective
BSD: not present
APM: not present
GPT: not present
Creating new GPT entries.
************************************************************************
Most versions of Windows cannot boot from a GPT disk except on a UEFI-based
computer, and most varieties prior to Vista cannot read GPT disks. Therefore,
you should exit now unless you understand the implications of converting MBR
to GPT or creating a new GPT disk layout!
************************************************************************
Are you SURE you want to continue? (Y/N): y
Command (? for help): l
Disk \\.\physicaldrive1: 244190646 sectors, 931.5 GiB
Logical sector size: 4096 bytes
Disk identifier (GUID): EE734396-FF46-48DD-A2D3-40E508B33FA3
Partition table holds up to 128 entries
First usable sector is 6, last usable sector is 244190640
Partitions will be aligned on 256-sector boundaries
Total free space is 244190635 sectors (931.5 GiB)
Number Start (sector) End (sector) Size Code Name
Command (? for help): r
Recovery/transformation command (? for help): i
No partitions
Recovery/transformation command (? for help): o
Disk size is 244190646 sectors (931.5 GiB)
MBR disk identifier: 0x00000000
MBR partitions:
Number Boot Start Sector End Sector Status Code
1 1 244190645 primary 0xEE

I also tried to read disk on Fedora, but no more luck.


Is there anything to do to, at least, copy the data, or better repair the partition table (or something else that is broken).


if any information is missing to make a better diagnosis, tell me
Thank you


Edit and solution :
As Rod pointed out, the laptop's hardware configured the drive's sector size to 4096 bytes.
Once the drive plugged into the original laptop (and not on another with USB cable), the drive is recognized and fully operational.


Answer



STOP!


There's a warning sign in your output:


Logical sector size: 4096 bytes

The vast majority of hard disks today use 512-byte logical sectors. Some external enclosures and adapters, though, translate groups of eight 512-byte sectors into 4096-byte sectors. Doing so has certain advantages, but it makes it very difficult to safely move a disk from a direct connection to a connection involving an adapter that does such a translation. Changing the sector sizes in this way renders critical data structures, such as the partition table, invalid. If you start writing data with your USB adapter, you're almost certain to do additional harm to your disk.


To recover your data, you should first connect the disk in the way it was connected before your problems began, or at least find a way to connect it that will produce the same sector size as it had when it was connected normally. Only after you've connected your disk in this way will you be able to extract useful data for diagnosis and repair.


No comments:

Post a Comment

linux - How to SSH to ec2 instance in VPC private subnet via NAT server

I have created a VPC in aws with a public subnet and a private subnet. The private subnet does not have direct access to external network. S...