您现在的位置:主页 > 技术中心 > 操作系统 > Linux

clear Linux memory cache

来源:网络 责任编辑:admin 发表时间:2013-07-01 22:34 点击:

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 not freeable, the user should run "sync" first in order to make sure all cached objects are freed.

Reference:

http://www.linuxinsight.com/proc_sys_vm_drop_caches.html

作者“梦的脚印”

    相关新闻>>

      发表评论
      请自觉遵守互联网相关的政策法规,严禁发布色情、暴力、反动的言论。
      评价:
      表情:
      用户名: 验证码:点击我更换图片

      推荐热点

      • /etc/fstab 详解
      • nginx主主集群
      •  LVS-NAT和LVS-DR模式的实现详解
      •  RHCE考试之磁盘配额
      • 学习笔记:ACL详解
      •  LVM逻辑卷管理器
      • suse linux双网卡双网关配置
      •  Nginx主主负载均衡架构
      • linux top命令详解

      快速直达

      ?? - ?? - ÝřŝžľŘÝź - TAGąęÇŠ - RSSśŠÔÄ - ??
      Copyright © 2004-2024 上海卓卓网络科技有限公司