Page 1 of 1

logs (zmfilter.log etc) not in directory but piped to logger

Posted: Thu Nov 04, 2004 12:12 pm
by 2tomcats
Dear all,

as a great fan of logfiles I'm a bit unhappy about the way those ZM internal logfiles are handled.

Let me explain:
The main syslog (/var/log/messages) of my cameraserver is redirected to my main logserver. As is done with all my other servers. So I have one centralized logfile which is rotated and archived every night. Furthermore this daily logfile is processed by some scripts to extract and report unusal things etc.
So I would like the logs of ZM like 'zmfilter.log' also be piped to the syslog on the cameraserver.

I'm thinking of 2 different config possibilities:
- either using a directory for storage as it is now
- or pipe the output to ie. 'logger' so they go into /var/log/messages

That way one doesn't have to care about different locations for logs and rotating, processing them.

What do you think?

Uli

Posted: Thu Nov 04, 2004 11:09 pm
by zoneminder
I put my ZM logs in /var/log/zm and add a file called 'zm' to /etc/logrotate.d as follows

Code: Select all

/var/log/zm/*.log {
    notifempty
    missingok
    copytruncate
}
Obviously you might want different settings but its pretty easy to rotate the logs. I aggree though that it would be nice to have all the logs in one central place and it's something on I have on my 'to do' list.

Phil,

Posted: Fri Nov 05, 2004 10:37 am
by 2tomcats
Thx for the answer.
Rotating is not the problem. My point is that I'd love to have all the logs collected at one centralized location.
Nevermind, as it is on your todo list ;-)

have fun
Uli