* Allen S. Rout <[log in to unmask]> [2007-08-06 08:51:13 -0400]:
> So, for debugging purposes (long story) I want to create a couple of
> files which are precisely
$ dd if=/dev/urandom of=foo bs=1k count=1018368
Ran on my FreeBSD desktop...I'm sure the Linux version is similar, if
not identical. Took about 46 seconds (wall clock) on my Pentium D
3.00GHz with 2 GiB RAM.
> Of course, doing this with /dev/random takes a while. :)
Use /dev/urandom if you can. /dev/random gives out 100% random bits, but
it takes a while to generate the entropy needed for this randomness,
hence the slowness. /dev/urandom gets some random bits from /dev/random,
but then uses it to seed more random numbers. They are not as "high
quality" randomness as /dev/random, but you get bits out *much* faster.
/dev/random = slow, very random
/dev/urandom = fast, not so random
Choose whichever is more appropriate for your application.