在docker安装tomcat的时候,报错:Caused by: java.lang.IllegalArgumentException: The AJP Connector is configured with secretRequired="true


  初识docker,试着在docker中安装tomcat(安装的tomcat8.5),并且挂载到宿主机的相关目录下,结果启动的时候报错:

12-May-2020 01:14:34.061 SEVERE [main] org.apache.catalina.core.StandardService.startInternal Failed to start connector [Connector[AJP/1.3-8009]]
	org.apache.catalina.LifecycleException: Protocol handler start failed
		at org.apache.catalina.connector.Connector.startInternal(Connector.java:1085)
		at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
		at org.apache.catalina.core.StandardService.startInternal(StandardService.java:440)
		at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
		at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:766)
		at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
		at org.apache.catalina.startup.Catalina.start(Catalina.java:688)
		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.start(Bootstrap.java:343)
		at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:474)
	Caused by: java.lang.IllegalArgumentException: The AJP Connector is configured with secretRequired="true" but the secret attribute is either null or "". This combination is not valid.
		at org.apache.coyote.ajp.AbstractAjpProtocol.start(AbstractAjpProtocol.java:274)
		at org.apache.catalina.connector.Connector.startInternal(Connector.java:1083)
		... 12 more
22-May-2020 01:14:34.062 INFO [main] org.apache.catalina.startup.Catalina.start Server startup in 124 ms

  查阅资料,发现了8.5版本的tomcat的sever.xml中有个属性 secretRequired需要给设置值

<Connector port="8009" protocol="AJP/1.3" redirectPort="8443" />

设置成""就可以了,也就是下面的设置结果:

<Connector port="8009" protocol="AJP/1.3" redirectPort="8443" secretRequired="" />

  然后重新启动docer中的tomcat,发现启动成功了,大功告成!

 


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



猜您在找 Caused by: java.lang.IllegalArgumentException springboot整合mybatis的时候报错Caused by: java.lang.IllegalArgumentException: Property 'sqlSessionFactory' or 'sqlSessionTemplate' are required java.lang.IllegalArgumentException: Expected MultipartHttpServletRequest: is a MultipartResolver configured? tomcat报错java.lang.IllegalArgumentException: Document base XXXXX does not exist or is not a readable directory 解决kylin报错:Failed to create dictionary on ., Caused by: java.lang.IllegalArgumentException: Too high cardinality is not suitable for dictionary java.lang.illegalArgumentException异常 java.lang.IllegalArgumentException: null Caused by: java.lang.IllegalArgumentException: Invalid [studentServlet] in servlet mapping Caused by: java.lang.IllegalArgumentException: DefaultSerializer requires a Serializable payload but received an object of type [VCodeModel] SpringBoot启动报:Caused by: java.lang.IllegalArgumentException: At least one JPA metamodel must be present!
 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM