Skip to content

ocserv scales poorly on platforms with out malloc_trim

ocserv scales poorly on platforms with out malloc_trim (like musl C library)

Memory consumed by ocserv explodes as the number of clients rises on platforms that lack the malloc_trim API.

Viewing the /proc/[PID]/statm for the worker process shows that the first client to connect has a resident set of around 200KB while last processes to connect have a resident set of around 3000KB. 213 213 215 229 231 ... 3046 3058 3061 3066 3072 3101

Options to trim the resident set of the process after fork?