Re: How random is random?
- From: ottomeister@xxxxxxxx
- Date: 11 May 2007 13:36:42 -0700
On May 11, 12:12 pm, "Colin B." <cbi...@xxxxxxxxxxxxxxxxxxxxxxxxx>
wrote:
$ dd if=/dev/random of=<filename> bs=x count=y conv=sync.
Now assuming that we keep the filesize the same (i.e. x*y=constant),
the time to generate files goes up as count increases and bs decreases.
The interesting thing is that files created with low count and high bs...
- compress much better
- generate far fewer lines (as measured by wc -l)
Now since compress and gzip are apparently entropy-based algorithms, it
stands to reason (at least by me!) that the small-count file has less
entropy. The question is, what does this actually mean, and what are the
consequences of it?
'conv=sync' tells 'dd' that if it gets a short read from its input
then it
should pad the output record to the specified blocksize with zeroes.
/dev/random can produce short reads if its entropy pool gets depleted.
If you examine the compressible output files I expect you'll find
that
they contain lots of runs of zeroes, and those runs of zeroes are
highly compressible.
This is also the reason why the large 'bs' causes the file to be
generated more quickly.
OttoM.
__
ottomeister
Disclaimer: These are my opinions. I do not speak for my employer.
.
- Follow-Ups:
- Re: How random is random?
- From: Colin B.
- Re: How random is random?
- References:
- How random is random?
- From: Colin B.
- How random is random?
- Prev by Date: Re: Password Dictionary File/ Each Entry is 2 or 3 Words Concatenated?
- Next by Date: Re: How random is random?
- Previous by thread: How random is random?
- Next by thread: Re: How random is random?
- Index(es):
Relevant Pages
|
|