码迷,mamicode.com
首页 > 系统相关 > 详细

Linux hang when password encryption

时间:2019-08-27 19:16:15      阅读:110      评论:0      收藏:0      [点我收藏+]

标签:service   emd   machine   gen   sysconf   tool   result   oge   rhel6   

When using encryption (cfglib @Secured items, dblib-disk disk encryption), the application uses SecureRandom to get random data (for key generation, etc.). In case of a virtual machine and Linux, the system entropy can be low which may result in extremely poor performance.

To avoid this, we need to enable rngd daemon (and install it first, it’s in rng-tools package).

init.d based systems (RHEL6 and older)

First try to start it:

/etc/init.d/rngd start

If it complains about entropy source (Starting rngd: can‘t open entropy source(tpm or intel/amd rng)), modify /etc/sysconfig/rngd to contain the following:

EXTRAOPTIONS="-r /dev/urandom" 

Then, start and enable rngd:

/etc/init.d/rngd start
chkconfig rngd on

 

systemd based systems (RHEL7)

First try to start it:

systemctl start rngd

 

If it complains about entropy source (can‘t open entropy source(tpm or intel/amd rng) in output of systemctl status rngd, do the following:

cp /usr/lib/systemd/system/rngd.service /etc/systemd/system

Then edit /etc/systemd/system/rngd.service ExecStart line to this:

ExecStart=/sbin/rngd -f -r /dev/urandom

 

Then, start and enable rngd:

systemctl start rngd
systemctl enable rngd

Linux hang when password encryption

标签:service   emd   machine   gen   sysconf   tool   result   oge   rhel6   

原文地址:https://www.cnblogs.com/Reclouds-shangri-la/p/11420046.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!