发布一个hudson的时候tomcat报错,查看日志如下
严重: Servlet.service() for servlet [HTMLManager] in context with path [/manager] threw exception
java.lang.IllegalStateException: org.apache.tomcat.util.http.fileupload.FileUploadBase$SizeLimitExceededException: the request was rejected because its size (61021239) exceeds the configured maximum (52428800)
看到是发布的war包超过了tomcat设置的值,
修改下最大文件大小,重启即可
tomcat/webapps/manager/WEB-INF/web.xml
找到
<multipart-config>
<!-- 50MB max -->
<max-file-size>52428800</max-file-size>
<max-request-size>52428800</max-request-size>
<file-size-threshold>0</file-size-threshold>
</multipart-config>
</servlet>
<servlet>
修改为
<!-- 100MB max -->
<max-file-size>524288000</max-file-size>
<max-request-size>524288000</max-request-size>
<file-size-threshold>0</file-size-threshold>
</multipart-config>
最后别忘记重新启动tomcat。
修改tomcat 发布war大小限制
Tomcat部署异常解决
最新推荐文章于 2021-08-10 17:24:43 发布
本文介绍了一种在使用Hudson进行部署时遇到的Tomcat错误,并详细解释了解决该问题的具体步骤,包括调整Tomcat中文件上传的最大尺寸限制。

5273

被折叠的 条评论
为什么被折叠?



