Re: [Exim] syslog

Top Pagina
Delete this message
Reply to this message
Auteur: Philip Hazel
Datum:  
Aan: Chris Edwards
CC: exim-users
Onderwerp: Re: [Exim] syslog
On Thu, 11 Nov 1999, Chris Edwards wrote:

> OK - the daemon is syslogging its arguments at startup:
>
> exim[11327]: 1999-11-11 13:26:26 3 args: exim -bd -q10m
>
> but not the real startup message:
>
>   exim[11327]: 1999-11-11 13:26:26 exim 3.092 daemon started:
>       pid=11327, -q10m listening for SMTP on port 25

>
> nor anything else. As far as I can see, the daemon exim closes all
> descriptors, including the one used by syslog(), so nothing more ever gets
> logged.
>
> Adding a call to closelog() *before* closing all descriptors appears to
> sort this, although I don't totally understand why.


Aha! I think I do. The answer is that you have "log_arguments" set,
which causes Exim to start logging (i.e. open syslog) before this
descriptor-closing that happens in the daemon. In my test I didn't have
log_arguments set. Closing syslog before closing the descriptors
presumably allows it to reopen then next time it logs something.

I'll install this closelog() call. Thanks for the debugging.

-- 
Philip Hazel            University of Cambridge Computing Service,
ph10@???      Cambridge, England. Phone: +44 1223 334714.