How to securely erase the hard disk before selling ones computer
There are times when the news sites are abuzz with sensational news items. I am speaking of those news items which tempts one to pitch in and have his/her say come what may. And the news of someone who bought a laptop on ebay only to find it defective and how he took revenge on the seller by posting all the personal data on the hard disk on a website is by now a legend.
Now it is hard to decide who is in the right here – the person who published the private data on the website (for all you know, the laptop in question could have been damaged in transit) or the seller who is now the talk of the town, whose life is being dissected. There is no way to know. But that is besides the point. The truth is that it is scary to realize that it is next to impossible to delete all the data that one stores on ones storage media without completely destroying it. Because, with the right tools anybody can retrieve even deleted data.
So what can be done to alleviate the situation ? If you are using GNU/Linux or any other UNIX, then you have a tool called shred which can be used to wipe all the data from the hard disk. Here is how it works. Suppose I want to erase all the data on my hard disk, then I boot using a LiveCD like Knoppix and open a shell and type the following command:
# shred -vfz -n 100 /dev/hda
Here /dev/hda is my whole hard disk. And I am asking shred to make (-n) 100 passes by overwriting the entire hard disk with (-z) zeros. And shred program (-f) forces the write by changing the permissions wherever necessary.
Another GPLed tool (though not specifically related to Linux) which is quite popular is Darik’s Boot and Nuke (DBAN) which also does a swell job of wiping ones hard disk.
It is claimed that experts in the field of retrieving data can still get some data from a hard disk that has been wiped in the above manner. But atleast lesser mortals who buy second hand laptops and computers will find it beyond their means to lay their hands on the data.
All about Linux: How to securely erase the hard disk before selling ones computer