Page 1 of 1

automically old event delete ??

Posted: Wed Dec 01, 2004 7:31 pm
by panadol
Hi
I am new Zoneminder user. I'm sorry but my english is very bad.
I have simple question abaut events in ZM.
Are eldest events automattically delete when my disk with var catalog is full ??
Can I make that they will be deleted for example when disk is 90% full ??
Best regards
Adam Pilat

Posted: Wed Dec 01, 2004 10:47 pm
by sgn
Sure. If you look in the "Hints/Tips"-section of the forum, you'll find a great script to be run in cron. ZM has such a function integrated, in the Event-filter window there is a dropdown with the "PurgeWhenFull"-filter.

Configure, save, sit back and let it do the work.

Posted: Thu Dec 02, 2004 10:45 am
by panadol
Hi
Thx for Your answer. I found this Purgewhenfull filter and configure.
I make disk procent=50 and mark delete events. Now when disk ist over 50% events in ZM console are delete but disk procent still grov up and in var - events catalog old events still exist. Will they delete later ??
PanAdol

Posted: Thu Dec 02, 2004 11:49 am
by lazyleopard
First the events are deleted from the database, and then some while later the images are cleaned off disk.

The other place ZM may be consuming diskspace is with its log files, so it's a good idea to rotate them from time to time. I use "logrotate" with a script like this:

Code: Select all

/var/log/zone/*.log {
        missingok
        rotate 7
        weekly
        compress
        nocreate
        nomail
        notifempty
        sharedscripts
        prerotate
                /etc/init.d/zoneminder stop > /dev/null
        endscript
        postrotate
                (sleep 30; /etc/init.d/zoneminder start) > /dev/null
        endscript
}