GNU/Linux Desktop Survival Guide
by Graham Williams
Blanking a Hard Disk
When data is deleted from a hard disk the actual 1's and 0's are not removed from the disk, as such. Instead the directory information about the name and location of the file is lost and the area where the file was stored is made available for overwriting by other data. This means that the original data can be recovered even though the file has been deleted (but possibly not yet overwritten).
This is great if you have accidentally deleted data and need to recover it. There exist forensic tools to do this. A technique called Magnetic Force Microscopy (MFM) allows, at a cost, the recovery of even the last two or three layers of data as written to disk! But today's hard disks are also clever in dealing with bad blocks and may unwittingly store some of your data permanently in places that no one generally has access to!
However, if you are wiping a disk for return to someone else, or never plan to use the disk again, you may want to ensure that you have completely removed any trace of your possibly confidential data from the disk. The wipe package in Debian GNU/Linux provides a tool to do this.
$ wipe -kD /dev/sdb1 $ wipe -kD /dev/sdb2
Copyright © 1995-2014 Togaware Pty Ltd