I have two supposedly identical 3TB Western Digital USB HDDs. One contains nearly the full 3TB of data. I want the other to be a backup of that data. There are lots of small files, so running cp would be even slower than copying 3TB over USB using dd. Both drivers were bought at the same time, both use msdos partition table, but one shows logical/physical sector sizes of 4096/4096 and the other shows 512/4096.

My problem is that I'm trying to copy to the 512/4096 drive, but I can't create a large enough partition because of the limits of the msdos partition table with 512 byte (logical) sectors. I've tried various commands (dd of the first few sectors to partition table, parted, fdisk, gparted, Windows XP "Manage" and Windows 7 "Manage") but end up with either 2TB max limits or ~300GB partitions that thought they were 3TB when they were created.

Given that one of my drives is running at 4096/4096 then this question doesn't hold true for my case.

Using GPT is my fall-back option, but it creates a partition that is slightly smaller than the NTFS partition, so I wouldn't be able to just dd the filesystem on the partition.

Is there a way to force 4096/4096 for an msdos partition table (either from Linux or Windows) so that I can create a 3TB partition that perfectly matches my source disk?

  • Couldn't you use software to simply duplicate the entire disk sector by sector? I know Acronis and CloneZilla have this ability. – Ramhound Aug 20 '12 at 15:04
  • 1
    Why can't you create a FAT32 partition with a sector size greater than 512? That's what is limiting the size of the volume. FAT32 maximum volume sizes range from 2 TB for a sector size of 512 bytes up to 16 TB for a sector size of 4,096 bytes. – martineau Aug 20 '12 at 15:18
  • @Ramhound - I've used dd if=/dev/sdb of=/dev/sdc, which is a Linux command that does sector by sector copying of an entire device (not just a partition), but the partition on the second device comes out at ~300GB despite being a perfect copy. dd is one of Clonezilla's 'last ditch' options when it can't do anything more intelligent. – IBBoard Aug 20 '12 at 18:27
  • @martineau: I'm using NTFS, because that's what the source partition was. I've mounted the drive in Win7, opened "Manage" and if it is on "MBR" partitioning (which the first disk appears to be) then even Win7 won't let me create a partition larger than 2TB. When printing the disk info in Linux using fdisk (IIRC) then "Sector size (logical/physical)" definitely differs between devices, which screws the partitions I have made. – IBBoard Aug 20 '12 at 18:31
  • Western Digital has free disk utilities for partitioning their drives -- you could try using them. Personally I use Acronis Disk Director -- a commercial program -- to do virtually all my partition manipulations. – martineau Aug 20 '12 at 19:28

I just had a similar issue. I had a Seagate 3TB USB Desktop Expansion drive that I wanted to move into my PC for faster access (I only had USB 2.0 on the PC). Once I did that I couldn't access the filesystem. Returning it to the USB to SATA controller made it work again. Comparing the two I found that in the external case (using the USB to SATA controller) the drive had 4096/4096 logical/physical sector sizes and when connected to the internal motherboard SATA, it had 512/4096 logical/physical sector sizes. Much like the OP sugguests, a 4096 logical sector size allows for > 2TiB partitions, but at the 512 sector size we get the 2TiB limit. I didn't want to copy stuff off (slowly over USB) to somewhere, repartition (GPT), reformat, and copy back, so I kept at it. My ultimate solution on Linux was to:

Delete the original MBR partition table which uses 4k sectors. Use gdisk (GPT variant of fdisk) to create the partition using 512 byte sectors spanning the exact same area. This basically amounted to taking the sectors for start/end of the partition in 4K-land and multiplying by 8. I did have an off-by one on the end, so I added 8 more there and so far so good (e2fsck alerted me to that.) The e2fsk is still going, so I'm not 100% sure I'm safe, but it seems all good in theory and I did mount the files for a bit and they looked fine.

  • So Linux tools seem to work okay and ignore the 2TiB limit? Interesting, but unfortunately I needed the HDD for Windows, so it had to be NTFS. Even if Ext3 lets you go past 2TiB, I suspect Windows will get upset or ignore it. – IBBoard Jan 28 '13 at 20:03
  • 1
    It's a GPT partition table versus a MSDOS partition table. No one mentioned filesystems. You can do a conversion from MSDOS/MBR to GPT using gdisk relatively safely. – justbrowsing Sep 7 '13 at 22:25
  • There are many other reasons to want to move to a GPT, even if you have a disk smaller than 2TiB, safety and redundancy chief among them. You may wish to read this excellent article, ibm.com/developerworks/linux/library/l-gpt/index.html – MariusMatutiae Nov 7 '13 at 7:35
  • 1
    the limit does not related to Linux or Windows. It's just because MBR doesn't support drives larger than 2TB – phuclv Jan 10 '14 at 10:57
  • I can confirm this approach works. This was my partition table after a night-long rsync and after having moved the disk from a USB-to-SATA adapter to a proper SATA connector (if you do the sums, you'll notice a perfect factor of 8). I've first tried a few times with a partial dd image and then I took the plunge. BTRFS scrub was totally happy with the values. Hope I'll never have to do this again, but it has been a didactic moment. – Avio Nov 30 '18 at 14:39

The sector size is HDD's native size, so there's no way to "force" it to change that value. Some old 4K HDD may support emulated 512-byte sector mode but it requires partitions to be aligned properly or performance will be reduced greatly.

You shouldn't use dd for copying disks. Instead, use some disk cloning tools, they'll smart enough to skip blank clusters and are also capable of cloning between disks with different sizes. Also, there's no "DOS partition table" but MBR and GPT (and some uncommon formats). With MBR you can only addressed 232 sectors (2TB with 512 bytes/sector). So the only way is using GPT.

  • 1
    If there's no way to force it, how did it change? That is the crux of the problem. An identical disk (make, model, etc) shows 4K sectors. The 512b sector disk used to report the correct size, but now reports a much smaller size. /Something/ changed, so unless it is a hardware failure of some intermediary level that faked the size then it should be possible to change it back. As for the "msdos" partition table - tell that to GParted, because that's what they give you as an option. I used dd because the disk was 95% full, so ghosting apps won't be much more efficient. – IBBoard Jan 18 '14 at 12:02
  1. Sector:

    1) Logical Sector: Called Native Sector.

    Manufacture default setting. user cannot change.

    Before 2010 year: 512b/sector

    After 2010 year: 4k/sector.

    Some manufacture provide HDD tool to change native sector.

    2) Physical Sector: Called Cluster(FAT windows) or Block(Linux/Unix)

    User can change physical sector size 512b,1k,... by format or partition tool. Physical sector contains one or few more native sectors.

    (example1: if you have HDD 512b/native sector: user can set 4K/Physical sector. this mean 1 cluster = 4 native sector)

    (example2: if you have HDD 4K/native sector: user can set 4K/Physical sector. this mead 1 cluster = 1 native sector)

    3) File system deal with Physical sector(or block or Cluster) only.

  • you missed to write down the source of this quotation – andras.tim Apr 16 at 12:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.