Tomcat 内存使用量在 IDLE 中增长 [英] Tomcat memory usage grows in IDLE

查看:76
本文介绍了Tomcat 内存使用量在 IDLE 中增长的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在 Tomcat 上不断增加内存消耗的问题.在启动之后什么也没有发生,但是如果有用户登录,在 Edem 中内存使用量开始增长之后.PermGen 不会增长,但无论如何,它是不正常的.

I have problem with growing memory consuming on Tomcat. Just after start nothing happens,but if some user login, after this memory usage start growing in Edem. PermGen does not grow, but anyway, it anormal.

我的分析表明线程 RMI TCP Connection 产生了很多 Object[] char[] 和 String[] 对象.我不明白出了什么问题以及在哪里挖掘.谁启动了这个线程,是 postgres 连接,这是什么?

My analyze shows that thread RMI TCP Connection produces lot of Object[] char[] and String[] objects. I can not understand what's wrong and where to dig. Who starts this thread, is is postgres connections and what is this?

推荐答案

这是正常现象,不是内存泄漏.对象由用于管理应用程序的线程不断创建和销毁.您会看到内存在增加,因为 JVM 垃圾收集器并没有急切地回收未使用的内存.这会定期发生(基于之前的统计数据)或在内存不足时发生.如果这是真正的内存泄漏,您将不会看到 Eden 内存使用量在收集后下降到几乎为零.内存泄漏显示为最低点(就在 GC 之后)随时间增加.

This is normal, and is NOT a memory leak. Objects are created and destroyed constantly by the threads used to manage the application. You see the memory increasing because the JVM garbage collector is not eagerly reclaiming unused memory. This happens periodically (based on previous statistics) or when memory is running low. If it were a real memory leak, you would not see the Eden memory usage drop down to almost zero after a collection. A memory leak is shown as the lowest point (right after a GC) increasing over time.

这篇关于Tomcat 内存使用量在 IDLE 中增长的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆