Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Securely wiping NVMe SSD drives using Linux (Ubuntu/Debian shown but others are supported)

In order to securely wipe an NVME drive you can use the nvme-cli package that provides the nvme command nvme only exists in the root path so you have to use sudo nvme.

For Debian you need to add jessie-backports (on jessie) and it may be in the newer version default repos. For Ubuntu it should be available in the default repos from Xenial onwards, there may be a PPA if you need it on earlier versions.

You can find your devices with sudo nvme list and securely format with sudo nvme /dev/nvme0n1 --ses=1. You can also explicitly add a namespace but I haven't seen or setup a drive with multiple yet.

Soon I'd like to make an extremely tiny netbootable image with Alpine or Debian to boot with as pulling down the Debian LiveCD and adding the extra repository just to run a couple commands was overkill.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.