Welcome! Log In Create A New Profile

Advanced

How to calculate used shared memory in slab?

August 17, 2016 05:38PM
Hello, I'm the developer of Nchan (previously known as the http push
module) -- https://github.com/slact/nchan. I'm writing a stub_status -
like stats output handler, and I want to output the amount of shared
memory actually used. I could keep track of the raw bytes allocated with
wrappers to ngx_slab_alloc, but that does not produce accurate numbers
because the slab allocator works on pages.

I'm having some trouble understanding the internal working of the slab
allocator. Is there a straightforward way to get the number of pages
currently in use?


Thanks,
Leo

_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

How to calculate used shared memory in slab?

slact August 17, 2016 05:38PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 140
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready