On 18/03/2019 17:32, Konstantin Belousov wrote:
> tmpfs, swap-backed (or even memory backed) md, persistent posix shared
> memory, SysV shared memory.

In the end, it was POSIX shared memory.
I put the system into the single-user to clean up the memory as much as possible
and then I panic'ed it and went through dirty pages and their related objects in
kgdb.  As far as I can tell, the memory was leaked via POSIX shared memory
objects that were never shm_unlink-ed.  It seems that there was a misbehaving
program that had been creating such objects and then losing track of them.  (I
was able to identify it from names it used for the objects)

It seems that, unfortunately, there is no way to list / discover POSIX shared
memory objects that are not opened by any process.
I wrote a small gdb script to examine shm_dictionary in kgdb.  It would be nice
to have a utility (and a kernel interface) that could do the same from userland.

Andriy Gapon
freebsd-current@freebsd.org mailing list
To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"

Reply via email to