tomcat 8.0 升级 9.0,启动报错Protocol handler start failed

武平宁 / 2024-08-27 / 原文

  1. 关键日志如下:
    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.

  2. 检索文档
    在 apache-tomcat-9.0.93/webapps/docs/changelog.html 文档中看到 "secretRequired that defaults to true."
    说明在之前版本,默认值为false

  3. 修改 server.xml 配置
    <Connector port="8071" protocol="AJP/1.3" redirectPort="8448" secretRequired="false" />

  4. 重启服务
    验证成功。