centos7.x tomcat 卡在 Deploying web application directory的解决方法
时间:2020-12-09 12:51:45 +0800 CST 浏览:1020

问题

前天在部署一个项目的时候,发现tomcat启动,总是卡在INFO: Deploying web application directory
……这个地方…

问题

前天在部署一个项目的时候,发现tomcat启动,总是卡在INFO: Deploying web application directory
……这个地方,有时候能启动成功,但是需要等待很长的时间。于是搜索了一下,发现原来是tomcat启动的时候调用了linux的一个随机数设备/dev/urandom(/dev/random)。

解决

修改$JAVA_HOME/jre/lib/security/java.security
文件,替换securerandom.source=file:/dev/random为securerandom.source=file:/dev/./urandom。不管securerandom.source的值是什么,都将其修改成securerandom.source=file:/dev/./urandom,否则不生效。



如果这篇文章对你有所帮助,可以通过下边的“打赏”功能进行小额的打赏。

本网站部分内容来源于互联网,如有侵犯版权请来信告知,我们将立即处理。


来说两句吧