Index resident ratio below 10% with 70% memory available

Hi Team,

Why does resident ratio is very low when available memory on Index/Query is 24 GB?

image

How am I exceeding memory quota?

image

Thanks.

Hello,

I believe there are two different issues here:

  1. The low resident ratio on indexes
  2. The query not running with the “Request has exceeded memory quota” message.

For the low resident ratio on indexes:

In a node with multiple services the memory will be distributed out between the operating system and all the services on the node.

In your case you have a node with 32Gb of RAM. Of that 32Gb 20% is given to the OS. That will leave you with 25Gb.

The 25Gb is then divided between the three services (Query, Index and Search) each will be assigned 8.3Gb (25/3).

I see you have a number of indexes and I suspect you have gone over the memory quota for the index service which is why the resident ratio is low on some of your indexes.

The best practice for a production cluster is to have each service on a different nodes so all memory can be assigned to that one service. This would be the preferred option if you need to increase the resident ratio of your indexes.

For the “Request has exceeded memory quota” message:

Can you provide the query your trying to run, I wonder does it include the UNNEST clause?

Hi Adam,

The 25Gb is then divided between the three services (Query, Index and Search) each will be assigned 8.3Gb (25/3).

That’s a interesting info, Is this available on Capella docs?

Can you provide the query your trying to run, I wonder does it include the UNNEST clause?

That’s correct, It’s a UNNEST clause.

SELECT field.name
FROM bucketname
UNNEST products product
WHERE product.accountnumber = ‘xx’

Thanks.

1 Like

I don’t believe that information is in the documentation. I will submit a request to get it added.

For the “Request has exceeded memory quota” error, this is due to unnest being used and https://issues.couchbase.com/browse/MB-52959. Please open up a ticket with support through the Capella UI (under support) referencing this post and the above MB Jira and the support team will be able to make a configuration change to workaround this problem.

I hope this helps

Adam

1 Like