Whats your test / burn in processes for new disks

Before trusting a new or repurposed drive with my data, or secure erasing used disks, I perform the following steps:

  1. smartctl to create a baseline
  2. shred one-pass with random data
  3. badblocks alternating four write passes with four read verification passes
  4. blkdiscard for full disk trim on SSD
  5. smartctl to compare with baseline

NOTE: Command badblocks defaults to a 1024 byte block size limiting it to 4 TB disks. Increasing the block size from 1024 bytes to 1048576 bytes (1 MB) allows very large disks. Using the default block size with an 8 TB disk throws the following error:
badblocks: Value too large for defined data type invalid end block (7814026584): must be 32-bit value

sudo smartctl -x /dev/sdX ; date -Iseconds
sudo bash -c 'device=sdX && time shred -n1 /dev/$device && time badblocks -b 1048576 -wvs /dev/$device && time blkdiscard -v /dev/$device ; date -Iseconds'
sudo smartctl -x /dev/sdX ; date -Iseconds
2 Likes