標題: [介紹] Linux 釋放記憶體的方法 - CentOS 清除 cache [打印本頁]
作者: girl 時間: 2012-4-13 16:32 標題: Linux 釋放記憶體的方法 - CentOS 清除 cache
有時後當某些程式執行完時...會發現執時期間所使用的記憶體竟然沒釋放or清除...
這時就可以執行以下指令釋放記憶體了
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"
如果選第三種...就可以完成整個清除動作了~~
歡迎光臨 ADJ網路實驗室 (http://dz.adj.idv.tw/) |
Powered by Discuz! 6.0.0 |