1、CDH 踩坑之:熵不足

解决过程:
1.查看系统当前的熵:发现确实很少

  1. [root@wjltony ~]#cat /proc/sys/kernel/random/entropy_avail
  2. 20

2.查看管理熵的工具是否启动

  1. [root@wjltony ~]# systemctl status rngd
  2. Unit rngd.service could not be found.

3.安装管理工具rng-tools

  1. [root@wjltony ~]# yum install -y rng-tools

4.启动rngd服务

  1. [root@wjltony ~]# systemctl start rngd
  2. [root@wjltony ~]# systemctl status rngd
  3. rngd.service - Hardware RNG Entropy Gatherer Daemon
  4. Loaded: loaded (/usr/lib/systemd/system/rngd.service; enabled; vendor preset: enabled)
  5. Active: active (running) since Tue 2019-05-21 06:28:08 CST; 1 months 26 days ago
  6. Main PID: 782 (rngd)
  7. CGroup: /system.slice/rngd.service
  8. └─782 /sbin/rngd -f
  9. May 21 06:28:08 wjltony systemd[1]: Started Hardware RNG Entropy Gatherer Daemon.
  10. May 21 06:28:08 wjltony systemd[1]: Starting Hardware RNG Entropy Gatherer Daemon...
  11. May 21 06:28:08 wjltony rngd[782]: read error
  12. May 21 06:28:08 wjltony rngd[782]: hwrng: no available rng
  13. May 21 06:28:08 wjltony rngd[782]: Unable to open file: /dev/tpm0

5.查看熵

  1. [root@wjltony~]# cat /proc/sys/kernel/random/entropy_avail
  2. 3834

6.过1分钟后再看 CDH已经不告警了。