您好我已经在Windows上配置了tomcat Server而没有任何安全性,它开始运行良好。
当我将其迁移到具有SSL安全性的Linux服务器时,我重新配置为SSL安全性,但它始终给出了以下错误:
06-Oct-2017 10:45:34.858 SEVERE [main] org.apache.coyote.AbstractProtocol.init Failed to initialize end point associated with ProtocolHandler ["https-jsse-nio-443"]
java.net.SocketException: Permission denied
at sun.nio.ch.Net.bind0(Native Method)
at sun.nio.ch.Net.bind(Net.java:433)
at sun.nio.ch.Net.bind(Net.java:425)
at sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:223)
at sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:74)
at org.apache.tomcat.util.net.NioEndpoint.bind(NioEndpoint.java:210)
at org.apache.tomcat.util.net.AbstractEndpoint.init(AbstractEndpoint.java:982)
at org.apache.tomcat.util.net.AbstractJsseEndpoint.init(AbstractJsseEndpoint.java:244)
at org.apache.coyote.AbstractProtocol.init(AbstractProtocol.java:620)
at org.apache.coyote.http11.AbstractHttp11Protocol.init(AbstractHttp11Protocol.java:66)
at org.apache.catalina.connector.Connector.initInternal(Connector.java:997)
at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:107)
at org.apache.catalina.core.StandardService.initInternal(StandardService.java:549)
at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:107)
at org.apache.catalina.core.StandardServer.initInternal(StandardServer.java:875)
at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:107)
at org.apache.catalina.startup.Catalina.load(Catalina.java:607)
at org.apache.catalina.startup.Catalina.load(Catalina.java:630)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.apache.catalina.startup.Bootstrap.load(Bootstrap.java:311)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:494)
这是我的服务器配置:
<Connector port="443" maxHttpHeaderSize="8192"
maxThreads="100" minSpareThreads="25" maxSpareThreads="50"
enableLookups="true" disableUploadTimeout="true"
acceptCount="50" scheme="https" secure="true"
URIEncoding="UTF-8"
connectionTimeout="20000"
SSLEnabled="true"
SSLPassword="hasanpass"
keystorePass="hasanpass"
SSLCertificateFile="/usr/local/tomcat/crypto/hasan1.crt"
SSLCertificateKeyFile="/usr/local/tomcat/crypto/hasan.key"/>
答案 0 :(得分:1)
我有同样的问题。我提到Starting Tomcat Failed to initialize end point associated with ProtocolHandler但没有成功。先尝试一下。如果没有这样做。
我在Ubuntu上运行了tomcat,其中一个用户具有root权限。最初我运行了正常的命令./startup.sh
,我得到了此权限被拒绝的异常。然后我跑了sudo ./startup.sh
并且它运作了。
希望它有所帮助!!!