How to log size of cookies in request header with apache
- by chrisst
We have an issue on our site with cookies growing too large. We have already expanded the acceptable header size and throttled the cookie sizes for now, but I'd like to figure out what the average client's header sizes are, specifically of the cookies.
I've created an apache log that captures the cookies being set on each request:
LogFormat "%{Cookie}i" cookies
But this just spits out the entire contents of all cookies in the header.
Is there a way to have apache just log the size (or just length of the string) per request?