cloudstack-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From li jerry <div...@hotmail.com>
Subject 回复: KVM host AvailableMemory data is incorrect
Date Tue, 21 Jul 2020 07:04:36 GMT
@Andrija Panic<mailto:andrija.panic@gmail.com> Sorry, there are other VMs running on
this HOST, and they have allocated 160G of memory in total.
What I want to express is that we should mark Buffers as AvailableMemory

Because Buffers memory can be automatically recycled by the system

-Jerry

发件人: Andrija Panic<mailto:andrija.panic@gmail.com>
发送时间: 2020年7月21日 14:48
收件人: users<mailto:users@cloudstack.apache.org>; li jerry<mailto:div8cn@hotmail.com>
主题: Re: KVM host AvailableMemory data is incorrect

@li jerry<mailto:div8cn@hotmail.com> if ACS tells you your KVM host has 16GB instead
256GB - that is wrong by all means - and you should try to see where this comes from (have
you upgraded the host in the meantime, or did anything with it) ?
Even with your break-down of total/cache/buffers etc - your host *should* has more than 100GB
free (buffers + cache = 92GB out of 256B)

You should check you "slab" usage etc - there are other "hiden" RAM usage beside the buffer
and cache.

Best,

On Thu, 16 Jul 2020 at 17:24, Riepl, Gregor (SWISS TXT) <Gregor.Riepl@swisstxt.ch<mailto:Gregor.Riepl@swisstxt.ch>>
wrote:
Sounds like a calculation bug in cloudstack-agent then.
You should probably report it on Github.
________________________________
From: li jerry <div8cn@hotmail.com<mailto:div8cn@hotmail.com>>
Sent: 15 July 2020 12:08
To: users@cloudstack.apache.org<mailto:users@cloudstack.apache.org> <users@cloudstack.apache.org<mailto:users@cloudstack.apache.org>>
Subject: 回复: KVM host AvailableMemory data is incorrect

In my scene

KVM host
cat /proc/meminfo
MemTotal=256G
MemFree=4G
Cached=12G
Buffers=80G

When I want to deploy a VM with 32G memory to this host, it prompts that the resources are
insufficient (mem.overprovisioning.factor=1.0).

CLOUDSTACK tells me that KVMHOST has 16GB of available memory (it does not count Buffers).
So 16<32, so there is not enough data.


But I manually started a VM with 32G memory on KVM HOST, and it succeeded; and Buffers/cached/memfree/they
were reduced accordingly.

therefore:
Can we add the memory occupied by Buffers to AvailableMemory and report to CLOUDSTACK?

-----邮件原件-----
发件人: Riepl, Gregor (SWISS TXT) <Gregor.Riepl@swisstxt.ch<mailto:Gregor.Riepl@swisstxt.ch>>
发送时间: 2020年7月15日 17:41
收件人: users@cloudstack.apache.org<mailto:users@cloudstack.apache.org>
主题: Re: KVM host AvailableMemory data is incorrect

This sounds very familiar...

https://bugzilla.redhat.com/show_bug.cgi?id=1250060
and they rolled it back in
https://bugzilla.redhat.com/show_bug.cgi?id=1779609
because upstream didn't accept their patch.

We had to "fix" our memory monitoring twice because of this.

It's important to *not* calculate buffer/cache memory towards memory usage, because the kernel
can reclaim this memory whenever there is a need.
________________________________
From: li jerry <div8cn@hotmail.com<mailto:div8cn@hotmail.com>>
Sent: 15 July 2020 08:27
To: users@cloudstack.apache.org<mailto:users@cloudstack.apache.org> <users@cloudstack.apache.org<mailto:users@cloudstack.apache.org>>
Subject: KVM host AvailableMemory data is incorrect

Hello everyone
     We use HCI to run CloudStack (KVM+CEPH). After running for a period of time, cloudstack
reports that HOST has no available memory. But ZABBIX monitoring shows that HOST still has
a lot of available memory. By observing /proc/meminfo on KVM HOST, it is found that most of
the memory is occupied by Buffers.

     Further analysis of the source code of cloudstack-agent shows that the algorithm for
cloudstack-agent to obtain AvailableMemory on the host is:

Cached +MemFree -reservedMemory +overCommitMemory

It does not calculate the memory occupied by Buffers.


Excuse me, can I mark the memory occupied by Buffers as AvailableMemory?

If not, what is the reason?

Thank you!


-       Jerry


--

Andrija Panić

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message