好的,因为我没有10个引文,所以我无法发布图片,但是我会尝试用文字解释。
我有一个包含4个存储桶的7节点Couchbase(社区)集群。最近,我一直(一直)被其中一个存储桶的元数据开销警告所发送的垃圾邮件。警告弹出,看起来像这样:
元数据开销警告。分配给节点“ xxx”上的存储区XXXX的RAM的62%以上被键和元数据占用。
而且我读到,这通常表明该铲斗需要更多的柱塞。但是我认为这不是我的问题。我只是猜想有很多元数据。当我查看“数据桶”选项卡时,此桶具有RAM /配额使用量 64GB / 75GB。因此对我来说,大约有11GB(75-64GB)可用空间。
如果我查看Bucket Analytics VBUCKET RESOURCES指标,就会发现 RAM中有59GB的用户数据,RAM中有46GB的 元数据。因此,据我了解,一个存储桶中应该有105GB的RAM,总共有75GB !!!
但这对我而言并没有那么明显,这里有些我不了解的事情。是的,46GB的75GB约为62%。但是,应该在RAM中存储的59GB用户数据又如何呢?
编辑:一个典型的文档可以看起来像这样:
ID=1:CAESEA---rldZ5PhdV4msSdEchI
CONTENT=z2TjZEzkZ84=
和我的问题。我该怎么办?在我的情况下这种情况是否可以接受?如果是这样,我是否要更改该警告的阈值(不建议阅读,因为警告被设置为50%是有原因的)。
还是分配更多的RAM?如果可以的话,如果已经有11GB的可用空间,那对我有什么帮助?
请帮助我弄清楚这些数字,并建议我是否需要采取任何措施。
First of all, there isn't necessarily a problem with having a high percentage of memory used by metadata - it just means there's less RAM available for caching actual documents. If your application is working well then it may be fine for your use-case. However, having said that let me try and address your questions on it, and what to change if you do want to improve things:
If i look at the Bucket Analytics VBUCKET RESOURCES metrics I see that there is 59GB user data in RAM and 46GB metadata in RAM. So to my understanding there should be 105GB in RAM on a bucket that has a total of 75GB!?!
IIRC "user data in RAM" is inclusive of "metadata in RAM" - so you have a total of 59 GB data used, of which 46 GB is metadata.
And to my question. What do I do? Is the situation acceptable in my circumstances. If so, do I change the threshold for that warning(which I read is not recommended since the warning is set at 50% for a reason). Or do I assign more RAM? And if so how does that help me if there is already 11GB free?
So basically you are storing lots of very small documents, so the per-document metadata overhead (~48 bytes plus the length of the key) is very high compared to the actual document size.
The 11GB free is mainly made up of the difference between the bucket quota and the high watermark.
Here are a few options to improve this:
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
我来说两句