安装 软件包 .
要检查是否需要 Haveged, 使用下面命令查看当前收集到的熵:
# cat /proc/sys/kernel/random/entropy_avail
如果结果比较低 (<1000)，建议安装 haveged. 否则加密程序会等待系统有足够的熵。例如如果使用 软件热点，网速会比较慢。
安装 haveged 之后，可以再次查看系统熵看下有无提升。
Unless you have a specific reason to not trust any hardware random number generator on your system, you should try to use them with the rng-tools first and if it turns out not to be enough (or if you do not have a hardware random number generator available), then use Haveged.
As discussed at Is it appropriate to use haveged as a source of entropy on virtual machines?, it can be contested whether haveged provides quality entropy within a virtual environment. Haveged relies on the rdtsc instruction, which may be virtualized within a virtual machine resulting in lower quantity entropy. On some hypervisors, it is possible to disable the virtualization of rdtsc, which would in theory allow haveged to provide higher quality entropy.
To disable the virtualization of the rdtsc instruction in VMware ESXi, add the setting
monitor_control.virtual_rdtsc = "FALSE" to the virtual machine’s .vmx configuration file. VMware recommends the setting for use when performing measurements that require a precise source of real time in the virtual machine.