os/linux/ SecurityStuff


Erasing an SSD

These steps must be performed as root, where $device is your device, e.g. /dev/sda

  1. hdparm -I $device and check device:
    1. not frozen
      1. if frozen, suspend/sleep and then wake (if running ubuntu live cd, make a note of the username, e.g. ubuntu-studio, before this so that you can unlock)
    2. supports enhanced erase
  2. Set user password: hdparm --user-master u --security-set-pass MrFlibble $device
  3. Security erase: hdparm --user-master u --security-erase MrFlibble $device
  4. Check drive status hdparm -I $device, should be not locked

(Summarised from https://www.thomas-krenn.com/en/wiki/SSD_Secure_Erase)