Is there a way to have database only for last 30 days despite having older files ?

General discussion about Blue Iris
Post Reply
Old_Boy
Posts: 2
Joined: Sun Apr 21, 2024 4:45 am

Is there a way to have database only for last 30 days despite having older files ?

Post by Old_Boy »

Hello,
I an running 25 cameras on Blue Iris 5 in a system with a dedicated 20TB storage for Blue Iris. Is there a way to have database only for last 30 days despite having older files ?
I want Blue Iris to store the files older than 30 days and manage that folder to delete the files when there is no more storage but not to include this folder of older files in the database.
User avatar
TimG
Posts: 2806
Joined: Tue Jun 18, 2019 10:45 am
Location: Nottinghamshire, UK.

Re: Is there a way to have database only for last 30 days despite having older files ?

Post by TimG »

My first thought would be to export them as Mp4. I think that would do it. Does anybody have a better idea ?
Forum Moderator.
Problem ? Ask and we will try to assist, but please check the Help file.
BruceH
Posts: 242
Joined: Wed Apr 01, 2020 10:10 pm

Re: Is there a way to have database only for last 30 days despite having older files ?

Post by BruceH »

TimG,

I agree exporting them sounds like a good solution, even if they are left in BVR format, BI would no longer see them and would not have them in the DB, but they could still be viewed from the BI PC by opening the file from windows explorer.
PaulDaisy
Posts: 85
Joined: Mon Nov 25, 2024 5:06 am

Re: Is there a way to have database only for last 30 days despite having older files ?

Post by PaulDaisy »

I think that one can set up an automatic Move from New to Stored or AUX1, and leave that AUX1 as an "unmanaged" option (or have them expire after a year or something). That would not remove them from the database though. However, if one was to use another utility to move them (a chron job or a sync software) elsewhere, then BI should probably lose track of them when it rebuilds the DB.

That said, the OP didn't say why he wants to do that. Is the DB getting too big and slow? My DB is over a month long and is only 1Gb in size, and is lightning fast. A senior software engineer at work told me "don't try to over-optimize". So I listen to him and only try to change things if something isn't working.
Old_Boy
Posts: 2
Joined: Sun Apr 21, 2024 4:45 am

Re: Is there a way to have database only for last 30 days despite having older files ?

Post by Old_Boy »

Sorry for the late reply. Let me explain my situation in a bit more detail.

I wanted Blue Iris to save the recording directly in the cloud storage, because from where I am it is common for thieves and robbers to take the DVR/NVR/PC with them so as not to leave any evidence. Initally I did set up recordings to be saved directly in the cloud using Pcloud Drive Software, but data of 25 camers even in substreams was simply too much for my internet bandwidth. So as a workaround I setup exports of Hi-res-Jpeg Images and mp4 videos of the alert events in different Aux folders and synced them to the cloud storage. Now at least my alerts are online and backed up in cloud in real time.

But due to these jpeg and mp4 exports, the sheer number of files is huge. I just checked its 13,11,678 files totaling 14 tb. And the problem I face due to this is that whenever I have to restart my pc, after the restart when I open the Blue Iris it genrates/repairs the database. This genrating process takes more than 24 hours and during these 24 hours I do not get new alerts. So every restart leaves me without alerts for 24 hours !!

I want the files and folders to be managed by Blue Iris, deleting the oldest file when my storage is full. If I remove the files from the Blue Iris Folders then restarts will be a lot faster but then file management would be too difficult for me.

So my problem will be solved if :-
1. Blue Iris could give alerts during the genration period.
2. There could be a way to exclude older files from database, lets say older than 30 days or x number days.
3. There could be a way to exclude folders like Aux 1 and Aux 2 from the database genration with them to be managed by Blue Iris.

Or any other possible solution will be greatly appreciated. Thanking you.
Post Reply