Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Drop_caches clears the system cache

2025-04-01 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >

Share

Shulou(Shulou.com)06/03 Report--

For program exception terminal, the data in cache is not synchronized to disk. You need to call sync to synchronize data to disk first, and then empty drop_caches cache.

Use sync command to synchronize data to disk before emptying cache

# cat /proc/sys/vm/drop_caches

Default is 0, 1 to clear page cache, 2 to clear inode and directory tree cache, 3 to clear all cache

#sync

#free -m

total used free shared buffers cached

Mem: 23953 4741 19211 0 967 2129

-/+ buffers/cache: 1644 22308

Swap: 12047 0 12047

#echo 3 > /proc/sys/vm/drop_caches

#free -m //cache detail reduction will be found

total used free shared buffers cached

Mem: 23953 735 23218 0 3 74

-/+ buffers/cache: 656 23296

Swap: 12047 0 12047

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Internet Technology

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report