无法使用 BoundsChecker 检测内存问题
最近我们观察到我们的应用程序服务器内存随着一些客户端 API 的增加而增加,最终导致崩溃。
所以我们尝试使用boundschecker,它显示没有内存泄漏,并随着内存增加(私有字节增加)而导致崩溃。在 MS(sysinternals) 的 Process Explore 中得到验证。
那么有什么方法可以获取内存如何按顺序分配(函数调用),或如何按顺序分配句柄。所以我们可以得到这个位置的内存正在增加。
我们想要捕获来自所有线程的所有函数调用。我们也不能更改太多代码,因为它有数千行代码。
recently we observed that our application server memory is increasing with some client API, in the end it leads to crash.
so we tried using boundschecker and it shows NO memory leak and leads to crash as memory is increasing ( private bytes are increasing ). verified in Process Explore of MS(sysinternals).
so is there any way to get how memory is allocated in sequence (function calls), or handle allocated in sequence. so we can get memory is increasing at this position.
we wants to capture all function calls from all threads. also we can't chnage too much code as it is thousnads lines of code.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
如果您找不到任何内存泄漏,则很可能存在句柄泄漏 - 您甚至可以在任务管理器中通过选择列列表中的“句柄计数”来检查这一点。 Process Explorer 应该能够向您显示应用程序中打开的句柄列表。这可能不是按顺序排列的,但它应该让您了解哪种资源正在泄漏 - 通常,所有泄漏都源自应用程序的同一区域,随着时间的推移,这些泄漏可能会累积并导致崩溃。
If you can't find any memory leak, it's very likely that you have a handle leak - you can check this even in Task Manager by selecting "Handle Count" in the list of columns. Process Explorer should be able to show you a list of open handles in your application. This may not be in sequence but it should give you an idea of what kind of resource is leaking - often, all the leaks originate from the same area of your application, which can accumulate over time and cause a crash.