Newbie: Shmem constructor not being called after reload
Maxim Dounin
mdounin at mdounin.ru
Thu Jul 16 22:31:44 UTC 2015
Hello!
On Thu, Jul 16, 2015 at 07:07:28PM -0300, Acácio Centeno wrote:
[...]
> The message to stderr is printed when Nginx starts, but not after a reload,
> that's why I know that the constructor is not being called again. Also, I
> have a counter on the shared area and it's value is reset after a reload.
>
> Any thoughts?
First of all, you need some other method for debugging, or a way
to make sure that stderr is not closed in your particular setup.
Normally nginx closes stderr while becoming a daemon, so it's
expected that printing to stderr won't work.
Normally one should use ngx_log_error() and/or ngx_log_debugN()
to print log and/or debug messages.
--
Maxim Dounin
http://nginx.org/
More information about the nginx-devel
mailing list