tomcat报warinigUnable to add the resource at [] to the cache

tomcat报warinig Unable to add the resource at [] to the cache 线下用的tomcat7.07,线上用了 tomcat8.5.4,就出了这个 (1)[ContainerBackgroundProcessor[StandardEngine[Catalina]]]org.apache.catalina.webresourcesXache.getResource Unable to add the resource at [/WEBINF/lib/libsigar-x86-linux.so] to the cache because there was insufficient free space available after evicting expired cache entries - consider increasing the maximum size of the cache (2) [ContainerBackgroundProcessor[StandardEr»gine[Catalina]]] org.apache.catalina.webresourcesXache.backgroundProcess The background cache eviction process was unable to free [10] percent of the cache for Context [] - consider increasing the maximum size of the cache. After eviction approximately 110,228] KB of data remained in the cache。 waring信息大致的意思就是不能给资源加cache了,因为没有足够的可用空间了。 原来 tomcat8中增加了静态资源缓存的配置 以下是两个相关参数说明: cacheMaxSize:静态资源缓存最大值,以KB为单位,默认值为10240KB The maximum size of the static resource cache in kilobytes. If not specified, the default value is 10240 (10 megabytes). This value may be changed while the web application is running (e.g. via JMX). If the cache is using more memory than the new limit the cache will attempt to reduce in size over time to meet the new limit. If necessary, cacheObjectMaxSize will be reduced to ensure that it is no larger thancacheMaxSize/20. cachingAllowed:是否允许静态资源缓存,默认为true If the value of this flag is true, the cache for static resources will be used. If not specified, the default value of the flag is true. This value may be changed while the web application is running (e.g. via JMX). When the cache is disabled any resources currently in the cache are cleared from the cache. 对应两个参数,解决方法有两种, 1:考虑增加cache的最大大小 2:关闭缓存v 办法1: 增大缓存 在 conf/context.xml中加入:

方法2: 关闭cache 在 conf/context.xml中加入:

我这里有一个大牛交流群,里面每天更新新的视频新的技术,群里有阿里大牛直播讲解技术,以及Java大型互联网技术的视频免费分享给大家。如果想学习Java工程化、高性能及分布式、深入浅出。性能调优、Spring,MyBatis,Netty源码分析的朋友可以加Java进阶群:454377428,群里有阿里大牛直播讲解技术,以及Java大型互联网技术的视频免费分享给大家

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值