Yahoo Groups archive

Milter-greylist

Index last updated: 2026-04-28 23:32 UTC

Thread

changing logging

changing logging

2006-06-19 by c.r.p.

I really like milter-greylist, except for one thing.
Is there a way to change the log file? I really do not want the
messages from milter-greylist showing up in the maillog file.

Re: [milter-greylist] changing logging

2006-06-19 by manu@netbsd.org

c.r.p. <shcv34c@...> wrote:

> I really like milter-greylist, except for one thing.
> Is there a way to change the log file? I really do not want the
> messages from milter-greylist showing up in the maillog file.

Patch the call to openlog() in milter-greylist.c and use a different
logging facility.

If you are ready to contribute a config-file option to control logging
destination, that would be great, of course.

--
Emmanuel Dreyfus
manu@...

Re: [milter-greylist] changing logging

2006-06-19 by Jack L. Stone

At 07:13 AM 6.19.2006 +0200, manu@... wrote:
>c.r.p. <shcv34c@...> wrote:
>
>> I really like milter-greylist, except for one thing.
>> Is there a way to change the log file? I really do not want the
>> messages from milter-greylist showing up in the maillog file.
>
>Patch the call to openlog() in milter-greylist.c and use a different
>logging facility.
>

Emmanuel, I'd like to log to a different log file too, like
"milter-greylist.log"

I gather below are the lines to modify, however I'm unsure of what to
replace "LOG_MAIL" with, being script-challenged and merely a user/admin.
Would you please advise further of how the lines should look to make the
change?

        if (conf.c_nodetach != 0)    
                openlog("milter-greylist", LOG_PERROR, LOG_MAIL);
        else
                openlog("milter-greylist", 0, LOG_MAIL);

Thanks!
Jack

(^_^)
Happy trails,
Jack L. Stone

System Admin
Sage-american

Re: [milter-greylist] changing logging

2006-06-19 by Martin Paul

On Mon, Jun 19, 2006 at 08:12:21AM -0500, Jack L. Stone wrote:
> Emmanuel, I'd like to log to a different log file too, like
> "milter-greylist.log"
> 
> I gather below are the lines to modify, however I'm unsure of what to
> replace "LOG_MAIL" with, being script-challenged and merely a user/admin.
> Would you please advise further of how the lines should look to make the
> change?

Change LOG_MAIL to LOG_LOCAL0 in both lines. Recompile milter-greylist
and restart it. Add a line like:

  local0.debug	/var/log/milter-greylist.log
              ^^ this is a TAB, *not* spaces

to /etc/syslog.conf, and send the syslog daemon (syslogd) a HUP signal.

See the syslog man page for alternatives to LOG_LOCAL0 and general
information about syslog.

mp.

Re: [milter-greylist] changing logging

2006-06-19 by Emmanuel Dreyfus

On Mon, Jun 19, 2006 at 08:12:21AM -0500, Jack L. Stone wrote:
> Emmanuel, I'd like to log to a different log file too, like
> "milter-greylist.log"
> 
> I gather below are the lines to modify, however I'm unsure of what to
> replace "LOG_MAIL" with, being script-challenged and merely a user/admin.
> Would you please advise further of how the lines should look to make the
> change?
> 
>         if (conf.c_nodetach != 0)    
>                 openlog("milter-greylist", LOG_PERROR, LOG_MAIL);
>         else
>                 openlog("milter-greylist", 0, LOG_MAIL);

s/LOG_MAIl/LOG_LOCAL0/

Then edit syslog.conf to redirect local0.* to milter-greylist.log,
and signal syslogd.

There are also local1, local2 ... local7

-- 
Emmanuel Dreyfus
manu@...

Re: [milter-greylist] changing logging

2006-06-19 by Jack L. Stone

At 03:19 PM 6.19.2006 +0200, Martin Paul wrote:
>On Mon, Jun 19, 2006 at 08:12:21AM -0500, Jack L. Stone wrote:
>> Emmanuel, I'd like to log to a different log file too, like
>> "milter-greylist.log"
>> 
>> I gather below are the lines to modify, however I'm unsure of what to
>> replace "LOG_MAIL" with, being script-challenged and merely a user/admin.
>> Would you please advise further of how the lines should look to make the
>> change?
>
>Change LOG_MAIL to LOG_LOCAL0 in both lines. Recompile milter-greylist
>and restart it. Add a line like:
>
>  local0.debug	/var/log/milter-greylist.log
>              ^^ this is a TAB, *not* spaces
>
>to /etc/syslog.conf, and send the syslog daemon (syslogd) a HUP signal.
>
>See the syslog man page for alternatives to LOG_LOCAL0 and general
>information about syslog.
>
>mp.
>

That works great. Thanks Martin!

(^_^)
Happy trails,
Jack L. Stone

System Admin
Sage-american

Re: changing logging

2006-06-21 by c.r.p.

--- In milter-greylist@yahoogroups.com, manu@... wrote:
>
> c.r.p. <shcv34c@...> wrote:
> 
> > I really like milter-greylist, except for one thing.
> > Is there a way to change the log file? I really do not want the
> > messages from milter-greylist showing up in the maillog file.
> 
> Patch the call to openlog() in milter-greylist.c and use a different
> logging facility.
> 
The one I have is dated Sep 20  2005 , is that the correct one?

Move to quarantaine

This moves the raw source file on disk only. The archive index is not changed automatically, so you still need to run a manual refresh afterward.