Tomcat启动时Creation of SecureRandom instance for session ID很慢

Posted youbowen

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Tomcat启动时Creation of SecureRandom instance for session ID很慢相关的知识,希望对你有一定的参考价值。

启动tomcat很慢,检查后发现:
[localhost-startStop-1]
org.apache.catalina.util.SessionIdGeneratorBase.createSecureRandom Creation of SecureRandom instance for session ID generation using [SHA1PRNG] took [131,830] milliseconds。

主要时间都花在Creation of SecureRandom instance上了

解决办法:

先检查$JAVA_HOME/jre/lib/security/java.security中用的file:/dev/./random!是否前面少了个u!!如果是,改成file:/dev/urandom后,重启tomcat,sucess。




以上是关于Tomcat启动时Creation of SecureRandom instance for session ID很慢的主要内容,如果未能解决你的问题,请参考以下文章

tomcat启动慢,Creation of SecureRandom instance for session ID generation using [SHA1PRNG]took [xx] ms

tomcat启动慢,Creation of SecureRandom instance for session ID generation using [SHA1PRNG]took [xx] ms

tomcat启动慢,Creation of SecureRandom instance for session ID generation using [SHA1PRNG]took [xx] ms(代

tomcat启动慢, Creation of SecureRandom instance for session ID generation using [SHA1PRNG]took [xx] mil

Creation of SecureRandom instance for session ID generation using [SHA1PRNG] took [32,176] milliseco

重启tomcat后,访问登陆接口响应慢--Creation of SecureRandom instance for session ID generation using [SHA1PRNG] to