Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Well, according to these information, the cache seems to be freeing itself.
If you don't experience any oom issue (just grep "Out of memory" in /var/syslog to check that) then it means that your system is safe.
it's a normal behavior for linux to allocate all the available memory and to free the caches when a process needs more memory.
Thank you so much for this useful link. but why my other server is fine and i always get alarm memory critical so is there any way to prevent this?
Nothing is wrong with the memory use. So something is wrong with the configuration of whatever program is producing that "alarm".
It is reporting a problem where there is no problem.
Quote:
Originally Posted by vannathlab
Now I fix it.
...
root@backup2:~# echo 3 | sudo tee /proc/sys/vm/drop_caches
3
That is a bad idea. It just makes your system slower.
Quote:
Originally Posted by akiuni
I suggest that you monitor the /proc/slabinfo file if the problem occures again.
That is a total waste of effort. There have been a few past threads in this forum about mysterious memory consumption, in which the problem was inside the kernel slab allocations, so examining slabinfo was needed to further diagnose the issue. BUT the information in post #1 and in more detail in post #8 of the current thread completely rule out complicated problems like that. There is no reason to look for details of a rare problem known to not be present in the current situation.
I think my configuration is right to produce this alarm.
No. It is not right.
For almost all purposes cache memory is as good as free memory.
That is what the free program means with its "-/+ buffers/cache:" line. It is telling you how much memory is used/free if you interpret buffers and cache as equivalent to free, which is the normal interpretation of buffers and cache.
Linux memory reporting tools report buffers and cache separate from free memory, because Linux is designed for experts who are supposed to understand subtle differences. But a beginner should treat buffers and cache as if they are just two more kinds of free memory.
For almost all purposes cache memory is as good as free memory.
That is what the free program means with its "-/+ buffers/cache:" line. It is telling you how much memory is used/free if you interpret buffers and cache as equivalent to free, which is the normal interpretation of buffers and cache.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.