Monday 24 June 2019

windows 7 - Why is my USB drive showing corrupted data when plugged as an internal SATA drive?


I have a 3TB Seagate Backup Plus Desktop USB 3.0 drive, which works fine when in its enclosure, but when I get it off its enclosure and directly plug it as an internal SATA drive, it's just not properly recognized (it works again when used in the enclosure).
My systems’s motherboard is an ASUS P8P67 LE, which has two SATA 6.0 Gb/s and four SATA 3.0 Gb/s ports.


When used as an internal SATA drive Windows 7 asks if I want to format the drive, as if it didn’t have a proper filesystem, and if I use the DISKMGMT.MSC tool (typing that in the start menu) I get completely wrong information about the drive.


It says the drive has 3 partitions (349,31GB of RAW data and two unassigned partitions of 1698,68GB and 746,52GB). This information is plain wrong, since the drive, when used in the USB enclosure, works as a single NTFS partition (2794,52GB). How come it’s shown as 3 partitions without filesystem when connected through SATA?!


Is Seagate using some proprietary way of storing the data when using the drive in its provided USB 3.0 enclosure? I didn’t use any kind of encryption. I just plugged the drive with USB 3.0 and started using it straight away, since it apparently came pre-formatted with an NTFS filesystem.



Answer



The enclosure exposes the drive to the computer as an Advanced Format 4Kn device, allowing the use of MBR for compatibility with Windows XP systems. When the drive is removed from the enclosure, the change in logical sector format results in an invalid partition table.




  • External hard drives larger than 2 TiB in capacity often expose 4K sectors directly to the operating system. The 2 TiB limit commonly associated with MBR is tied to the traditional 512-byte sector size; 4K sectors are eight times as large and therefore extend the MBR limit to 16 TiB. This allows the use of MBR on disks larger than 2 TiB in capacity, enabling use on Windows XP and other systems which do not support GPT.




  • The underlying hard drive uses 512-byte sector emulation for compatibility with legacy systems. This means that while the disk physically has 4K sectors, the immediate host device (in this case, the enclosure) sees 512-byte sectors. However, to perform the aforementioned MBR expansion and enable Windows XP compatibility, the enclosure makes the drive appear to the computer as having 4K native sectors.




  • When the drive is removed from the enclosure, the 512-byte logical sectors of the underlying 512e disk are exposed. This results in an invalid partition table that cannot be correctly interpreted. The 746.52 GiB value you gave for the last "partition" when the drive is connected directly is precisely the amount of space that lies beyond the 2 TiB limit for MBR drives with 512-byte sectors.




More details about the implications of this conversion are available in this blog post.


No comments:

Post a Comment

How can I VLOOKUP in multiple Excel documents?

I am trying to VLOOKUP reference data with around 400 seperate Excel files. Is it possible to do this in a quick way rather than doing it m...