Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Openssl Memory leak #1217

abdessamad-zevenet opened this Issue Nov 29, 2018 · 2 comments


None yet
2 participants
Copy link

abdessamad-zevenet commented Nov 29, 2018

Did anyone realize a growing memory usage in cherokee over time whit tls enabled and requesting a simple cgi script?, after running a memory heap tracer it seems that it's comes under ssl_do_handshake when using openssl <= 1.1. with openssl 1.1.1 the things seems to get better and at some point memory stops growing.

screenshot from 2018-11-29 17-44-19

Also, how to get openssl statically linked ?, already tried --enable static and also adding LDFLAGS="-lssl -lcrypto -lz -ldl -static-libgcc" and no luck.

Thanks in advance.


This comment has been minimized.

Copy link

skinkie commented Nov 29, 2018

Could you compile cherokee without trace and see if you can reproduce it?

@skinkie skinkie self-assigned this Nov 29, 2018


This comment has been minimized.

Copy link

abdessamad-zevenet commented Nov 30, 2018

Thank you for answering.
I compile cherokee without the options "--enable-trace --enable-backtraces", I just use --with-mysql=no --with-ffmpeg=no --with-ldap=no, but also tried with default configure and same happens. What I think is that SSL session allocation are not freed correctly. Also I realized that CLEAR_LIBSSL_ERRORS leak some bytes when are no error queue when using ERR_get_error().
Only improvement I saw is when using latest libssl version.

Thanks for your help!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.