in Uncategorized

Flush Buffers And cache On Linux

Many users tend to worry when the free memory on a Linux system is very low. Especially when the system is barely active. What many don’t know is that this is normal behavior for Linux. It simply takes your free memory and caches it. This caching behavior makes subsequent memory allocations much faster. So it improves performance overall.

However, if you really really need to flush the cache and buffers, you can run the following two commands on the shell as root:

sync; echo 3 > /proc/sys/vm/drop_caches

Here’s the output of free before and after running the above command.

Before

# free -m
             total       used       free     shared    buffers     cached
Mem:           502        487         15          0         15        170
-/+ buffers/cache:        301        201
Swap:         3153        375       2777

After

# free -m
             total       used       free     shared    buffers     cached
Mem:           502        345        157          0          1         44
-/+ buffers/cache:        300        202

As you can see the highlighted numbers, the buffers and cached values have dropped significantly after I ran the command. Again, this is not necessary. In fact, it’s not recommended at all but there it is if you’re curious to know.

That’s all folks. I hope you enjoyed this one.

Write a Comment

Comment

Comment moderation is enabled. Your comment may take some time to appear.

Webmentions

  • Wholesale NFL Jerseys nike
    Notice: Trying to get property of non-object in /home/unixy/public_html/blog/wp-includes/comment-template.php on line 542

    Wholesale NFL Jerseys nike

    a panic such as this is to .They are quite powerful when it comes to branding you will have learned all there is to know and have mastered every skill there is first entry level acquired by people willing to build their careers in this sector.North Car…

  • ???????????????????
    Notice: Trying to get property of non-object in /home/unixy/public_html/blog/wp-includes/comment-template.php on line 542

    ???????????????????

    or perhaps. fresh air jordanWith the actual ??????????????????? impressive increase inside demand associated with vital food products within Asia, desire for getting fertilizer Flush Buffers And cache On Linux | UNIXy is actually maximizing fast around…

  • 2 day diet
    Notice: Trying to get property of non-object in /home/unixy/public_html/blog/wp-includes/comment-template.php on line 542

    2 day diet…

    It very effortless to find out any topic on web as compared to textbooks, as I fount this article at this site….

  • payday loans
    Notice: Trying to get property of non-object in /home/unixy/public_html/blog/wp-includes/comment-template.php on line 542

    payday loans…

    genuinely good points right here, just thank you…

  • Elektrische Zahnbuerste
    Notice: Trying to get property of non-object in /home/unixy/public_html/blog/wp-includes/comment-template.php on line 542

    … [Trackback]…

    […] Read More: blog.unixy.net/2009/07/flush-buffers-and-cache-on-linux/ […]…