主题:[讨论]观察到一个内存持续消耗/泄露?的问题 共有31858人关注过本帖 |
---|
lgz |
1楼 信息 | 搜索 | 邮箱 |
加好友 发短信 员工 |
Post By:2017-2-27 11:40:00 [显示全部帖子]
你好,这是并不是内存泄露,这是linux的disk canche机制,linux会将文件在内存中进行缓存,已加快文件(存储设备)读写,并不影响程序运行
|
单帖管理 | 引用 | 回复 |
lgz |
2楼 信息 | 搜索 | 邮箱 |
加好友 发短信 员工 |
Post By:2017-2-27 12:52:00 [显示全部帖子]
怎么影响了,这个机制不会影响程序获取内存空间
|
单帖管理 | 引用 | 回复 |
lgz |
3楼 信息 | 搜索 | 邮箱 |
加好友 发短信 员工 |
Post By:2017-2-27 15:15:00 [显示全部帖子]
This file is not a means to control the growth of the various kernel caches (inodes, dentries, pagecache, etc...) These objects are automatically reclaimed by the kernel when memory is needed elsewhere on the system. Use of this file can cause performance problems. Since it discards cached objects, it may cost a significant amount of I/O and CPU to recreate the dropped objects, especially if they were under heavy use. Because of this, use outside of a testing or debugging environment is not recommended. 上面是内核文档片段,不建议修改与caches相关的设置,随意修改反倒会影响系统性能,这些caches不会影响到你的程序的运行的 |
单帖管理 | 引用 | 回复 |