<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>http://wiki.staging.zoneminder.com/index.php?action=history&amp;feed=atom&amp;title=Backups</id>
	<title>Backups - Revision history</title>
	<link rel="self" type="application/atom+xml" href="http://wiki.staging.zoneminder.com/index.php?action=history&amp;feed=atom&amp;title=Backups"/>
	<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Backups&amp;action=history"/>
	<updated>2026-04-19T20:19:09Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.37.1</generator>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Backups&amp;diff=5731&amp;oldid=prev</id>
		<title>Flasheart: Created page with &quot;General notes about backups:  Zoneminder requires the filesystem to be backed up, AND the Database. It can be backed up whilst running (if you can accept the odd missing event...&quot;</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Backups&amp;diff=5731&amp;oldid=prev"/>
		<updated>2013-05-24T14:59:27Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;General notes about backups:  Zoneminder requires the filesystem to be backed up, AND the Database. It can be backed up whilst running (if you can accept the odd missing event...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;General notes about backups:&lt;br /&gt;
&lt;br /&gt;
Zoneminder requires the filesystem to be backed up, AND the Database. It can be backed up whilst running (if you can accept the odd missing event taken during the backup).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Backing up ==&lt;br /&gt;
&lt;br /&gt;
A typical backup would be to dump the mysql database &amp;quot;zm&amp;quot; and also the events directories. Because of the size of both of these in an active system with many cameras, this may require a LOT of space. The events won&amp;#039;t compress well, being JPGs (already compressed) The event directory is build and distro dependant, but on a typical debian install will be in /usr/share/zoneminder/events &lt;br /&gt;
&lt;br /&gt;
ZM&amp;#039;s main configuration is kept in the mysql database, although some basic settings are typically held in /etc/zm (debian)&lt;br /&gt;
&lt;br /&gt;
How often you do this is up to you, but consider CPU load during backup, and length of backup. It&amp;#039;s not unknown for a highly stressed server to be overwhelmed with a large backup.&lt;br /&gt;
&lt;br /&gt;
&amp;quot;backup-manager&amp;quot; is an excellent program that will do both database and directories, and sequentialise them as you wish, keeping only the N most recent. It can transfer them offsite too.&lt;br /&gt;
&lt;br /&gt;
Because of these complexities, some zoneminder admins do not do do regular backups, preferring to archive and export as video any events they particularly want to keep as they occur.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Offsite Live Backups ==&lt;br /&gt;
&lt;br /&gt;
Occasionally an admin realises that because the server recording CCTV is housed at the same location it is recording, should a burglary take place the thieves are likely to take the shiny server while they&amp;#039;re at it, even if they don&amp;#039;t realise it&amp;#039;s acting as a cctv recorder. It&amp;#039;s hard to dispute this logic. However, because of the amount of bandwidth a medium sized zoneminder install requires, offsite backups may be difficult to achieve using consumer grade technologies. A professional thief may also cut phone/data wires or power before gaining entry.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Some thoughts to formulating your plan... ==&lt;br /&gt;
&lt;br /&gt;
* Hide the server!  Make it hidden. Cupboards, in loftspace, an outbuilding, etc. Consideration should be given to heat dissipation, dust, acessibility and noise - but this is a low cost and often effective low-tech solution.&lt;br /&gt;
&lt;br /&gt;
* Record offsite. You can use existing technologies like NFS to mount a remote drive to your local server, and change your events/ do to live on that. The downside is fairly obvious - you will need a LOT of upstream bandwidth to cope with anything but the most basic of installs. Of course, you will also have to formulate a plan for keeping the database up to date too, unless you want a lot of manual digging through directories to find the files you want.&lt;br /&gt;
&lt;br /&gt;
* Record selected cameras from a remote server. Either using IP cameras, or having Zoneminder locally acting as a transcoder (you can record from a zoneminder monitor), have a remote server recording 1 or 2 cameras so you at least stand a shot. This is also a highly configurable system allowing for you to adjust FPS, size and colour to suit your upstream.&lt;br /&gt;
&lt;br /&gt;
* Synchronous backup. In theory it&amp;#039;s possible to set mysql to replicate to a slave database offsite, and have rsync (or similar) constantly synchronising the events/ dir. Given the large file directories (deep or not), I have no idea how rsync will cope constantly syncing such a large filesystem with regard to both local cpu and io load, and bandwidth. If you have experience of this, please expand this article.&lt;/div&gt;</summary>
		<author><name>Flasheart</name></author>
	</entry>
</feed>