Max size of a string that can be logged in error log

Ashish S ashishs.dev at gmail.com
Wed May 2 15:52:07 UTC 2012


Thanks for the response, maxim!

--Ashish

On Wed, May 2, 2012 at 3:39 AM, Maxim Dounin <mdounin at mdounin.ru> wrote:
> Hello!
>
> On Tue, May 01, 2012 at 08:38:01AM -0700, Ashish S wrote:
>
>> Is there a maximum size (and a corresponding tunable buffer size or
>> so) for a string that can be logged in nginx Error log? I could find
>
> The hard limit is in code, NGX_MAX_ERROR_STR which is defined to
> 2048.  The limit is due to use of static buffer for logging
> errors, it's used to avoid allocations in error logging path (as
> allocation may fail, especially if we are trying to log allocation
> error).
>
>> the tunable for access log (buffer=size), but not for error log.
>
> The access log line size isn't limited.  The buffer= argument is
> to reduce number of write() calls, which is helpfull in case of high
> load.
>
> Maxim Dounin
>
> _______________________________________________
> nginx mailing list
> nginx at nginx.org
> http://mailman.nginx.org/mailman/listinfo/nginx



More information about the nginx mailing list