3 ms·
The author mentions that removed files stick around on disk after being removed, and that this can increase the size of a compressed bit-for-bit copy. They the
by Yen 13y ago
The author mentions that removed files stick around on disk after being removed, and that this can increase the size of a compressed bit-for-bit copy.
They then suggest you can mitigate this by writing zeros to a file before rm'ing it. However, this is slow in the general case, and doesn't help if you've already rm'd the file.
As an alternative, the 'sfree' utility, available in the debian package 'secure-delete', can be used to fill the unallocated portions of a disk with zeroes (or random data).
sfree -llz <disk device>
will write zeroes to the free areas of a disk. -ll limits it to only one pass over the disk, and -z makes that pass write zeroes, instead of random data.
man page: http://manpages.ubuntu.com/manpages/lucid/man1/sfill.1.html http://manpages.ubuntu.com/manpages/lucid/man1/sfill.1.html
- allgood38 13y agoThis is a pretty cool utility, I never really did like just creating a blank file, I'd rather use an explicit tool I'll update the article.