Press "Enter" to skip to content

解决OSError: [Errno 2] No such file or directory: ‘/dev/urandom’

最近自己的CentOS6在yum update以后,所有的yum命令都会遭遇如下错误

Traceback (most recent call last):
  File "/usr/bin/yum", line 4, in 
    import yum
  File "/usr/lib/python2.6/site-packages/yum/", line 46, in 
    import tempfile
  File "/usr/lib/python2.6/", line 34, in 
    from random import Random as _Random
  File "/usr/lib/python2.6/", line 873, in 
    _inst = Random()
  File "/usr/lib/python2.6/", line 96, in __init__
  File "/usr/lib/python2.6/", line 110, in seed
    a = long(_hexlify(_urandom(16)), 16)
OSError: [Errno 2] No such file or directory: '/dev/urandom'


mknod -m 644 /dev/urandom c 1 9

One Comment

  1. 大发 2013-06-16


Leave a Reply

Your email address will not be published. Required fields are marked *