How to fix T10-PI Type 1 Protected Disk?

T10-PI Type 1 protection

Hi! I have some drives with T10-PI Type 1 protection on them. Not sure what any of this means, but the output was something like this:

# sg_readcap -l /dev/sda
Read Capacity results:
   Protection: prot_en=1, p_type=0, p_i_exponent=0 [type 1 protection]

I ran this command to fix them:

sg_format -v -F /dev/sdX

But it took 16 hours for a 10TB HDD. Is there a quicker way to do it?

What’s this protection? What does it do?

Branded maybe?

I read somewhere about branded drives also needing to be formatted?

When I run this command, it says HGST instead of ATA:

# sg_scan -i /dev/sdab
/dev/sdab: scsi19 channel=0 id=2 lun=0 [em]
    HGST      H7210A520SUN010T  A680 [rmb=0 cmdq=1 pqual=0 pdev=0x0] 

Compare to my SSD:

# sg_scan -i /dev/sdad
/dev/sdad: scsi19 channel=0 id=30 lun=0 [em]
    ATA       CT4000MX500SSD1   046  [rmb=0 cmdq=1 pqual=0 pdev=0x0] 
# sg_format -v /dev/sdab
    HGST      H7210A520SUN010T  A680   peripheral_type: disk [0x0]
      PROTECT=1
      << supports protection information>>
      Unit serial number: [REDACTED]
      LU name: 5000cca2675f5708
    mode sense(10) cdb: [5a 00 01 00 00 00 00 00 fc 00]
Mode Sense (block descriptor) data, prior to changes:
block count maxed out, set <<longlba>>
    mode sense(10) cdb: [5a 10 01 00 00 00 00 00 fc 00]
  <<< longlba flag set (64 bit lba) >>>
  Number of blocks=19134414848 [0x474800000]
  Block size=512 [0x200]
    read capacity(16) cdb: [9e 10 00 00 00 00 00 00 00 00 00 00 00 20 00 00]
Read Capacity (16) results:
   Protection: prot_en=0, p_type=0, p_i_exponent=0
   Logical block provisioning: lbpme=0, lbprz=0
   Logical blocks per physical block exponent=3
   Lowest aligned logical block address=0
   Number of logical blocks=19134414848
   Logical block size=512 bytes

Does that mean it’s branded? Or would it only be branded if it’s block size is 520 bytes?

These are 512e drives. Not sure if 4Kn is better or not. I could format it either way.

Someone was saying you can fix branded disks this way:

# time sg_format -v -F -s 512 /dev/sdX

But I’m wondering if I should be reformatting them as 4Kn anyway:

# time sg_format -v -F -s 4096 /dev/sdX

This topic was automatically closed 273 days after the last reply. New replies are no longer allowed.