Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 11 Jun 2009 18:15:29 +0300
From:      Andriy Gapon <avg@freebsd.org>
To:        Andriy Gapon <avg@freebsd.org>
Cc:        svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Dmitry Morozovsky <marck@rinet.ru>, John Baldwin <jhb@freebsd.org>
Subject:   Re: svn commit: r194005 - head/etc
Message-ID:  <4A311F91.6040601@freebsd.org>
In-Reply-To: <200906111507.n5BF72IH050955@svn.freebsd.org>
References:  <200906111507.n5BF72IH050955@svn.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
on 11/06/2009 18:07 Andriy Gapon said the following:
> Author: avg
> Date: Thu Jun 11 15:07:02 2009
> New Revision: 194005
> URL: http://svn.freebsd.org/changeset/base/194005
> 
> Log:
>   syslog.conf: pop up from logging only ppp messages at the end of file
>   
>   This allows to append custom rules at the end of the file without
>   risk of confusion that can result when one misses default !ppp line
>   and doesn't add another program specification and thus subsequent
>   selector(s) would belong to ppp program block.
>   
>   Requested by:	marck
>   Submitted by:	marck
>   Approved by:	jhb (mentor)
> 
> Modified:
>   head/etc/syslog.conf
> 
> Modified: head/etc/syslog.conf
> ==============================================================================
> --- head/etc/syslog.conf	Thu Jun 11 14:44:10 2009	(r194004)
> +++ head/etc/syslog.conf	Thu Jun 11 15:07:02 2009	(r194005)
> @@ -28,3 +28,4 @@ cron.*						/var/log/cron
>  # news.notice					/var/log/news/news.notice
>  !ppp
>  *.*						/var/log/ppp.log
> +!*

I forgot to add "MFC after", but  I think 2 weeks should be sufficient.

Another thing - it seems that the example in syslog.conf(5) is incorrect.
First, the manual says:

     Each block of lines is separated from the previous block by a program or
     hostname specification.  A block will only log messages corresponding to
     the most recent program and hostname specifications given.  Thus, with a
     block which selects ‘ppp’ as the program, directly followed by a block
     that selects messages from the hostname ‘dialhost’, the second block will
     only log messages from the ppp(8) program on dialhost.

But then:
     # Save ftpd transactions along with mail and news
     !ftpd
     *.*                                                     /var/log/spoolerr

     # Log all security messages to a separate file.
     security.*                                              /var/log/security

     # Log all writes to /dev/console to a separate file.
     console.*                                               /var/log/console.log

If I am not mistaken, this is a classic example of the confusion that this commit
tries to prevent - the last two rules would apply only to messages from 'ftp', but
not to all messages as the comments say.

Unfortunately I am not very fluent with man page syntax (*roff), so if anybody
could provide a patch then I could commit it - I am sure that jhb would approve :-)


-- 
Andriy Gapon



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4A311F91.6040601>