Need some random data quickly?
dd if=/dev/urandom count=1024 bs=1 | base64
Need it to be in a particular subset of characters?
dd if=/dev/urandom count=1024 bs=1 |tr -dc 'A-Za-z0-9'
Note: if you're on a mac, its tr is kind of broken. Do export LC_ALL=C first.