Replies: 1 comment 3 replies
-
|
Nothing stands out to me in the heap profile. The posting cache seems to use close to the configured 2 GiB of memory. In my testing when increasing the cache size (of all three caches) dgraph also used more memory outside of the caches. For example when increasing size-mb=2048 to size-mb=4096, memory usage grew from 5.4 GiB to 8.4 GiB. So 1 GiB higher than expected. I think that is what you are also observing. I suggest experimenting with the cache size to find a value which gives you good performance at a reasonable memory footprint. |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Continuing the discussion for #9526 @matthewmcneely @xqqp . Please find below my heap output. This is at the exact same point on the same data, the only difference is that one has --cache "size-mb=5120; percentage=40,40,20; remove-on-update=true" and the other has --cache "size-mb=5120; percentage=0,65,35; remove-on-update=true". Memory usage of the former was around 9G at the point of the dump, the latter has around 2G.
heap.zip
I understand that there are many other variables in mem usage, but given that everything else is completely identical, and the size of the memory discrepancy, in this case it does infer that the posting cache is responsible here?
sh-5.2# dgraph version
Dgraph version : 2ec41c9
Dgraph codename : dgraph
Dgraph SHA-256 : 69f19385f47bad662ae92214c67be9177ed3be785e940fa07c3a403f8c9d47d5
Commit SHA-1 : 2ec41c9
Commit timestamp : 2025-12-02 09:52:52 +0100
Branch : v25
Go version : go1.25.4
jemalloc enabled : true
The commit hash there is from my own fork as i periodically bump go.mod for security reasons.
You can see however that this commit is directly on top of 68c24d so that is my effective version.
Thanks for looking into this and shout if you need any more info at all!
Beta Was this translation helpful? Give feedback.
All reactions