<div dir="ltr">Hello,<div>I'm following an issue that caused some OOMs during a huge spike.</div><div>Currently I have the following properties set:</div><div><br></div><div> -p thread_pool_max=2000 \<br> -p thread_pool_min=35 \<br>       -p feature=+esi_disable_xml_check \<br>   -p feature=+esi_ignore_other_elements \<br>       -p feature=+esi_remove_bom \<br>  -p feature=+http2 \<br>   -p pcre_match_limit_recursion=64 \<br>    -p syslog_cli_traffic=off \<br>   -p sigsegv_handler=on \<br>       -p workspace_client=2m \<br>      -p workspace_backend=2m \<br>     -p http_max_hdr=128 \<br> -p http_req_hdr_len=32k \<br>     -p http_resp_hdr_len=32k \<br>    -p http_req_size=2m \<br> -p http_resp_size=2m \<br>        -p thread_pool_stack=256k \<br>   -s malloc,20G \<br>       -S /config/varnish/secret \<br>   -f /config/varnish/default.vcl \<br>      -p vsl_reclen=700<br></div><div><br></div><div>And I'm using this formula to somehow calculate how much memory is varnish going to use:</div><div>thread_pool_max*thread_pool_stack+thread_pool_max*(workspace_client+http_req_hdr_len+http_req_size) + malloc<br><br>And it is somewhere close to where I get OOM. I suspect that what did screw up was the high esi-to-request ration that I normally have:</div><div><br></div><div>MAIN.client_req        469.22<br>MAIN.esi_req          5489.25<br></div><div><br></div><div>Hit rate on that esi requests is pretty high as we use high ttls and invalidations, but I think that those ESIs have to be taken into account too (as well as the backend requests too...).</div><div><br></div><div>I wasn't able to find an official memory sizing guide, sorry. How do you size correctly memory usage?</div><div>I know I should use MSE, at the moment is not on my list.</div><div><br></div><div>Thanks</div><div>Luca</div></div>