$random with seed parameter

In reply to sush:

You should not supply a seed argument; just use $urandom;. By providing a seed, you are re-initializing the random number generate with the same initial value each time it is called.

Please read section 18.14 in the 1800-2017 LRM