Jump to content

Free Space wiping


tf1
 Share

Recommended Posts

You can get Eraser 5.7 for free, and this will erase the free space on a drive whilst the operating system is booted. It also comes with the boot and nuke disk that you mentioned above, but the main prog is a gui in Windows.

 

Download here:

 

http://www.heidi.ie/eraser/

Link to comment
Share on other sites

I can think of ways to do it from the command line. Depending on how thorough you want to be, and assumming the mount point of the partition you want to have the free space cleaned on is /mnt/hda1, you could run as root with the partitiion mounted:

 

# dd if=/dev/urandom of=/mnt/hda1/cleanup
# sync
# rm -f /mnt/hda1/cleanup
# sync
# dd if=/dev/zero of=/mnt/hda1/cleanup
# sync
# rm -f /mnt/hda1/cleanup
#sync

 

What this should do is fill up all the free space on the partition with random data, delete it, fill up that space with zeroes and delete it again. This will clean things up pretty securely, but the main caveat is with journalling filesystems like reiserfs or ext3, there may still be recoverable info about what was on the drive prior to deletion.

Link to comment
Share on other sites

I suppose if you do have a journaling partition, you could always replace with ext2 and then do the data wipe. I guess that would help get rid of the problem with journaling letting you recover later :unsure:

 

But worth a shot perhaps :D

Link to comment
Share on other sites

Re ramfree's question on why mounted:

 

The method I gave is for wiping only the free space on the partition, leaving the data on the partition intact. It just fills up the empty space on the partition with random junk, deletes it, fills it up with zeroes and deletes it. Whether this is effective with a journalled filesystem, I can't say. You could adopt the same method to wipe the entire partition:

 

# dd if=/dev/urandom of=/dev/hda1

# dd if=/dev/zero of=/dev/hda1

 

or the entire drive:

 

# dd if=/dev/urandom of=/dev/hda

# dd if=/dev/zero of=/dev/hda

 

In either of these cases, the partition/drive would not be mounted. If you just want to cleanup the free space on the partition, however, I think you would have to mount the partition to create and write a file on the partition which will occupy all the free space and then delete it.

Link to comment
Share on other sites

If you just want to cleanup the free space on the partition, however, I think you would have to mount the partition to create and write a file on the partition which will occupy all the free space and then delete it.

If you then switch a journaling file system for a non journaling then repeat the journal will also be destroyed.

Link to comment
Share on other sites

I can think of ways to do it from the command line. Depending on how thorough you want to be, and assumming the mount point of the partition you want to have the free space cleaned on is /mnt/hda1, you could run as root with the partitiion mounted:

 

# dd if=/dev/urandom of=/mnt/hda1/cleanup
# sync
# rm -f /mnt/hda1/cleanup
# sync
# dd if=/dev/zero of=/mnt/hda1/cleanup
# sync
# rm -f /mnt/hda1/cleanup
#sync

 

What this should do is fill up all the free space on the partition with random data, delete it, fill up that space with zeroes and delete it again. This will clean things up pretty securely, but the main caveat is with journalling filesystems like reiserfs or ext3, there may still be recoverable info about what was on the drive prior to deletion.

 

Why is my computer telling me

 dd: opening `/mnt/hda1/cleanup': No such file or directory

when I run that as root? I tried it with and without a directory called cleanup.

Edited by eyeh8windows
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...