Bug 503 - smb.conf log file statement non compatible with logrotate
smb.conf log file statement non compatible with logrotate
Status: CLOSED FIXED
Product: Samba 3.0
Classification: Unclassified
Component: Config Files
3.0.0preX
All other
: P3 trivial
: none
Assigned To: Gerald (Jerry) Carter
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2003-09-25 01:49 UTC by Magnus Sundberg
Modified: 2005-08-24 10:21 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Magnus Sundberg 2003-09-25 01:49:56 UTC
Well,
Please throw this bug report away if you find it irrelevant. 

The smb.conf file have the statement 'log file = /usr/samba/var/log.%m'
This requires a file statement in the logrotate config file as:
/usr/samba/var/log.*
This will move 
/usr/samba/var/log.nmdb to /usr/samba/var/log.nmdb.1.gz the first week
Next week will you get
/usr/samba/var/log.nmdb
/usr/samba/var/log.nmdb.1.gz
/usr/samba/var/log.nmdb.2.gz
/usr/samba/var/log.nmdb.1.gz.1.gz
since /usr/samba/var/log.nmdb.1.gz also matches in the logrotate config file.
I propose that the log file statement should be changed to
'log file = /usr/samba/var/%m.log'
This will make logrotate much easier to configure.

/Magnus
Comment 1 Gerald (Jerry) Carter 2003-11-06 08:40:29 UTC
actually %m.log was at one point a source of a security hole
due to variable expansion based on strings sent from the client.
A better solution is to simply put all the log information in
one file

   log file = /var/log/log/smbd.log

I'll look into this.
Comment 2 Gerald (Jerry) Carter 2004-03-03 09:55:32 UTC
set log file to smbd.log for smb.conf.default, RedHat and Fedora packages
Comment 3 Gerald (Jerry) Carter 2005-02-07 09:05:50 UTC
originally reported against one of the 3.0.0rc[1-4] releases.
Cleaning up non-production versions.
Comment 4 Gerald (Jerry) Carter 2005-08-24 10:21:21 UTC
sorry for the same, cleaning up the database to prevent unecessary reopens of bugs.