Auto Delete?
Auto Delete?
I tried to search the forum for this, but had no luck. Is there a way to configure zm to auto delete events and images older than 30 days?
Re: Auto Delete?
http://www.zoneminder.com/wiki/index.php/Documentation
Look at the section on filters, especially "PurgeWhenFull" filter, but adapted ...
From my install notes ...
Purge When Full
This filter is already installed, but needs enabling
"Archive Status equal to Unarchived Only" "and Disk Percent greater than or equal to 95"
"Limit to first 50 results only" and tick "Delete All Matches"
Then click "Save" and select "Run Filter In Background"
"Purge When Old"
"Archive Status equal to Unarchived Only" "and Date less than 7 days ago"
and tick "Delete All Matches"
Then click "Save" and select "Run Filter In Background"
Big Noobie Note: The use of "less than 7 days ago" means OLDER THAN 7 days. This is not intuitive, until you realise it means a date MATHEMATICALLY LESS THAN 7 days ago, which is OLDER. You will want 30 days here.
You can test what the filter will do by hitting "submit" and it will show you a list of events that "would have" been deleted if it ran properly.
Hope that points you in the right direction. Filters are very powerful, and make sure you test them before setting them to run in the background
Look at the section on filters, especially "PurgeWhenFull" filter, but adapted ...
From my install notes ...
Purge When Full
This filter is already installed, but needs enabling
"Archive Status equal to Unarchived Only" "and Disk Percent greater than or equal to 95"
"Limit to first 50 results only" and tick "Delete All Matches"
Then click "Save" and select "Run Filter In Background"
"Purge When Old"
"Archive Status equal to Unarchived Only" "and Date less than 7 days ago"
and tick "Delete All Matches"
Then click "Save" and select "Run Filter In Background"
Big Noobie Note: The use of "less than 7 days ago" means OLDER THAN 7 days. This is not intuitive, until you realise it means a date MATHEMATICALLY LESS THAN 7 days ago, which is OLDER. You will want 30 days here.
You can test what the filter will do by hitting "submit" and it will show you a list of events that "would have" been deleted if it ran properly.
Hope that points you in the right direction. Filters are very powerful, and make sure you test them before setting them to run in the background
Re: Auto Delete?
That looks to be exactly what I'm looking for, very helpful. I didn't think I needed to use "filters" for anything so I was sorta skipping right over it. I gotta figure out this verbiage!
Thanks!
Thanks!
Re: Auto Delete?
ok, now that I understand what filters are and how they work, I have one more question. When I set the filter to Date and less than, do I put in "30" or do I put in "30 days", "30d"?
Re: Auto Delete?
Literally :-
but I'm sure other syntaxes are available
Code: Select all
30 days ago
Re: Auto Delete?
that's hilarious, but I love it!
Re: Auto Delete?
Well it's true, isn't it? You can use all sorts of notations in the filters. I'm not sure if the "ago" is needed/ignored, but it makes it clearer to me.MKEbrew wrote:that's hilarious, but I love it!
Re: Auto Delete?
Got it. Changed to 7 days after I started wondering why I thought I needed 30. Still need to tweak the sensitivity to reduce some of this, but that's a different thread and I think I got the info I need. Just need to spend some time on it.
Thanks for the help!
Thanks for the help!