difference between mount point and physical drive?
Michael George
yellowdog-general@lists.terrasoftsolutions.com
Fri Oct 25 13:47:01 2002
I don't think I was clear enough. You are right, there will be no=20
catastrophic outcomes, however if there are exactly xMb of space and=20
you start off dd writing xMb of zeros to the disk, then any increase in=20=
the used space on the disk will cause dd to kick a "filesystem full"=20
error condition.
This will be a minor problem, as the dd will stop and you will have all=20=
the free space (up to xMb) filled with 0's.
At one time it would be dangerous to do this on /, as the system would=20=
panic if the / partition filled up. Lately, though, there is root=20
space reserved on every partition to avert such issues. That's IIRC,=20
which doesn't always happen.
This is all pedantic, of course, and mostly for the education of=20
newcomers to unix. I like the idea first presented (dd of 0's and then=20=
bzip2 it), I had never thought of that before.
Happy Hacking!
-Michael
On Friday, October 25, 2002, at 03:12 PM, Tim Seufert wrote:
> On Friday, October 25, 2002, at 11:49 AM, Michael George wrote:
>
>>
>> On Friday, October 25, 2002, at 02:37 PM, Albrecht Dre=DF wrote:
>>
>>> Am 25.10.02 19:45:05 schrieb(en) Stephen Lewis:
>>>> Sometimes it is faster than reading the
>>>> filesystem, but because it copies empty
>>>> blocks also it might be slower too. If your
>>>
>>> It's sometimes nice to burn complete partitions compressed on a=20
>>> cd/dvd. To avoid that you have random data on the unused space, you=20=
>>> can use e.g.
>>>
>>> dd if=3D/dev/zero of=3Dzerofile bs=3D1M count=3D1
>>
>> This will fill the disk with data (even if it is all 0's). I am=20
>> guessing that one would want to make sure that nothing else is=20
>> writing to the partition and you don't want to do this to your /=20
>> partition (which would be a bad idea anyhow)?
>
> Doesn't matter whether anything else is writing to the partition, and=20=
> it's perfectly safe to do it to the root FS. He's using dd to=20
> generate a regular file (named "zerofile"), not to write directly on a=20=
> partition. The idea is simply to create a file occupying all the free=20=
> space on the target FS, filling it with 0 rather than the leftover=20
> random contents from old file deletes. Later on, gzip will get=20
> enormous compression ratios on the long strings of zeroes this=20
> generates, dramatically reducing the size of the partition image if=20
> there is much free space on the partition.
>
> _______________________________________________
> yellowdog-general mailing list
> yellowdog-general@lists.terrasoftsolutions.com
> http://lists.terrasoftsolutions.com/mailman/listinfo/yellowdog-general
>
>