Answer the question
In order to leave comments, you need to log in
OS does not release memory. What could be?
Hello.
There are about 10 servers, partly CloudLinux 6 is installed (this is an OS based on CentOS 6), partly CentOS 6. Faced the problem of allocating and freeing memory.
Initially, I noticed that MySQL servers (there are versions of MariaDB 10.2.17 and Percona 5.6.39, depending on the server) consume more memory than they are allocated. For example, mysqltuner.pl might have the following output (this is a test server, buffers are set to minimum):
-------- Storage Engine Statistics --------------------------------------- --------------------------
[-] Data in MyISAM tables: 284.6M (Tables: 8400)
[-] Data in InnoDB tables: 2.1G (Tables: 9416)
[-] Data in MEMORY tables: 0B (Tables: 62)
-------- Performance Metrics ---------------------------------------- -------------------------------
[-] Up for: 2m 34s (7K q [47.175 qps], 696 conn, TX: 23M, RX: 18M)
[-] Physical Memory: 7.7G
[-] Max MySQL memory: <b>562.8M</b>
[-] Other process memory: 2.2G
[-] Total buffers: 184.0M global + 2.9M per thread (100 max threads)
Answer the question
In order to leave comments, you need to log in
Initially noticed that MySQL servers.... consume more memory than they are allocated.During memory allocation, the operating system is up to the ass, what is written there in the configuration files of the applications that it serves.
And the database server can eat 2 gigabytes at the same time (namely RES, not VIRT memory)Firstly, it's not so much if you only have 7.7G on the Physical Memory server. Secondly, where should the remaining memory go for some other applications? Thirdly, what's with the swap partition?
At startup, it consumes 1.4 gigabytes (RES) of memory, if you perform a soft reboot (graceful), then after the "rebirth" of processes, new ones begin to consume 3 gigabytes (RES) of memory.Here it is possible that the operating system does not immediately reset the data pages, but thinks that they can still come in handy - a variant of a clock with two hands. In order not to go to the disk later for data in the event of a page out of memory error, the operating system does not immediately flush recent data to disk.
Why does the same software behave differently?I myself am breaking my head over this question: two identical twin brother servers, the same distribution kit, but, bitch, they become different. Or the case - you put the driver for the video card on the machine, where there are two disks with identical operating systems (one in reserve). On one it becomes like clockwork, on the other it climbs like cancer, then in the end it ruins the entire system.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question