If a disk contains secure information, it may need to be securely erased.
This article outlines a simple disk-wipe procedure for the Linux command line. Tested on Ubuntu 16.04.
Determine the Target Drive
To find the drive, run the
lsblk command. This will output drive name and mount point:
Determine the relevant disk name from this list.
Double Check: Avoid Foot-Shooting
When you run the
dd command in the “Wipe the Disk” section of this article, the target disk will be completely overwritten.
You should therefore double check that you’re operating on the right drive:
The output should correspond to the target disk you’re expecting to wipe.
Wipe the Disk
This is achieved by writing random data from
/dev/urandom to the target disk.
Block size is set to 1M for the sake of increasing speed -
dd will read and write up to 1M bytes at a time.
Setting the status option to “progress” prints periodic transfer stats to stderr.
comments powered by Disqus