linux下清除cahce

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了linux下清除cahce相关的知识,希望对你有一定的参考价值。

drop_caches文档说明

Writing to this will cause the kernel to drop clean caches, dentries and inodes from memory, causing that memory to become free.
To free pagecache:
* echo 1 > /proc/sys/vm/drop_caches

To free dentries and inodes:
* echo 2 > /proc/sys/vm/drop_caches
To free pagecache, dentries and inodes:

* echo 3 > /proc/sys/vm/drop_caches
As this is a non-destructive operation, and dirty objects are notfreeable, the user should run "sync" first in order to make sure allcached objects are freed.
This tunable was added in 2.6.16.







以上是关于linux下清除cahce的主要内容,如果未能解决你的问题,请参考以下文章

linux下清除cahce

linux下彻底清除apache2

转:Linux下随机10字符病毒的清除

在 Linux/Unix/Mac 下清除 DNS 查询缓存

Linux下清除tomcat缓存

linux下清除svn的用户名和密码