jenkins war 采用tomcat 启动空白页问题

一、问题(1)

1、centos7 安装jenkins ,tomcat9, jenkisn.war 

2、启动tomcat后,输入密码后一直卡在一个页面那里

3、排查原因:看日志发现了一段:

04-Mar-2020 21:31:33.020 WARNING [Handling GET /jenkins/login from 192.168.1xx.xx : http-nio-8080-exec-2 Jenkins/login.jelly] org.apache.catalina.webresources.Cache.getResource Unable to add the resource at [/WEB-INF/side-files/hudson/model/Descriptor/index.html] to the cache for web application [/jenkins] because there was insufficient free space available after evicting expired cache entries - consider increasing the maximum size of the cache

然后定位到了tomcat的配置文件context.xml,路径一般在:apache-tomcat-xxx\conf\context.xml,默认只有10M的大小.,cacheMaxSize的单位是kb。

4、解决:在Context中添加<Resources cachingAllowed="true" cacheMaxSize="150000" ></Resources>

二、问题(2)

war包tomcat运行的qing情况下,如果问题(1)已经处理,还是在空白页,则进行一下操作,浏览器另外开一个tab窗口,访问:

http://192.168.1xx.1xx:8080/jenkins/pluginManager/advanced,找到Update Site,然后修改url为:https://mirrors.tuna.tsinghua.edu.cn/jenkins/updates/update-center.json,提交。

最后重启tomcat。

参考:【1】https://www.jianshu.com/p/1e411d225186

 

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章