A format command is actually not guaranteed to do anything at all to a disk drive.
It may in fact overwrite all blocks on the drive, but then again it may not. OTOH a sequential write test of the entire will guarantee that all blocks have been overwritten.
What do the official specifications say about Format commands?
For SAS/SCSI/FC drives
the T10 SCSI Block Commands (SBC-3) document says this:
The FORMAT UNIT command requests that the device server format the medium into application client accessible logical blocks as specified in the number of logical blocks and logical block length values received in the last mode parameter block descriptor in a MODE SELECT command. In addition, the device server may certify the medium and create control structures for the management of the medium and defects. The degree that the medium is altered by this command is vendor specific. (Emphasis mine).
And what about SATA?
The T13 ATA/ATAPI Command Set (ACS-2) document says this about the Format Command…nothing. That’s right – there isn’t a Format command in the SATA/ATA command specification! The closest thing found is in the SCSI->ATA Translation (SAT-3) document, describing how a SCSI FORMAT UNIT command may be mapped to an ATA/SATA drive –
The FORMAT UNIT command verifies that all logical block addresses accessible to SCSI application clients are formatted and ready for data transfers.
That’s pretty vague. In fact the SAT-3 specification further states this concerning the FORMAT UNIT Op Code:
Set to 04h. If no defect list header is provided or a defect list header is provided with the DCRT bit set to one, then the SATL shall return GOOD status without issuing any commands to the ATA device.
So in reality, issuing a FORMAT UNIT command to a SATA drive is not guaranteed to do much of anything. It may, or it may not. And for SAS/SCSI/FC drives? Remember that the spec states The degree that the medium is altered by this command is vendor specific.
It may overwrite the drive, but then again it may not, at the drive vendor’s discretion.
When you absolutely, positively…
If you need to be 100% certain that every block on the drive has been overwritten then you must take matters into your own hands and explicitly overwrite all blocks yourself. This is easily accomplished in the STB Suite DMM by defining a Sequential Write test which will write your chosen data pattern to all blocks on the drive. Using the DMM Test Setup tab define your test step like this:
(The Blocks -1 tells DMM to write all blocks on the drive)
If you need 100% assurance that every block on the drive was indeed overwritten, simply define a second test step to run a Sequential Read test across all blocks, doing a data compare operation – like this:
If there was a block which wasn’t correctly overwritten the DMM test will mark the drive as failed and the DMM log file will look like this:
09/10/2012 12:16:42 TEST 1 of 1: Read Test; Sequential; for 1 Minutes Fixed-Length Transfers of 128 (0x0080) Blocks Start Block: 0 Data Pattern: Random; Data Compare ON Queue Depth = 1 FUA = OFF Stop-on-Error Type: Stop Current Test
09/10/2012 12:16:42 CDB = 28 00 00 00 00 00 00 00 80 00 Miscompare: LBA 0xA at 0x00000014 Exp: 41 54 47 32 65 20 20 22 94 A8 7A 55 61 74 67 52 Act: 30 30 36 32 30 4E 53 20 20 20 20 20 43 43 30 31 >>> Current Test Aborted <<<
09/10/2012 12:16:42 *** FAIL ***
If there were no data compare errors i.e. the drive was successfully completely overwritten, the DMM log file will show that the sequential read test with data compare passed.
There really isn’t any good reason to ever use a Format command. Of course if your customer asks you to format the drive, then go ahead and do it. But don’t count on that comm