Backup all the essential stuff

Support and queries relating to all previous versions of ZoneMinder
Post Reply
jamescollings
Posts: 59
Joined: Wed Nov 22, 2006 11:26 am
Location: Bucks, UK

Backup all the essential stuff

Post by jamescollings » Thu Nov 23, 2006 9:48 am

I have looked through the wiki and FAQ but can't see the answer (can't believe no-one else has asked).

Does anyone have a script (or defined process) that will back up all of the essential data to a single file?

I am guessing that the "essential" information would be the camera configuration information, zones, and the events and images from the MySQL database. I'd like to be able to schedule this backup to occur regularly and then ftp the file to a NAS that I have. If someone knows the commands/locations for this information, then I can write the shell script quite easily.

I need this for 2 reasons.
1) Now that I have configured my zones and cameras to just the way I need them, I now have to re-install ZM from scratch (to repair the bodged modifications that I made).
2) If a toe-rag does break in... I don't want them to take all the PC's that have the recordings of their faces (my NAS is very well hidden).

Thanks in advance

User avatar
zoneminder
Site Admin
Posts: 5220
Joined: Wed Jul 09, 2003 2:07 pm
Location: Bristol, UK
Contact:

Post by zoneminder » Thu Nov 23, 2006 11:17 am

The two main things you would need to back up are the db, which you can do with mysqldump, and the 'events' directory, which would need tar. I do have a prototype system backup and restore script somewhere that never quite got finished. I think I will try and polish them off for the next release.
Phil

jamescollings
Posts: 59
Joined: Wed Nov 22, 2006 11:26 am
Location: Bucks, UK

Post by jamescollings » Thu Nov 23, 2006 12:39 pm

zoneminder wrote:I do have a prototype system backup and restore script somewhere that never quite got finished.
Do you fancy sending it to me (in it's current state) and I'll finish it up for you?
Only guessing, but we'd want to read the location of the events and images directories from the database, and take the output filename from the command line or prompt the user. I don't know enough about the web interface to know if it could be incorporated into that, but if it was written so that all inputs could be provided on the command line, then that enhancement could be worked on later.

Whaddya think?

User avatar
rdmelin
Posts: 863
Joined: Wed Oct 29, 2003 2:23 pm
Location: Ellensburg, WA USA

Post by rdmelin » Thu Nov 23, 2006 2:59 pm

You might find some of this useful.

http://www.zoneminder.com/forums/viewtopic.php?t=6299

jamescollings
Posts: 59
Joined: Wed Nov 22, 2006 11:26 am
Location: Bucks, UK

Post by jamescollings » Thu Nov 23, 2006 3:13 pm

Cool 8)

Since I am running that release of the LiveCD, it looks like I already have everything I need.

I'll give it a go tonight. Thanks

Post Reply

Who is online

Users browsing this forum: No registered users and 16 guests