LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 06-28-2005, 06:34 PM   #1
sausagejohnson
Member
 
Registered: Mar 2004
Location: Canberra Area, Australia
Distribution: Kubuntu
Posts: 242

Rep: Reputation: 30
Deleting unused harddisk blocks


I came across an interesting tidbit regarding erasing the sections of your harddisk that are unused. The command is:

dd if=/dev/zero of=/tmp/deleteme bs=8M
rm /tmp/deleteme

Does this work because it is getting 0's and writing a large file of 0's by choosing sections of the harddisk that are marked as unused, effectively filling up the entire harddisk before you delete the file?

Am I reading this right?
 
Old 06-28-2005, 11:41 PM   #2
Noth
Member
 
Registered: Jun 2005
Distribution: Debian
Posts: 356

Rep: Reputation: 30
Pretty much. But to be useful you would have to do it at least a half-dozen times, overwriting data on a hard disk once isn't enough to make it non-recoverable.
 
Old 06-29-2005, 12:27 AM   #3
sausagejohnson
Member
 
Registered: Mar 2004
Location: Canberra Area, Australia
Distribution: Kubuntu
Posts: 242

Original Poster
Rep: Reputation: 30
Why isn't once enough? I can't see any technical reason why.

After running over each partition, I managed to get the 80GB drive down to just 118MB. Much better than I could have hoped for.
 
Old 06-29-2005, 12:32 AM   #4
Noth
Member
 
Registered: Jun 2005
Distribution: Debian
Posts: 356

Rep: Reputation: 30
Quote:
Originally posted by sausagejohnson
Why isn't once enough? I can't see any technical reason why.
Because of the physical properties of the platters, even after you've overwritten data once or twice the original data can still be read in a clean room with the proper equipment.
 
Old 06-29-2005, 01:04 AM   #5
Matir
LQ Guru
 
Registered: Nov 2004
Location: San Jose, CA
Distribution: Debian, Arch
Posts: 8,507

Rep: Reputation: 128Reputation: 128
I don't know that 'zeroing' blocks can reduce blocks in use, as the original poster seemed to suggest.

Noth: you are correct, it COULD still be read, but only by someone who has a LOT of money to spend on reading it. For your average user, even a single overwrite is plenty. A single overwrite will make it impossible for any software tool to recover data from the overwritten blocks.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
read blocks directly from the harddisk Gregory Programming 1 12-20-2017 03:54 AM
amavisd unused ?? Wynand1 SUSE / openSUSE 0 09-22-2005 07:50 AM
Deleting unused space from a partition Tsukasa7 Linux - Newbie 2 08-31-2005 02:05 PM
Removing unused packages objorkum Debian 2 04-05-2005 08:32 PM
Low Harddisk space. Can I just transfer the entire Linux to a bigger harddisk? davidas Linux - Newbie 12 04-13-2004 02:03 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 09:38 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration