关于tomcat启动卡在INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory D...

启动tomcat的时候卡在了

25-Jan-2019 16:26:15.269 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.io.tmpdir=/usr/local/tomcat/temp
25-Jan-2019 16:26:15.269 INFO [main] org.apache.catalina.core.AprLifecycleListener.lifecycleEvent The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java
.library.path: /usr/java/packages/lib/amd64:/usr/lib64:/lib64:/lib:/usr/lib25-Jan-2019 16:26:15.549 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-8080"]
25-Jan-2019 16:26:15.560 INFO [main] org.apache.tomcat.util.net.NioSelectorPool.getSharedSelector Using a shared selector for servlet write/read
25-Jan-2019 16:26:15.587 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["ajp-nio-8009"]
25-Jan-2019 16:26:15.588 INFO [main] org.apache.tomcat.util.net.NioSelectorPool.getSharedSelector Using a shared selector for servlet write/read
25-Jan-2019 16:26:15.600 INFO [main] org.apache.catalina.startup.Catalina.load Initialization processed in 1046 ms
25-Jan-2019 16:26:15.657 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service Catalina
25-Jan-2019 16:26:15.658 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet Engine: Apache Tomcat/8.0.50
25-Jan-2019 16:26:15.670 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deploying web application directory /usr/local/tomcat/webapps/ROOT

后经过查询,找到解决方案:

cd /usr/local/java/jre/lib/security/
vim java.security

修改内容:

securerandom.source=file:/dev/urandom
#securerandom.source=file:/dev/random

设置之后可以正常启动

参考文章:https://blog.csdn.net/njchenyi/article/details/46641141
感谢njchenyi

你可能感兴趣的:(关于tomcat启动卡在INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory D...)