<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>http://wiki.staging.zoneminder.com/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Snake</id>
	<title>ZoneMinder Wiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="http://wiki.staging.zoneminder.com/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Snake"/>
	<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/Special:Contributions/Snake"/>
	<updated>2026-05-03T15:18:06Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.37.1</generator>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Helpful_user_contributed_resources&amp;diff=16767</id>
		<title>Helpful user contributed resources</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Helpful_user_contributed_resources&amp;diff=16767"/>
		<updated>2021-12-15T16:42:17Z</updated>

		<summary type="html">&lt;p&gt;Snake: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==FAQ==&lt;br /&gt;
&lt;br /&gt;
[[FAQ]]&lt;br /&gt;
&lt;br /&gt;
==Installation==&lt;br /&gt;
&lt;br /&gt;
[http://zoneminder.readthedocs.org/en/latest/installationguide/index.html Official install guides ]&lt;br /&gt;
&lt;br /&gt;
[https://wiki.zoneminder.com/Ubuntu  Ubuntu specific guides (currently more updated than official guides)]&lt;br /&gt;
&lt;br /&gt;
[https://wiki.zoneminder.com/Debian  Debian specific guides]&lt;br /&gt;
&lt;br /&gt;
[https://wiki.zoneminder.com/Ubuntu#Common_Issues_with_Zoneminder_Installation_on_Ubuntu._Includes_upgrade_instructions.21 Common problems migrating from old versions to new versions ]&lt;br /&gt;
&lt;br /&gt;
[https://github.com/pliablepixels/zmNinja/wiki/Configuring-ZoneMinder-with-API API installation/validation guide]-  (use the link above first, if you face problems, refer to this link)&lt;br /&gt;
&lt;br /&gt;
[https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive] - Adding HDDs.&lt;br /&gt;
&lt;br /&gt;
[[Single Board Computers]] - ARM devices.&lt;br /&gt;
&lt;br /&gt;
[[GPU passthrough in VMWare]] - Notes on using GPUs with Zoneminder running in a virtual machine&lt;br /&gt;
&lt;br /&gt;
[[Email]]&lt;br /&gt;
&lt;br /&gt;
==Supported== &lt;br /&gt;
&lt;br /&gt;
[[Beginner hardware]] - What cameras to start with.&lt;br /&gt;
&lt;br /&gt;
[[Supported distributions]]&lt;br /&gt;
&lt;br /&gt;
[[Hardware Compatibility List ]]&lt;br /&gt;
&lt;br /&gt;
[[MobileDevices]] - View ZM from your phone.&lt;br /&gt;
&lt;br /&gt;
==Third party==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Utilities]] - Software for ZM&lt;br /&gt;
&lt;br /&gt;
[[Infrared Leds, Cameras, DC-DC converters etc]] - Hardware&lt;br /&gt;
&lt;br /&gt;
[[External resources of information related to ZM]]&lt;br /&gt;
&lt;br /&gt;
[[Consultants]]&lt;br /&gt;
&lt;br /&gt;
==Community docs==&lt;br /&gt;
&lt;br /&gt;
[[How To]] &lt;br /&gt;
&lt;br /&gt;
[[Miscellaneous helpful hints]]&lt;br /&gt;
&lt;br /&gt;
[[Various Learnings from getting Zomeminder 1.28.1 working well on Ubuntu Server 14.04]]&lt;br /&gt;
&lt;br /&gt;
[[Dummies Guide]]&lt;br /&gt;
&lt;br /&gt;
[[MySQL]]&lt;br /&gt;
&lt;br /&gt;
[[Hardware recommendations]] - What computer hardware to use.&lt;br /&gt;
&lt;br /&gt;
==CCTV Laws==&lt;br /&gt;
[[Area Specific Laws]]&lt;br /&gt;
&lt;br /&gt;
 &lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Hardware_recommendations&amp;diff=16760</id>
		<title>Hardware recommendations</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Hardware_recommendations&amp;diff=16760"/>
		<updated>2021-12-15T06:38:57Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Overview */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a subject that has been hashed over many times, so here is an&lt;br /&gt;
attempt at a summary of what is discussed in the forum at:&lt;br /&gt;
http://forums.zoneminder.com/viewforum.php?f=14&lt;br /&gt;
&lt;br /&gt;
== Overview ==&lt;br /&gt;
&lt;br /&gt;
For 1-4 cameras, you can use a core2duo or better CPU.&lt;br /&gt;
&lt;br /&gt;
10 cameras, you should have low end server CPUs (i.e. avoid i3,i5 etc)(Xeon is an intel&lt;br /&gt;
server CPU. AMD has a variety of server CPUs that work well).&lt;br /&gt;
&lt;br /&gt;
10-50 cameras you want a powerful server CPU, but still don&amp;#039;t need to break the bank.&lt;br /&gt;
Old server hardware can be got for &amp;lt;$1000, even $600 if you are lucky.&lt;br /&gt;
&lt;br /&gt;
Above that you might just want to pay the developer&amp;#039;s for advice to get them to fine tune a system.&lt;br /&gt;
But you can also give a try at it yourself if you wish.&lt;br /&gt;
&lt;br /&gt;
Keep in mind that depending on how you configure ZM can make or break your systems.&lt;br /&gt;
Trying to run 4 4K cameras with mocord on a core 2 duo will fail, but it might handle 4 1080p&lt;br /&gt;
streams with record on the hi res stream and modect on the low res stream. These kinds &lt;br /&gt;
of settings are variable. When in doubt browse the forums and wiki.&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
&lt;br /&gt;
=== General ===&lt;br /&gt;
&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=29339 Misc. advice&lt;br /&gt;
&lt;br /&gt;
=== Small ===&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=29706 7 Cameras&lt;br /&gt;
&lt;br /&gt;
=== Medium ===&lt;br /&gt;
&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=30166 24 Cameras&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=43&amp;amp;t=31384&lt;br /&gt;
&lt;br /&gt;
=== Large ===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Experts Only!&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=30973 100-150 Cameras&lt;br /&gt;
&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=29953 250 Cameras&lt;br /&gt;
&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=31179 500 Cameras&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Hardware_recommendations&amp;diff=16759</id>
		<title>Hardware recommendations</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Hardware_recommendations&amp;diff=16759"/>
		<updated>2021-12-15T06:38:15Z</updated>

		<summary type="html">&lt;p&gt;Snake: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a subject that has been hashed over many times, so here is an&lt;br /&gt;
attempt at a summary of what is discussed in the forum at:&lt;br /&gt;
http://forums.zoneminder.com/viewforum.php?f=14&lt;br /&gt;
&lt;br /&gt;
== Overview ==&lt;br /&gt;
&lt;br /&gt;
For 1-4 cameras, you can use a core2duo or better CPU.&lt;br /&gt;
&lt;br /&gt;
10 cameras, you should have low end server CPUs (i.e. avoid i3,i5 etc)(Xeon is an intel&lt;br /&gt;
server CPU. AMD has a variety of server CPUs that work well.&lt;br /&gt;
&lt;br /&gt;
10-50 cameras you want a powerful server CPU, but still don&amp;#039;t need to break the bank.&lt;br /&gt;
Old server hardware can be got for &amp;lt;$1000, even $600 if you are lucky.&lt;br /&gt;
&lt;br /&gt;
Above that you might just want to pay the developer&amp;#039;s to get them to fine tune a system.&lt;br /&gt;
But you can also give a try at it yourself if you wish.&lt;br /&gt;
&lt;br /&gt;
Keep in mind that depending on how you configure ZM can make or break your systems.&lt;br /&gt;
Trying to run 4 4K cameras with mocord on a core 2 duo will fail, but it might handle 4 1080p&lt;br /&gt;
streams with record on the hi res stream and modect on the low res stream. These kinds &lt;br /&gt;
of settings are variable. When in doubt browse the forums and wiki.&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
&lt;br /&gt;
=== General ===&lt;br /&gt;
&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=29339 Misc. advice&lt;br /&gt;
&lt;br /&gt;
=== Small ===&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=29706 7 Cameras&lt;br /&gt;
&lt;br /&gt;
=== Medium ===&lt;br /&gt;
&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=30166 24 Cameras&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=43&amp;amp;t=31384&lt;br /&gt;
&lt;br /&gt;
=== Large ===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Experts Only!&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=30973 100-150 Cameras&lt;br /&gt;
&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=29953 250 Cameras&lt;br /&gt;
&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=31179 500 Cameras&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Hardware_recommendations&amp;diff=16758</id>
		<title>Hardware recommendations</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Hardware_recommendations&amp;diff=16758"/>
		<updated>2021-12-15T06:28:27Z</updated>

		<summary type="html">&lt;p&gt;Snake: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a subject that has been hashed over many times, so here is an&lt;br /&gt;
attempt at a summary of what is discussed in the forum at:&lt;br /&gt;
http://forums.zoneminder.com/viewforum.php?f=14&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
&lt;br /&gt;
=== General ===&lt;br /&gt;
&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=29339 Misc. advice&lt;br /&gt;
&lt;br /&gt;
=== Small ===&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=29706 7 Cameras&lt;br /&gt;
&lt;br /&gt;
=== Medium ===&lt;br /&gt;
&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=30166 24 Cameras&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=43&amp;amp;t=31384&lt;br /&gt;
&lt;br /&gt;
=== Large ===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Experts Only!&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=30973 100-150 Cameras&lt;br /&gt;
&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=29953 250 Cameras&lt;br /&gt;
&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=31179 500 Cameras&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Hardware_recommendations&amp;diff=16757</id>
		<title>Hardware recommendations</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Hardware_recommendations&amp;diff=16757"/>
		<updated>2021-12-15T06:25:25Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Links */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a subject that has been hashed over many times, so here is an&lt;br /&gt;
attempt at a summary of what is discussed in the forum at:&lt;br /&gt;
http://forums.zoneminder.com/viewforum.php?f=14&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
&lt;br /&gt;
=== Small ===&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=29706 7 Cameras&lt;br /&gt;
&lt;br /&gt;
=== Medium ===&lt;br /&gt;
&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=30166 24 Cameras&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=43&amp;amp;t=31384&lt;br /&gt;
&lt;br /&gt;
=== Large ===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Experts Only!&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=30973 100-150 Cameras&lt;br /&gt;
&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=29953 250 Cameras&lt;br /&gt;
&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=31179 500 Cameras&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Hardware_recommendations&amp;diff=16756</id>
		<title>Hardware recommendations</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Hardware_recommendations&amp;diff=16756"/>
		<updated>2021-12-15T06:14:42Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Large */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a subject that has been hashed over many times, so here is an&lt;br /&gt;
attempt at a summary of what is discussed in the forum at:&lt;br /&gt;
http://forums.zoneminder.com/viewforum.php?f=14&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
&lt;br /&gt;
=== Medium ===&lt;br /&gt;
&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=30166 24 Cameras&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=43&amp;amp;t=31384&lt;br /&gt;
&lt;br /&gt;
=== Large ===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Experts Only!&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=30973 100-150 Cameras&lt;br /&gt;
&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=29953 250 Cameras&lt;br /&gt;
&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=31179 500 Cameras&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Hardware_recommendations&amp;diff=16755</id>
		<title>Hardware recommendations</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Hardware_recommendations&amp;diff=16755"/>
		<updated>2021-12-15T06:13:13Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Links */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a subject that has been hashed over many times, so here is an&lt;br /&gt;
attempt at a summary of what is discussed in the forum at:&lt;br /&gt;
http://forums.zoneminder.com/viewforum.php?f=14&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
&lt;br /&gt;
=== Medium ===&lt;br /&gt;
&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=30166 24 Cameras&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=43&amp;amp;t=31384&lt;br /&gt;
&lt;br /&gt;
=== Large ===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Experts Only!&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=30973 100-150 Cameras&lt;br /&gt;
&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=31179 500 Cameras&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Hardware_recommendations&amp;diff=16754</id>
		<title>Hardware recommendations</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Hardware_recommendations&amp;diff=16754"/>
		<updated>2021-12-15T06:12:49Z</updated>

		<summary type="html">&lt;p&gt;Snake: Created page with &amp;quot;This is a subject that has been hashed over many times, so here is an attempt at a summary of what is discussed in the forum at: http://forums.zoneminder.com/viewforum.php?f=1...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a subject that has been hashed over many times, so here is an&lt;br /&gt;
attempt at a summary of what is discussed in the forum at:&lt;br /&gt;
http://forums.zoneminder.com/viewforum.php?f=14&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
&lt;br /&gt;
=== Medium ===&lt;br /&gt;
&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=30166 24 Cameras&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=43&amp;amp;t=31384&lt;br /&gt;
&lt;br /&gt;
=== Large ===&lt;br /&gt;
&lt;br /&gt;
*Experts Only!*&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=30973 100-150 Cameras&lt;br /&gt;
&lt;br /&gt;
* http://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=31179 500 Cameras&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Talk:Helpful_user_contributed_resources&amp;diff=16753</id>
		<title>Talk:Helpful user contributed resources</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Talk:Helpful_user_contributed_resources&amp;diff=16753"/>
		<updated>2021-12-15T06:05:44Z</updated>

		<summary type="html">&lt;p&gt;Snake: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== organized distriution-specifics a bit ==&lt;br /&gt;
&lt;br /&gt;
hi, i saw that things were getting a bit messy, especially the distribution-specific stuff, so i went ahead and organized it. -jan&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== added **Hardware specific tips** topic ==&lt;br /&gt;
&lt;br /&gt;
maybe if someone thinks it should better be under **supported hardware** , please move;&lt;br /&gt;
--[[User:Henriquejf|Henriquejf]] 06:39, 28 March 2009 (UTC)&lt;br /&gt;
&lt;br /&gt;
== jabber / xmpp instant messages on motion detection ==&lt;br /&gt;
&lt;br /&gt;
Trying to upload the file here, as I have restrictions in forums.&lt;br /&gt;
&lt;br /&gt;
[[File:Zmsendxmpp.pdf]]&lt;br /&gt;
&lt;br /&gt;
== Beginner hardware vs. Hardware recommendations ==&lt;br /&gt;
&lt;br /&gt;
To avoid confusion between the two pages, should make beginner hardware title specify it is about cameras,&lt;br /&gt;
not computer hardware.&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Helpful_user_contributed_resources&amp;diff=16752</id>
		<title>Helpful user contributed resources</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Helpful_user_contributed_resources&amp;diff=16752"/>
		<updated>2021-12-15T06:04:13Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Community docs */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==FAQ==&lt;br /&gt;
&lt;br /&gt;
[[FAQ]]&lt;br /&gt;
&lt;br /&gt;
==Installation==&lt;br /&gt;
&lt;br /&gt;
[http://zoneminder.readthedocs.org/en/latest/installationguide/index.html Official install guides ]&lt;br /&gt;
&lt;br /&gt;
[https://wiki.zoneminder.com/Ubuntu  Ubuntu specific guides (currently more updated than official guides)]&lt;br /&gt;
&lt;br /&gt;
[https://wiki.zoneminder.com/Debian  Debian specific guides]&lt;br /&gt;
&lt;br /&gt;
[https://wiki.zoneminder.com/Ubuntu#Common_Issues_with_Zoneminder_Installation_on_Ubuntu._Includes_upgrade_instructions.21 Common problems migrating from old versions to new versions ]&lt;br /&gt;
&lt;br /&gt;
[https://github.com/pliablepixels/zmNinja/wiki/Configuring-ZoneMinder-with-API API installation/validation guide]-  (use the link above first, if you face problems, refer to this link)&lt;br /&gt;
&lt;br /&gt;
[https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive] - Adding HDDs.&lt;br /&gt;
&lt;br /&gt;
[[Single Board Computers]] - ARM devices.&lt;br /&gt;
&lt;br /&gt;
[[GPU passthrough in VMWare]] - Notes on using GPUs with Zoneminder running in a virtual machine&lt;br /&gt;
&lt;br /&gt;
[[Email]]&lt;br /&gt;
&lt;br /&gt;
==Supported== &lt;br /&gt;
&lt;br /&gt;
[[Beginner hardware]] - What cameras to start with.&lt;br /&gt;
&lt;br /&gt;
[[Supported distributions]]&lt;br /&gt;
&lt;br /&gt;
[[Hardware Compatibility List ]]&lt;br /&gt;
&lt;br /&gt;
[[MobileDevices]] - View ZM from your phone.&lt;br /&gt;
&lt;br /&gt;
==Third party==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Utilities]] - Software for ZM&lt;br /&gt;
&lt;br /&gt;
[[Infrared Leds, Cameras, DC-DC converters etc]] - Hardware&lt;br /&gt;
&lt;br /&gt;
[[External resources of information related to ZM]]&lt;br /&gt;
&lt;br /&gt;
[[Consultants]]&lt;br /&gt;
&lt;br /&gt;
==Community docs==&lt;br /&gt;
&lt;br /&gt;
[[How To]] &lt;br /&gt;
&lt;br /&gt;
[[Miscellaneous helpful hints]]&lt;br /&gt;
&lt;br /&gt;
[[Various Learnings from getting Zomeminder 1.28.1 working well on Ubuntu Server 14.04]]&lt;br /&gt;
&lt;br /&gt;
[[Dummies Guide]]&lt;br /&gt;
&lt;br /&gt;
[[MySQL]]&lt;br /&gt;
&lt;br /&gt;
[[Hardware Recommendations]] - What computer hardware to use.&lt;br /&gt;
&lt;br /&gt;
==CCTV Laws==&lt;br /&gt;
[[Area Specific Laws]]&lt;br /&gt;
&lt;br /&gt;
 &lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Helpful_user_contributed_resources&amp;diff=16751</id>
		<title>Helpful user contributed resources</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Helpful_user_contributed_resources&amp;diff=16751"/>
		<updated>2021-12-15T06:03:36Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Supported */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==FAQ==&lt;br /&gt;
&lt;br /&gt;
[[FAQ]]&lt;br /&gt;
&lt;br /&gt;
==Installation==&lt;br /&gt;
&lt;br /&gt;
[http://zoneminder.readthedocs.org/en/latest/installationguide/index.html Official install guides ]&lt;br /&gt;
&lt;br /&gt;
[https://wiki.zoneminder.com/Ubuntu  Ubuntu specific guides (currently more updated than official guides)]&lt;br /&gt;
&lt;br /&gt;
[https://wiki.zoneminder.com/Debian  Debian specific guides]&lt;br /&gt;
&lt;br /&gt;
[https://wiki.zoneminder.com/Ubuntu#Common_Issues_with_Zoneminder_Installation_on_Ubuntu._Includes_upgrade_instructions.21 Common problems migrating from old versions to new versions ]&lt;br /&gt;
&lt;br /&gt;
[https://github.com/pliablepixels/zmNinja/wiki/Configuring-ZoneMinder-with-API API installation/validation guide]-  (use the link above first, if you face problems, refer to this link)&lt;br /&gt;
&lt;br /&gt;
[https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive] - Adding HDDs.&lt;br /&gt;
&lt;br /&gt;
[[Single Board Computers]] - ARM devices.&lt;br /&gt;
&lt;br /&gt;
[[GPU passthrough in VMWare]] - Notes on using GPUs with Zoneminder running in a virtual machine&lt;br /&gt;
&lt;br /&gt;
[[Email]]&lt;br /&gt;
&lt;br /&gt;
==Supported== &lt;br /&gt;
&lt;br /&gt;
[[Beginner hardware]] - What cameras to start with.&lt;br /&gt;
&lt;br /&gt;
[[Supported distributions]]&lt;br /&gt;
&lt;br /&gt;
[[Hardware Compatibility List ]]&lt;br /&gt;
&lt;br /&gt;
[[MobileDevices]] - View ZM from your phone.&lt;br /&gt;
&lt;br /&gt;
==Third party==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Utilities]] - Software for ZM&lt;br /&gt;
&lt;br /&gt;
[[Infrared Leds, Cameras, DC-DC converters etc]] - Hardware&lt;br /&gt;
&lt;br /&gt;
[[External resources of information related to ZM]]&lt;br /&gt;
&lt;br /&gt;
[[Consultants]]&lt;br /&gt;
&lt;br /&gt;
==Community docs==&lt;br /&gt;
&lt;br /&gt;
[[How To]] &lt;br /&gt;
&lt;br /&gt;
[[Miscellaneous helpful hints]]&lt;br /&gt;
&lt;br /&gt;
[[Various Learnings from getting Zomeminder 1.28.1 working well on Ubuntu Server 14.04]]&lt;br /&gt;
&lt;br /&gt;
[[Dummies Guide]]&lt;br /&gt;
&lt;br /&gt;
[[MySQL]]&lt;br /&gt;
&lt;br /&gt;
[[Hardware Recommendations]]&lt;br /&gt;
&lt;br /&gt;
==CCTV Laws==&lt;br /&gt;
[[Area Specific Laws]]&lt;br /&gt;
&lt;br /&gt;
 &lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Helpful_user_contributed_resources&amp;diff=16750</id>
		<title>Helpful user contributed resources</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Helpful_user_contributed_resources&amp;diff=16750"/>
		<updated>2021-12-15T06:03:05Z</updated>

		<summary type="html">&lt;p&gt;Snake: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==FAQ==&lt;br /&gt;
&lt;br /&gt;
[[FAQ]]&lt;br /&gt;
&lt;br /&gt;
==Installation==&lt;br /&gt;
&lt;br /&gt;
[http://zoneminder.readthedocs.org/en/latest/installationguide/index.html Official install guides ]&lt;br /&gt;
&lt;br /&gt;
[https://wiki.zoneminder.com/Ubuntu  Ubuntu specific guides (currently more updated than official guides)]&lt;br /&gt;
&lt;br /&gt;
[https://wiki.zoneminder.com/Debian  Debian specific guides]&lt;br /&gt;
&lt;br /&gt;
[https://wiki.zoneminder.com/Ubuntu#Common_Issues_with_Zoneminder_Installation_on_Ubuntu._Includes_upgrade_instructions.21 Common problems migrating from old versions to new versions ]&lt;br /&gt;
&lt;br /&gt;
[https://github.com/pliablepixels/zmNinja/wiki/Configuring-ZoneMinder-with-API API installation/validation guide]-  (use the link above first, if you face problems, refer to this link)&lt;br /&gt;
&lt;br /&gt;
[https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive] - Adding HDDs.&lt;br /&gt;
&lt;br /&gt;
[[Single Board Computers]] - ARM devices.&lt;br /&gt;
&lt;br /&gt;
[[GPU passthrough in VMWare]] - Notes on using GPUs with Zoneminder running in a virtual machine&lt;br /&gt;
&lt;br /&gt;
[[Email]]&lt;br /&gt;
&lt;br /&gt;
==Supported== &lt;br /&gt;
&lt;br /&gt;
[[Beginner hardware]]&lt;br /&gt;
&lt;br /&gt;
[[Supported distributions]]&lt;br /&gt;
&lt;br /&gt;
[[Hardware Compatibility List ]]&lt;br /&gt;
&lt;br /&gt;
[[MobileDevices]] - View ZM from your phone.&lt;br /&gt;
&lt;br /&gt;
==Third party==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Utilities]] - Software for ZM&lt;br /&gt;
&lt;br /&gt;
[[Infrared Leds, Cameras, DC-DC converters etc]] - Hardware&lt;br /&gt;
&lt;br /&gt;
[[External resources of information related to ZM]]&lt;br /&gt;
&lt;br /&gt;
[[Consultants]]&lt;br /&gt;
&lt;br /&gt;
==Community docs==&lt;br /&gt;
&lt;br /&gt;
[[How To]] &lt;br /&gt;
&lt;br /&gt;
[[Miscellaneous helpful hints]]&lt;br /&gt;
&lt;br /&gt;
[[Various Learnings from getting Zomeminder 1.28.1 working well on Ubuntu Server 14.04]]&lt;br /&gt;
&lt;br /&gt;
[[Dummies Guide]]&lt;br /&gt;
&lt;br /&gt;
[[MySQL]]&lt;br /&gt;
&lt;br /&gt;
[[Hardware Recommendations]]&lt;br /&gt;
&lt;br /&gt;
==CCTV Laws==&lt;br /&gt;
[[Area Specific Laws]]&lt;br /&gt;
&lt;br /&gt;
 &lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16745</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16745"/>
		<updated>2021-12-03T06:57:57Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Obtaining more Cameras */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
On the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
If you are already knowledgeable about unix based computers, then you shouldn&amp;#039;t have any trouble.&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). &lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an early [[Axis]]. They are well documented and easy to setup. &lt;br /&gt;
Old ones go for $10-20. Follow the instructions on either the Zoneminder Hardware compatibility list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatibility List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. from terminal: ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5/video.mjpg&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; (obsolete) Precursor to ffmpeg. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide images that change from anywhere on the filesystem). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. They can also watch MJPEG streams and the former can loop local video files.&lt;br /&gt;
&lt;br /&gt;
And some others...&lt;br /&gt;
&lt;br /&gt;
FFMPEG / LibVLC is recommended.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; has the option of RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
Older cameras from 2000&amp;#039;s. E.g.[[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-30.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
2010&amp;#039;s and newer cameras: These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 means less bytes, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. .&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. That being said, customers generally prefer higher res cameras, so you probably should replace them, unless its a low priority area.&lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog over coax, and I don&amp;#039;t recommend it. It is not standardized yet.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server website and/or ZMNinja.&lt;br /&gt;
&lt;br /&gt;
For business customers use ZMNinja. Its more user friendly. Or build something custom if you like.&lt;br /&gt;
&lt;br /&gt;
You can make fully customizable pages i.e. make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs) if whole img boxes seem to drop out.&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis (1.36).&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (better, but uses HDD, and event list timeline in ZMNinja shows 10 minute segments). But all of these are flawed. Here&amp;#039;s what you do: always record two streams per camera. One, the low res stream, is set to modect, with reasonable (but no need to be perfect) settings for detection. Two, the high res stream is set to either record or nodect under linked monitors and uses h264 passthrough.* The hi res compressed stream is saved directly to disk.&lt;br /&gt;
&lt;br /&gt;
See also this link for a way to use a high res stream under analysis with less CPU: https://forums.zoneminder.com/viewtopic.php?f=10&amp;amp;t=31334&amp;amp;p=124410&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32+, you can use multiple HDs (as many as you like), and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
*Linked monitors have from time to time had bugs or configuration gotchas, so for simplicity sake, I use record. HDD space is cheap.&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until few false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by e.g. &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. &lt;br /&gt;
&lt;br /&gt;
Flawless professional systems use hardware motion detectors, as software detection is not perfect. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442 You aren&amp;#039;t mil grade probably so just use sensitive zone settings and two streams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
You can re run analysis on old videos with: https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video, then make that a video source in zm as file.).&lt;br /&gt;
&lt;br /&gt;
See also: https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=31355 to run zm on files on the server filesystem.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones Tip&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*You can use external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required. More setup cost though.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors (48v poe is recommended though).&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
* If you are setting up mobile phones with ZMNinja, and the wifi is the same WAN IP as the camera system, setup a VPS with a http/https proxy and point zmninja at the proxy. The proxy can be as simple as: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:80&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:443&lt;br /&gt;
sudo iptables-legacy -t nat -A POSTROUTING -j MASQUERADE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note that you might want to set nonstandard ports.&lt;br /&gt;
&lt;br /&gt;
* run 2k cameras at least. people like flashy things (like birds) and hi res.&lt;br /&gt;
&lt;br /&gt;
* users seem to like fluid video, so put high fps on low res substream. analysis fps limit to 2. we don&amp;#039;t have (asic) hardware yet, so there are limits, but cpu is still pretty powerful.&lt;br /&gt;
&lt;br /&gt;
* the more you overbuild the cpu, the faster you can go.&lt;br /&gt;
&lt;br /&gt;
* passthrough on hi res stream obv. watch low res stream live, expand / open window to hi res stream, ideally (custom javascript could do this:todo).&lt;br /&gt;
&lt;br /&gt;
* use zmninja + the website. offer customers both apps. there are also some other apps available. (e.g. possibly zmsquarer).&lt;br /&gt;
&lt;br /&gt;
* in most cases, you should replace coax cams with ethernet. customers that are camera happy tend to like hi res, whether its needed or not, and coax is low res.&lt;br /&gt;
&lt;br /&gt;
* (optional) configure zmes or good blob detection. you pretty much only will be detecting people in the average business. maybe cars. For extra points, figure out how to assign names to people in zmes.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16744</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16744"/>
		<updated>2021-12-03T06:57:26Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Obtaining more Cameras */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
On the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
If you are already knowledgeable about unix based computers, then you shouldn&amp;#039;t have any trouble.&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). &lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an early [[Axis]]. They are well documented and easy to setup. &lt;br /&gt;
Old ones go for $10-20. Follow the instructions on either the Zoneminder Hardware compatibility list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatibility List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. from terminal: ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5/video.mjpg&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; (obsolete) Precursor to ffmpeg. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide images that change from anywhere on the filesystem). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. They can also watch MJPEG streams and the former can loop local video files.&lt;br /&gt;
&lt;br /&gt;
And some others...&lt;br /&gt;
&lt;br /&gt;
FFMPEG / LibVLC is recommended.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; has the option of either RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
Older cameras from 2000&amp;#039;s. E.g.[[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-30.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
2010&amp;#039;s and newer cameras: These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 means less bytes, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. .&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. That being said, customers generally prefer higher res cameras, so you probably should replace them, unless its a low priority area.&lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog over coax, and I don&amp;#039;t recommend it. It is not standardized yet.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server website and/or ZMNinja.&lt;br /&gt;
&lt;br /&gt;
For business customers use ZMNinja. Its more user friendly. Or build something custom if you like.&lt;br /&gt;
&lt;br /&gt;
You can make fully customizable pages i.e. make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs) if whole img boxes seem to drop out.&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis (1.36).&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (better, but uses HDD, and event list timeline in ZMNinja shows 10 minute segments). But all of these are flawed. Here&amp;#039;s what you do: always record two streams per camera. One, the low res stream, is set to modect, with reasonable (but no need to be perfect) settings for detection. Two, the high res stream is set to either record or nodect under linked monitors and uses h264 passthrough.* The hi res compressed stream is saved directly to disk.&lt;br /&gt;
&lt;br /&gt;
See also this link for a way to use a high res stream under analysis with less CPU: https://forums.zoneminder.com/viewtopic.php?f=10&amp;amp;t=31334&amp;amp;p=124410&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32+, you can use multiple HDs (as many as you like), and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
*Linked monitors have from time to time had bugs or configuration gotchas, so for simplicity sake, I use record. HDD space is cheap.&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until few false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by e.g. &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. &lt;br /&gt;
&lt;br /&gt;
Flawless professional systems use hardware motion detectors, as software detection is not perfect. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442 You aren&amp;#039;t mil grade probably so just use sensitive zone settings and two streams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
You can re run analysis on old videos with: https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video, then make that a video source in zm as file.).&lt;br /&gt;
&lt;br /&gt;
See also: https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=31355 to run zm on files on the server filesystem.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones Tip&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*You can use external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required. More setup cost though.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors (48v poe is recommended though).&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
* If you are setting up mobile phones with ZMNinja, and the wifi is the same WAN IP as the camera system, setup a VPS with a http/https proxy and point zmninja at the proxy. The proxy can be as simple as: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:80&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:443&lt;br /&gt;
sudo iptables-legacy -t nat -A POSTROUTING -j MASQUERADE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note that you might want to set nonstandard ports.&lt;br /&gt;
&lt;br /&gt;
* run 2k cameras at least. people like flashy things (like birds) and hi res.&lt;br /&gt;
&lt;br /&gt;
* users seem to like fluid video, so put high fps on low res substream. analysis fps limit to 2. we don&amp;#039;t have (asic) hardware yet, so there are limits, but cpu is still pretty powerful.&lt;br /&gt;
&lt;br /&gt;
* the more you overbuild the cpu, the faster you can go.&lt;br /&gt;
&lt;br /&gt;
* passthrough on hi res stream obv. watch low res stream live, expand / open window to hi res stream, ideally (custom javascript could do this:todo).&lt;br /&gt;
&lt;br /&gt;
* use zmninja + the website. offer customers both apps. there are also some other apps available. (e.g. possibly zmsquarer).&lt;br /&gt;
&lt;br /&gt;
* in most cases, you should replace coax cams with ethernet. customers that are camera happy tend to like hi res, whether its needed or not, and coax is low res.&lt;br /&gt;
&lt;br /&gt;
* (optional) configure zmes or good blob detection. you pretty much only will be detecting people in the average business. maybe cars. For extra points, figure out how to assign names to people in zmes.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16743</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16743"/>
		<updated>2021-12-03T06:57:19Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Motion Detection */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
On the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
If you are already knowledgeable about unix based computers, then you shouldn&amp;#039;t have any trouble.&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). &lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an early [[Axis]]. They are well documented and easy to setup. &lt;br /&gt;
Old ones go for $10-20. Follow the instructions on either the Zoneminder Hardware compatibility list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatibility List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. from terminal: ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5/video.mjpg&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; (obsolete) Precursor to ffmpeg. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide images that change from anywhere on the filesystem). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. Anything RTSP should use FFMPEG.&lt;br /&gt;
&lt;br /&gt;
And some others...&lt;br /&gt;
&lt;br /&gt;
FFMPEG / LibVLC is recommended.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; has the option of either RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
Older cameras from 2000&amp;#039;s. E.g.[[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-30.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
2010&amp;#039;s and newer cameras: These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 means less bytes, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. .&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. That being said, customers generally prefer higher res cameras, so you probably should replace them, unless its a low priority area.&lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog over coax, and I don&amp;#039;t recommend it. It is not standardized yet.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server website and/or ZMNinja.&lt;br /&gt;
&lt;br /&gt;
For business customers use ZMNinja. Its more user friendly. Or build something custom if you like.&lt;br /&gt;
&lt;br /&gt;
You can make fully customizable pages i.e. make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs) if whole img boxes seem to drop out.&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis (1.36).&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (better, but uses HDD, and event list timeline in ZMNinja shows 10 minute segments). But all of these are flawed. Here&amp;#039;s what you do: always record two streams per camera. One, the low res stream, is set to modect, with reasonable (but no need to be perfect) settings for detection. Two, the high res stream is set to either record or nodect under linked monitors and uses h264 passthrough.* The hi res compressed stream is saved directly to disk.&lt;br /&gt;
&lt;br /&gt;
See also this link for a way to use a high res stream under analysis with less CPU: https://forums.zoneminder.com/viewtopic.php?f=10&amp;amp;t=31334&amp;amp;p=124410&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32+, you can use multiple HDs (as many as you like), and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
*Linked monitors have from time to time had bugs or configuration gotchas, so for simplicity sake, I use record. HDD space is cheap.&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until few false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by e.g. &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. &lt;br /&gt;
&lt;br /&gt;
Flawless professional systems use hardware motion detectors, as software detection is not perfect. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442 You aren&amp;#039;t mil grade probably so just use sensitive zone settings and two streams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
You can re run analysis on old videos with: https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video, then make that a video source in zm as file.).&lt;br /&gt;
&lt;br /&gt;
See also: https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=31355 to run zm on files on the server filesystem.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones Tip&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*You can use external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required. More setup cost though.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors (48v poe is recommended though).&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
* If you are setting up mobile phones with ZMNinja, and the wifi is the same WAN IP as the camera system, setup a VPS with a http/https proxy and point zmninja at the proxy. The proxy can be as simple as: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:80&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:443&lt;br /&gt;
sudo iptables-legacy -t nat -A POSTROUTING -j MASQUERADE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note that you might want to set nonstandard ports.&lt;br /&gt;
&lt;br /&gt;
* run 2k cameras at least. people like flashy things (like birds) and hi res.&lt;br /&gt;
&lt;br /&gt;
* users seem to like fluid video, so put high fps on low res substream. analysis fps limit to 2. we don&amp;#039;t have (asic) hardware yet, so there are limits, but cpu is still pretty powerful.&lt;br /&gt;
&lt;br /&gt;
* the more you overbuild the cpu, the faster you can go.&lt;br /&gt;
&lt;br /&gt;
* passthrough on hi res stream obv. watch low res stream live, expand / open window to hi res stream, ideally (custom javascript could do this:todo).&lt;br /&gt;
&lt;br /&gt;
* use zmninja + the website. offer customers both apps. there are also some other apps available. (e.g. possibly zmsquarer).&lt;br /&gt;
&lt;br /&gt;
* in most cases, you should replace coax cams with ethernet. customers that are camera happy tend to like hi res, whether its needed or not, and coax is low res.&lt;br /&gt;
&lt;br /&gt;
* (optional) configure zmes or good blob detection. you pretty much only will be detecting people in the average business. maybe cars. For extra points, figure out how to assign names to people in zmes.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16740</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16740"/>
		<updated>2021-12-01T02:52:11Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Motion Detection */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
On the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
If you are already knowledgeable about unix based computers, then you shouldn&amp;#039;t have any trouble.&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). &lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an early [[Axis]]. They are well documented and easy to setup. &lt;br /&gt;
Old ones go for $10-20. Follow the instructions on either the Zoneminder Hardware compatibility list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatibility List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. from terminal: ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5/video.mjpg&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; (obsolete) Precursor to ffmpeg. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide images that change from anywhere on the filesystem). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. Anything RTSP should use FFMPEG.&lt;br /&gt;
&lt;br /&gt;
And some others...&lt;br /&gt;
&lt;br /&gt;
FFMPEG / LibVLC is recommended.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; has the option of either RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
Older cameras from 2000&amp;#039;s. E.g.[[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-30.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
2010&amp;#039;s and newer cameras: These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 means less bytes, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. .&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. That being said, customers generally prefer higher res cameras, so you probably should replace them, unless its a low priority area.&lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog over coax, and I don&amp;#039;t recommend it. It is not standardized yet.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server website and/or ZMNinja.&lt;br /&gt;
&lt;br /&gt;
For business customers use ZMNinja. Its more user friendly. Or build something custom if you like.&lt;br /&gt;
&lt;br /&gt;
You can make fully customizable pages i.e. make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs) if whole img boxes seem to drop out.&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis (1.36).&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (better, but uses HDD, and event list timeline in ZMNinja shows 10 minute segments). But all of these are flawed. Here&amp;#039;s what you do: always record two streams per camera. One, the low res stream, is set to modect, with reasonable (but no need to be perfect) settings for detection. Two, the high res stream is set to either record or nodect under linked monitors and uses h264 passthrough.* The hi res compressed stream is saved directly to disk.&lt;br /&gt;
&lt;br /&gt;
See also this link for a way to use a high res stream under analysis with less CPU: https://forums.zoneminder.com/viewtopic.php?f=10&amp;amp;t=31334&amp;amp;p=124410&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32+, you can use multiple HDs (as many as you like), and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
*Linked monitors have from time to time had bugs or configuration gotchas, so for simplicity sake, I use record. HDD space is cheap.&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until few false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by e.g. &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. &lt;br /&gt;
&lt;br /&gt;
Flawless professional systems use hardware motion detectors, as software detection is not perfect. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442 You aren&amp;#039;t mil grade probably so just use sensitive zone settings and two streams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
You can re run analysis on old videos with: https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video, then make that a video source in zm as file.).&lt;br /&gt;
&lt;br /&gt;
See also: https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=31355 for 1.36 (untested, atm)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones Tip&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*You can use external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required. More setup cost though.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors (48v poe is recommended though).&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
* If you are setting up mobile phones with ZMNinja, and the wifi is the same WAN IP as the camera system, setup a VPS with a http/https proxy and point zmninja at the proxy. The proxy can be as simple as: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:80&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:443&lt;br /&gt;
sudo iptables-legacy -t nat -A POSTROUTING -j MASQUERADE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note that you might want to set nonstandard ports.&lt;br /&gt;
&lt;br /&gt;
* run 2k cameras at least. people like flashy things (like birds) and hi res.&lt;br /&gt;
&lt;br /&gt;
* users seem to like fluid video, so put high fps on low res substream. analysis fps limit to 2. we don&amp;#039;t have (asic) hardware yet, so there are limits, but cpu is still pretty powerful.&lt;br /&gt;
&lt;br /&gt;
* the more you overbuild the cpu, the faster you can go.&lt;br /&gt;
&lt;br /&gt;
* passthrough on hi res stream obv. watch low res stream live, expand / open window to hi res stream, ideally (custom javascript could do this:todo).&lt;br /&gt;
&lt;br /&gt;
* use zmninja + the website. offer customers both apps. there are also some other apps available. (e.g. possibly zmsquarer).&lt;br /&gt;
&lt;br /&gt;
* in most cases, you should replace coax cams with ethernet. customers that are camera happy tend to like hi res, whether its needed or not, and coax is low res.&lt;br /&gt;
&lt;br /&gt;
* (optional) configure zmes or good blob detection. you pretty much only will be detecting people in the average business. maybe cars. For extra points, figure out how to assign names to people in zmes.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16738</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16738"/>
		<updated>2021-11-23T11:33:02Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Recording in Zoneminder */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
On the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
If you are already knowledgeable about unix based computers, then you shouldn&amp;#039;t have any trouble.&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). &lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an early [[Axis]]. They are well documented and easy to setup. &lt;br /&gt;
Old ones go for $10-20. Follow the instructions on either the Zoneminder Hardware compatibility list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatibility List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. from terminal: ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5/video.mjpg&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; (obsolete) Precursor to ffmpeg. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide images that change from anywhere on the filesystem). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. Anything RTSP should use FFMPEG.&lt;br /&gt;
&lt;br /&gt;
And some others...&lt;br /&gt;
&lt;br /&gt;
FFMPEG / LibVLC is recommended.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; has the option of either RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
Older cameras from 2000&amp;#039;s. E.g.[[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-30.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
2010&amp;#039;s and newer cameras: These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 means less bytes, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. .&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. That being said, customers generally prefer higher res cameras, so you probably should replace them, unless its a low priority area.&lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog over coax, and I don&amp;#039;t recommend it. It is not standardized yet.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server website and/or ZMNinja.&lt;br /&gt;
&lt;br /&gt;
For business customers use ZMNinja. Its more user friendly. Or build something custom if you like.&lt;br /&gt;
&lt;br /&gt;
You can make fully customizable pages i.e. make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs) if whole img boxes seem to drop out.&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis (1.36).&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (better, but uses HDD, and event list timeline in ZMNinja shows 10 minute segments). But all of these are flawed. Here&amp;#039;s what you do: always record two streams per camera. One, the low res stream, is set to modect, with reasonable (but no need to be perfect) settings for detection. Two, the high res stream is set to either record or nodect under linked monitors and uses h264 passthrough.* The hi res compressed stream is saved directly to disk.&lt;br /&gt;
&lt;br /&gt;
See also this link for a way to use a high res stream under analysis with less CPU: https://forums.zoneminder.com/viewtopic.php?f=10&amp;amp;t=31334&amp;amp;p=124410&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32+, you can use multiple HDs (as many as you like), and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
*Linked monitors have from time to time had bugs or configuration gotchas, so for simplicity sake, I use record. HDD space is cheap.&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until few false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by e.g. &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. &lt;br /&gt;
&lt;br /&gt;
Flawless professional systems use hardware motion detectors, as software detection is not perfect. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442 You aren&amp;#039;t mil grade probably so just use sensitive zone settings and two streams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
You can re run analysis on old videos with: https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video, then make that a video source in zm as file.).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones Tip&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*You can use external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required. More setup cost though.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors (48v poe is recommended though).&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
* If you are setting up mobile phones with ZMNinja, and the wifi is the same WAN IP as the camera system, setup a VPS with a http/https proxy and point zmninja at the proxy. The proxy can be as simple as: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:80&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:443&lt;br /&gt;
sudo iptables-legacy -t nat -A POSTROUTING -j MASQUERADE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note that you might want to set nonstandard ports.&lt;br /&gt;
&lt;br /&gt;
* run 2k cameras at least. people like flashy things (like birds) and hi res.&lt;br /&gt;
&lt;br /&gt;
* users seem to like fluid video, so put high fps on low res substream. analysis fps limit to 2. we don&amp;#039;t have (asic) hardware yet, so there are limits, but cpu is still pretty powerful.&lt;br /&gt;
&lt;br /&gt;
* the more you overbuild the cpu, the faster you can go.&lt;br /&gt;
&lt;br /&gt;
* passthrough on hi res stream obv. watch low res stream live, expand / open window to hi res stream, ideally (custom javascript could do this:todo).&lt;br /&gt;
&lt;br /&gt;
* use zmninja + the website. offer customers both apps. there are also some other apps available. (e.g. possibly zmsquarer).&lt;br /&gt;
&lt;br /&gt;
* in most cases, you should replace coax cams with ethernet. customers that are camera happy tend to like hi res, whether its needed or not, and coax is low res.&lt;br /&gt;
&lt;br /&gt;
* (optional) configure zmes or good blob detection. you pretty much only will be detecting people in the average business. maybe cars. For extra points, figure out how to assign names to people in zmes.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=ZMNinja&amp;diff=16737</id>
		<title>ZMNinja</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=ZMNinja&amp;diff=16737"/>
		<updated>2021-11-22T11:31:33Z</updated>

		<summary type="html">&lt;p&gt;Snake: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;ZMNinja is a frontend for mobile phones and x86 computers. &lt;br /&gt;
&lt;br /&gt;
This is the community wiki documentation on ZMNinja. Please refer to the official docs for more information. https://zmninja.readthedocs.io&lt;br /&gt;
&lt;br /&gt;
==Setting up ZMNinja - serverside==&lt;br /&gt;
Typically when setting up ZMNinja you will be doing so for WAN access. This will require the following:&lt;br /&gt;
&lt;br /&gt;
* Confirm API is working (see [[API]])&lt;br /&gt;
* Enable SSL for apache (covered briefly in API page above)&lt;br /&gt;
* Make sure php-gd is installed (picture thumbnails)(apt-get install php-gd, then restart apache)&lt;br /&gt;
* [[MySQL]]: update zm.Config set Value = 1 where Name = &amp;quot;ZM_AUTH_HASH_LOGINS&amp;quot;; (picture thumbnails)&lt;br /&gt;
&lt;br /&gt;
There isn&amp;#039;t much more to it than that. If your API is working, and you have SSL working, then ZMNinja should do its job. Picture thumbnails will work if you enable auth hash logins and have gd support in php.&lt;br /&gt;
&lt;br /&gt;
This assumes you have installed ZM properly. The easiest (and most maintained) guides are [[Debian]], and [[Ubuntu]].&lt;br /&gt;
&lt;br /&gt;
==Setting up ZMNinja - client==&lt;br /&gt;
&lt;br /&gt;
The next step is to download ZMNinja Pro from your app store (or if using a desktop, the x86 binary from the releases of the git repo),&lt;br /&gt;
&lt;br /&gt;
# Enable ZM Authentication&lt;br /&gt;
# Enable Low bandwidth mode&lt;br /&gt;
# Add username and password (this will only be typed once, then ZMNinja will save it.)&lt;br /&gt;
# Type in the IP address into the 3 paths&lt;br /&gt;
&lt;br /&gt;
The rest of ZMNinja can be left at defaults. The paths can look something like this (Note that usually it autofills partway for you, once you type in the IP):&lt;br /&gt;
&lt;br /&gt;
 ZM Portal URL: https://WANIPOFSERVER/zm/&lt;br /&gt;
 path to cgi-bin: https://WANIPOFSERVER/zm/cgi-bin&lt;br /&gt;
 ZM api url:        https://WANIPOFSERVER/zm/api&lt;br /&gt;
&lt;br /&gt;
[[File:Zmninja instructions 1.png|500px|border|alt=Instructions for Mobile Phone Client ZMNinja||Username and password]]&lt;br /&gt;
&lt;br /&gt;
[[File:Zmninja instructions 2.png|500px|border|alt=Instructions for Mobile Phone Client ZMNinja||WAN IP]]&lt;br /&gt;
&lt;br /&gt;
==Security==&lt;br /&gt;
&lt;br /&gt;
It is recommended to have strong passwords for ZMNinja on the WAN. One method to isolate your network from a potentially vulnerable Zoneminder system on the WAN is to have a separate static IP for your camera network, and then have all of your office LAN use ZMNinja out to the WAN and back to view cameras.&lt;br /&gt;
&lt;br /&gt;
See also: &lt;br /&gt;
https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server#Hardening_Webserver&lt;br /&gt;
&lt;br /&gt;
SSL should be the only port accessible via WAN. SSL certificates should be setup.&lt;br /&gt;
&lt;br /&gt;
Fail2ban is recommended.&lt;br /&gt;
&lt;br /&gt;
Geoblocking is a good idea. There are guides online for geoblocking such as:&lt;br /&gt;
&lt;br /&gt;
* https://wiki.pratznschutz.com/index.php/Apache2_Geo_IP&lt;br /&gt;
&lt;br /&gt;
e.g.&lt;br /&gt;
 #apt-get install libapache2-mod-geoip &lt;br /&gt;
 #a2enmod geoip &lt;br /&gt;
geoip.conf&lt;br /&gt;
 &amp;lt;IfModule mod_geoip.c&amp;gt;&lt;br /&gt;
  GeoIPEnable On&lt;br /&gt;
  GeoIPDBFile /usr/share/GeoIP/GeoIP.dat  #NOTE: ipv6 requires another file, see /usr/share/GeoIP.&lt;br /&gt;
 &amp;lt;/IfModule&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now, edit your /etc/apache2/conf-available/zoneminder.conf to look something like this:&lt;br /&gt;
 Alias /zm /usr/share/zoneminder/www&lt;br /&gt;
 &amp;lt;Directory /usr/share/zoneminder/www&amp;gt;&lt;br /&gt;
  Options -Indexes +FollowSymLinks&lt;br /&gt;
  &amp;lt;IfModule mod_dir.c&amp;gt;&lt;br /&gt;
    DirectoryIndex index.php&lt;br /&gt;
  &amp;lt;/IfModule&amp;gt;&lt;br /&gt;
        AllowOverride FileInfo Options&lt;br /&gt;
        SetEnvIf GEOIP_COUNTRY_CODE FR AllowCountry&lt;br /&gt;
        Deny from all&lt;br /&gt;
        Allow from env=AllowCountry&lt;br /&gt;
 &amp;lt;/Directory&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
php test script (note: remove html comment tags)&lt;br /&gt;
 &amp;lt;pre&amp;gt;&amp;lt;!--?php $country_name = apache_note(&amp;quot;GEOIP_COUNTRY_NAME&amp;quot;); echo &amp;quot;Land: &amp;quot; . $country_name; ?--&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that more configuration on zoneminder.conf will be needed, but the above should at least show you that it&amp;#039;s working. Beware that existing connections may need to time out if one is open. The expected result is a 403 (access forbidden) error. Verify the error in access.log.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
If you have trouble, refer to the Debug Logs included in ZMNinja. ZMNinja also has extensive docs.&lt;br /&gt;
&lt;br /&gt;
For further information, refer to the official docs.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=ZMNinja&amp;diff=16736</id>
		<title>ZMNinja</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=ZMNinja&amp;diff=16736"/>
		<updated>2021-11-22T11:30:52Z</updated>

		<summary type="html">&lt;p&gt;Snake: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;ZMNinja is a frontend that allows cellphone and desktop access to ZM. &lt;br /&gt;
&lt;br /&gt;
This is the community wiki documentation on ZMNinja. Please refer to the official docs for more information. https://zmninja.readthedocs.io&lt;br /&gt;
&lt;br /&gt;
==Setting up ZMNinja - serverside==&lt;br /&gt;
Typically when setting up ZMNinja you will be doing so for WAN access. This will require the following:&lt;br /&gt;
&lt;br /&gt;
* Confirm API is working (see [[API]])&lt;br /&gt;
* Enable SSL for apache (covered briefly in API page above)&lt;br /&gt;
* Make sure php-gd is installed (picture thumbnails)(apt-get install php-gd, then restart apache)&lt;br /&gt;
* [[MySQL]]: update zm.Config set Value = 1 where Name = &amp;quot;ZM_AUTH_HASH_LOGINS&amp;quot;; (picture thumbnails)&lt;br /&gt;
&lt;br /&gt;
There isn&amp;#039;t much more to it than that. If your API is working, and you have SSL working, then ZMNinja should do its job. Picture thumbnails will work if you enable auth hash logins and have gd support in php.&lt;br /&gt;
&lt;br /&gt;
This assumes you have installed ZM properly. The easiest (and most maintained) guides are [[Debian]], and [[Ubuntu]].&lt;br /&gt;
&lt;br /&gt;
==Setting up ZMNinja - client==&lt;br /&gt;
&lt;br /&gt;
The next step is to download ZMNinja Pro from your app store (or if using a desktop, the x86 binary from the releases of the git repo),&lt;br /&gt;
&lt;br /&gt;
# Enable ZM Authentication&lt;br /&gt;
# Enable Low bandwidth mode&lt;br /&gt;
# Add username and password (this will only be typed once, then ZMNinja will save it.)&lt;br /&gt;
# Type in the IP address into the 3 paths&lt;br /&gt;
&lt;br /&gt;
The rest of ZMNinja can be left at defaults. The paths can look something like this (Note that usually it autofills partway for you, once you type in the IP):&lt;br /&gt;
&lt;br /&gt;
 ZM Portal URL: https://WANIPOFSERVER/zm/&lt;br /&gt;
 path to cgi-bin: https://WANIPOFSERVER/zm/cgi-bin&lt;br /&gt;
 ZM api url:        https://WANIPOFSERVER/zm/api&lt;br /&gt;
&lt;br /&gt;
[[File:Zmninja instructions 1.png|500px|border|alt=Instructions for Mobile Phone Client ZMNinja||Username and password]]&lt;br /&gt;
&lt;br /&gt;
[[File:Zmninja instructions 2.png|500px|border|alt=Instructions for Mobile Phone Client ZMNinja||WAN IP]]&lt;br /&gt;
&lt;br /&gt;
==Security==&lt;br /&gt;
&lt;br /&gt;
It is recommended to have strong passwords for ZMNinja on the WAN. One method to isolate your network from a potentially vulnerable Zoneminder system on the WAN is to have a separate static IP for your camera network, and then have all of your office LAN use ZMNinja out to the WAN and back to view cameras.&lt;br /&gt;
&lt;br /&gt;
See also: &lt;br /&gt;
https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server#Hardening_Webserver&lt;br /&gt;
&lt;br /&gt;
SSL should be the only port accessible via WAN. SSL certificates should be setup.&lt;br /&gt;
&lt;br /&gt;
Fail2ban is recommended.&lt;br /&gt;
&lt;br /&gt;
Geoblocking is a good idea. There are guides online for geoblocking such as:&lt;br /&gt;
&lt;br /&gt;
* https://wiki.pratznschutz.com/index.php/Apache2_Geo_IP&lt;br /&gt;
&lt;br /&gt;
e.g.&lt;br /&gt;
 #apt-get install libapache2-mod-geoip &lt;br /&gt;
 #a2enmod geoip &lt;br /&gt;
geoip.conf&lt;br /&gt;
 &amp;lt;IfModule mod_geoip.c&amp;gt;&lt;br /&gt;
  GeoIPEnable On&lt;br /&gt;
  GeoIPDBFile /usr/share/GeoIP/GeoIP.dat  #NOTE: ipv6 requires another file, see /usr/share/GeoIP.&lt;br /&gt;
 &amp;lt;/IfModule&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now, edit your /etc/apache2/conf-available/zoneminder.conf to look something like this:&lt;br /&gt;
 Alias /zm /usr/share/zoneminder/www&lt;br /&gt;
 &amp;lt;Directory /usr/share/zoneminder/www&amp;gt;&lt;br /&gt;
  Options -Indexes +FollowSymLinks&lt;br /&gt;
  &amp;lt;IfModule mod_dir.c&amp;gt;&lt;br /&gt;
    DirectoryIndex index.php&lt;br /&gt;
  &amp;lt;/IfModule&amp;gt;&lt;br /&gt;
        AllowOverride FileInfo Options&lt;br /&gt;
        SetEnvIf GEOIP_COUNTRY_CODE FR AllowCountry&lt;br /&gt;
        Deny from all&lt;br /&gt;
        Allow from env=AllowCountry&lt;br /&gt;
 &amp;lt;/Directory&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
php test script (note: remove html comment tags)&lt;br /&gt;
 &amp;lt;pre&amp;gt;&amp;lt;!--?php $country_name = apache_note(&amp;quot;GEOIP_COUNTRY_NAME&amp;quot;); echo &amp;quot;Land: &amp;quot; . $country_name; ?--&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that more configuration on zoneminder.conf will be needed, but the above should at least show you that it&amp;#039;s working. Beware that existing connections may need to time out if one is open. The expected result is a 403 (access forbidden) error. Verify the error in access.log.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
If you have trouble, refer to the Debug Logs included in ZMNinja. ZMNinja also has extensive docs.&lt;br /&gt;
&lt;br /&gt;
For further information, refer to the official docs.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=ZMNinja&amp;diff=16735</id>
		<title>ZMNinja</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=ZMNinja&amp;diff=16735"/>
		<updated>2021-11-22T11:30:14Z</updated>

		<summary type="html">&lt;p&gt;Snake: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;ZMNinja is a program that allows cellphone and desktop access to ZM. Desktop access can be used to test and verify your ZMNinja setup is working, whereby then you can add a mobile phone with a reasonable expectation it will work.&lt;br /&gt;
&lt;br /&gt;
This is the community wiki documentation on ZMNinja. Please refer to the official docs for more information. https://zmninja.readthedocs.io&lt;br /&gt;
&lt;br /&gt;
==Setting up ZMNinja - serverside==&lt;br /&gt;
Typically when setting up ZMNinja you will be doing so for WAN access. This will require the following:&lt;br /&gt;
&lt;br /&gt;
* Confirm API is working (see [[API]])&lt;br /&gt;
* Enable SSL for apache (covered briefly in API page above)&lt;br /&gt;
* Make sure php-gd is installed (picture thumbnails)(apt-get install php-gd, then restart apache)&lt;br /&gt;
* [[MySQL]]: update zm.Config set Value = 1 where Name = &amp;quot;ZM_AUTH_HASH_LOGINS&amp;quot;; (picture thumbnails)&lt;br /&gt;
&lt;br /&gt;
There isn&amp;#039;t much more to it than that. If your API is working, and you have SSL working, then ZMNinja should do its job. Picture thumbnails will work if you enable auth hash logins and have gd support in php.&lt;br /&gt;
&lt;br /&gt;
This assumes you have installed ZM properly. The easiest (and most maintained) guides are [[Debian]], and [[Ubuntu]].&lt;br /&gt;
&lt;br /&gt;
==Setting up ZMNinja - client==&lt;br /&gt;
&lt;br /&gt;
The next step is to download ZMNinja Pro from your app store (or if using a desktop, the x86 binary from the releases of the git repo),&lt;br /&gt;
&lt;br /&gt;
# Enable ZM Authentication&lt;br /&gt;
# Enable Low bandwidth mode&lt;br /&gt;
# Add username and password (this will only be typed once, then ZMNinja will save it.)&lt;br /&gt;
# Type in the IP address into the 3 paths&lt;br /&gt;
&lt;br /&gt;
The rest of ZMNinja can be left at defaults. The paths can look something like this (Note that usually it autofills partway for you, once you type in the IP):&lt;br /&gt;
&lt;br /&gt;
 ZM Portal URL: https://WANIPOFSERVER/zm/&lt;br /&gt;
 path to cgi-bin: https://WANIPOFSERVER/zm/cgi-bin&lt;br /&gt;
 ZM api url:        https://WANIPOFSERVER/zm/api&lt;br /&gt;
&lt;br /&gt;
[[File:Zmninja instructions 1.png|500px|border|alt=Instructions for Mobile Phone Client ZMNinja||Username and password]]&lt;br /&gt;
&lt;br /&gt;
[[File:Zmninja instructions 2.png|500px|border|alt=Instructions for Mobile Phone Client ZMNinja||WAN IP]]&lt;br /&gt;
&lt;br /&gt;
==Security==&lt;br /&gt;
&lt;br /&gt;
It is recommended to have strong passwords for ZMNinja on the WAN. One method to isolate your network from a potentially vulnerable Zoneminder system on the WAN is to have a separate static IP for your camera network, and then have all of your office LAN use ZMNinja out to the WAN and back to view cameras.&lt;br /&gt;
&lt;br /&gt;
See also: &lt;br /&gt;
https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server#Hardening_Webserver&lt;br /&gt;
&lt;br /&gt;
SSL should be the only port accessible via WAN. SSL certificates should be setup.&lt;br /&gt;
&lt;br /&gt;
Fail2ban is recommended.&lt;br /&gt;
&lt;br /&gt;
Geoblocking is a good idea. There are guides online for geoblocking such as:&lt;br /&gt;
&lt;br /&gt;
* https://wiki.pratznschutz.com/index.php/Apache2_Geo_IP&lt;br /&gt;
&lt;br /&gt;
e.g.&lt;br /&gt;
 #apt-get install libapache2-mod-geoip &lt;br /&gt;
 #a2enmod geoip &lt;br /&gt;
geoip.conf&lt;br /&gt;
 &amp;lt;IfModule mod_geoip.c&amp;gt;&lt;br /&gt;
  GeoIPEnable On&lt;br /&gt;
  GeoIPDBFile /usr/share/GeoIP/GeoIP.dat  #NOTE: ipv6 requires another file, see /usr/share/GeoIP.&lt;br /&gt;
 &amp;lt;/IfModule&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now, edit your /etc/apache2/conf-available/zoneminder.conf to look something like this:&lt;br /&gt;
 Alias /zm /usr/share/zoneminder/www&lt;br /&gt;
 &amp;lt;Directory /usr/share/zoneminder/www&amp;gt;&lt;br /&gt;
  Options -Indexes +FollowSymLinks&lt;br /&gt;
  &amp;lt;IfModule mod_dir.c&amp;gt;&lt;br /&gt;
    DirectoryIndex index.php&lt;br /&gt;
  &amp;lt;/IfModule&amp;gt;&lt;br /&gt;
        AllowOverride FileInfo Options&lt;br /&gt;
        SetEnvIf GEOIP_COUNTRY_CODE FR AllowCountry&lt;br /&gt;
        Deny from all&lt;br /&gt;
        Allow from env=AllowCountry&lt;br /&gt;
 &amp;lt;/Directory&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
php test script (note: remove html comment tags)&lt;br /&gt;
 &amp;lt;pre&amp;gt;&amp;lt;!--?php $country_name = apache_note(&amp;quot;GEOIP_COUNTRY_NAME&amp;quot;); echo &amp;quot;Land: &amp;quot; . $country_name; ?--&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that more configuration on zoneminder.conf will be needed, but the above should at least show you that it&amp;#039;s working. Beware that existing connections may need to time out if one is open. The expected result is a 403 (access forbidden) error. Verify the error in access.log.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
If you have trouble, refer to the Debug Logs included in ZMNinja. ZMNinja also has extensive docs.&lt;br /&gt;
&lt;br /&gt;
For further information, refer to the official docs.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=ZMNinja&amp;diff=16734</id>
		<title>ZMNinja</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=ZMNinja&amp;diff=16734"/>
		<updated>2021-11-22T11:28:36Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Setting up ZMNinja - serverside */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;ZMNinja is a program that allows cellphone and desktop access to ZM. Cellphone access is $5 per mobile device. Desktop access is free. Desktop access can be used to test and verify your ZMNinja setup is working, whereby then you can add a mobile phone with a reasonable expectation it will work.&lt;br /&gt;
&lt;br /&gt;
This is the community wiki documentation on ZMNinja. Please refer to the official docs for more information. https://zmninja.readthedocs.io&lt;br /&gt;
&lt;br /&gt;
==Setting up ZMNinja - serverside==&lt;br /&gt;
Typically when setting up ZMNinja you will be doing so for WAN access. This will require the following:&lt;br /&gt;
&lt;br /&gt;
* Confirm API is working (see [[API]])&lt;br /&gt;
* Enable SSL for apache (covered briefly in API page above)&lt;br /&gt;
* Make sure php-gd is installed (picture thumbnails)(apt-get install php-gd, then restart apache)&lt;br /&gt;
* [[MySQL]]: update zm.Config set Value = 1 where Name = &amp;quot;ZM_AUTH_HASH_LOGINS&amp;quot;; (picture thumbnails)&lt;br /&gt;
&lt;br /&gt;
There isn&amp;#039;t much more to it than that. If your API is working, and you have SSL working, then ZMNinja should do its job. Picture thumbnails will work if you enable auth hash logins and have gd support in php.&lt;br /&gt;
&lt;br /&gt;
This assumes you have installed ZM properly. The easiest (and most maintained) guides are [[Debian]], and [[Ubuntu]].&lt;br /&gt;
&lt;br /&gt;
==Setting up ZMNinja - client==&lt;br /&gt;
&lt;br /&gt;
The next step is to download ZMNinja Pro from your app store (or if using a desktop, the x86 binary from the releases of the git repo),&lt;br /&gt;
&lt;br /&gt;
# Enable ZM Authentication&lt;br /&gt;
# Enable Low bandwidth mode&lt;br /&gt;
# Add username and password (this will only be typed once, then ZMNinja will save it.)&lt;br /&gt;
# Type in the IP address into the 3 paths&lt;br /&gt;
&lt;br /&gt;
The rest of ZMNinja can be left at defaults. The paths can look something like this (Note that usually it autofills partway for you, once you type in the IP):&lt;br /&gt;
&lt;br /&gt;
 ZM Portal URL: https://WANIPOFSERVER/zm/&lt;br /&gt;
 path to cgi-bin: https://WANIPOFSERVER/zm/cgi-bin&lt;br /&gt;
 ZM api url:        https://WANIPOFSERVER/zm/api&lt;br /&gt;
&lt;br /&gt;
[[File:Zmninja instructions 1.png|500px|border|alt=Instructions for Mobile Phone Client ZMNinja||Username and password]]&lt;br /&gt;
&lt;br /&gt;
[[File:Zmninja instructions 2.png|500px|border|alt=Instructions for Mobile Phone Client ZMNinja||WAN IP]]&lt;br /&gt;
&lt;br /&gt;
==Security==&lt;br /&gt;
&lt;br /&gt;
It is recommended to have strong passwords for ZMNinja on the WAN. One method to isolate your network from a potentially vulnerable Zoneminder system on the WAN is to have a separate static IP for your camera network, and then have all of your office LAN use ZMNinja out to the WAN and back to view cameras.&lt;br /&gt;
&lt;br /&gt;
See also: &lt;br /&gt;
https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server#Hardening_Webserver&lt;br /&gt;
&lt;br /&gt;
SSL should be the only port accessible via WAN. SSL certificates should be setup.&lt;br /&gt;
&lt;br /&gt;
Fail2ban is recommended.&lt;br /&gt;
&lt;br /&gt;
Geoblocking is a good idea. There are guides online for geoblocking such as:&lt;br /&gt;
&lt;br /&gt;
* https://wiki.pratznschutz.com/index.php/Apache2_Geo_IP&lt;br /&gt;
&lt;br /&gt;
e.g.&lt;br /&gt;
 #apt-get install libapache2-mod-geoip &lt;br /&gt;
 #a2enmod geoip &lt;br /&gt;
geoip.conf&lt;br /&gt;
 &amp;lt;IfModule mod_geoip.c&amp;gt;&lt;br /&gt;
  GeoIPEnable On&lt;br /&gt;
  GeoIPDBFile /usr/share/GeoIP/GeoIP.dat  #NOTE: ipv6 requires another file, see /usr/share/GeoIP.&lt;br /&gt;
 &amp;lt;/IfModule&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now, edit your /etc/apache2/conf-available/zoneminder.conf to look something like this:&lt;br /&gt;
 Alias /zm /usr/share/zoneminder/www&lt;br /&gt;
 &amp;lt;Directory /usr/share/zoneminder/www&amp;gt;&lt;br /&gt;
  Options -Indexes +FollowSymLinks&lt;br /&gt;
  &amp;lt;IfModule mod_dir.c&amp;gt;&lt;br /&gt;
    DirectoryIndex index.php&lt;br /&gt;
  &amp;lt;/IfModule&amp;gt;&lt;br /&gt;
        AllowOverride FileInfo Options&lt;br /&gt;
        SetEnvIf GEOIP_COUNTRY_CODE FR AllowCountry&lt;br /&gt;
        Deny from all&lt;br /&gt;
        Allow from env=AllowCountry&lt;br /&gt;
 &amp;lt;/Directory&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
php test script (note: remove html comment tags)&lt;br /&gt;
 &amp;lt;pre&amp;gt;&amp;lt;!--?php $country_name = apache_note(&amp;quot;GEOIP_COUNTRY_NAME&amp;quot;); echo &amp;quot;Land: &amp;quot; . $country_name; ?--&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that more configuration on zoneminder.conf will be needed, but the above should at least show you that it&amp;#039;s working. Beware that existing connections may need to time out if one is open. The expected result is a 403 (access forbidden) error. Verify the error in access.log.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
If you have trouble, refer to the Debug Logs included in ZMNinja. ZMNinja also has extensive docs.&lt;br /&gt;
&lt;br /&gt;
For further information, refer to the official docs.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=ZMNinja&amp;diff=16733</id>
		<title>ZMNinja</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=ZMNinja&amp;diff=16733"/>
		<updated>2021-11-22T11:28:17Z</updated>

		<summary type="html">&lt;p&gt;Snake: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;ZMNinja is a program that allows cellphone and desktop access to ZM. Cellphone access is $5 per mobile device. Desktop access is free. Desktop access can be used to test and verify your ZMNinja setup is working, whereby then you can add a mobile phone with a reasonable expectation it will work.&lt;br /&gt;
&lt;br /&gt;
This is the community wiki documentation on ZMNinja. Please refer to the official docs for more information. https://zmninja.readthedocs.io&lt;br /&gt;
&lt;br /&gt;
==Setting up ZMNinja - serverside==&lt;br /&gt;
Typically when setting up ZMNinja you will be doing so for WAN access. This will require the following:&lt;br /&gt;
&lt;br /&gt;
* Confirm API is working (see [[API]])&lt;br /&gt;
* Enable SSL for apache (covered briefly in API page above)&lt;br /&gt;
* Make sure php-gd is installed (picture thumbnails)(apt-get install php-gd)(then restart apache)&lt;br /&gt;
* [[MySQL]]: update zm.Config set Value = 1 where Name = &amp;quot;ZM_AUTH_HASH_LOGINS&amp;quot;; (picture thumbnails)&lt;br /&gt;
&lt;br /&gt;
There isn&amp;#039;t much more to it than that. If your API is working, and you have SSL working, then ZMNinja should do its job. Picture thumbnails will work if you enable auth hash logins and have gd support in php.&lt;br /&gt;
&lt;br /&gt;
This assumes you have installed ZM properly. The easiest (and most maintained) guides are [[Debian]], and [[Ubuntu]].&lt;br /&gt;
&lt;br /&gt;
==Setting up ZMNinja - client==&lt;br /&gt;
&lt;br /&gt;
The next step is to download ZMNinja Pro from your app store (or if using a desktop, the x86 binary from the releases of the git repo),&lt;br /&gt;
&lt;br /&gt;
# Enable ZM Authentication&lt;br /&gt;
# Enable Low bandwidth mode&lt;br /&gt;
# Add username and password (this will only be typed once, then ZMNinja will save it.)&lt;br /&gt;
# Type in the IP address into the 3 paths&lt;br /&gt;
&lt;br /&gt;
The rest of ZMNinja can be left at defaults. The paths can look something like this (Note that usually it autofills partway for you, once you type in the IP):&lt;br /&gt;
&lt;br /&gt;
 ZM Portal URL: https://WANIPOFSERVER/zm/&lt;br /&gt;
 path to cgi-bin: https://WANIPOFSERVER/zm/cgi-bin&lt;br /&gt;
 ZM api url:        https://WANIPOFSERVER/zm/api&lt;br /&gt;
&lt;br /&gt;
[[File:Zmninja instructions 1.png|500px|border|alt=Instructions for Mobile Phone Client ZMNinja||Username and password]]&lt;br /&gt;
&lt;br /&gt;
[[File:Zmninja instructions 2.png|500px|border|alt=Instructions for Mobile Phone Client ZMNinja||WAN IP]]&lt;br /&gt;
&lt;br /&gt;
==Security==&lt;br /&gt;
&lt;br /&gt;
It is recommended to have strong passwords for ZMNinja on the WAN. One method to isolate your network from a potentially vulnerable Zoneminder system on the WAN is to have a separate static IP for your camera network, and then have all of your office LAN use ZMNinja out to the WAN and back to view cameras.&lt;br /&gt;
&lt;br /&gt;
See also: &lt;br /&gt;
https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server#Hardening_Webserver&lt;br /&gt;
&lt;br /&gt;
SSL should be the only port accessible via WAN. SSL certificates should be setup.&lt;br /&gt;
&lt;br /&gt;
Fail2ban is recommended.&lt;br /&gt;
&lt;br /&gt;
Geoblocking is a good idea. There are guides online for geoblocking such as:&lt;br /&gt;
&lt;br /&gt;
* https://wiki.pratznschutz.com/index.php/Apache2_Geo_IP&lt;br /&gt;
&lt;br /&gt;
e.g.&lt;br /&gt;
 #apt-get install libapache2-mod-geoip &lt;br /&gt;
 #a2enmod geoip &lt;br /&gt;
geoip.conf&lt;br /&gt;
 &amp;lt;IfModule mod_geoip.c&amp;gt;&lt;br /&gt;
  GeoIPEnable On&lt;br /&gt;
  GeoIPDBFile /usr/share/GeoIP/GeoIP.dat  #NOTE: ipv6 requires another file, see /usr/share/GeoIP.&lt;br /&gt;
 &amp;lt;/IfModule&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now, edit your /etc/apache2/conf-available/zoneminder.conf to look something like this:&lt;br /&gt;
 Alias /zm /usr/share/zoneminder/www&lt;br /&gt;
 &amp;lt;Directory /usr/share/zoneminder/www&amp;gt;&lt;br /&gt;
  Options -Indexes +FollowSymLinks&lt;br /&gt;
  &amp;lt;IfModule mod_dir.c&amp;gt;&lt;br /&gt;
    DirectoryIndex index.php&lt;br /&gt;
  &amp;lt;/IfModule&amp;gt;&lt;br /&gt;
        AllowOverride FileInfo Options&lt;br /&gt;
        SetEnvIf GEOIP_COUNTRY_CODE FR AllowCountry&lt;br /&gt;
        Deny from all&lt;br /&gt;
        Allow from env=AllowCountry&lt;br /&gt;
 &amp;lt;/Directory&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
php test script (note: remove html comment tags)&lt;br /&gt;
 &amp;lt;pre&amp;gt;&amp;lt;!--?php $country_name = apache_note(&amp;quot;GEOIP_COUNTRY_NAME&amp;quot;); echo &amp;quot;Land: &amp;quot; . $country_name; ?--&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that more configuration on zoneminder.conf will be needed, but the above should at least show you that it&amp;#039;s working. Beware that existing connections may need to time out if one is open. The expected result is a 403 (access forbidden) error. Verify the error in access.log.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
If you have trouble, refer to the Debug Logs included in ZMNinja. ZMNinja also has extensive docs.&lt;br /&gt;
&lt;br /&gt;
For further information, refer to the official docs.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=ZMNinja&amp;diff=16732</id>
		<title>ZMNinja</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=ZMNinja&amp;diff=16732"/>
		<updated>2021-11-22T11:25:55Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Setting up ZMNinja - serverside */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;ZMNinja is a program that allows cellphone and desktop access to ZM. Cellphone access is $5 per mobile device. Desktop access is free. Desktop access can be used to test and verify your ZMNinja setup is working, whereby then you can add a mobile phone with a reasonable expectation it will work.&lt;br /&gt;
&lt;br /&gt;
This is the community wiki documentation on ZMNinja. Please refer to the official docs for more information. https://zmninja.readthedocs.io&lt;br /&gt;
&lt;br /&gt;
==Setting up ZMNinja - serverside==&lt;br /&gt;
Typically when setting up ZMNinja you will be doing so for WAN access. This will require the following:&lt;br /&gt;
&lt;br /&gt;
* Confirm API is working (see [[API]])&lt;br /&gt;
* Enable SSL for apache (covered briefly in API page above)&lt;br /&gt;
* Make sure php-gd is installed (picture thumbnails)(apt-get install php-gd)&lt;br /&gt;
* [[MySQL]]: update zm.Config set Value = 1 where Name = &amp;quot;ZM_AUTH_HASH_LOGINS&amp;quot;; (picture thumbnails)&lt;br /&gt;
&lt;br /&gt;
There isn&amp;#039;t much more to it than that. If your API is working, and you have SSL working, then ZMNinja should do its job. Picture thumbnails will work if you enable auth hash logins and have gd support in php.&lt;br /&gt;
&lt;br /&gt;
This assumes you have installed ZM properly. The easiest (and most maintained) guides are [[Debian]], and [[Ubuntu]].&lt;br /&gt;
&lt;br /&gt;
==Setting up ZMNinja - client==&lt;br /&gt;
&lt;br /&gt;
The next step is to download ZMNinja Pro from your app store (or if using a desktop, the x86 binary from the releases of the git repo),&lt;br /&gt;
&lt;br /&gt;
# Enable ZM Authentication&lt;br /&gt;
# Enable Low bandwidth mode&lt;br /&gt;
# Add username and password (this will only be typed once, then ZMNinja will save it.)&lt;br /&gt;
# Type in the IP address into the 3 paths&lt;br /&gt;
&lt;br /&gt;
The rest of ZMNinja can be left at defaults. The paths can look something like this (Note that usually it autofills partway for you, once you type in the IP):&lt;br /&gt;
&lt;br /&gt;
 ZM Portal URL: https://WANIPOFSERVER/zm/&lt;br /&gt;
 path to cgi-bin: https://WANIPOFSERVER/zm/cgi-bin&lt;br /&gt;
 ZM api url:        https://WANIPOFSERVER/zm/api&lt;br /&gt;
&lt;br /&gt;
[[File:Zmninja instructions 1.png|500px|border|alt=Instructions for Mobile Phone Client ZMNinja||Username and password]]&lt;br /&gt;
&lt;br /&gt;
[[File:Zmninja instructions 2.png|500px|border|alt=Instructions for Mobile Phone Client ZMNinja||WAN IP]]&lt;br /&gt;
&lt;br /&gt;
==Security==&lt;br /&gt;
&lt;br /&gt;
It is recommended to have strong passwords for ZMNinja on the WAN. One method to isolate your network from a potentially vulnerable Zoneminder system on the WAN is to have a separate static IP for your camera network, and then have all of your office LAN use ZMNinja out to the WAN and back to view cameras.&lt;br /&gt;
&lt;br /&gt;
See also: &lt;br /&gt;
https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server#Hardening_Webserver&lt;br /&gt;
&lt;br /&gt;
SSL should be the only port accessible via WAN. SSL certificates should be setup.&lt;br /&gt;
&lt;br /&gt;
Fail2ban is recommended.&lt;br /&gt;
&lt;br /&gt;
Geoblocking is a good idea. There are guides online for geoblocking such as:&lt;br /&gt;
&lt;br /&gt;
* https://wiki.pratznschutz.com/index.php/Apache2_Geo_IP&lt;br /&gt;
&lt;br /&gt;
e.g.&lt;br /&gt;
 #apt-get install libapache2-mod-geoip &lt;br /&gt;
 #a2enmod geoip &lt;br /&gt;
geoip.conf&lt;br /&gt;
 &amp;lt;IfModule mod_geoip.c&amp;gt;&lt;br /&gt;
  GeoIPEnable On&lt;br /&gt;
  GeoIPDBFile /usr/share/GeoIP/GeoIP.dat  #NOTE: ipv6 requires another file, see /usr/share/GeoIP.&lt;br /&gt;
 &amp;lt;/IfModule&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now, edit your /etc/apache2/conf-available/zoneminder.conf to look something like this:&lt;br /&gt;
 Alias /zm /usr/share/zoneminder/www&lt;br /&gt;
 &amp;lt;Directory /usr/share/zoneminder/www&amp;gt;&lt;br /&gt;
  Options -Indexes +FollowSymLinks&lt;br /&gt;
  &amp;lt;IfModule mod_dir.c&amp;gt;&lt;br /&gt;
    DirectoryIndex index.php&lt;br /&gt;
  &amp;lt;/IfModule&amp;gt;&lt;br /&gt;
        AllowOverride FileInfo Options&lt;br /&gt;
        SetEnvIf GEOIP_COUNTRY_CODE FR AllowCountry&lt;br /&gt;
        Deny from all&lt;br /&gt;
        Allow from env=AllowCountry&lt;br /&gt;
 &amp;lt;/Directory&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
php test script (note: remove html comment tags)&lt;br /&gt;
 &amp;lt;pre&amp;gt;&amp;lt;!--?php $country_name = apache_note(&amp;quot;GEOIP_COUNTRY_NAME&amp;quot;); echo &amp;quot;Land: &amp;quot; . $country_name; ?--&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that more configuration on zoneminder.conf will be needed, but the above should at least show you that it&amp;#039;s working. Beware that existing connections may need to time out if one is open. The expected result is a 403 (access forbidden) error. Verify the error in access.log.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
If you have trouble, refer to the Debug Logs included in ZMNinja. ZMNinja also has extensive docs.&lt;br /&gt;
&lt;br /&gt;
For further information, refer to the official docs.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=ZMNinja&amp;diff=16731</id>
		<title>ZMNinja</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=ZMNinja&amp;diff=16731"/>
		<updated>2021-11-22T11:25:34Z</updated>

		<summary type="html">&lt;p&gt;Snake: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;ZMNinja is a program that allows cellphone and desktop access to ZM. Cellphone access is $5 per mobile device. Desktop access is free. Desktop access can be used to test and verify your ZMNinja setup is working, whereby then you can add a mobile phone with a reasonable expectation it will work.&lt;br /&gt;
&lt;br /&gt;
This is the community wiki documentation on ZMNinja. Please refer to the official docs for more information. https://zmninja.readthedocs.io&lt;br /&gt;
&lt;br /&gt;
==Setting up ZMNinja - serverside==&lt;br /&gt;
Typically when setting up ZMNinja you will be doing so for WAN access. This will require the following:&lt;br /&gt;
&lt;br /&gt;
* Confirm API is working (see [[API]])&lt;br /&gt;
* Enable SSL for apache (covered briefly in API page above)&lt;br /&gt;
* Make sure php-gd is installed (picture thumbnails)(apt-get install php-gd)&lt;br /&gt;
* [[MySql]]: update zm.Config set Value = 1 where Name = &amp;quot;ZM_AUTH_HASH_LOGINS&amp;quot;; (picture thumbnails)&lt;br /&gt;
&lt;br /&gt;
There isn&amp;#039;t much more to it than that. If your API is working, and you have SSL working, then ZMNinja should do its job. Picture thumbnails will work if you enable auth hash logins and have gd support in php.&lt;br /&gt;
&lt;br /&gt;
This assumes you have installed ZM properly. The easiest (and most maintained) guides are [[Debian]], and [[Ubuntu]].&lt;br /&gt;
&lt;br /&gt;
==Setting up ZMNinja - client==&lt;br /&gt;
&lt;br /&gt;
The next step is to download ZMNinja Pro from your app store (or if using a desktop, the x86 binary from the releases of the git repo),&lt;br /&gt;
&lt;br /&gt;
# Enable ZM Authentication&lt;br /&gt;
# Enable Low bandwidth mode&lt;br /&gt;
# Add username and password (this will only be typed once, then ZMNinja will save it.)&lt;br /&gt;
# Type in the IP address into the 3 paths&lt;br /&gt;
&lt;br /&gt;
The rest of ZMNinja can be left at defaults. The paths can look something like this (Note that usually it autofills partway for you, once you type in the IP):&lt;br /&gt;
&lt;br /&gt;
 ZM Portal URL: https://WANIPOFSERVER/zm/&lt;br /&gt;
 path to cgi-bin: https://WANIPOFSERVER/zm/cgi-bin&lt;br /&gt;
 ZM api url:        https://WANIPOFSERVER/zm/api&lt;br /&gt;
&lt;br /&gt;
[[File:Zmninja instructions 1.png|500px|border|alt=Instructions for Mobile Phone Client ZMNinja||Username and password]]&lt;br /&gt;
&lt;br /&gt;
[[File:Zmninja instructions 2.png|500px|border|alt=Instructions for Mobile Phone Client ZMNinja||WAN IP]]&lt;br /&gt;
&lt;br /&gt;
==Security==&lt;br /&gt;
&lt;br /&gt;
It is recommended to have strong passwords for ZMNinja on the WAN. One method to isolate your network from a potentially vulnerable Zoneminder system on the WAN is to have a separate static IP for your camera network, and then have all of your office LAN use ZMNinja out to the WAN and back to view cameras.&lt;br /&gt;
&lt;br /&gt;
See also: &lt;br /&gt;
https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server#Hardening_Webserver&lt;br /&gt;
&lt;br /&gt;
SSL should be the only port accessible via WAN. SSL certificates should be setup.&lt;br /&gt;
&lt;br /&gt;
Fail2ban is recommended.&lt;br /&gt;
&lt;br /&gt;
Geoblocking is a good idea. There are guides online for geoblocking such as:&lt;br /&gt;
&lt;br /&gt;
* https://wiki.pratznschutz.com/index.php/Apache2_Geo_IP&lt;br /&gt;
&lt;br /&gt;
e.g.&lt;br /&gt;
 #apt-get install libapache2-mod-geoip &lt;br /&gt;
 #a2enmod geoip &lt;br /&gt;
geoip.conf&lt;br /&gt;
 &amp;lt;IfModule mod_geoip.c&amp;gt;&lt;br /&gt;
  GeoIPEnable On&lt;br /&gt;
  GeoIPDBFile /usr/share/GeoIP/GeoIP.dat  #NOTE: ipv6 requires another file, see /usr/share/GeoIP.&lt;br /&gt;
 &amp;lt;/IfModule&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now, edit your /etc/apache2/conf-available/zoneminder.conf to look something like this:&lt;br /&gt;
 Alias /zm /usr/share/zoneminder/www&lt;br /&gt;
 &amp;lt;Directory /usr/share/zoneminder/www&amp;gt;&lt;br /&gt;
  Options -Indexes +FollowSymLinks&lt;br /&gt;
  &amp;lt;IfModule mod_dir.c&amp;gt;&lt;br /&gt;
    DirectoryIndex index.php&lt;br /&gt;
  &amp;lt;/IfModule&amp;gt;&lt;br /&gt;
        AllowOverride FileInfo Options&lt;br /&gt;
        SetEnvIf GEOIP_COUNTRY_CODE FR AllowCountry&lt;br /&gt;
        Deny from all&lt;br /&gt;
        Allow from env=AllowCountry&lt;br /&gt;
 &amp;lt;/Directory&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
php test script (note: remove html comment tags)&lt;br /&gt;
 &amp;lt;pre&amp;gt;&amp;lt;!--?php $country_name = apache_note(&amp;quot;GEOIP_COUNTRY_NAME&amp;quot;); echo &amp;quot;Land: &amp;quot; . $country_name; ?--&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that more configuration on zoneminder.conf will be needed, but the above should at least show you that it&amp;#039;s working. Beware that existing connections may need to time out if one is open. The expected result is a 403 (access forbidden) error. Verify the error in access.log.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
If you have trouble, refer to the Debug Logs included in ZMNinja. ZMNinja also has extensive docs.&lt;br /&gt;
&lt;br /&gt;
For further information, refer to the official docs.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16730</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16730"/>
		<updated>2021-11-21T10:34:20Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Watching the Cameras */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
On the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
If you are already knowledgeable about unix based computers, then you shouldn&amp;#039;t have any trouble.&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). &lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an early [[Axis]]. They are well documented and easy to setup. &lt;br /&gt;
Old ones go for $10-20. Follow the instructions on either the Zoneminder Hardware compatibility list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatibility List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. from terminal: ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5/video.mjpg&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; (obsolete) Precursor to ffmpeg. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide images that change from anywhere on the filesystem). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. Anything RTSP should use FFMPEG.&lt;br /&gt;
&lt;br /&gt;
And some others...&lt;br /&gt;
&lt;br /&gt;
FFMPEG / LibVLC is recommended.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; has the option of either RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
Older cameras from 2000&amp;#039;s. E.g.[[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-30.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
2010&amp;#039;s and newer cameras: These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 means less bytes, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. .&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. That being said, customers generally prefer higher res cameras, so you probably should replace them, unless its a low priority area.&lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog over coax, and I don&amp;#039;t recommend it. It is not standardized yet.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server website and/or ZMNinja.&lt;br /&gt;
&lt;br /&gt;
For business customers use ZMNinja. Its more user friendly. Or build something custom if you like.&lt;br /&gt;
&lt;br /&gt;
You can make fully customizable pages i.e. make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs) if whole img boxes seem to drop out.&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis.&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (better, but uses HDD, and event list timeline in ZMNinja shows 10 minute segments). But all of these are flawed. Here&amp;#039;s what you do: always record two streams per camera. One, the low res stream, is set to modect, with reasonable (but no need to be perfect) settings for detection. Two, the high res stream is set to either record or nodect under linked monitors and uses h264 passthrough.* The hi res compressed stream is saved directly to disk.&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32+, you can use multiple HDs (as many as you like), and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
*Linked monitors have from time to time had bugs or configuration gotchas, so for simplicity sake, I use record. HDD space is cheap.&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until few false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by e.g. &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. &lt;br /&gt;
&lt;br /&gt;
Flawless professional systems use hardware motion detectors, as software detection is not perfect. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442 You aren&amp;#039;t mil grade probably so just use sensitive zone settings and two streams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
You can re run analysis on old videos with: https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video, then make that a video source in zm as file.).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones Tip&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*You can use external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required. More setup cost though.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors (48v poe is recommended though).&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
* If you are setting up mobile phones with ZMNinja, and the wifi is the same WAN IP as the camera system, setup a VPS with a http/https proxy and point zmninja at the proxy. The proxy can be as simple as: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:80&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:443&lt;br /&gt;
sudo iptables-legacy -t nat -A POSTROUTING -j MASQUERADE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note that you might want to set nonstandard ports.&lt;br /&gt;
&lt;br /&gt;
* run 2k cameras at least. people like flashy things (like birds) and hi res.&lt;br /&gt;
&lt;br /&gt;
* users seem to like fluid video, so put high fps on low res substream. analysis fps limit to 2. we don&amp;#039;t have (asic) hardware yet, so there are limits, but cpu is still pretty powerful.&lt;br /&gt;
&lt;br /&gt;
* the more you overbuild the cpu, the faster you can go.&lt;br /&gt;
&lt;br /&gt;
* passthrough on hi res stream obv. watch low res stream live, expand / open window to hi res stream, ideally (custom javascript could do this:todo).&lt;br /&gt;
&lt;br /&gt;
* use zmninja + the website. offer customers both apps. there are also some other apps available. (e.g. possibly zmsquarer).&lt;br /&gt;
&lt;br /&gt;
* in most cases, you should replace coax cams with ethernet. customers that are camera happy tend to like hi res, whether its needed or not, and coax is low res.&lt;br /&gt;
&lt;br /&gt;
* (optional) configure zmes or good blob detection. you pretty much only will be detecting people in the average business. maybe cars. For extra points, figure out how to assign names to people in zmes.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16729</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16729"/>
		<updated>2021-11-21T10:32:40Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Watching the Cameras */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
On the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
If you are already knowledgeable about unix based computers, then you shouldn&amp;#039;t have any trouble.&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). &lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an early [[Axis]]. They are well documented and easy to setup. &lt;br /&gt;
Old ones go for $10-20. Follow the instructions on either the Zoneminder Hardware compatibility list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatibility List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. from terminal: ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5/video.mjpg&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; (obsolete) Precursor to ffmpeg. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide images that change from anywhere on the filesystem). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. Anything RTSP should use FFMPEG.&lt;br /&gt;
&lt;br /&gt;
And some others...&lt;br /&gt;
&lt;br /&gt;
FFMPEG / LibVLC is recommended.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; has the option of either RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
Older cameras from 2000&amp;#039;s. E.g.[[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-30.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
2010&amp;#039;s and newer cameras: These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 means less bytes, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. .&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. That being said, customers generally prefer higher res cameras, so you probably should replace them, unless its a low priority area.&lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog over coax, and I don&amp;#039;t recommend it. It is not standardized yet.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server website and/or ZMNinja.&lt;br /&gt;
&lt;br /&gt;
You can make fully customizable pages i.e. make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs) if whole img boxes seem to drop out.&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis.&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (better, but uses HDD, and event list timeline in ZMNinja shows 10 minute segments). But all of these are flawed. Here&amp;#039;s what you do: always record two streams per camera. One, the low res stream, is set to modect, with reasonable (but no need to be perfect) settings for detection. Two, the high res stream is set to either record or nodect under linked monitors and uses h264 passthrough.* The hi res compressed stream is saved directly to disk.&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32+, you can use multiple HDs (as many as you like), and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
*Linked monitors have from time to time had bugs or configuration gotchas, so for simplicity sake, I use record. HDD space is cheap.&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until few false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by e.g. &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. &lt;br /&gt;
&lt;br /&gt;
Flawless professional systems use hardware motion detectors, as software detection is not perfect. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442 You aren&amp;#039;t mil grade probably so just use sensitive zone settings and two streams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
You can re run analysis on old videos with: https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video, then make that a video source in zm as file.).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones Tip&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*You can use external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required. More setup cost though.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors (48v poe is recommended though).&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
* If you are setting up mobile phones with ZMNinja, and the wifi is the same WAN IP as the camera system, setup a VPS with a http/https proxy and point zmninja at the proxy. The proxy can be as simple as: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:80&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:443&lt;br /&gt;
sudo iptables-legacy -t nat -A POSTROUTING -j MASQUERADE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note that you might want to set nonstandard ports.&lt;br /&gt;
&lt;br /&gt;
* run 2k cameras at least. people like flashy things (like birds) and hi res.&lt;br /&gt;
&lt;br /&gt;
* users seem to like fluid video, so put high fps on low res substream. analysis fps limit to 2. we don&amp;#039;t have (asic) hardware yet, so there are limits, but cpu is still pretty powerful.&lt;br /&gt;
&lt;br /&gt;
* the more you overbuild the cpu, the faster you can go.&lt;br /&gt;
&lt;br /&gt;
* passthrough on hi res stream obv. watch low res stream live, expand / open window to hi res stream, ideally (custom javascript could do this:todo).&lt;br /&gt;
&lt;br /&gt;
* use zmninja + the website. offer customers both apps. there are also some other apps available. (e.g. possibly zmsquarer).&lt;br /&gt;
&lt;br /&gt;
* in most cases, you should replace coax cams with ethernet. customers that are camera happy tend to like hi res, whether its needed or not, and coax is low res.&lt;br /&gt;
&lt;br /&gt;
* (optional) configure zmes or good blob detection. you pretty much only will be detecting people in the average business. maybe cars. For extra points, figure out how to assign names to people in zmes.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16728</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16728"/>
		<updated>2021-11-21T10:31:43Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Obtaining more Cameras */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
On the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
If you are already knowledgeable about unix based computers, then you shouldn&amp;#039;t have any trouble.&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). &lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an early [[Axis]]. They are well documented and easy to setup. &lt;br /&gt;
Old ones go for $10-20. Follow the instructions on either the Zoneminder Hardware compatibility list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatibility List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. from terminal: ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5/video.mjpg&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; (obsolete) Precursor to ffmpeg. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide images that change from anywhere on the filesystem). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. Anything RTSP should use FFMPEG.&lt;br /&gt;
&lt;br /&gt;
And some others...&lt;br /&gt;
&lt;br /&gt;
FFMPEG / LibVLC is recommended.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; has the option of either RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
Older cameras from 2000&amp;#039;s. E.g.[[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-30.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
2010&amp;#039;s and newer cameras: These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 means less bytes, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. .&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. That being said, customers generally prefer higher res cameras, so you probably should replace them, unless its a low priority area.&lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog over coax, and I don&amp;#039;t recommend it. It is not standardized yet.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server website and/or ZMNinja.&lt;br /&gt;
&lt;br /&gt;
Yu can make fully customizable pages i.e. make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs) if whole img boxes seem to drop out.&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis.&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (better, but uses HDD, and event list timeline in ZMNinja shows 10 minute segments). But all of these are flawed. Here&amp;#039;s what you do: always record two streams per camera. One, the low res stream, is set to modect, with reasonable (but no need to be perfect) settings for detection. Two, the high res stream is set to either record or nodect under linked monitors and uses h264 passthrough.* The hi res compressed stream is saved directly to disk.&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32+, you can use multiple HDs (as many as you like), and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
*Linked monitors have from time to time had bugs or configuration gotchas, so for simplicity sake, I use record. HDD space is cheap.&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until few false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by e.g. &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. &lt;br /&gt;
&lt;br /&gt;
Flawless professional systems use hardware motion detectors, as software detection is not perfect. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442 You aren&amp;#039;t mil grade probably so just use sensitive zone settings and two streams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
You can re run analysis on old videos with: https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video, then make that a video source in zm as file.).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones Tip&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*You can use external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required. More setup cost though.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors (48v poe is recommended though).&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
* If you are setting up mobile phones with ZMNinja, and the wifi is the same WAN IP as the camera system, setup a VPS with a http/https proxy and point zmninja at the proxy. The proxy can be as simple as: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:80&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:443&lt;br /&gt;
sudo iptables-legacy -t nat -A POSTROUTING -j MASQUERADE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note that you might want to set nonstandard ports.&lt;br /&gt;
&lt;br /&gt;
* run 2k cameras at least. people like flashy things (like birds) and hi res.&lt;br /&gt;
&lt;br /&gt;
* users seem to like fluid video, so put high fps on low res substream. analysis fps limit to 2. we don&amp;#039;t have (asic) hardware yet, so there are limits, but cpu is still pretty powerful.&lt;br /&gt;
&lt;br /&gt;
* the more you overbuild the cpu, the faster you can go.&lt;br /&gt;
&lt;br /&gt;
* passthrough on hi res stream obv. watch low res stream live, expand / open window to hi res stream, ideally (custom javascript could do this:todo).&lt;br /&gt;
&lt;br /&gt;
* use zmninja + the website. offer customers both apps. there are also some other apps available. (e.g. possibly zmsquarer).&lt;br /&gt;
&lt;br /&gt;
* in most cases, you should replace coax cams with ethernet. customers that are camera happy tend to like hi res, whether its needed or not, and coax is low res.&lt;br /&gt;
&lt;br /&gt;
* (optional) configure zmes or good blob detection. you pretty much only will be detecting people in the average business. maybe cars. For extra points, figure out how to assign names to people in zmes.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16727</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16727"/>
		<updated>2021-11-21T10:29:52Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Install */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
On the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
If you are already knowledgeable about unix based computers, then you shouldn&amp;#039;t have any trouble.&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). &lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an early [[Axis]]. They are well documented and easy to setup. &lt;br /&gt;
Old ones go for $10-20. Follow the instructions on either the Zoneminder Hardware compatibility list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatibility List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. from terminal: ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5/video.mjpg&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; (obsolete) Precursor to ffmpeg. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide images that change from anywhere on the filesystem). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. Anything RTSP should use FFMPEG.&lt;br /&gt;
&lt;br /&gt;
And some others...&lt;br /&gt;
&lt;br /&gt;
FFMPEG / LibVLC is recommended.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; has the option of either RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
These include [[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-30.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 means less bytes, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. .&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. That being said, customers generally prefer higher res cameras, so you probably should replace them, unless its a low priority area.&lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog over coax, and I don&amp;#039;t recommend it. It is not standardized yet.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server website and/or ZMNinja.&lt;br /&gt;
&lt;br /&gt;
Yu can make fully customizable pages i.e. make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs) if whole img boxes seem to drop out.&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis.&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (better, but uses HDD, and event list timeline in ZMNinja shows 10 minute segments). But all of these are flawed. Here&amp;#039;s what you do: always record two streams per camera. One, the low res stream, is set to modect, with reasonable (but no need to be perfect) settings for detection. Two, the high res stream is set to either record or nodect under linked monitors and uses h264 passthrough.* The hi res compressed stream is saved directly to disk.&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32+, you can use multiple HDs (as many as you like), and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
*Linked monitors have from time to time had bugs or configuration gotchas, so for simplicity sake, I use record. HDD space is cheap.&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until few false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by e.g. &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. &lt;br /&gt;
&lt;br /&gt;
Flawless professional systems use hardware motion detectors, as software detection is not perfect. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442 You aren&amp;#039;t mil grade probably so just use sensitive zone settings and two streams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
You can re run analysis on old videos with: https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video, then make that a video source in zm as file.).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones Tip&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*You can use external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required. More setup cost though.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors (48v poe is recommended though).&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
* If you are setting up mobile phones with ZMNinja, and the wifi is the same WAN IP as the camera system, setup a VPS with a http/https proxy and point zmninja at the proxy. The proxy can be as simple as: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:80&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:443&lt;br /&gt;
sudo iptables-legacy -t nat -A POSTROUTING -j MASQUERADE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note that you might want to set nonstandard ports.&lt;br /&gt;
&lt;br /&gt;
* run 2k cameras at least. people like flashy things (like birds) and hi res.&lt;br /&gt;
&lt;br /&gt;
* users seem to like fluid video, so put high fps on low res substream. analysis fps limit to 2. we don&amp;#039;t have (asic) hardware yet, so there are limits, but cpu is still pretty powerful.&lt;br /&gt;
&lt;br /&gt;
* the more you overbuild the cpu, the faster you can go.&lt;br /&gt;
&lt;br /&gt;
* passthrough on hi res stream obv. watch low res stream live, expand / open window to hi res stream, ideally (custom javascript could do this:todo).&lt;br /&gt;
&lt;br /&gt;
* use zmninja + the website. offer customers both apps. there are also some other apps available. (e.g. possibly zmsquarer).&lt;br /&gt;
&lt;br /&gt;
* in most cases, you should replace coax cams with ethernet. customers that are camera happy tend to like hi res, whether its needed or not, and coax is low res.&lt;br /&gt;
&lt;br /&gt;
* (optional) configure zmes or good blob detection. you pretty much only will be detecting people in the average business. maybe cars. For extra points, figure out how to assign names to people in zmes.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16726</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16726"/>
		<updated>2021-11-21T10:28:48Z</updated>

		<summary type="html">&lt;p&gt;Snake: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
On the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
If you are already knowledgeable about unix based computers, then you shouldn&amp;#039;t have any trouble.&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). &lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
Use 1.34.&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an early [[Axis]]. They are well documented and easy to setup. &lt;br /&gt;
Old ones go for $10-20. Follow the instructions on either the Zoneminder Hardware compatibility list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatibility List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. from terminal: ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5/video.mjpg&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; (obsolete) Precursor to ffmpeg. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide images that change from anywhere on the filesystem). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. Anything RTSP should use FFMPEG.&lt;br /&gt;
&lt;br /&gt;
And some others...&lt;br /&gt;
&lt;br /&gt;
FFMPEG / LibVLC is recommended.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; has the option of either RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
These include [[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-30.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 means less bytes, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. .&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. That being said, customers generally prefer higher res cameras, so you probably should replace them, unless its a low priority area.&lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog over coax, and I don&amp;#039;t recommend it. It is not standardized yet.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server website and/or ZMNinja.&lt;br /&gt;
&lt;br /&gt;
Yu can make fully customizable pages i.e. make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs) if whole img boxes seem to drop out.&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis.&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (better, but uses HDD, and event list timeline in ZMNinja shows 10 minute segments). But all of these are flawed. Here&amp;#039;s what you do: always record two streams per camera. One, the low res stream, is set to modect, with reasonable (but no need to be perfect) settings for detection. Two, the high res stream is set to either record or nodect under linked monitors and uses h264 passthrough.* The hi res compressed stream is saved directly to disk.&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32+, you can use multiple HDs (as many as you like), and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
*Linked monitors have from time to time had bugs or configuration gotchas, so for simplicity sake, I use record. HDD space is cheap.&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until few false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by e.g. &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. &lt;br /&gt;
&lt;br /&gt;
Flawless professional systems use hardware motion detectors, as software detection is not perfect. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442 You aren&amp;#039;t mil grade probably so just use sensitive zone settings and two streams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
You can re run analysis on old videos with: https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video, then make that a video source in zm as file.).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones Tip&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*You can use external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required. More setup cost though.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors (48v poe is recommended though).&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
* If you are setting up mobile phones with ZMNinja, and the wifi is the same WAN IP as the camera system, setup a VPS with a http/https proxy and point zmninja at the proxy. The proxy can be as simple as: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:80&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:443&lt;br /&gt;
sudo iptables-legacy -t nat -A POSTROUTING -j MASQUERADE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note that you might want to set nonstandard ports.&lt;br /&gt;
&lt;br /&gt;
* run 2k cameras at least. people like flashy things (like birds) and hi res.&lt;br /&gt;
&lt;br /&gt;
* users seem to like fluid video, so put high fps on low res substream. analysis fps limit to 2. we don&amp;#039;t have (asic) hardware yet, so there are limits, but cpu is still pretty powerful.&lt;br /&gt;
&lt;br /&gt;
* the more you overbuild the cpu, the faster you can go.&lt;br /&gt;
&lt;br /&gt;
* passthrough on hi res stream obv. watch low res stream live, expand / open window to hi res stream, ideally (custom javascript could do this:todo).&lt;br /&gt;
&lt;br /&gt;
* use zmninja + the website. offer customers both apps. there are also some other apps available. (e.g. possibly zmsquarer).&lt;br /&gt;
&lt;br /&gt;
* in most cases, you should replace coax cams with ethernet. customers that are camera happy tend to like hi res, whether its needed or not, and coax is low res.&lt;br /&gt;
&lt;br /&gt;
* (optional) configure zmes or good blob detection. you pretty much only will be detecting people in the average business. maybe cars. For extra points, figure out how to assign names to people in zmes.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16725</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16725"/>
		<updated>2021-11-21T10:27:53Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Notes */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
Consider the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
If you are already knowledgeable about servers, then you shouldn&amp;#039;t have any trouble.&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). &lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
Use 1.34.&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an early [[Axis]]. They are well documented and easy to setup. &lt;br /&gt;
Old ones go for $10-20. Follow the instructions on either the Zoneminder Hardware compatibility list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatibility List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. from terminal: ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5/video.mjpg&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; (obsolete) Precursor to ffmpeg. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide images that change from anywhere on the filesystem). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. Anything RTSP should use FFMPEG.&lt;br /&gt;
&lt;br /&gt;
And some others...&lt;br /&gt;
&lt;br /&gt;
FFMPEG / LibVLC is recommended.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; has the option of either RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
These include [[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-30.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 means less bytes, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. .&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. That being said, customers generally prefer higher res cameras, so you probably should replace them, unless its a low priority area.&lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog over coax, and I don&amp;#039;t recommend it. It is not standardized yet.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server website and/or ZMNinja.&lt;br /&gt;
&lt;br /&gt;
Yu can make fully customizable pages i.e. make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs) if whole img boxes seem to drop out.&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis.&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (better, but uses HDD, and event list timeline in ZMNinja shows 10 minute segments). But all of these are flawed. Here&amp;#039;s what you do: always record two streams per camera. One, the low res stream, is set to modect, with reasonable (but no need to be perfect) settings for detection. Two, the high res stream is set to either record or nodect under linked monitors and uses h264 passthrough.* The hi res compressed stream is saved directly to disk.&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32+, you can use multiple HDs (as many as you like), and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
*Linked monitors have from time to time had bugs or configuration gotchas, so for simplicity sake, I use record. HDD space is cheap.&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until few false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by e.g. &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. &lt;br /&gt;
&lt;br /&gt;
Flawless professional systems use hardware motion detectors, as software detection is not perfect. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442 You aren&amp;#039;t mil grade probably so just use sensitive zone settings and two streams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
You can re run analysis on old videos with: https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video, then make that a video source in zm as file.).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones Tip&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*You can use external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required. More setup cost though.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors (48v poe is recommended though).&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
* If you are setting up mobile phones with ZMNinja, and the wifi is the same WAN IP as the camera system, setup a VPS with a http/https proxy and point zmninja at the proxy. The proxy can be as simple as: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:80&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:443&lt;br /&gt;
sudo iptables-legacy -t nat -A POSTROUTING -j MASQUERADE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note that you might want to set nonstandard ports.&lt;br /&gt;
&lt;br /&gt;
* run 2k cameras at least. people like flashy things (like birds) and hi res.&lt;br /&gt;
&lt;br /&gt;
* users seem to like fluid video, so put high fps on low res substream. analysis fps limit to 2. we don&amp;#039;t have (asic) hardware yet, so there are limits, but cpu is still pretty powerful.&lt;br /&gt;
&lt;br /&gt;
* the more you overbuild the cpu, the faster you can go.&lt;br /&gt;
&lt;br /&gt;
* passthrough on hi res stream obv. watch low res stream live, expand / open window to hi res stream, ideally (custom javascript could do this:todo).&lt;br /&gt;
&lt;br /&gt;
* use zmninja + the website. offer customers both apps. there are also some other apps available. (e.g. possibly zmsquarer).&lt;br /&gt;
&lt;br /&gt;
* in most cases, you should replace coax cams with ethernet. customers that are camera happy tend to like hi res, whether its needed or not, and coax is low res.&lt;br /&gt;
&lt;br /&gt;
* (optional) configure zmes or good blob detection. you pretty much only will be detecting people in the average business. maybe cars. For extra points, figure out how to assign names to people in zmes.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16724</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16724"/>
		<updated>2021-11-21T10:27:31Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Notes */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
Consider the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
If you are already knowledgeable about servers, then you shouldn&amp;#039;t have any trouble.&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). &lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
Use 1.34.&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an early [[Axis]]. They are well documented and easy to setup. &lt;br /&gt;
Old ones go for $10-20. Follow the instructions on either the Zoneminder Hardware compatibility list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatibility List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. from terminal: ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5/video.mjpg&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; (obsolete) Precursor to ffmpeg. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide images that change from anywhere on the filesystem). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. Anything RTSP should use FFMPEG.&lt;br /&gt;
&lt;br /&gt;
And some others...&lt;br /&gt;
&lt;br /&gt;
FFMPEG / LibVLC is recommended.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; has the option of either RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
These include [[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-30.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 means less bytes, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. .&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. That being said, customers generally prefer higher res cameras, so you probably should replace them, unless its a low priority area.&lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog over coax, and I don&amp;#039;t recommend it. It is not standardized yet.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server website and/or ZMNinja.&lt;br /&gt;
&lt;br /&gt;
Yu can make fully customizable pages i.e. make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs) if whole img boxes seem to drop out.&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis.&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (better, but uses HDD, and event list timeline in ZMNinja shows 10 minute segments). But all of these are flawed. Here&amp;#039;s what you do: always record two streams per camera. One, the low res stream, is set to modect, with reasonable (but no need to be perfect) settings for detection. Two, the high res stream is set to either record or nodect under linked monitors and uses h264 passthrough.* The hi res compressed stream is saved directly to disk.&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32+, you can use multiple HDs (as many as you like), and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
*Linked monitors have from time to time had bugs or configuration gotchas, so for simplicity sake, I use record. HDD space is cheap.&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until few false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by e.g. &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. &lt;br /&gt;
&lt;br /&gt;
Flawless professional systems use hardware motion detectors, as software detection is not perfect. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442 You aren&amp;#039;t mil grade probably so just use sensitive zone settings and two streams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
You can re run analysis on old videos with: https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video, then make that a video source in zm as file.).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones Tip&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*You can use external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required. More setup cost though.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors (48v poe is recommended though).&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
* If you are setting up mobile phones with ZMNinja, and the wifi is the same WAN IP as the camera system, setup a VPS with a http/https proxy and point zmninja at the proxy. The proxy can be as simple as: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:80&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:443&lt;br /&gt;
sudo iptables-legacy -t nat -A POSTROUTING -j MASQUERADE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note that you might want to set nonstandard ports.&lt;br /&gt;
&lt;br /&gt;
* run 2k cameras at least. people like flashy things (like birds) and hi res.&lt;br /&gt;
&lt;br /&gt;
* users seem to like fluid video, so put high fps on low res substream. analysis fps limit to 2. we don&amp;#039;t have (asic) hardware yet, so there are limits, but cpu is still pretty &lt;br /&gt;
powerful.&lt;br /&gt;
&lt;br /&gt;
* the more you overbuild the cpu, the faster you can go.&lt;br /&gt;
&lt;br /&gt;
* passthrough on hi res stream obv. watch low res stream live, expand / open window to hi res stream, ideally (custom javascript could do this:todo).&lt;br /&gt;
&lt;br /&gt;
* use zmninja + the website. offer customers both apps. there are also some other apps available. (e.g. possibly zmsquarer).&lt;br /&gt;
&lt;br /&gt;
* in most cases, you should replace coax cams with ethernet. customers that are camera happy tend to like hi res, whether its needed or not, and coax is low res.&lt;br /&gt;
&lt;br /&gt;
* (optional) configure zmes or good blob detection. you pretty much only will be detecting people in the average business. maybe cars. For extra points, figure out how to assign names to people in zmes.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16723</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16723"/>
		<updated>2021-11-21T10:26:20Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Hardware Advice */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
Consider the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
If you are already knowledgeable about servers, then you shouldn&amp;#039;t have any trouble.&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). &lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
Use 1.34.&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an early [[Axis]]. They are well documented and easy to setup. &lt;br /&gt;
Old ones go for $10-20. Follow the instructions on either the Zoneminder Hardware compatibility list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatibility List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. from terminal: ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5/video.mjpg&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; (obsolete) Precursor to ffmpeg. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide images that change from anywhere on the filesystem). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. Anything RTSP should use FFMPEG.&lt;br /&gt;
&lt;br /&gt;
And some others...&lt;br /&gt;
&lt;br /&gt;
FFMPEG / LibVLC is recommended.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; has the option of either RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
These include [[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-30.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 means less bytes, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. .&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. That being said, customers generally prefer higher res cameras, so you probably should replace them, unless its a low priority area.&lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog over coax, and I don&amp;#039;t recommend it. It is not standardized yet.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server website and/or ZMNinja.&lt;br /&gt;
&lt;br /&gt;
Yu can make fully customizable pages i.e. make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs) if whole img boxes seem to drop out.&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis.&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (better, but uses HDD, and event list timeline in ZMNinja shows 10 minute segments). But all of these are flawed. Here&amp;#039;s what you do: always record two streams per camera. One, the low res stream, is set to modect, with reasonable (but no need to be perfect) settings for detection. Two, the high res stream is set to either record or nodect under linked monitors and uses h264 passthrough.* The hi res compressed stream is saved directly to disk.&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32+, you can use multiple HDs (as many as you like), and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
*Linked monitors have from time to time had bugs or configuration gotchas, so for simplicity sake, I use record. HDD space is cheap.&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until few false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by e.g. &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. &lt;br /&gt;
&lt;br /&gt;
Flawless professional systems use hardware motion detectors, as software detection is not perfect. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442 You aren&amp;#039;t mil grade probably so just use sensitive zone settings and two streams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
You can re run analysis on old videos with: https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video, then make that a video source in zm as file.).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones Tip&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*You can use external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required. More setup cost though.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors (48v poe is recommended though).&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
* If you are setting up mobile phones with ZMNinja, and the wifi is the same WAN IP as the camera system, setup a VPS with a http/https proxy and point zmninja at the proxy. The proxy can be as simple as: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:80&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:443&lt;br /&gt;
sudo iptables-legacy -t nat -A POSTROUTING -j MASQUERADE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note that you might want to set nonstandard ports.&lt;br /&gt;
&lt;br /&gt;
* run 2k cameras at least. people like flashy things (like birds) and hi &lt;br /&gt;
res.&lt;br /&gt;
&lt;br /&gt;
* users seem to like fluid video, so put high fps on low res substream. &lt;br /&gt;
analysis fps limit to 2. we don&amp;#039;t have (asic) hardware yet, so there are limits, but cpu is still pretty &lt;br /&gt;
powerful.&lt;br /&gt;
&lt;br /&gt;
* the more you overbuild the cpu, the faster you can go.&lt;br /&gt;
&lt;br /&gt;
* passthrough on hi res stream obv. watch low res stream live, expand / &lt;br /&gt;
open window to hi res stream, ideally (custom javascript could do this:todo).&lt;br /&gt;
&lt;br /&gt;
* use zmninja + the website. offer customers both apps. there are also some other apps available. (e.g. possibly zmsquarer).&lt;br /&gt;
&lt;br /&gt;
* in most cases, you should replace coax cams with ethernet. customers&lt;br /&gt;
that are camera happy tend to like hi res, whether its needed or not, &lt;br /&gt;
and coax is low res.&lt;br /&gt;
&lt;br /&gt;
* (optional) configure zmes or good blob detection. you pretty much only&lt;br /&gt;
will be detecting people in the average business. maybe cars. For extra points, &lt;br /&gt;
figure out how to assign names to people in zmes.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16722</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16722"/>
		<updated>2021-11-21T10:25:23Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Tips */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
Consider the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
If you are already knowledgeable about servers, then you shouldn&amp;#039;t have any trouble.&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). &lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
Use 1.34.&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an early [[Axis]]. They are well documented and easy to setup. &lt;br /&gt;
Old ones go for $10-20. Follow the instructions on either the Zoneminder Hardware compatibility list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatibility List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. from terminal: ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5/video.mjpg&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; (obsolete) Precursor to ffmpeg. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide images that change from anywhere on the filesystem). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. Anything RTSP should use FFMPEG.&lt;br /&gt;
&lt;br /&gt;
And some others...&lt;br /&gt;
&lt;br /&gt;
FFMPEG / LibVLC is recommended.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; has the option of either RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
These include [[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-30.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 means less bytes, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. .&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. That being said, customers generally prefer higher res cameras, so you probably should replace them, unless its a low priority area.&lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog over coax, and I don&amp;#039;t recommend it. It is not standardized yet.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server website and/or ZMNinja.&lt;br /&gt;
&lt;br /&gt;
Yu can make fully customizable pages i.e. make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs) if whole img boxes seem to drop out.&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis.&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (better, but uses HDD, and event list timeline in ZMNinja shows 10 minute segments). But all of these are flawed. Here&amp;#039;s what you do: always record two streams per camera. One, the low res stream, is set to modect, with reasonable (but no need to be perfect) settings for detection. Two, the high res stream is set to either record or nodect under linked monitors and uses h264 passthrough.* The hi res compressed stream is saved directly to disk.&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32+, you can use multiple HDs (as many as you like), and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
*Linked monitors have from time to time had bugs or configuration gotchas, so for simplicity sake, I use record. HDD space is cheap.&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until few false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by e.g. &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. &lt;br /&gt;
&lt;br /&gt;
Flawless professional systems use hardware motion detectors, as software detection is not perfect. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442 You aren&amp;#039;t mil grade probably so just use sensitive zone settings and two streams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
You can re run analysis on old videos with: https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video, then make that a video source in zm as file.).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones Tip&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*You can use external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required. More setup cost though.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors.&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
* If you are setting up mobile phones with ZMNinja, and the wifi is the same WAN IP as the camera system, setup a VPS with a http/https proxy and point zmninja at the proxy. The proxy can be as simple as: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:80&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:443&lt;br /&gt;
sudo iptables-legacy -t nat -A POSTROUTING -j MASQUERADE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note that you might want to set nonstandard ports.&lt;br /&gt;
&lt;br /&gt;
* run 2k cameras at least. people like flashy things (like birds) and hi &lt;br /&gt;
res.&lt;br /&gt;
&lt;br /&gt;
* users seem to like fluid video, so put high fps on low res substream. &lt;br /&gt;
analysis fps limit to 2. we don&amp;#039;t have (asic) hardware yet, so there are limits, but cpu is still pretty &lt;br /&gt;
powerful.&lt;br /&gt;
&lt;br /&gt;
* the more you overbuild the cpu, the faster you can go.&lt;br /&gt;
&lt;br /&gt;
* passthrough on hi res stream obv. watch low res stream live, expand / &lt;br /&gt;
open window to hi res stream, ideally (custom javascript could do this:todo).&lt;br /&gt;
&lt;br /&gt;
* use zmninja + the website. offer customers both apps. there are also some other apps available. (e.g. possibly zmsquarer).&lt;br /&gt;
&lt;br /&gt;
* in most cases, you should replace coax cams with ethernet. customers&lt;br /&gt;
that are camera happy tend to like hi res, whether its needed or not, &lt;br /&gt;
and coax is low res.&lt;br /&gt;
&lt;br /&gt;
* (optional) configure zmes or good blob detection. you pretty much only&lt;br /&gt;
will be detecting people in the average business. maybe cars. For extra points, &lt;br /&gt;
figure out how to assign names to people in zmes.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16721</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16721"/>
		<updated>2021-11-21T10:23:44Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Motion Detection */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
Consider the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
If you are already knowledgeable about servers, then you shouldn&amp;#039;t have any trouble.&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). &lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
Use 1.34.&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an early [[Axis]]. They are well documented and easy to setup. &lt;br /&gt;
Old ones go for $10-20. Follow the instructions on either the Zoneminder Hardware compatibility list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatibility List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. from terminal: ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5/video.mjpg&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; (obsolete) Precursor to ffmpeg. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide images that change from anywhere on the filesystem). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. Anything RTSP should use FFMPEG.&lt;br /&gt;
&lt;br /&gt;
And some others...&lt;br /&gt;
&lt;br /&gt;
FFMPEG / LibVLC is recommended.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; has the option of either RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
These include [[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-30.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 means less bytes, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. .&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. That being said, customers generally prefer higher res cameras, so you probably should replace them, unless its a low priority area.&lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog over coax, and I don&amp;#039;t recommend it. It is not standardized yet.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server website and/or ZMNinja.&lt;br /&gt;
&lt;br /&gt;
Yu can make fully customizable pages i.e. make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs) if whole img boxes seem to drop out.&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis.&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (better, but uses HDD, and event list timeline in ZMNinja shows 10 minute segments). But all of these are flawed. Here&amp;#039;s what you do: always record two streams per camera. One, the low res stream, is set to modect, with reasonable (but no need to be perfect) settings for detection. Two, the high res stream is set to either record or nodect under linked monitors and uses h264 passthrough.* The hi res compressed stream is saved directly to disk.&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32+, you can use multiple HDs (as many as you like), and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
*Linked monitors have from time to time had bugs or configuration gotchas, so for simplicity sake, I use record. HDD space is cheap.&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until few false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by e.g. &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. &lt;br /&gt;
&lt;br /&gt;
Flawless professional systems use hardware motion detectors, as software detection is not perfect. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442 You aren&amp;#039;t mil grade probably so just use sensitive zone settings and two streams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
You can re run analysis on old videos with: https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video, then make that a video source in zm as file.).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones Tip&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*I prefer the usage of external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors.&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
* If you are setting up mobile phones with ZMNinja, and the wifi is the same WAN IP as the camera system, setup a VPS with a http/https proxy and point zmninja at the proxy. The proxy can be as simple as: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:80&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:443&lt;br /&gt;
sudo iptables-legacy -t nat -A POSTROUTING -j MASQUERADE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note that you might want to set nonstandard ports.&lt;br /&gt;
&lt;br /&gt;
* run 2k cameras at least. people like flashy things (like birds) and hi &lt;br /&gt;
res.&lt;br /&gt;
&lt;br /&gt;
* users seem to like fluid video, so put high fps on low res substream. &lt;br /&gt;
analysis fps limit to 2. we don&amp;#039;t have (asic) hardware yet, so there are limits, but cpu is still pretty &lt;br /&gt;
powerful.&lt;br /&gt;
&lt;br /&gt;
* the more you overbuild the cpu, the faster you can go.&lt;br /&gt;
&lt;br /&gt;
* passthrough on hi res stream obv. watch low res stream live, expand / &lt;br /&gt;
open window to hi res stream, ideally (custom javascript could do this:todo).&lt;br /&gt;
&lt;br /&gt;
* use zmninja + the website. offer customers both apps. there are also some other apps available. (e.g. possibly zmsquarer).&lt;br /&gt;
&lt;br /&gt;
* in most cases, you should replace coax cams with ethernet. customers&lt;br /&gt;
that are camera happy tend to like hi res, whether its needed or not, &lt;br /&gt;
and coax is low res.&lt;br /&gt;
&lt;br /&gt;
* (optional) configure zmes or good blob detection. you pretty much only&lt;br /&gt;
will be detecting people in the average business. maybe cars. For extra points, &lt;br /&gt;
figure out how to assign names to people in zmes.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16720</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16720"/>
		<updated>2021-11-21T10:17:36Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Recording in Zoneminder */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
Consider the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
If you are already knowledgeable about servers, then you shouldn&amp;#039;t have any trouble.&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). &lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
Use 1.34.&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an early [[Axis]]. They are well documented and easy to setup. &lt;br /&gt;
Old ones go for $10-20. Follow the instructions on either the Zoneminder Hardware compatibility list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatibility List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. from terminal: ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5/video.mjpg&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; (obsolete) Precursor to ffmpeg. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide images that change from anywhere on the filesystem). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. Anything RTSP should use FFMPEG.&lt;br /&gt;
&lt;br /&gt;
And some others...&lt;br /&gt;
&lt;br /&gt;
FFMPEG / LibVLC is recommended.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; has the option of either RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
These include [[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-30.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 means less bytes, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. .&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. That being said, customers generally prefer higher res cameras, so you probably should replace them, unless its a low priority area.&lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog over coax, and I don&amp;#039;t recommend it. It is not standardized yet.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server website and/or ZMNinja.&lt;br /&gt;
&lt;br /&gt;
Yu can make fully customizable pages i.e. make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs) if whole img boxes seem to drop out.&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis.&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (better, but uses HDD, and event list timeline in ZMNinja shows 10 minute segments). But all of these are flawed. Here&amp;#039;s what you do: always record two streams per camera. One, the low res stream, is set to modect, with reasonable (but no need to be perfect) settings for detection. Two, the high res stream is set to either record or nodect under linked monitors and uses h264 passthrough.* The hi res compressed stream is saved directly to disk.&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32+, you can use multiple HDs (as many as you like), and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
*Linked monitors have from time to time had bugs or configuration gotchas, so for simplicity sake, I use record. HDD space is cheap.&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until no false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt; in Devuan based distros. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. Mocord is the best, but uses more HDD. Beware of running into issues with [[PurgeWhenFull]] not able to keep up.&lt;br /&gt;
&lt;br /&gt;
I personally like using hardware motion detectors, as ZMA/zmeventnotification and all the associated software to detect people can be a rabbit hole. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442 In some ways, ZMES may be an easier (less hardware) solution, so consider that.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. POTENTIAL RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
After using this setup for some years, a sudden rise in the cost of some goods a business kept in storage led to thefts. The bad news was, my modect zone wasn&amp;#039;t sensitive enough. This, with the added ability of ZM&amp;gt;1.32&amp;#039;s storage areas led me to re-evaulate the above. It turns out, there is another way. Instead of Modect on a zone, you can Record (or mocord). And, instead of motion detecting on the live video, you can do analysis on old videos. With a combination of these two posts (note: untested, for the record) https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video).&lt;br /&gt;
&lt;br /&gt;
This gives the CPU reductions of not actively Modect/Mocord, while still not missing anything. A dedicated ZM computer (RPI) can be used to analyze old footage. EDIT: This is a lot of work, and &amp;#039;&amp;#039;&amp;#039;I don&amp;#039;t recommend it.&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
tl;dr: Use mocord or zmes.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up. If you want, you can use the &amp;#039;linked monitors&amp;#039; function, and only record the 4K on motion (search forums). &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Conclusion&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
After all is said and done, motion detection works but has limitations. Motion detection tends to report false alarms from weather, wildlife, changing from IR to Day sensor, and others. For users that need accurate motion detection, you will either need to A) tune the zones so that no false alarms occur (see [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]) or B) use the cameras built in motion detection or C) use external motion sensors with [[ZMTrigger]] or some combination of the above.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*I prefer the usage of external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors.&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
* If you are setting up mobile phones with ZMNinja, and the wifi is the same WAN IP as the camera system, setup a VPS with a http/https proxy and point zmninja at the proxy. The proxy can be as simple as: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:80&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:443&lt;br /&gt;
sudo iptables-legacy -t nat -A POSTROUTING -j MASQUERADE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note that you might want to set nonstandard ports.&lt;br /&gt;
&lt;br /&gt;
* run 2k cameras at least. people like flashy things (like birds) and hi &lt;br /&gt;
res.&lt;br /&gt;
&lt;br /&gt;
* users seem to like fluid video, so put high fps on low res substream. &lt;br /&gt;
analysis fps limit to 2. we don&amp;#039;t have (asic) hardware yet, so there are limits, but cpu is still pretty &lt;br /&gt;
powerful.&lt;br /&gt;
&lt;br /&gt;
* the more you overbuild the cpu, the faster you can go.&lt;br /&gt;
&lt;br /&gt;
* passthrough on hi res stream obv. watch low res stream live, expand / &lt;br /&gt;
open window to hi res stream, ideally (custom javascript could do this:todo).&lt;br /&gt;
&lt;br /&gt;
* use zmninja + the website. offer customers both apps. there are also some other apps available. (e.g. possibly zmsquarer).&lt;br /&gt;
&lt;br /&gt;
* in most cases, you should replace coax cams with ethernet. customers&lt;br /&gt;
that are camera happy tend to like hi res, whether its needed or not, &lt;br /&gt;
and coax is low res.&lt;br /&gt;
&lt;br /&gt;
* (optional) configure zmes or good blob detection. you pretty much only&lt;br /&gt;
will be detecting people in the average business. maybe cars. For extra points, &lt;br /&gt;
figure out how to assign names to people in zmes.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16719</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16719"/>
		<updated>2021-11-03T02:46:18Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* See Also */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
Consider the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
If you are already knowledgeable about servers, then you shouldn&amp;#039;t have any trouble.&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). &lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
Use 1.34.&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an early [[Axis]]. They are well documented and easy to setup. &lt;br /&gt;
Old ones go for $10-20. Follow the instructions on either the Zoneminder Hardware compatibility list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatibility List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. from terminal: ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5/video.mjpg&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; (obsolete) Precursor to ffmpeg. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide images that change from anywhere on the filesystem). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. Anything RTSP should use FFMPEG.&lt;br /&gt;
&lt;br /&gt;
And some others...&lt;br /&gt;
&lt;br /&gt;
FFMPEG / LibVLC is recommended.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; has the option of either RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
These include [[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-30.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 means less bytes, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. .&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. That being said, customers generally prefer higher res cameras, so you probably should replace them, unless its a low priority area.&lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog over coax, and I don&amp;#039;t recommend it. It is not standardized yet.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server website and/or ZMNinja.&lt;br /&gt;
&lt;br /&gt;
Yu can make fully customizable pages i.e. make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs) if whole img boxes seem to drop out.&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis.&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (best, but uses HDD). And finally, You can mix it up. I would recommend in small setups, to throw a &amp;gt;1TB HDD in there for videos and set everything to mocord. For larger setups, you will want to customize each camera based on its priority.&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32 and newer, you can use multiple HDs (as many as you want), and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Some cameras have two streams. Run Mocord on the low res stream, and record or modect w/linked monitors - search forums for more details.&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until no false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt; in Devuan based distros. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. Mocord is the best, but uses more HDD. Beware of running into issues with [[PurgeWhenFull]] not able to keep up.&lt;br /&gt;
&lt;br /&gt;
I personally like using hardware motion detectors, as ZMA/zmeventnotification and all the associated software to detect people can be a rabbit hole. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442 In some ways, ZMES may be an easier (less hardware) solution, so consider that.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. POTENTIAL RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
After using this setup for some years, a sudden rise in the cost of some goods a business kept in storage led to thefts. The bad news was, my modect zone wasn&amp;#039;t sensitive enough. This, with the added ability of ZM&amp;gt;1.32&amp;#039;s storage areas led me to re-evaulate the above. It turns out, there is another way. Instead of Modect on a zone, you can Record (or mocord). And, instead of motion detecting on the live video, you can do analysis on old videos. With a combination of these two posts (note: untested, for the record) https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video).&lt;br /&gt;
&lt;br /&gt;
This gives the CPU reductions of not actively Modect/Mocord, while still not missing anything. A dedicated ZM computer (RPI) can be used to analyze old footage. EDIT: This is a lot of work, and &amp;#039;&amp;#039;&amp;#039;I don&amp;#039;t recommend it.&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
tl;dr: Use mocord or zmes.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up. If you want, you can use the &amp;#039;linked monitors&amp;#039; function, and only record the 4K on motion (search forums). &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Conclusion&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
After all is said and done, motion detection works but has limitations. Motion detection tends to report false alarms from weather, wildlife, changing from IR to Day sensor, and others. For users that need accurate motion detection, you will either need to A) tune the zones so that no false alarms occur (see [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]) or B) use the cameras built in motion detection or C) use external motion sensors with [[ZMTrigger]] or some combination of the above.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*I prefer the usage of external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors.&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
* If you are setting up mobile phones with ZMNinja, and the wifi is the same WAN IP as the camera system, setup a VPS with a http/https proxy and point zmninja at the proxy. The proxy can be as simple as: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:80&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:443&lt;br /&gt;
sudo iptables-legacy -t nat -A POSTROUTING -j MASQUERADE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note that you might want to set nonstandard ports.&lt;br /&gt;
&lt;br /&gt;
* run 2k cameras at least. people like flashy things (like birds) and hi &lt;br /&gt;
res.&lt;br /&gt;
&lt;br /&gt;
* users seem to like fluid video, so put high fps on low res substream. &lt;br /&gt;
analysis fps limit to 2. we don&amp;#039;t have (asic) hardware yet, so there are limits, but cpu is still pretty &lt;br /&gt;
powerful.&lt;br /&gt;
&lt;br /&gt;
* the more you overbuild the cpu, the faster you can go.&lt;br /&gt;
&lt;br /&gt;
* passthrough on hi res stream obv. watch low res stream live, expand / &lt;br /&gt;
open window to hi res stream, ideally (custom javascript could do this:todo).&lt;br /&gt;
&lt;br /&gt;
* use zmninja + the website. offer customers both apps. there are also some other apps available. (e.g. possibly zmsquarer).&lt;br /&gt;
&lt;br /&gt;
* in most cases, you should replace coax cams with ethernet. customers&lt;br /&gt;
that are camera happy tend to like hi res, whether its needed or not, &lt;br /&gt;
and coax is low res.&lt;br /&gt;
&lt;br /&gt;
* (optional) configure zmes or good blob detection. you pretty much only&lt;br /&gt;
will be detecting people in the average business. maybe cars. For extra points, &lt;br /&gt;
figure out how to assign names to people in zmes.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16718</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16718"/>
		<updated>2021-11-03T02:45:24Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Motion Detection */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
Consider the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
If you are already knowledgeable about servers, then you shouldn&amp;#039;t have any trouble.&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). &lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
Use 1.34.&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an early [[Axis]]. They are well documented and easy to setup. &lt;br /&gt;
Old ones go for $10-20. Follow the instructions on either the Zoneminder Hardware compatibility list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatibility List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. from terminal: ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5/video.mjpg&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; (obsolete) Precursor to ffmpeg. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide images that change from anywhere on the filesystem). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. Anything RTSP should use FFMPEG.&lt;br /&gt;
&lt;br /&gt;
And some others...&lt;br /&gt;
&lt;br /&gt;
FFMPEG / LibVLC is recommended.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; has the option of either RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
These include [[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-30.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 means less bytes, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. .&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. That being said, customers generally prefer higher res cameras, so you probably should replace them, unless its a low priority area.&lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog over coax, and I don&amp;#039;t recommend it. It is not standardized yet.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server website and/or ZMNinja.&lt;br /&gt;
&lt;br /&gt;
Yu can make fully customizable pages i.e. make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs) if whole img boxes seem to drop out.&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis.&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (best, but uses HDD). And finally, You can mix it up. I would recommend in small setups, to throw a &amp;gt;1TB HDD in there for videos and set everything to mocord. For larger setups, you will want to customize each camera based on its priority.&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32 and newer, you can use multiple HDs (as many as you want), and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Some cameras have two streams. Run Mocord on the low res stream, and record or modect w/linked monitors - search forums for more details.&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until no false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt; in Devuan based distros. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. Mocord is the best, but uses more HDD. Beware of running into issues with [[PurgeWhenFull]] not able to keep up.&lt;br /&gt;
&lt;br /&gt;
I personally like using hardware motion detectors, as ZMA/zmeventnotification and all the associated software to detect people can be a rabbit hole. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442 In some ways, ZMES may be an easier (less hardware) solution, so consider that.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. POTENTIAL RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
After using this setup for some years, a sudden rise in the cost of some goods a business kept in storage led to thefts. The bad news was, my modect zone wasn&amp;#039;t sensitive enough. This, with the added ability of ZM&amp;gt;1.32&amp;#039;s storage areas led me to re-evaulate the above. It turns out, there is another way. Instead of Modect on a zone, you can Record (or mocord). And, instead of motion detecting on the live video, you can do analysis on old videos. With a combination of these two posts (note: untested, for the record) https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video).&lt;br /&gt;
&lt;br /&gt;
This gives the CPU reductions of not actively Modect/Mocord, while still not missing anything. A dedicated ZM computer (RPI) can be used to analyze old footage. EDIT: This is a lot of work, and &amp;#039;&amp;#039;&amp;#039;I don&amp;#039;t recommend it.&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
tl;dr: Use mocord or zmes.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up. If you want, you can use the &amp;#039;linked monitors&amp;#039; function, and only record the 4K on motion (search forums). &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Conclusion&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
After all is said and done, motion detection works but has limitations. Motion detection tends to report false alarms from weather, wildlife, changing from IR to Day sensor, and others. For users that need accurate motion detection, you will either need to A) tune the zones so that no false alarms occur (see [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]) or B) use the cameras built in motion detection or C) use external motion sensors with [[ZMTrigger]] or some combination of the above.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*I prefer the usage of external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors.&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
* If you are setting up mobile phones with ZMNinja, and the wifi is the same WAN IP as the camera system, setup a VPS with a http/https proxy and point zmninja at the proxy. The proxy can be as simple as: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:80&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:443&lt;br /&gt;
sudo iptables-legacy -t nat -A POSTROUTING -j MASQUERADE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note that you might want to set nonstandard ports.&lt;br /&gt;
&lt;br /&gt;
* run 2k cameras at least. people like flashy things (like birds) and hi &lt;br /&gt;
res.&lt;br /&gt;
&lt;br /&gt;
* users seem to like fluid video, so put high fps on low res substream. &lt;br /&gt;
analysis fps limit to 2. we don&amp;#039;t have (asic) hardware yet, so there are limits, but cpu is still pretty &lt;br /&gt;
powerful.&lt;br /&gt;
&lt;br /&gt;
* the more you overbuild the cpu, the faster you can go.&lt;br /&gt;
&lt;br /&gt;
* passthrough on hi res stream obv. watch low res stream live, expand / &lt;br /&gt;
open window to hi res stream, ideally (custom javascript could do this:todo).&lt;br /&gt;
&lt;br /&gt;
* use zmninja + the website. offer customers both apps. there are also some other apps available. (e.g. possibly zmsquarer).&lt;br /&gt;
&lt;br /&gt;
* in most cases, you should replace coax cams with ethernet. customers&lt;br /&gt;
that are camera happy tend to like hi res, whether its needed or not, &lt;br /&gt;
and coax is low res.&lt;br /&gt;
&lt;br /&gt;
* (optional) configure zmes or good blob detection. you pretty much only&lt;br /&gt;
will be detecting people in the average business. maybe cars. For extra points, &lt;br /&gt;
figure out how to assign names to people in zmes.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[MJPEG_vs_H264]] For ZM &amp;lt; 1.31, use MJPEG for large deployments&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16717</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16717"/>
		<updated>2021-11-03T02:43:50Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Recording in Zoneminder */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
Consider the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
If you are already knowledgeable about servers, then you shouldn&amp;#039;t have any trouble.&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). &lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
Use 1.34.&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an early [[Axis]]. They are well documented and easy to setup. &lt;br /&gt;
Old ones go for $10-20. Follow the instructions on either the Zoneminder Hardware compatibility list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatibility List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. from terminal: ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5/video.mjpg&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; (obsolete) Precursor to ffmpeg. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide images that change from anywhere on the filesystem). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. Anything RTSP should use FFMPEG.&lt;br /&gt;
&lt;br /&gt;
And some others...&lt;br /&gt;
&lt;br /&gt;
FFMPEG / LibVLC is recommended.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; has the option of either RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
These include [[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-30.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 means less bytes, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. .&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. That being said, customers generally prefer higher res cameras, so you probably should replace them, unless its a low priority area.&lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog over coax, and I don&amp;#039;t recommend it. It is not standardized yet.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server website and/or ZMNinja.&lt;br /&gt;
&lt;br /&gt;
Yu can make fully customizable pages i.e. make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs) if whole img boxes seem to drop out.&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis.&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (best, but uses HDD). And finally, You can mix it up. I would recommend in small setups, to throw a &amp;gt;1TB HDD in there for videos and set everything to mocord. For larger setups, you will want to customize each camera based on its priority.&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32 and newer, you can use multiple HDs (as many as you want), and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Some cameras have two streams. Run Mocord on the low res stream, and record or modect w/linked monitors - search forums for more details.&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until no false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt; in Devuan based distros. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. Mocord is the best, but uses more HDD. Beware of running into issues with [[PurgeWhenFull]] not able to keep up.&lt;br /&gt;
&lt;br /&gt;
I personally like using hardware motion detectors, as ZMA/zmeventnotification and all the associated software to detect people can be a rabbit hole. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442 In some ways, ZMES may be an easier (less hardware) solution, so consider that.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. POTENTIAL RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
After using this setup for some years, a sudden rise in the cost of some goods a business kept in storage led to thefts. The bad news was, my modect zone wasn&amp;#039;t sensitive enough. This, with the added ability of ZM&amp;gt;1.32&amp;#039;s storage areas led me to re-evaulate the above. It turns out, there is another way. Instead of Modect on a zone, you can Record (or mocord). And, instead of motion detecting on the live video, you can do analysis on old videos. With a combination of these two posts (note: untested, for the record) https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video).&lt;br /&gt;
&lt;br /&gt;
This gives the CPU reductions of not actively Modect/Mocord, while still not missing anything. A dedicated ZM computer (RPI) can be used to analyze old footage. EDIT: This is a lot of work, and &amp;#039;&amp;#039;&amp;#039;I don&amp;#039;t recommend it.&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
tl;dr: Use mocord. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up. If you want, you can use the &amp;#039;linked monitors&amp;#039; function, and only record the 4K on motion (search forums). &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Conclusion&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
After all is said and done, motion detection works but has limitations. Motion detection tends to report false alarms from weather, wildlife, changing from IR to Day sensor, and others. For users that need accurate motion detection, you will either need to A) tune the zones so that no false alarms occur (see [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]) or B) use the cameras built in motion detection or C) use external motion sensors with [[ZMTrigger]] or some combination of the above.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*I prefer the usage of external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors.&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
* If you are setting up mobile phones with ZMNinja, and the wifi is the same WAN IP as the camera system, setup a VPS with a http/https proxy and point zmninja at the proxy. The proxy can be as simple as: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:80&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:443&lt;br /&gt;
sudo iptables-legacy -t nat -A POSTROUTING -j MASQUERADE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note that you might want to set nonstandard ports.&lt;br /&gt;
&lt;br /&gt;
* run 2k cameras at least. people like flashy things (like birds) and hi &lt;br /&gt;
res.&lt;br /&gt;
&lt;br /&gt;
* users seem to like fluid video, so put high fps on low res substream. &lt;br /&gt;
analysis fps limit to 2. we don&amp;#039;t have (asic) hardware yet, so there are limits, but cpu is still pretty &lt;br /&gt;
powerful.&lt;br /&gt;
&lt;br /&gt;
* the more you overbuild the cpu, the faster you can go.&lt;br /&gt;
&lt;br /&gt;
* passthrough on hi res stream obv. watch low res stream live, expand / &lt;br /&gt;
open window to hi res stream, ideally (custom javascript could do this:todo).&lt;br /&gt;
&lt;br /&gt;
* use zmninja + the website. offer customers both apps. there are also some other apps available. (e.g. possibly zmsquarer).&lt;br /&gt;
&lt;br /&gt;
* in most cases, you should replace coax cams with ethernet. customers&lt;br /&gt;
that are camera happy tend to like hi res, whether its needed or not, &lt;br /&gt;
and coax is low res.&lt;br /&gt;
&lt;br /&gt;
* (optional) configure zmes or good blob detection. you pretty much only&lt;br /&gt;
will be detecting people in the average business. maybe cars. For extra points, &lt;br /&gt;
figure out how to assign names to people in zmes.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[MJPEG_vs_H264]] For ZM &amp;lt; 1.31, use MJPEG for large deployments&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16716</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16716"/>
		<updated>2021-11-03T02:42:49Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Watching the Cameras */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
Consider the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
If you are already knowledgeable about servers, then you shouldn&amp;#039;t have any trouble.&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). &lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
Use 1.34.&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an early [[Axis]]. They are well documented and easy to setup. &lt;br /&gt;
Old ones go for $10-20. Follow the instructions on either the Zoneminder Hardware compatibility list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatibility List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. from terminal: ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5/video.mjpg&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; (obsolete) Precursor to ffmpeg. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide images that change from anywhere on the filesystem). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. Anything RTSP should use FFMPEG.&lt;br /&gt;
&lt;br /&gt;
And some others...&lt;br /&gt;
&lt;br /&gt;
FFMPEG / LibVLC is recommended.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; has the option of either RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
These include [[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-30.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 means less bytes, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. .&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. That being said, customers generally prefer higher res cameras, so you probably should replace them, unless its a low priority area.&lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog over coax, and I don&amp;#039;t recommend it. It is not standardized yet.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server website and/or ZMNinja.&lt;br /&gt;
&lt;br /&gt;
Yu can make fully customizable pages i.e. make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs) if whole img boxes seem to drop out.&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis.&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (best, but uses HDD). And finally, You can mix it up. I would recommend in small setups, to throw a &amp;gt;1TB HDD in there for videos and set everything to mocord. For larger setups, you will want to customize each camera based on its priority.&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32 and newer, you can use multiple HDs, and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Some cameras have two streams. Run Mocord on the low res stream, and record or modect w/linked monitors - search forums for more details. Which you choose will depend whether you want to record all of the this camera or not. How much HDD space do you have?&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until no false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt; in Devuan based distros. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. Mocord is the best, but uses more HDD. Beware of running into issues with [[PurgeWhenFull]] not able to keep up.&lt;br /&gt;
&lt;br /&gt;
I personally like using hardware motion detectors, as ZMA/zmeventnotification and all the associated software to detect people can be a rabbit hole. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442 In some ways, ZMES may be an easier (less hardware) solution, so consider that.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. POTENTIAL RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
After using this setup for some years, a sudden rise in the cost of some goods a business kept in storage led to thefts. The bad news was, my modect zone wasn&amp;#039;t sensitive enough. This, with the added ability of ZM&amp;gt;1.32&amp;#039;s storage areas led me to re-evaulate the above. It turns out, there is another way. Instead of Modect on a zone, you can Record (or mocord). And, instead of motion detecting on the live video, you can do analysis on old videos. With a combination of these two posts (note: untested, for the record) https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video).&lt;br /&gt;
&lt;br /&gt;
This gives the CPU reductions of not actively Modect/Mocord, while still not missing anything. A dedicated ZM computer (RPI) can be used to analyze old footage. EDIT: This is a lot of work, and &amp;#039;&amp;#039;&amp;#039;I don&amp;#039;t recommend it.&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
tl;dr: Use mocord. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up. If you want, you can use the &amp;#039;linked monitors&amp;#039; function, and only record the 4K on motion (search forums). &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Conclusion&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
After all is said and done, motion detection works but has limitations. Motion detection tends to report false alarms from weather, wildlife, changing from IR to Day sensor, and others. For users that need accurate motion detection, you will either need to A) tune the zones so that no false alarms occur (see [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]) or B) use the cameras built in motion detection or C) use external motion sensors with [[ZMTrigger]] or some combination of the above.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*I prefer the usage of external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors.&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
* If you are setting up mobile phones with ZMNinja, and the wifi is the same WAN IP as the camera system, setup a VPS with a http/https proxy and point zmninja at the proxy. The proxy can be as simple as: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:80&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:443&lt;br /&gt;
sudo iptables-legacy -t nat -A POSTROUTING -j MASQUERADE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note that you might want to set nonstandard ports.&lt;br /&gt;
&lt;br /&gt;
* run 2k cameras at least. people like flashy things (like birds) and hi &lt;br /&gt;
res.&lt;br /&gt;
&lt;br /&gt;
* users seem to like fluid video, so put high fps on low res substream. &lt;br /&gt;
analysis fps limit to 2. we don&amp;#039;t have (asic) hardware yet, so there are limits, but cpu is still pretty &lt;br /&gt;
powerful.&lt;br /&gt;
&lt;br /&gt;
* the more you overbuild the cpu, the faster you can go.&lt;br /&gt;
&lt;br /&gt;
* passthrough on hi res stream obv. watch low res stream live, expand / &lt;br /&gt;
open window to hi res stream, ideally (custom javascript could do this:todo).&lt;br /&gt;
&lt;br /&gt;
* use zmninja + the website. offer customers both apps. there are also some other apps available. (e.g. possibly zmsquarer).&lt;br /&gt;
&lt;br /&gt;
* in most cases, you should replace coax cams with ethernet. customers&lt;br /&gt;
that are camera happy tend to like hi res, whether its needed or not, &lt;br /&gt;
and coax is low res.&lt;br /&gt;
&lt;br /&gt;
* (optional) configure zmes or good blob detection. you pretty much only&lt;br /&gt;
will be detecting people in the average business. maybe cars. For extra points, &lt;br /&gt;
figure out how to assign names to people in zmes.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[MJPEG_vs_H264]] For ZM &amp;lt; 1.31, use MJPEG for large deployments&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16715</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16715"/>
		<updated>2021-11-03T02:39:40Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Obtaining more Cameras */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
Consider the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
If you are already knowledgeable about servers, then you shouldn&amp;#039;t have any trouble.&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). &lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
Use 1.34.&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an early [[Axis]]. They are well documented and easy to setup. &lt;br /&gt;
Old ones go for $10-20. Follow the instructions on either the Zoneminder Hardware compatibility list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatibility List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. from terminal: ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5/video.mjpg&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; (obsolete) Precursor to ffmpeg. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide images that change from anywhere on the filesystem). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. Anything RTSP should use FFMPEG.&lt;br /&gt;
&lt;br /&gt;
And some others...&lt;br /&gt;
&lt;br /&gt;
FFMPEG / LibVLC is recommended.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; has the option of either RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
These include [[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-30.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 means less bytes, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. .&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. That being said, customers generally prefer higher res cameras, so you probably should replace them, unless its a low priority area.&lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog over coax, and I don&amp;#039;t recommend it. It is not standardized yet.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server. Montage view is good. See notes section for a hint about &amp;gt; 6 camera setups.&lt;br /&gt;
&lt;br /&gt;
Another way is to make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs).&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis.&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (best, but uses HDD). And finally, You can mix it up. I would recommend in small setups, to throw a &amp;gt;1TB HDD in there for videos and set everything to mocord. For larger setups, you will want to customize each camera based on its priority.&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32 and newer, you can use multiple HDs, and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Some cameras have two streams. Run Mocord on the low res stream, and record or modect w/linked monitors - search forums for more details. Which you choose will depend whether you want to record all of the this camera or not. How much HDD space do you have?&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until no false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt; in Devuan based distros. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. Mocord is the best, but uses more HDD. Beware of running into issues with [[PurgeWhenFull]] not able to keep up.&lt;br /&gt;
&lt;br /&gt;
I personally like using hardware motion detectors, as ZMA/zmeventnotification and all the associated software to detect people can be a rabbit hole. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442 In some ways, ZMES may be an easier (less hardware) solution, so consider that.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. POTENTIAL RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
After using this setup for some years, a sudden rise in the cost of some goods a business kept in storage led to thefts. The bad news was, my modect zone wasn&amp;#039;t sensitive enough. This, with the added ability of ZM&amp;gt;1.32&amp;#039;s storage areas led me to re-evaulate the above. It turns out, there is another way. Instead of Modect on a zone, you can Record (or mocord). And, instead of motion detecting on the live video, you can do analysis on old videos. With a combination of these two posts (note: untested, for the record) https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video).&lt;br /&gt;
&lt;br /&gt;
This gives the CPU reductions of not actively Modect/Mocord, while still not missing anything. A dedicated ZM computer (RPI) can be used to analyze old footage. EDIT: This is a lot of work, and &amp;#039;&amp;#039;&amp;#039;I don&amp;#039;t recommend it.&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
tl;dr: Use mocord. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up. If you want, you can use the &amp;#039;linked monitors&amp;#039; function, and only record the 4K on motion (search forums). &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Conclusion&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
After all is said and done, motion detection works but has limitations. Motion detection tends to report false alarms from weather, wildlife, changing from IR to Day sensor, and others. For users that need accurate motion detection, you will either need to A) tune the zones so that no false alarms occur (see [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]) or B) use the cameras built in motion detection or C) use external motion sensors with [[ZMTrigger]] or some combination of the above.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*I prefer the usage of external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors.&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
* If you are setting up mobile phones with ZMNinja, and the wifi is the same WAN IP as the camera system, setup a VPS with a http/https proxy and point zmninja at the proxy. The proxy can be as simple as: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:80&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:443&lt;br /&gt;
sudo iptables-legacy -t nat -A POSTROUTING -j MASQUERADE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note that you might want to set nonstandard ports.&lt;br /&gt;
&lt;br /&gt;
* run 2k cameras at least. people like flashy things (like birds) and hi &lt;br /&gt;
res.&lt;br /&gt;
&lt;br /&gt;
* users seem to like fluid video, so put high fps on low res substream. &lt;br /&gt;
analysis fps limit to 2. we don&amp;#039;t have (asic) hardware yet, so there are limits, but cpu is still pretty &lt;br /&gt;
powerful.&lt;br /&gt;
&lt;br /&gt;
* the more you overbuild the cpu, the faster you can go.&lt;br /&gt;
&lt;br /&gt;
* passthrough on hi res stream obv. watch low res stream live, expand / &lt;br /&gt;
open window to hi res stream, ideally (custom javascript could do this:todo).&lt;br /&gt;
&lt;br /&gt;
* use zmninja + the website. offer customers both apps. there are also some other apps available. (e.g. possibly zmsquarer).&lt;br /&gt;
&lt;br /&gt;
* in most cases, you should replace coax cams with ethernet. customers&lt;br /&gt;
that are camera happy tend to like hi res, whether its needed or not, &lt;br /&gt;
and coax is low res.&lt;br /&gt;
&lt;br /&gt;
* (optional) configure zmes or good blob detection. you pretty much only&lt;br /&gt;
will be detecting people in the average business. maybe cars. For extra points, &lt;br /&gt;
figure out how to assign names to people in zmes.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[MJPEG_vs_H264]] For ZM &amp;lt; 1.31, use MJPEG for large deployments&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16714</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16714"/>
		<updated>2021-11-03T02:35:06Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Test out a Camera */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
Consider the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
If you are already knowledgeable about servers, then you shouldn&amp;#039;t have any trouble.&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). &lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
Use 1.34.&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an early [[Axis]]. They are well documented and easy to setup. &lt;br /&gt;
Old ones go for $10-20. Follow the instructions on either the Zoneminder Hardware compatibility list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatibility List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. from terminal: ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5/video.mjpg&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; Grab MJPEG stream from IP camera on the network. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide jpeg images that change from somewhere). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. Anything RTSP should use FFMPEG.&lt;br /&gt;
&lt;br /&gt;
Local is for webcams (usb), or BTTV (pci) cards for analog aka coax cameras. Webcams are ok. BTTV is obsolete, but usable as legacy hardware. If you have analog cameras, you are best off using a video encoder. See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
After that you have FILE and REMOTE. I have not used FILE for anything but testing. I will cover REMOTE / FFMPEG.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;REMOTE &amp;amp; FFMPEG&amp;#039;&amp;#039;&amp;#039; have the option of either RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
These include [[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-80.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 uses compression, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. 1.36 has further efficiency improvements on this.&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. That being said, customers generally prefer higher res cameras, so you probably should replace them, unless its a low priority area.&lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog (a new type of analog camera that does HD over the coax), and I don&amp;#039;t recommend it. It is not standardized yet. Ethernet only for new cameras.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server. Montage view is good. See notes section for a hint about &amp;gt; 6 camera setups.&lt;br /&gt;
&lt;br /&gt;
Another way is to make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs).&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis.&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (best, but uses HDD). And finally, You can mix it up. I would recommend in small setups, to throw a &amp;gt;1TB HDD in there for videos and set everything to mocord. For larger setups, you will want to customize each camera based on its priority.&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32 and newer, you can use multiple HDs, and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Some cameras have two streams. Run Mocord on the low res stream, and record or modect w/linked monitors - search forums for more details. Which you choose will depend whether you want to record all of the this camera or not. How much HDD space do you have?&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until no false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt; in Devuan based distros. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. Mocord is the best, but uses more HDD. Beware of running into issues with [[PurgeWhenFull]] not able to keep up.&lt;br /&gt;
&lt;br /&gt;
I personally like using hardware motion detectors, as ZMA/zmeventnotification and all the associated software to detect people can be a rabbit hole. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442 In some ways, ZMES may be an easier (less hardware) solution, so consider that.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. POTENTIAL RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
After using this setup for some years, a sudden rise in the cost of some goods a business kept in storage led to thefts. The bad news was, my modect zone wasn&amp;#039;t sensitive enough. This, with the added ability of ZM&amp;gt;1.32&amp;#039;s storage areas led me to re-evaulate the above. It turns out, there is another way. Instead of Modect on a zone, you can Record (or mocord). And, instead of motion detecting on the live video, you can do analysis on old videos. With a combination of these two posts (note: untested, for the record) https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video).&lt;br /&gt;
&lt;br /&gt;
This gives the CPU reductions of not actively Modect/Mocord, while still not missing anything. A dedicated ZM computer (RPI) can be used to analyze old footage. EDIT: This is a lot of work, and &amp;#039;&amp;#039;&amp;#039;I don&amp;#039;t recommend it.&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
tl;dr: Use mocord. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up. If you want, you can use the &amp;#039;linked monitors&amp;#039; function, and only record the 4K on motion (search forums). &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Conclusion&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
After all is said and done, motion detection works but has limitations. Motion detection tends to report false alarms from weather, wildlife, changing from IR to Day sensor, and others. For users that need accurate motion detection, you will either need to A) tune the zones so that no false alarms occur (see [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]) or B) use the cameras built in motion detection or C) use external motion sensors with [[ZMTrigger]] or some combination of the above.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*I prefer the usage of external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors.&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
* If you are setting up mobile phones with ZMNinja, and the wifi is the same WAN IP as the camera system, setup a VPS with a http/https proxy and point zmninja at the proxy. The proxy can be as simple as: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:80&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:443&lt;br /&gt;
sudo iptables-legacy -t nat -A POSTROUTING -j MASQUERADE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note that you might want to set nonstandard ports.&lt;br /&gt;
&lt;br /&gt;
* run 2k cameras at least. people like flashy things (like birds) and hi &lt;br /&gt;
res.&lt;br /&gt;
&lt;br /&gt;
* users seem to like fluid video, so put high fps on low res substream. &lt;br /&gt;
analysis fps limit to 2. we don&amp;#039;t have (asic) hardware yet, so there are limits, but cpu is still pretty &lt;br /&gt;
powerful.&lt;br /&gt;
&lt;br /&gt;
* the more you overbuild the cpu, the faster you can go.&lt;br /&gt;
&lt;br /&gt;
* passthrough on hi res stream obv. watch low res stream live, expand / &lt;br /&gt;
open window to hi res stream, ideally (custom javascript could do this:todo).&lt;br /&gt;
&lt;br /&gt;
* use zmninja + the website. offer customers both apps. there are also some other apps available. (e.g. possibly zmsquarer).&lt;br /&gt;
&lt;br /&gt;
* in most cases, you should replace coax cams with ethernet. customers&lt;br /&gt;
that are camera happy tend to like hi res, whether its needed or not, &lt;br /&gt;
and coax is low res.&lt;br /&gt;
&lt;br /&gt;
* (optional) configure zmes or good blob detection. you pretty much only&lt;br /&gt;
will be detecting people in the average business. maybe cars. For extra points, &lt;br /&gt;
figure out how to assign names to people in zmes.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[MJPEG_vs_H264]] For ZM &amp;lt; 1.31, use MJPEG for large deployments&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16713</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16713"/>
		<updated>2021-11-03T02:32:53Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Install */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
Consider the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
If you are already knowledgeable about servers, then you shouldn&amp;#039;t have any trouble.&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). &lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
Use 1.34.&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an old [[Axis]] IP Camera. They are well documented and easy to setup. &lt;br /&gt;
Buy an old one for $10-20. Follow the instructions on either the Zoneminder Hardware compatiblity list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatiblity List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults in the source section.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; Grab MJPEG stream from IP camera on the network. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide jpeg images that change from somewhere). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. Anything RTSP should use FFMPEG.&lt;br /&gt;
&lt;br /&gt;
Local is for webcams (usb), or BTTV (pci) cards for analog aka coax cameras. Webcams are ok. BTTV is obsolete, but usable as legacy hardware. If you have analog cameras, you are best off using a video encoder. See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
After that you have FILE and REMOTE. I have not used FILE for anything but testing. I will cover REMOTE / FFMPEG.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;REMOTE &amp;amp; FFMPEG&amp;#039;&amp;#039;&amp;#039; have the option of either RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
These include [[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-80.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 uses compression, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. 1.36 has further efficiency improvements on this.&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. That being said, customers generally prefer higher res cameras, so you probably should replace them, unless its a low priority area.&lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog (a new type of analog camera that does HD over the coax), and I don&amp;#039;t recommend it. It is not standardized yet. Ethernet only for new cameras.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server. Montage view is good. See notes section for a hint about &amp;gt; 6 camera setups.&lt;br /&gt;
&lt;br /&gt;
Another way is to make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs).&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis.&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (best, but uses HDD). And finally, You can mix it up. I would recommend in small setups, to throw a &amp;gt;1TB HDD in there for videos and set everything to mocord. For larger setups, you will want to customize each camera based on its priority.&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32 and newer, you can use multiple HDs, and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Some cameras have two streams. Run Mocord on the low res stream, and record or modect w/linked monitors - search forums for more details. Which you choose will depend whether you want to record all of the this camera or not. How much HDD space do you have?&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until no false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt; in Devuan based distros. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. Mocord is the best, but uses more HDD. Beware of running into issues with [[PurgeWhenFull]] not able to keep up.&lt;br /&gt;
&lt;br /&gt;
I personally like using hardware motion detectors, as ZMA/zmeventnotification and all the associated software to detect people can be a rabbit hole. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442 In some ways, ZMES may be an easier (less hardware) solution, so consider that.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. POTENTIAL RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
After using this setup for some years, a sudden rise in the cost of some goods a business kept in storage led to thefts. The bad news was, my modect zone wasn&amp;#039;t sensitive enough. This, with the added ability of ZM&amp;gt;1.32&amp;#039;s storage areas led me to re-evaulate the above. It turns out, there is another way. Instead of Modect on a zone, you can Record (or mocord). And, instead of motion detecting on the live video, you can do analysis on old videos. With a combination of these two posts (note: untested, for the record) https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video).&lt;br /&gt;
&lt;br /&gt;
This gives the CPU reductions of not actively Modect/Mocord, while still not missing anything. A dedicated ZM computer (RPI) can be used to analyze old footage. EDIT: This is a lot of work, and &amp;#039;&amp;#039;&amp;#039;I don&amp;#039;t recommend it.&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
tl;dr: Use mocord. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up. If you want, you can use the &amp;#039;linked monitors&amp;#039; function, and only record the 4K on motion (search forums). &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Conclusion&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
After all is said and done, motion detection works but has limitations. Motion detection tends to report false alarms from weather, wildlife, changing from IR to Day sensor, and others. For users that need accurate motion detection, you will either need to A) tune the zones so that no false alarms occur (see [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]) or B) use the cameras built in motion detection or C) use external motion sensors with [[ZMTrigger]] or some combination of the above.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*I prefer the usage of external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors.&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
* If you are setting up mobile phones with ZMNinja, and the wifi is the same WAN IP as the camera system, setup a VPS with a http/https proxy and point zmninja at the proxy. The proxy can be as simple as: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:80&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:443&lt;br /&gt;
sudo iptables-legacy -t nat -A POSTROUTING -j MASQUERADE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note that you might want to set nonstandard ports.&lt;br /&gt;
&lt;br /&gt;
* run 2k cameras at least. people like flashy things (like birds) and hi &lt;br /&gt;
res.&lt;br /&gt;
&lt;br /&gt;
* users seem to like fluid video, so put high fps on low res substream. &lt;br /&gt;
analysis fps limit to 2. we don&amp;#039;t have (asic) hardware yet, so there are limits, but cpu is still pretty &lt;br /&gt;
powerful.&lt;br /&gt;
&lt;br /&gt;
* the more you overbuild the cpu, the faster you can go.&lt;br /&gt;
&lt;br /&gt;
* passthrough on hi res stream obv. watch low res stream live, expand / &lt;br /&gt;
open window to hi res stream, ideally (custom javascript could do this:todo).&lt;br /&gt;
&lt;br /&gt;
* use zmninja + the website. offer customers both apps. there are also some other apps available. (e.g. possibly zmsquarer).&lt;br /&gt;
&lt;br /&gt;
* in most cases, you should replace coax cams with ethernet. customers&lt;br /&gt;
that are camera happy tend to like hi res, whether its needed or not, &lt;br /&gt;
and coax is low res.&lt;br /&gt;
&lt;br /&gt;
* (optional) configure zmes or good blob detection. you pretty much only&lt;br /&gt;
will be detecting people in the average business. maybe cars. For extra points, &lt;br /&gt;
figure out how to assign names to people in zmes.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[MJPEG_vs_H264]] For ZM &amp;lt; 1.31, use MJPEG for large deployments&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16712</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16712"/>
		<updated>2021-11-03T02:32:01Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Motion Detection */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
Consider the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
If you are already knowledgeable about servers, then you shouldn&amp;#039;t have any trouble.&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). 1.34 is currently recommended (11/2021).&lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
For ZM &amp;lt; 1.29 Make sure you add &amp;lt;code&amp;gt;innodb_file_per_table=1&amp;lt;/code&amp;gt; and ensure that the ZM database is InnoDB format, otherwise you may run into the issues described in [[MySQL]]. This is not necessary in 1.30.4 and later.&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an old [[Axis]] IP Camera. They are well documented and easy to setup. &lt;br /&gt;
Buy an old one for $10-20. Follow the instructions on either the Zoneminder Hardware compatiblity list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatiblity List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults in the source section.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; Grab MJPEG stream from IP camera on the network. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide jpeg images that change from somewhere). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. Anything RTSP should use FFMPEG.&lt;br /&gt;
&lt;br /&gt;
Local is for webcams (usb), or BTTV (pci) cards for analog aka coax cameras. Webcams are ok. BTTV is obsolete, but usable as legacy hardware. If you have analog cameras, you are best off using a video encoder. See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
After that you have FILE and REMOTE. I have not used FILE for anything but testing. I will cover REMOTE / FFMPEG.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;REMOTE &amp;amp; FFMPEG&amp;#039;&amp;#039;&amp;#039; have the option of either RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
These include [[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-80.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 uses compression, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. 1.36 has further efficiency improvements on this.&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. That being said, customers generally prefer higher res cameras, so you probably should replace them, unless its a low priority area.&lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog (a new type of analog camera that does HD over the coax), and I don&amp;#039;t recommend it. It is not standardized yet. Ethernet only for new cameras.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server. Montage view is good. See notes section for a hint about &amp;gt; 6 camera setups.&lt;br /&gt;
&lt;br /&gt;
Another way is to make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs).&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis.&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (best, but uses HDD). And finally, You can mix it up. I would recommend in small setups, to throw a &amp;gt;1TB HDD in there for videos and set everything to mocord. For larger setups, you will want to customize each camera based on its priority.&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32 and newer, you can use multiple HDs, and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Some cameras have two streams. Run Mocord on the low res stream, and record or modect w/linked monitors - search forums for more details. Which you choose will depend whether you want to record all of the this camera or not. How much HDD space do you have?&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until no false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt; in Devuan based distros. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. Mocord is the best, but uses more HDD. Beware of running into issues with [[PurgeWhenFull]] not able to keep up.&lt;br /&gt;
&lt;br /&gt;
I personally like using hardware motion detectors, as ZMA/zmeventnotification and all the associated software to detect people can be a rabbit hole. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442 In some ways, ZMES may be an easier (less hardware) solution, so consider that.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. POTENTIAL RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
After using this setup for some years, a sudden rise in the cost of some goods a business kept in storage led to thefts. The bad news was, my modect zone wasn&amp;#039;t sensitive enough. This, with the added ability of ZM&amp;gt;1.32&amp;#039;s storage areas led me to re-evaulate the above. It turns out, there is another way. Instead of Modect on a zone, you can Record (or mocord). And, instead of motion detecting on the live video, you can do analysis on old videos. With a combination of these two posts (note: untested, for the record) https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video).&lt;br /&gt;
&lt;br /&gt;
This gives the CPU reductions of not actively Modect/Mocord, while still not missing anything. A dedicated ZM computer (RPI) can be used to analyze old footage. EDIT: This is a lot of work, and &amp;#039;&amp;#039;&amp;#039;I don&amp;#039;t recommend it.&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
tl;dr: Use mocord. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up. If you want, you can use the &amp;#039;linked monitors&amp;#039; function, and only record the 4K on motion (search forums). &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Conclusion&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
After all is said and done, motion detection works but has limitations. Motion detection tends to report false alarms from weather, wildlife, changing from IR to Day sensor, and others. For users that need accurate motion detection, you will either need to A) tune the zones so that no false alarms occur (see [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]) or B) use the cameras built in motion detection or C) use external motion sensors with [[ZMTrigger]] or some combination of the above.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*I prefer the usage of external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors.&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
* If you are setting up mobile phones with ZMNinja, and the wifi is the same WAN IP as the camera system, setup a VPS with a http/https proxy and point zmninja at the proxy. The proxy can be as simple as: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:80&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:443&lt;br /&gt;
sudo iptables-legacy -t nat -A POSTROUTING -j MASQUERADE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note that you might want to set nonstandard ports.&lt;br /&gt;
&lt;br /&gt;
* run 2k cameras at least. people like flashy things (like birds) and hi &lt;br /&gt;
res.&lt;br /&gt;
&lt;br /&gt;
* users seem to like fluid video, so put high fps on low res substream. &lt;br /&gt;
analysis fps limit to 2. we don&amp;#039;t have (asic) hardware yet, so there are limits, but cpu is still pretty &lt;br /&gt;
powerful.&lt;br /&gt;
&lt;br /&gt;
* the more you overbuild the cpu, the faster you can go.&lt;br /&gt;
&lt;br /&gt;
* passthrough on hi res stream obv. watch low res stream live, expand / &lt;br /&gt;
open window to hi res stream, ideally (custom javascript could do this:todo).&lt;br /&gt;
&lt;br /&gt;
* use zmninja + the website. offer customers both apps. there are also some other apps available. (e.g. possibly zmsquarer).&lt;br /&gt;
&lt;br /&gt;
* in most cases, you should replace coax cams with ethernet. customers&lt;br /&gt;
that are camera happy tend to like hi res, whether its needed or not, &lt;br /&gt;
and coax is low res.&lt;br /&gt;
&lt;br /&gt;
* (optional) configure zmes or good blob detection. you pretty much only&lt;br /&gt;
will be detecting people in the average business. maybe cars. For extra points, &lt;br /&gt;
figure out how to assign names to people in zmes.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[MJPEG_vs_H264]] For ZM &amp;lt; 1.31, use MJPEG for large deployments&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16711</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16711"/>
		<updated>2021-11-03T02:31:15Z</updated>

		<summary type="html">&lt;p&gt;Snake: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
Consider the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
If you are already knowledgeable about servers, then you shouldn&amp;#039;t have any trouble.&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). 1.34 is currently recommended (11/2021).&lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
For ZM &amp;lt; 1.29 Make sure you add &amp;lt;code&amp;gt;innodb_file_per_table=1&amp;lt;/code&amp;gt; and ensure that the ZM database is InnoDB format, otherwise you may run into the issues described in [[MySQL]]. This is not necessary in 1.30.4 and later.&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an old [[Axis]] IP Camera. They are well documented and easy to setup. &lt;br /&gt;
Buy an old one for $10-20. Follow the instructions on either the Zoneminder Hardware compatiblity list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatiblity List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults in the source section.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; Grab MJPEG stream from IP camera on the network. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide jpeg images that change from somewhere). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. Anything RTSP should use FFMPEG.&lt;br /&gt;
&lt;br /&gt;
Local is for webcams (usb), or BTTV (pci) cards for analog aka coax cameras. Webcams are ok. BTTV is obsolete, but usable as legacy hardware. If you have analog cameras, you are best off using a video encoder. See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
After that you have FILE and REMOTE. I have not used FILE for anything but testing. I will cover REMOTE / FFMPEG.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;REMOTE &amp;amp; FFMPEG&amp;#039;&amp;#039;&amp;#039; have the option of either RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
These include [[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-80.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 uses compression, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. 1.36 has further efficiency improvements on this.&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. That being said, customers generally prefer higher res cameras, so you probably should replace them, unless its a low priority area.&lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog (a new type of analog camera that does HD over the coax), and I don&amp;#039;t recommend it. It is not standardized yet. Ethernet only for new cameras.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server. Montage view is good. See notes section for a hint about &amp;gt; 6 camera setups.&lt;br /&gt;
&lt;br /&gt;
Another way is to make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs).&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis.&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (best, but uses HDD). And finally, You can mix it up. I would recommend in small setups, to throw a &amp;gt;1TB HDD in there for videos and set everything to mocord. For larger setups, you will want to customize each camera based on its priority.&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32 and newer, you can use multiple HDs, and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Some cameras have two streams. Run Mocord on the low res stream, and record or modect w/linked monitors - search forums for more details. Which you choose will depend whether you want to record all of the this camera or not. How much HDD space do you have?&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until no false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt; in Devuan based distros. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. Mocord is the best, but uses more HDD. Beware of running into issues with [[PurgeWhenFull]] not able to keep up.&lt;br /&gt;
&lt;br /&gt;
I personally like using hardware motion detectors, as ZMA/zmeventnotification and all the associated software to detect people can be a rabbit hole. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. POTENTIAL RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
After using this setup for some years, a sudden rise in the cost of some goods a business kept in storage led to thefts. The bad news was, my modect zone wasn&amp;#039;t sensitive enough. This, with the added ability of ZM&amp;gt;1.32&amp;#039;s storage areas led me to re-evaulate the above. It turns out, there is another way. Instead of Modect on a zone, you can Record (or mocord). And, instead of motion detecting on the live video, you can do analysis on old videos. With a combination of these two posts (note: untested, for the record) https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video).&lt;br /&gt;
&lt;br /&gt;
This gives the CPU reductions of not actively Modect/Mocord, while still not missing anything. A dedicated ZM computer (RPI) can be used to analyze old footage. EDIT: This is a lot of work, and &amp;#039;&amp;#039;&amp;#039;I don&amp;#039;t recommend it.&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
tl;dr: Use mocord. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up. If you want, you can use the &amp;#039;linked monitors&amp;#039; function, and only record the 4K on motion (search forums). &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Conclusion&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
After all is said and done, motion detection works but has limitations. Motion detection tends to report false alarms from weather, wildlife, changing from IR to Day sensor, and others. For users that need accurate motion detection, you will either need to A) tune the zones so that no false alarms occur (see [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]) or B) use the cameras built in motion detection or C) use external motion sensors with [[ZMTrigger]] or some combination of the above.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*I prefer the usage of external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors.&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
* If you are setting up mobile phones with ZMNinja, and the wifi is the same WAN IP as the camera system, setup a VPS with a http/https proxy and point zmninja at the proxy. The proxy can be as simple as: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:80&lt;br /&gt;
sudo iptables-legacy -t nat -A PREROUTING -i eth0 -p tcp --dport 443 -j &lt;br /&gt;
DNAT --to-destination &amp;lt;officeip&amp;gt;:443&lt;br /&gt;
sudo iptables-legacy -t nat -A POSTROUTING -j MASQUERADE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note that you might want to set nonstandard ports.&lt;br /&gt;
&lt;br /&gt;
* run 2k cameras at least. people like flashy things (like birds) and hi &lt;br /&gt;
res.&lt;br /&gt;
&lt;br /&gt;
* users seem to like fluid video, so put high fps on low res substream. &lt;br /&gt;
analysis fps limit to 2. we don&amp;#039;t have (asic) hardware yet, so there are limits, but cpu is still pretty &lt;br /&gt;
powerful.&lt;br /&gt;
&lt;br /&gt;
* the more you overbuild the cpu, the faster you can go.&lt;br /&gt;
&lt;br /&gt;
* passthrough on hi res stream obv. watch low res stream live, expand / &lt;br /&gt;
open window to hi res stream, ideally (custom javascript could do this:todo).&lt;br /&gt;
&lt;br /&gt;
* use zmninja + the website. offer customers both apps. there are also some other apps available. (e.g. possibly zmsquarer).&lt;br /&gt;
&lt;br /&gt;
* in most cases, you should replace coax cams with ethernet. customers&lt;br /&gt;
that are camera happy tend to like hi res, whether its needed or not, &lt;br /&gt;
and coax is low res.&lt;br /&gt;
&lt;br /&gt;
* (optional) configure zmes or good blob detection. you pretty much only&lt;br /&gt;
will be detecting people in the average business. maybe cars. For extra points, &lt;br /&gt;
figure out how to assign names to people in zmes.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[MJPEG_vs_H264]] For ZM &amp;lt; 1.31, use MJPEG for large deployments&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16710</id>
		<title>Dummies Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Dummies_Guide&amp;diff=16710"/>
		<updated>2021-11-02T22:39:56Z</updated>

		<summary type="html">&lt;p&gt;Snake: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a short guide for using ZM. It&amp;#039;s concise, and tells you what you need to know.&lt;br /&gt;
&lt;br /&gt;
If you wish to view the full ZM Documentation, I recommend viewing it through the PDF view, as the sphinx website is not efficient and requires javascript. PDF View: https://readthedocs.org/projects/zoneminder/downloads/pdf/stable/&lt;br /&gt;
If you want a hard copy, you can order the documentation through a self publishing service like lulu.com&lt;br /&gt;
&lt;br /&gt;
Zoneminder is a powerful tool, but it has a learning curve. The forums are there to answer questions. Search then post if its not already answered.&lt;br /&gt;
&lt;br /&gt;
Consider the learning curve: It can be some work (depending on how complex your system is), but you will become a proficient gnulinux sysadmin if you familiarize yourself with ZM and its many features. If you buy an off the shelf DVR you won&amp;#039;t learn nearly as much (if anything). Additionally, these skills are valuable for &amp;#039;any&amp;#039; Unix-based server (DB, website, email server, kiosk, etc).&lt;br /&gt;
&lt;br /&gt;
==Install==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Use the install guides provided by Bbunge on the wiki:&lt;br /&gt;
[https://wiki.zoneminder.com/Contents#Installation_Procedure Zoneminder Wiki: Contents]&lt;br /&gt;
These are the best supported install guides.&lt;br /&gt;
&lt;br /&gt;
[[Ubuntu]] or [[Debian]] / Devuan  1.34 is recommended.&lt;br /&gt;
&lt;br /&gt;
Even numbers (1.34) are stable. Use those. Odd numbers are testing/development (1.35). 1.34 is currently recommended (10/2021).&lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s a guide for using an external HDD: [https://wiki.zoneminder.com/Using_a_dedicated_Hard_Drive Using a dedicated Hard Drive]&lt;br /&gt;
&lt;br /&gt;
For ZM &amp;lt; 1.29 Make sure you add &amp;lt;code&amp;gt;innodb_file_per_table=1&amp;lt;/code&amp;gt; and ensure that the ZM database is InnoDB format, otherwise you may run into the issues described in [[MySQL]]. This is not necessary in 1.30.4 and later.&lt;br /&gt;
&lt;br /&gt;
==Test out a Camera==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once you get ZM installed, you will want to test out a camera.&lt;br /&gt;
You can do a webcam, or you can do an IP camera. &lt;br /&gt;
See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
I recommend you start with an old [[Axis]] IP Camera. They are well documented and easy to setup. &lt;br /&gt;
Buy an old one for $10-20. Follow the instructions on either the Zoneminder Hardware compatiblity list,&lt;br /&gt;
on ispyconnect&amp;#039;s url list, or in the user manual for the camera. Any respectable camera will document it&amp;#039;s RTSP and MJPEG / JPG paths for you to access. ONVIF is also an option to find the path for RTSP cameras. This is covered in more detail in [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Follow the instructions in the Hardware Compatiblity List for parameters&lt;br /&gt;
for setting up a camera the first time. If you have an error, look at the logs. FFMPEG and VLC can be used to test that the streams are valid. e.g. ffmpeg -i rtsp://username:password@&amp;lt;ipaddress&amp;gt;:554/path output.mp4 This is faster than using ZM.&lt;br /&gt;
&lt;br /&gt;
In ZM, IP address, path, port, and Resolution must be correct. Most other fields can be left at defaults in the source section.&lt;br /&gt;
&lt;br /&gt;
If you can view the MJPEG or JPG url in your browser, you will be in good shape. Take that path, and put it into Zoneminder. If the camera requires authorization, consult the user manual, or you can try adding the username and password before the ip like so username:password@ipaddress&lt;br /&gt;
e.g. root:mypass@192.168.1.5&lt;br /&gt;
This is an alternative to 192.168.1.5?username=root&amp;amp;pwd=mypass which most guides tell you to do. Both will work, however the latter can vary in what keywords it uses (pwd vs pass vs password) while the former requires no keywords.&lt;br /&gt;
&lt;br /&gt;
If pass is blank, you type in root:@192.168.1.5&lt;br /&gt;
&lt;br /&gt;
RTSP always specifies the port. e.g. &amp;lt;code&amp;gt;rtsp://user:password@192.168.1.10:554/somepath&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Obtaining more Cameras==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In ZoneMinder, when you add a camera, you have a few options: &lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;LOCAL&amp;#039;&amp;#039;&amp;#039; Camera connected directly to computer (webcam, or analog camera thorugh bttv card)(typically /dev/video0)&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;REMOTE&amp;#039;&amp;#039;&amp;#039; Grab MJPEG stream from IP camera on the network. &lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FILE&amp;#039;&amp;#039;&amp;#039; Grab a jpg file somewhere locally and display that (you provide jpeg images that change from somewhere). Can be used in unusual ways (i.e. a slide show, &amp;lt;insert use here&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;FFMPEG&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;LIBVLC&amp;#039;&amp;#039;&amp;#039; use the respective libraries to pull a stream similar to REMOTE does for RTSP only. Anything RTSP should use FFMPEG.&lt;br /&gt;
&lt;br /&gt;
Local is for webcams (usb), or BTTV (pci) cards for analog aka coax cameras. Webcams are ok. BTTV is obsolete, but usable as legacy hardware. If you have analog cameras, you are best off using a video encoder. See the [[Hardware_Compatibility_List]]&lt;br /&gt;
&lt;br /&gt;
After that you have FILE and REMOTE. I have not used FILE for anything but testing. I will cover REMOTE / FFMPEG.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;REMOTE &amp;amp; FFMPEG&amp;#039;&amp;#039;&amp;#039; have the option of either RTSP (h264) or MJPEG streams. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===MJPEG===&lt;br /&gt;
These include [[Arecont Vision]], [[Axis]], Bosch, [[Foscam]], [[Grandstream]], Instar, Messoa, Zavio and others. &lt;br /&gt;
The prices scale with features. Old indoor Axis cameras at 480p-720p resolution (no IR) can be found&lt;br /&gt;
online easily for $10-80.&lt;br /&gt;
&lt;br /&gt;
Also see, [[Hardware_Compatibility_List#Single_Board_Computers SBC cameras]].&lt;br /&gt;
&lt;br /&gt;
===RTSP===&lt;br /&gt;
These cameras use h264 (or h265) compression. They serve it on an RTSP server. h264 uses compression, so you end up using less HDD space than compared with MJPEG. H264 is recommended when possible.&lt;br /&gt;
&lt;br /&gt;
Note: Users with 1.32+ can use &amp;#039;&amp;#039;&amp;#039;H264 passthrough&amp;#039;&amp;#039;&amp;#039;, which writes the h264 direct to mp4, and saves some CPU usage. 1.36 has further efficiency improvements on this.&lt;br /&gt;
&lt;br /&gt;
===How Powerful of a Computer to Use===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;High-end&amp;#039;&amp;#039;&amp;#039; server hardware will perform better than desktop, or low end server hardware. I have seen this firsthand between two servers: KFSN4-DRE and the KGPE-D16.  The latter runs ZM with 25+ cameras, not breaking a sweat. The former reaches a limit at about 10. Another limitation is HDD size. &lt;br /&gt;
&lt;br /&gt;
I currently recommend buying Axis (new is expensive, so you&amp;#039;ll probably purchase used), although many do not have IR. This is not a problem, as outdoors IR on cameras attracts spider webs, and external IR is recommended. Another recommended brand is Hikvision. Hikvision can be bought new for a lower price if warranty is an issue (for business clients that can&amp;#039;t afford Axis). The cameras work well with ZM, and are configurable without Windows, Otherwise, any respectable name brand camera will work. Look through the hardware compatibility list. Read the user manual before you purchase the camera, and look for the following: Outdoors/indoors, IR/no-IR, Resolution. IR can be supplemented with external appliances. &lt;br /&gt;
&lt;br /&gt;
=== A note on Analog Cameras ===&lt;br /&gt;
&lt;br /&gt;
If you are upgrading an existing camera installation, you will likely have coaxial cables for the old cameras. These can be used with Zoneminder in either LOCAL, or REMOTE/FFMPEG. LOCAL, via a PCI or PCI-Express card, REMOTE/FFMPEG through a video encoder that takes the analog stream and converts to either MJPG or RTSP. I recommend the latter. &lt;br /&gt;
&lt;br /&gt;
There is no reason to rip out, or ignore old coaxial cables. They are perfectly viable for Zoneminder. They may be a step behind the IP cameras, however they can be used. &lt;br /&gt;
&lt;br /&gt;
I have not worked with HD analog (a new type of analog camera that does HD over the coax), and I don&amp;#039;t recommend it. It is not standardized yet. Ethernet only for new cameras.&lt;br /&gt;
&lt;br /&gt;
==Watching the Cameras==&lt;br /&gt;
&lt;br /&gt;
Cameras can be watched from the ZM apache server. Montage view is good. See notes section for a hint about &amp;gt; 6 camera setups.&lt;br /&gt;
&lt;br /&gt;
Another way is to make an html file on a remote machine with the following code embedded in an img tag. Adjust monitor ID as needed.&lt;br /&gt;
[https://wiki.zoneminder.com/How_to_stream_from_another_ZoneMinder_installation   How to stream from another ZoneMinder installation]. Also an easy way to embed video in a website (img tag). See [[Dedicated SBC Camera Monitor]] for notes on refreshing the stream periodically. [[https://wiki.zoneminder.com/Example_Camera_View_HTML]]&lt;br /&gt;
&lt;br /&gt;
Streaming in ZM, does not slow it down, in my experience.&lt;br /&gt;
&lt;br /&gt;
If you embed the URL in an img tag, include http prefix or it wont work.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
img width=&amp;quot;500px&amp;quot; height=&amp;quot;500px&amp;quot; src=&amp;quot;http://zmserveripaddress/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=#&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;user=username&amp;amp;pass=password&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Call it locally:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
firefox file:///home/username/file.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you have &amp;gt; 6 cameras, you can either use firefox and edit about:config (explained below in guide), or see&lt;br /&gt;
https://forums.zoneminder.com/viewtopic.php?t=28168&amp;amp;p=113934#p113934&lt;br /&gt;
for instructions regarding multi port. &lt;br /&gt;
&lt;br /&gt;
Watch the scale parameter. That can be adjusted for clients with low power CPUs (ARM SBCs).&lt;br /&gt;
&lt;br /&gt;
=== Quick Example ===&lt;br /&gt;
&lt;br /&gt;
[[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
[https://forums.zoneminder.com/viewtopic.php?f=37&amp;amp;t=26982 Embedding Streaming Video in External Website] from Forums&lt;br /&gt;
&lt;br /&gt;
==Recording in Zoneminder==&lt;br /&gt;
The zmc binary handles recording and analysis.&lt;br /&gt;
&lt;br /&gt;
You can record everything (good, but no way to find events). You can modect everything (light HDD use, but misses stuff). You can mocord everything (best, but uses HDD). And finally, You can mix it up. I would recommend in small setups, to throw a &amp;gt;1TB HDD in there for videos and set everything to mocord. For larger setups, you will want to customize each camera based on its priority.&lt;br /&gt;
&lt;br /&gt;
In ZM 1.32 and newer, you can use multiple HDs, and assign cameras to where they should be saved. These are &amp;#039;&amp;#039;&amp;#039;storage areas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Some cameras have two streams. Run Mocord on the low res stream, and record or modect w/linked monitors - search forums for more details. Which you choose will depend whether you want to record all of the this camera or not. How much HDD space do you have?&lt;br /&gt;
&lt;br /&gt;
==Motion Detection==&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What&amp;#039;s all this motion detection stuff, anyhow?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The strength of zoneminder lies in its motion detection analysis (thus the &amp;#039;zone&amp;#039; in zoneminder, being the motion detection zones). See: [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]&lt;br /&gt;
&lt;br /&gt;
Start with the most sensitive settings, and make them less sensitive until no false alarms are recorded. Night IR detects more false events than daylight. Monitoring for all alarms can easily be done by &amp;lt;code&amp;gt;$ tail -f /var/log/syslog&amp;lt;/code&amp;gt; in Devuan based distros. &lt;br /&gt;
&lt;br /&gt;
Or you can record everything, if modect isn&amp;#039;t working. Mocord will combine both modect and record, having everything recorded, but making a graph where motion occurs (in &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039; https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline. Mocord is the best, but uses more HDD. Beware of running into issues with [[PurgeWhenFull]] not able to keep up.&lt;br /&gt;
&lt;br /&gt;
I personally like using hardware motion detectors, as ZMA/zmeventnotification and all the associated software to detect people can be a rabbit hole. But, these come at a cost - more initial setup and wiring. I have an arduino sketch here: https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=27442&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why motion detection?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Using modect or mocord is &amp;#039;&amp;#039;&amp;#039;recommended&amp;#039;&amp;#039;&amp;#039; here. Because you are able to click from the main zm index - events - &amp;#039;&amp;#039;&amp;#039;show timeline&amp;#039;&amp;#039;&amp;#039;, and from there quickly review your modect events. Because you save HDD space. And [[SMS Notifications]] and [[ZMTrigger]] can be setup off of modect alarms (the latter requiring either modect, mocord, or nodect).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Any downsides?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Zones must be tuned to be sensitive enough to see all events, but not so sensitive as to detect false alarms. This requires work, and is not guaranteed to work 100% even after tweaking. POTENTIAL RABBIT HOLE WARNING...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Help, I missed an event!?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
After using this setup for some years, a sudden rise in the cost of some goods a business kept in storage led to thefts. The bad news was, my modect zone wasn&amp;#039;t sensitive enough. This, with the added ability of ZM&amp;gt;1.32&amp;#039;s storage areas led me to re-evaulate the above. It turns out, there is another way. Instead of Modect on a zone, you can Record (or mocord). And, instead of motion detecting on the live video, you can do analysis on old videos. With a combination of these two posts (note: untested, for the record) https://forums.zoneminder.com/viewtopic.php?f=11&amp;amp;t=24686 and https://forums.zoneminder.com/viewtopic.php?f=8&amp;amp;t=28013&amp;amp;p=109190   You can re-create videos from your (JPEG ONLY) footage, and then reanalyze them. (those with ffmpeg mp4s created, may need to combine the footage into one video).&lt;br /&gt;
&lt;br /&gt;
This gives the CPU reductions of not actively Modect/Mocord, while still not missing anything. A dedicated ZM computer (RPI) can be used to analyze old footage. EDIT: This is a lot of work, and &amp;#039;&amp;#039;&amp;#039;I don&amp;#039;t recommend it.&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
tl;dr: Use mocord. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;4K Cameras&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Mocord on the low res stream, and record on the high res stream. Do NOT use any analysis (zma) on the high res stream. Analysis is where the CPU is eaten up. If you want, you can use the &amp;#039;linked monitors&amp;#039; function, and only record the 4K on motion (search forums). &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Conclusion&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
After all is said and done, motion detection works but has limitations. Motion detection tends to report false alarms from weather, wildlife, changing from IR to Day sensor, and others. For users that need accurate motion detection, you will either need to A) tune the zones so that no false alarms occur (see [https://wiki.zoneminder.com/Understanding_ZoneMinder%27s_Zoning_system_for_Dummies  Understanding Zoneminder&amp;#039;s Zoning system for Dummies]) or B) use the cameras built in motion detection or C) use external motion sensors with [[ZMTrigger]] or some combination of the above.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Sizing Zones&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;My first thought is the threshold is too low. It happened to me when I &lt;br /&gt;
first started with ZM. I figured out a little trick:&lt;br /&gt;
&lt;br /&gt;
Draw a new zone a little smaller than you appear in the video. The zone &lt;br /&gt;
will tell you the number of pixels or the percent of the whole frame. &lt;br /&gt;
Compare that to the size you have setup to detect. If you are using &lt;br /&gt;
percent try changing to pixels, that will not require the math to adjust &lt;br /&gt;
the percent.&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref: http://forums.zoneminder.com/viewtopic.php?f=40&amp;amp;t=30570&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
&lt;br /&gt;
*Zones should be as small as possible, and you should use as few zones per monitor, to lower CPU usage. &lt;br /&gt;
*Analysis FPS can be limited to 1-2 FPS to lower CPU usage. &amp;#039;&amp;#039;&amp;#039;IMPORTANT&amp;#039;&amp;#039;&amp;#039; (do not limit Max FPS, only analysis).&lt;br /&gt;
*Aggressive Modect usage can run into issues with [[PurgeWhenFull]], beware. &lt;br /&gt;
*Transitions from [https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=27141 daylight to IR] cause false alarms. The solution is to &amp;quot;Set a max alarmed area so it doesn&amp;#039;t alarm if the whole area is changing&amp;quot;. &lt;br /&gt;
*I prefer the usage of external hardware motion sensors via [[ZMTrigger]] over modect, when high reliability / low false alarms is required.&lt;br /&gt;
*JPEG saving, should be avoided on H264 streams when possible. Use H264 passthrough. Consider how decoding the H264 stream to JPEG uses CPU, while passthrough will avoid this conversion step.&lt;br /&gt;
* If you have more than 6 cameras you may want to setup multi-port as an alternative to firefox about:config edits. See: https://medium.com/zmninja/multi-port-storage-areas-and-more-d5836a336c93    Note: article written by zm dev. See also [[Multi_Port]]&lt;br /&gt;
&lt;br /&gt;
==Hardware Advice==&lt;br /&gt;
&lt;br /&gt;
When setting up the cameras, here is some advice.&lt;br /&gt;
* Use fuses on the PSU output to the cameras, if using passive POE adaptors.&lt;br /&gt;
* Use barrel plug splitters, and use one 12V PSU. (i.e. a barrel plug that is a 1 to 5 splitter). Cameras in my experience use around 200-400mA of current at 12V (400mA is when IR LEDs are on).&lt;br /&gt;
* If you purchase axis cameras, be aware that the cameras are 5V and the barrel plug is 4.0mm x 1.7mm. It&amp;#039;s easiest to use POE on these (and all cameras actually).&lt;br /&gt;
* Installing areas where the temperature is high may cause early camera failure (especially for cheaper cameras). Even something as simple as a corner of an enclosed room where the sun shines all day may be enough heat.&lt;br /&gt;
&lt;br /&gt;
==Troubleshooting==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Watch logs.&lt;br /&gt;
&lt;br /&gt;
* Use forum search.&lt;br /&gt;
&lt;br /&gt;
* Use web search.&lt;br /&gt;
&lt;br /&gt;
* Enable component logs and navigate to /var/log/zm/.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;# tail -F /var/log/syslog&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Beware of underlying hardware faults such as bad RAM.&lt;br /&gt;
&lt;br /&gt;
* Disable logs after you are done.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Some cams will have two video streams (e.g. Hikvision, Amcrest). The resolutions/video type may or may not be the same. For example, there may be a low resolution mjpeg stream, and a high resolution RTSP stream. Read the data sheet / user manual for cameras you intend to purchase. Multiple streams are desirable.&lt;br /&gt;
&lt;br /&gt;
* I found it helpful to include monitor ID in camera names, as you run into monitor ID in logs often.&lt;br /&gt;
&lt;br /&gt;
* Proprietary cameras are known to report to outside IPs. Don&amp;#039;t give them internet access. Only the server should be wan-accessible. Make a separate network.&lt;br /&gt;
&lt;br /&gt;
* Many cameras have default telnet passwords, in addition to the default web access passwords. Change these or keep cameras away from the wan. Cameras are common botnet targets.&lt;br /&gt;
&lt;br /&gt;
* With server motherboard hardware, you will be able to have more cameras (servers are more powerful, and better servers will have better performance).&lt;br /&gt;
&lt;br /&gt;
* I use ext4 filesystem for the HDDs. I had tried using ext2 filesystem for better performance, but the fsck time is prohibatively slow for ext2 (&amp;gt;24 hours for &amp;gt;2TB). Ext4 seems to work well. Older ext2, or ext3 fs can be upgraded to ext4. Other filesystems are generally, not recommended. Ext4 works fine. You have been warned.&lt;br /&gt;
&lt;br /&gt;
* When viewing the cameras in Firefox, once you get more than 6 cameras from ZM on the browser Firefox will not display the seventh. This is due to a limit of Firefox and can be adjusted in about:config. See: [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23417&amp;amp;p=89249  ZM Forums: Problems when two people are watching live] [http://kb.mozillazine.org/Network.http.max-persistent-connections-per-server Network.http.max-persistent-connections-per-server]. This max persistent connections per server must be &amp;gt; 6 in order to see &amp;gt; 6 camera streams.&lt;br /&gt;
&lt;br /&gt;
* Adding &amp;quot;&amp;lt; /dev/null&amp;quot; to the ffmpeg path used by ZM might fix some issues. See [https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23861&amp;amp;p=91771  ZM Forums: Truncated Video Export]&lt;br /&gt;
&lt;br /&gt;
* If you are going to use a BT878 based card, you can add a heatsink onto the top of all *878 chips. This has been mentioned in the [https://forums.zoneminder.com/search.php?keywords=heatsink+bt878 forums in various spots], Use a ruler, and measure the dimensions in mm, then purchase one on digikey. A heatsink attached to the plastic of the IC, instead of the actual IC die is not ideal, but it will help. EDIT: I&amp;#039;m not sure if this is necessary, in hindsight. Also consider a video encoder instead of a BT878 card (e.g. search auction sites for 1 or 2 or 4 channel video encoder). &lt;br /&gt;
&lt;br /&gt;
* Edit /etc/default/rcS (applies to devuan/trisquel) and make sure auto FSCK is enabled. Failure to set this, will require manual intervention when the server is repairing the filesystem, requiring you to press a key.&lt;br /&gt;
&lt;br /&gt;
* Make sure the BIOS is set to power on after power fails.&lt;br /&gt;
&lt;br /&gt;
* Set colourspace to 32-bit for a possible performance boost.&lt;br /&gt;
&lt;br /&gt;
* Don&amp;#039;t set a Max FPS limit on REMOTE or FFMPEG, or VLC cameras in Zoneminder. The FPS should only to be set at the IP camera itself. Max FPS limiting is for LOCAL cameras, only.&lt;br /&gt;
&lt;br /&gt;
* With larger camera setups (one 10, one &amp;gt;20 cameras) I needed to change the watchdog timer (/usr/bin/zmwatch.pl) from the default of 10 seconds to 30 or 60 seconds in order to avoid periodic drop outs of individual cameras. The cameras would drop, and not return, unless i restarted zoneminder or disabled and enabled that camera. This setting is managed in options - system. If you see dropouts after that, review /usr/bin/zmwatch.pl and insert additional logging. You can also add a hack to the API so that if cameras drop out they are restarted. See documentation of ZM API. For my setups, they typically drop out once a day on specific cameras. Other cameras will never drop out. EDIT: This was because I had poorly supported cameras. Don&amp;#039;t buy off brand cameras, or this might happen to you.&lt;br /&gt;
&lt;br /&gt;
* Do NOT point cameras at bright light, such as facing a window, a garage door, or anything that generates glare. It will blur the image / potentially damage the camera&amp;#039;s image sensor.&lt;br /&gt;
&lt;br /&gt;
* Buy a set of adapters such as these: to use with your normal 5.5 2.1mm barrel plug. Search multi type 23 or 28 dc power adapter.&lt;br /&gt;
&lt;br /&gt;
[[File:Universal-28pcs-5-5x2-1mm-Multi-type-Male-Jack-for-DC-Plugs-for-AC-Power-Adapter.jpg 640x640.jpg|200px|Coaxial barrel plug adaptors||Universal 28pcx Multi type Male Jack for DC Plugs]]&lt;br /&gt;
&lt;br /&gt;
* I made a script to watch cameras that drop out, and disable/reenable them for my 1.29 setup. See [https://forums.zoneminder.com/viewtopic.php?f=9&amp;amp;t=26909 here]. This also doubles as a notification in case the cameras somehow are powered off. You&amp;#039;ll get emails telling you cameras are down. EDIT: See note about poorly supported cameras above. With good cameras, this does not occur. Rabbit hole warning.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[API]]&lt;br /&gt;
&lt;br /&gt;
* [[Cron]] example&lt;br /&gt;
&lt;br /&gt;
* [[Dedicated SBC Camera Monitor]] Guides for using a Beaglebone Black or Desktop as a client to watch the ZM Server.&lt;br /&gt;
&lt;br /&gt;
* [[Docker]]&lt;br /&gt;
&lt;br /&gt;
* [[Example Camera View HTML]] A quick html file you can deploy on clients to watch the server.&lt;br /&gt;
&lt;br /&gt;
* [[Exporting Videos Hack]] (not recommended)&lt;br /&gt;
&lt;br /&gt;
* [[Filters]] Examples&lt;br /&gt;
&lt;br /&gt;
* [[Finding Camera Stream Paths]]&lt;br /&gt;
&lt;br /&gt;
* [[ffmpeg]] Example usage, and notes.&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/How_to_view_recorded_history_from_show_timeline&lt;br /&gt;
&lt;br /&gt;
* [[MJPEG_vs_H264]] For ZM &amp;lt; 1.31, use MJPEG for large deployments&lt;br /&gt;
&lt;br /&gt;
* [[Multi_Port]] For streaming more than 6 cameras at once to a browser.&lt;br /&gt;
&lt;br /&gt;
* [[MySQL]] can require some optimizing, and there are potential gotchas. Though newer releases of Zoneminder may have resolved some of the issues.&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]] tips&lt;br /&gt;
&lt;br /&gt;
* [[PurgeWhenFull]] requires configuration on larger systems, or systems where events are created at a pace faster than PurgeWhenFull can keep up. Failure to do so, will result in all events being blank, and you will have to fix it.&lt;br /&gt;
&lt;br /&gt;
* [[SMS Notifications]] or email.&lt;br /&gt;
&lt;br /&gt;
* [[Zmodopipe]] Is a tool that can tie an analog DVR system to Zoneminder, although it is far from perfect. I have documented it there, and recommend purchasing a (some #) channel video encoder instead.&lt;br /&gt;
&lt;br /&gt;
* [[ZMNinja]] - General usage, also Geoblocking w/apache.&lt;br /&gt;
&lt;br /&gt;
* [[ZMTrigger]] is a tool that can be used to take outside information and overlay it onto the camera display. For example, you might take the temperature, or wind speed, and overlay it on a camera. It can also be used as external motion detection. Experience with electronics and microcontrollers such as AVRs, Pics, and the Arduino IDE are applicable here.&lt;br /&gt;
&lt;br /&gt;
===Other Users===&lt;br /&gt;
&lt;br /&gt;
* [[How to share an USB camera from a remote ZM server to another ZM Server]]&lt;br /&gt;
&lt;br /&gt;
* [[General Notes]]&lt;br /&gt;
&lt;br /&gt;
* https://forums.zoneminder.com/viewtopic.php?f=32&amp;amp;t=23815&amp;amp;hilit=i+run+this+script+every+night Backup DB script (Recommended)&lt;br /&gt;
&lt;br /&gt;
* https://wiki.zoneminder.com/Ubuntu_Install_ZoneMinder_on_Ubuntu_Server Apache Hardening&lt;br /&gt;
&lt;br /&gt;
* https://github.com/lbdc/zm_movie_bootstrap Create timelapse videos (adjust fps) or just export. Terminal or GUI. Good example of a basic ZM hack interfacing with db, and querying video files.&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=External_Live_Stream&amp;diff=16709</id>
		<title>External Live Stream</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=External_Live_Stream&amp;diff=16709"/>
		<updated>2021-11-02T18:12:27Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Setup */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Here is an html file you might use in a ZM client [[Desktop SBC Camera Monitor]] to view the streams from the ZM Server. You will need to adjust the resolution, number of cameras, and monitor id of the URL to your setup.&lt;br /&gt;
&lt;br /&gt;
In my experience, Clients viewing the Streams (up to 3 clients, with 20+ cameras) do not slow down the ZM Server.&lt;br /&gt;
&lt;br /&gt;
For more details, see [[Dummies_Guide#Watching_the_Cameras]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;html&amp;gt;&amp;lt;body bgcolor=&amp;quot;black&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;img width=&amp;quot;412px&amp;quot; height=&amp;quot;268px&amp;quot; src=&amp;quot;http://IPOFZMSERVER/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=1&amp;amp;scale=100&amp;quot;&amp;amp;user=&amp;quot;watchinguser&amp;quot;&amp;amp;pass=&amp;quot;somepassword&amp;quot; &amp;gt;&lt;br /&gt;
&amp;lt;img width=&amp;quot;412px&amp;quot; height=&amp;quot;268px&amp;quot; src=&amp;quot;http://IPOFZMSERVER/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=2&amp;amp;scale=100&amp;quot;&amp;amp;user=&amp;quot;watchinguser&amp;quot;&amp;amp;pass=&amp;quot;somepassword&amp;quot; &amp;gt;&lt;br /&gt;
&amp;lt;img width=&amp;quot;412px&amp;quot; height=&amp;quot;268px&amp;quot; src=&amp;quot;http://IPOFZMSERVER/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=3&amp;amp;scale=100&amp;quot;&amp;amp;user=&amp;quot;watchinguser&amp;quot;&amp;amp;pass=&amp;quot;somepassword&amp;quot; &amp;gt;&lt;br /&gt;
&amp;lt;img width=&amp;quot;412px&amp;quot; height=&amp;quot;268px&amp;quot; src=&amp;quot;http://IPOFZMSERVER/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=4&amp;amp;scale=100&amp;quot;&amp;amp;user=&amp;quot;watchinguser&amp;quot;&amp;amp;pass=&amp;quot;somepassword&amp;quot; &amp;gt;&lt;br /&gt;
&amp;lt;img width=&amp;quot;412px&amp;quot; height=&amp;quot;268px&amp;quot; src=&amp;quot;http://IPOFZMSERVER/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=5&amp;amp;scale=100&amp;quot;&amp;amp;user=&amp;quot;watchinguser&amp;quot;&amp;amp;pass=&amp;quot;somepassword&amp;quot; &amp;gt;&lt;br /&gt;
&amp;lt;img width=&amp;quot;412px&amp;quot; height=&amp;quot;268px&amp;quot; src=&amp;quot;http://IPOFZMSERVER/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=6&amp;amp;scale=100&amp;quot;&amp;amp;user=&amp;quot;watchinguser&amp;quot;&amp;amp;pass=&amp;quot;somepassword&amp;quot; &amp;gt;&lt;br /&gt;
&amp;lt;/body&amp;gt;&lt;br /&gt;
&amp;lt;/html&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Setup==&lt;br /&gt;
In 1.32 and 1.34, you may have to adjust the following setting for auth_relay if authentication is used. Note that this conflicts with [[ZMNinja]], which requires auth_relay to be set to hashed, I believe. &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Post by rockedge» Fri Jun 30, 2017 8:09 pm&lt;br /&gt;
in a WordPress page or post I use something like this: Remember that &lt;br /&gt;
with certain authorizations set, the URL would be slightly different.&lt;br /&gt;
this URL works when :&lt;br /&gt;
Options-&amp;gt;System-&amp;gt;OPT_USE_AUTH = ON&lt;br /&gt;
Options-&amp;gt;System-&amp;gt;AUTH_TYPE = Builtin&lt;br /&gt;
Options-&amp;gt;System-&amp;gt;AUTH_RELAY = NONE&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;&amp;lt;img class=&amp;quot;aligncenter&amp;quot; &lt;br /&gt;
src=&amp;quot;http://your_zm_server/cgi-bin/nph-zms?mode=jpeg&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;buffer=1000&amp;amp;monitor=1&amp;amp;user=admin&amp;quot; alt=&amp;quot;stream down&amp;quot; width=&amp;quot;420&amp;quot; height=&amp;quot;340&amp;quot; /&amp;gt;&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref:https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=26292&lt;br /&gt;
&lt;br /&gt;
&amp;lt;small&amp;gt;Note that this URL omits password. But it is given in the top example.&amp;lt;/small&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
===Quickly Change pixel settings for page===&lt;br /&gt;
It should be possible to use CSS and have the videos fill the page appropriately (I haven&amp;#039;t gotten around to it. Contributions welcome.) but it&amp;#039;s also possible to use sed here to adjust the pixels as needed:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sed -e &amp;#039;s/oldpx/newpx/g&amp;#039; -i cameras.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Refresh Page Periodically===&lt;br /&gt;
Refreshing the page is a good idea, so that any streams don&amp;#039;t drop out for any reason. You can do this with xdotool (see [[Dedicated_SBC_Camera_Monitor#Refresh_Screen_Periodically]] )or possibly with html:[https://forums.zoneminder.com/viewtopic.php?f=39&amp;amp;t=28897]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;meta http-equiv=&amp;quot;refresh&amp;quot; content=&amp;quot;300&amp;quot;&amp;gt;&amp;lt;!-- EDIT: This may not work. Perhaps try js --&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Scale may be required for large numbers of cameras or SBCs===&lt;br /&gt;
&lt;br /&gt;
See that scale=100 option in the URL? That is used to downscale or downsample the video stream resolution. But, since you set the height and width, it won&amp;#039;t make the video smaller. If you have a 2K stream, but you are viewing it at 640x480, you don&amp;#039;t need 100% scaling. Lower the number to keep the bandwidth / memory usage down. &lt;br /&gt;
&lt;br /&gt;
Where this is required, is when you have a lot of monitors, say 20+ cameras. Or you have an SBC that can&amp;#039;t handle full res streams. In these scenarios, if you don&amp;#039;t scale, you will either see the CPU max out on the watching computer, or you will see video feeds drop in and out periodically. For more details, see how ZM handles the URL for montage.&lt;br /&gt;
&lt;br /&gt;
===Single Snapshot URL===&lt;br /&gt;
The URL for a single snapshot is:&lt;br /&gt;
 http://serverip/zm/cgi-bin/nph-zms?mode=single&amp;amp;monitor=2&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;buffer=1000&amp;amp;user=somename&amp;amp;pass=somepass&lt;br /&gt;
Adjust Monitor # as needed. (Also see note in setup section above).&lt;br /&gt;
&lt;br /&gt;
===Alternative Single Snapshop JPG via ZMU===&lt;br /&gt;
zmu is a binary, along with zma, and zmc that can do various functions. One of them is creating a jpeg.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/bin# zmu -h&lt;br /&gt;
zmu &amp;lt;-d device_path&amp;gt; [-v] [function] [-U&amp;lt;username&amp;gt; -P&amp;lt;password&amp;gt;]&lt;br /&gt;
zmu &amp;lt;-m monitor_id&amp;gt; [-v] [function] [-U&amp;lt;username&amp;gt; -P&amp;lt;password&amp;gt;]&lt;br /&gt;
General options:&lt;br /&gt;
  -h, --help           : This screen&lt;br /&gt;
  -v, --verbose          : Produce more verbose output&lt;br /&gt;
 ...&lt;br /&gt;
  -i, --image [image_index]    : Write captured image to disk as &amp;lt;monitor_name&amp;gt;.jpg, last image captured&lt;br /&gt;
                   or specified ring buffer index if given.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===ffplay===&lt;br /&gt;
It is possible to use ffplay to directly stream a single camera feed (bypassing ZM) to the desktop. Although refreshing may be more involved.&lt;br /&gt;
 ffplay -i rtsp://user:Password@ipaddress:554/video&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=External_Live_Stream&amp;diff=16708</id>
		<title>External Live Stream</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=External_Live_Stream&amp;diff=16708"/>
		<updated>2021-11-02T18:12:08Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Setup */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Here is an html file you might use in a ZM client [[Desktop SBC Camera Monitor]] to view the streams from the ZM Server. You will need to adjust the resolution, number of cameras, and monitor id of the URL to your setup.&lt;br /&gt;
&lt;br /&gt;
In my experience, Clients viewing the Streams (up to 3 clients, with 20+ cameras) do not slow down the ZM Server.&lt;br /&gt;
&lt;br /&gt;
For more details, see [[Dummies_Guide#Watching_the_Cameras]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;html&amp;gt;&amp;lt;body bgcolor=&amp;quot;black&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;img width=&amp;quot;412px&amp;quot; height=&amp;quot;268px&amp;quot; src=&amp;quot;http://IPOFZMSERVER/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=1&amp;amp;scale=100&amp;quot;&amp;amp;user=&amp;quot;watchinguser&amp;quot;&amp;amp;pass=&amp;quot;somepassword&amp;quot; &amp;gt;&lt;br /&gt;
&amp;lt;img width=&amp;quot;412px&amp;quot; height=&amp;quot;268px&amp;quot; src=&amp;quot;http://IPOFZMSERVER/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=2&amp;amp;scale=100&amp;quot;&amp;amp;user=&amp;quot;watchinguser&amp;quot;&amp;amp;pass=&amp;quot;somepassword&amp;quot; &amp;gt;&lt;br /&gt;
&amp;lt;img width=&amp;quot;412px&amp;quot; height=&amp;quot;268px&amp;quot; src=&amp;quot;http://IPOFZMSERVER/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=3&amp;amp;scale=100&amp;quot;&amp;amp;user=&amp;quot;watchinguser&amp;quot;&amp;amp;pass=&amp;quot;somepassword&amp;quot; &amp;gt;&lt;br /&gt;
&amp;lt;img width=&amp;quot;412px&amp;quot; height=&amp;quot;268px&amp;quot; src=&amp;quot;http://IPOFZMSERVER/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=4&amp;amp;scale=100&amp;quot;&amp;amp;user=&amp;quot;watchinguser&amp;quot;&amp;amp;pass=&amp;quot;somepassword&amp;quot; &amp;gt;&lt;br /&gt;
&amp;lt;img width=&amp;quot;412px&amp;quot; height=&amp;quot;268px&amp;quot; src=&amp;quot;http://IPOFZMSERVER/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=5&amp;amp;scale=100&amp;quot;&amp;amp;user=&amp;quot;watchinguser&amp;quot;&amp;amp;pass=&amp;quot;somepassword&amp;quot; &amp;gt;&lt;br /&gt;
&amp;lt;img width=&amp;quot;412px&amp;quot; height=&amp;quot;268px&amp;quot; src=&amp;quot;http://IPOFZMSERVER/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=6&amp;amp;scale=100&amp;quot;&amp;amp;user=&amp;quot;watchinguser&amp;quot;&amp;amp;pass=&amp;quot;somepassword&amp;quot; &amp;gt;&lt;br /&gt;
&amp;lt;/body&amp;gt;&lt;br /&gt;
&amp;lt;/html&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Setup==&lt;br /&gt;
In 1.32 and 1.34, you may have to adjust the following setting for auth_relay if authentication is used. Note that this conflicts with [[ZMNinja]], which requires auth_relay to be set to hashed, I believe. &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Post by rockedge» Fri Jun 30, 2017 8:09 pm&lt;br /&gt;
in a WordPress page or post I use something like this: Remember that &lt;br /&gt;
with certain authorizations set, the URL would be slightly different.&lt;br /&gt;
this URL works when :&lt;br /&gt;
Options-&amp;gt;System-&amp;gt;OPT_USE_AUTH = ON&lt;br /&gt;
Options-&amp;gt;System-&amp;gt;AUTH_TYPE = Builtin&lt;br /&gt;
Options-&amp;gt;System-&amp;gt;AUTH_RELAY = NONE&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;&amp;lt;img class=&amp;quot;aligncenter&amp;quot; &lt;br /&gt;
src=&amp;quot;http://your_zm_server/cgi-bin/nph-zms?mode=jpeg&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;buffer=1000&amp;amp;monitor=1&amp;amp;user=admin&amp;quot; alt=&amp;quot;stream down&amp;quot; width=&amp;quot;420&amp;quot; height=&amp;quot;340&amp;quot; /&amp;gt;&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref:https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=26292&lt;br /&gt;
&lt;br /&gt;
&amp;lt;small&amp;gt;Note that this URL omits password. But it is given in the preface example.&amp;lt;/small&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
===Quickly Change pixel settings for page===&lt;br /&gt;
It should be possible to use CSS and have the videos fill the page appropriately (I haven&amp;#039;t gotten around to it. Contributions welcome.) but it&amp;#039;s also possible to use sed here to adjust the pixels as needed:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sed -e &amp;#039;s/oldpx/newpx/g&amp;#039; -i cameras.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Refresh Page Periodically===&lt;br /&gt;
Refreshing the page is a good idea, so that any streams don&amp;#039;t drop out for any reason. You can do this with xdotool (see [[Dedicated_SBC_Camera_Monitor#Refresh_Screen_Periodically]] )or possibly with html:[https://forums.zoneminder.com/viewtopic.php?f=39&amp;amp;t=28897]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;meta http-equiv=&amp;quot;refresh&amp;quot; content=&amp;quot;300&amp;quot;&amp;gt;&amp;lt;!-- EDIT: This may not work. Perhaps try js --&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Scale may be required for large numbers of cameras or SBCs===&lt;br /&gt;
&lt;br /&gt;
See that scale=100 option in the URL? That is used to downscale or downsample the video stream resolution. But, since you set the height and width, it won&amp;#039;t make the video smaller. If you have a 2K stream, but you are viewing it at 640x480, you don&amp;#039;t need 100% scaling. Lower the number to keep the bandwidth / memory usage down. &lt;br /&gt;
&lt;br /&gt;
Where this is required, is when you have a lot of monitors, say 20+ cameras. Or you have an SBC that can&amp;#039;t handle full res streams. In these scenarios, if you don&amp;#039;t scale, you will either see the CPU max out on the watching computer, or you will see video feeds drop in and out periodically. For more details, see how ZM handles the URL for montage.&lt;br /&gt;
&lt;br /&gt;
===Single Snapshot URL===&lt;br /&gt;
The URL for a single snapshot is:&lt;br /&gt;
 http://serverip/zm/cgi-bin/nph-zms?mode=single&amp;amp;monitor=2&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;buffer=1000&amp;amp;user=somename&amp;amp;pass=somepass&lt;br /&gt;
Adjust Monitor # as needed. (Also see note in setup section above).&lt;br /&gt;
&lt;br /&gt;
===Alternative Single Snapshop JPG via ZMU===&lt;br /&gt;
zmu is a binary, along with zma, and zmc that can do various functions. One of them is creating a jpeg.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/bin# zmu -h&lt;br /&gt;
zmu &amp;lt;-d device_path&amp;gt; [-v] [function] [-U&amp;lt;username&amp;gt; -P&amp;lt;password&amp;gt;]&lt;br /&gt;
zmu &amp;lt;-m monitor_id&amp;gt; [-v] [function] [-U&amp;lt;username&amp;gt; -P&amp;lt;password&amp;gt;]&lt;br /&gt;
General options:&lt;br /&gt;
  -h, --help           : This screen&lt;br /&gt;
  -v, --verbose          : Produce more verbose output&lt;br /&gt;
 ...&lt;br /&gt;
  -i, --image [image_index]    : Write captured image to disk as &amp;lt;monitor_name&amp;gt;.jpg, last image captured&lt;br /&gt;
                   or specified ring buffer index if given.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===ffplay===&lt;br /&gt;
It is possible to use ffplay to directly stream a single camera feed (bypassing ZM) to the desktop. Although refreshing may be more involved.&lt;br /&gt;
 ffplay -i rtsp://user:Password@ipaddress:554/video&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Hardware_Compatibility_List&amp;diff=16707</id>
		<title>Hardware Compatibility List</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Hardware_Compatibility_List&amp;diff=16707"/>
		<updated>2021-11-02T18:10:15Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* IP Network Cameras */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The ZoneMinder Wiki is community based. That means the list below is only as good as those who chose to maintain it. Did you find something outdated? Did you get a camera working, which is not shown in the list below? Please consider adding or improving this list.&lt;br /&gt;
&lt;br /&gt;
== IP Network Cameras ==&lt;br /&gt;
Most modern IP cameras are ONVIF compliant, which means they should work with ZoneMinder because ONVIF is a standard that is widely supported. However, not all cameras are compliant. Cameras which only work with &amp;quot;cloud&amp;quot; services or proprietary apps may not work with any third party recording software. Some &amp;quot;cloud&amp;quot; cameras fit into this category [examples?].&lt;br /&gt;
&lt;br /&gt;
You should verify you can adjust camera parameters such as frame rate, resolution, contrast, etc. from within the camera&amp;#039;s web portal. This, in itself, is not a show-stopper, but it will make your experience easier. Often you want to adjust the FPS or resolution to fit your needs. You do not need 4K to watch a hallway, and 320x240 is no good for reading license plates. &lt;br /&gt;
&lt;br /&gt;
The following list of IP cameras is not exhaustive. If your camera is not listed, it does not mean that it won&amp;#039;t work with ZoneMinder. Rather, it is likely that no one has taken the time to add it to the list. Please consider adding your camera to this list once you get it working. More details on obtaining stream paths can be found on [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Full Compatibility &amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
* [[7Links]](TM Trade Mark)&lt;br /&gt;
&lt;br /&gt;
* [[A-mtk]]&lt;br /&gt;
&lt;br /&gt;
* [[Abus]]  some&lt;br /&gt;
&lt;br /&gt;
* [[Airlink 101]] some &lt;br /&gt;
&lt;br /&gt;
* [[AirLive AirCam OD325HD]]&lt;br /&gt;
&lt;br /&gt;
* [[Amcrest]]&lt;br /&gt;
&lt;br /&gt;
* [[Amcrest QCam]]&lt;br /&gt;
&lt;br /&gt;
* [[Amovision AM-Q630M | Amovision]] some&lt;br /&gt;
&lt;br /&gt;
* [[Anpviz]]&lt;br /&gt;
&lt;br /&gt;
* [[Android]]&lt;br /&gt;
&lt;br /&gt;
* [[Anran VGB101-IP]]&lt;br /&gt;
&lt;br /&gt;
* [[Apexis]] most if not all (only tested some)&lt;br /&gt;
&lt;br /&gt;
* [[ArecontVision]] (AV3130M, probably other too)&lt;br /&gt;
&lt;br /&gt;
* [[Asgari]] 720pro&lt;br /&gt;
&lt;br /&gt;
* [[Astak Mole]] Some&lt;br /&gt;
&lt;br /&gt;
* [[Axis]] All&lt;br /&gt;
&lt;br /&gt;
* [[BesDERSEC]] HX WIFI - ONVIF&lt;br /&gt;
&lt;br /&gt;
* [[BesDERSEC]] A6 PTZ - ONVIF - Used Netcat ONVIF for control&lt;br /&gt;
&lt;br /&gt;
* [[Brickcom]] These have been tested&lt;br /&gt;
&lt;br /&gt;
* [[B-QTECH]] H.264 Camera&lt;br /&gt;
&lt;br /&gt;
* [[BSTI]] Some&lt;br /&gt;
&lt;br /&gt;
* [[Cisco]] some&lt;br /&gt;
&lt;br /&gt;
* [[COT Pro]] some&lt;br /&gt;
&lt;br /&gt;
* [[Dahua]] (IPC-HDB3200C, probably others)&lt;br /&gt;
&lt;br /&gt;
* [[DBPower]] (H.264 Model, possibly others)&lt;br /&gt;
&lt;br /&gt;
* [[Digoo]] At least M1Q, probably more. &lt;br /&gt;
&lt;br /&gt;
* [[D-Link]] Most&lt;br /&gt;
&lt;br /&gt;
* [[EasyN]] (Mini Speed Dome 1BF)&lt;br /&gt;
&lt;br /&gt;
* [[Edimax]] only tested some&lt;br /&gt;
&lt;br /&gt;
* [[EyeSpy247]] (Branded Sercomm RC8021)&lt;br /&gt;
&lt;br /&gt;
* [[EZVIZ]] (by Hikvision)&lt;br /&gt;
&lt;br /&gt;
* [[Flir]] (rebranded [[Lorex]] which are rebranded [[Dahua]])&lt;br /&gt;
&lt;br /&gt;
* [[Foscam]] (FI8908W, FI8904W, possibly others)&lt;br /&gt;
&lt;br /&gt;
* [[Gadspot]] Most&lt;br /&gt;
&lt;br /&gt;
* [[GBF_PL960PM_IP_Video_Door_Phone | GBF]] One reportedly (doorbell camera)&lt;br /&gt;
&lt;br /&gt;
* [[Generic]] Only tested one &lt;br /&gt;
&lt;br /&gt;
* [[Geovision]] (GV-FE420, possibly others)&lt;br /&gt;
&lt;br /&gt;
* [[Grandstream]] Grandstream (GXV-3672-FHD &amp;amp; GXV-3672-FHD-36 &amp;amp; GXV3611_HD tested)&lt;br /&gt;
&lt;br /&gt;
* [[Hikvision]] Most&lt;br /&gt;
&lt;br /&gt;
* [[Honeywell]] HD3MDIP&lt;br /&gt;
&lt;br /&gt;
* [[hootoo]] Some&lt;br /&gt;
&lt;br /&gt;
* [[Iguard]] IP390E&lt;br /&gt;
&lt;br /&gt;
* [[ieGeek]] CT0247UK&lt;br /&gt;
&lt;br /&gt;
* [[Instar]] (IN-2905, IN-5907HD, possibly others)&lt;br /&gt;
&lt;br /&gt;
* [[InternetEye]] M6840&lt;br /&gt;
&lt;br /&gt;
* [[Jennov]] (only tested model JE-A73WG20-E)&lt;br /&gt;
&lt;br /&gt;
* [[Keekoon]] KK002 (KK001 and 3 are probably the same)&lt;br /&gt;
&lt;br /&gt;
* [[LaView]]  many  LV-PB932F4&lt;br /&gt;
&lt;br /&gt;
* [[Level One]] some&lt;br /&gt;
&lt;br /&gt;
* [[Lilin]] LR7022&lt;br /&gt;
&lt;br /&gt;
* [[Linksys]] WVC-210 / WVC2300 / PVC2300 / WVC54GC&lt;br /&gt;
&lt;br /&gt;
* [[Loftek]] Sentinel PTZ&lt;br /&gt;
&lt;br /&gt;
* [[Lorex]] (rebranded [[Dahua]])&lt;br /&gt;
&lt;br /&gt;
* [[Maygion]] (IP-603, IP-604, possibly others)&lt;br /&gt;
&lt;br /&gt;
* [[Messoa]] (NCR870, probably others)&lt;br /&gt;
&lt;br /&gt;
* [[MPIX]] (40-IRBF-K28, probably others)&lt;br /&gt;
&lt;br /&gt;
* [[Netcat]] IP Cameras&lt;br /&gt;
&lt;br /&gt;
* [https://wiki.openwrt.org/tag/ip_camera?do=showtag&amp;amp;tag=ip_camera Openwrt] Webcam, or custom firmware on commercial cameras.&lt;br /&gt;
&lt;br /&gt;
* [[Panasonic]] IP Cameras&lt;br /&gt;
&lt;br /&gt;
* [[Pelco]] IP Cameras&lt;br /&gt;
&lt;br /&gt;
* [[Revotech]]&lt;br /&gt;
&lt;br /&gt;
* [[Reolink]]&lt;br /&gt;
&lt;br /&gt;
* [[Rimax]] Some&lt;br /&gt;
&lt;br /&gt;
* [[Rovio]]&lt;br /&gt;
&lt;br /&gt;
* [[Sercomm]] (ADT)&lt;br /&gt;
&lt;br /&gt;
* [[Sony]] Most&lt;br /&gt;
&lt;br /&gt;
* [[Sricam]]&lt;br /&gt;
&lt;br /&gt;
* [[SV3C]]&lt;br /&gt;
&lt;br /&gt;
* [[TMEZON]] Some&lt;br /&gt;
&lt;br /&gt;
* [[TP-LINK]] Some&lt;br /&gt;
&lt;br /&gt;
* [[Trendnet]] Most&lt;br /&gt;
&lt;br /&gt;
* [[Uokoo]] One&lt;br /&gt;
&lt;br /&gt;
* [[Vstar T7833WIP HD Dome Network Camera]]&lt;br /&gt;
&lt;br /&gt;
* [[Wanscam]] FR4020A2 (Foscam clone)&lt;br /&gt;
&lt;br /&gt;
* [[Wgcc]] One&lt;br /&gt;
&lt;br /&gt;
* [[Wyze Cam]]&lt;br /&gt;
&lt;br /&gt;
* [[x-vision]] Xvision cameras by y3k (some)&lt;br /&gt;
&lt;br /&gt;
* [[Xiongmai]]  They sell modules used in multiple Chinese cameras like Misecu IPC-DM07-20SC (with module IPG-50HV20PES-S)&lt;br /&gt;
&lt;br /&gt;
* [[Y-Cam]] (Sharx Ip) Most&lt;br /&gt;
&lt;br /&gt;
* [[Zavio]] Some&lt;br /&gt;
&lt;br /&gt;
* [[Zecumate]] JPT3815W&lt;br /&gt;
&lt;br /&gt;
* [[ZoneWay ZW-NC863M-P Megapixel IP]]&lt;br /&gt;
&lt;br /&gt;
* ZoneMinder can also be accessed as if it were another camera, using a Remote Path such as:&lt;br /&gt;
  &amp;#039;&amp;#039;&amp;#039;/cgi-bin/nph-zms?mode=single&amp;amp;monitor=&amp;lt;monitor id&amp;gt;&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;buffer=1000&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Where the &amp;lt;monitor id&amp;gt; is the correct camera id on the remote system. More details: [[Example Camera View HTML]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Single JPEG Frames Only&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
* [[Airlink 101]] some&lt;br /&gt;
&lt;br /&gt;
* [[JVC]] some&lt;br /&gt;
&lt;br /&gt;
* [[Panasonic]] some&lt;br /&gt;
&lt;br /&gt;
* [[PLANET]] some   &lt;br /&gt;
&lt;br /&gt;
* [[Toshiba]] some&lt;br /&gt;
&lt;br /&gt;
* [[Veo Observer IP NetCam]] most&lt;br /&gt;
&lt;br /&gt;
* [[Vivotek]] All&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;MPEG (v1.24.0+)&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
* [[ABS_MegaCam]]&lt;br /&gt;
&lt;br /&gt;
* [[Axis]] All&lt;br /&gt;
&lt;br /&gt;
* [[ ACTi]] All&lt;br /&gt;
&lt;br /&gt;
* [[Vivotek]] Most&lt;br /&gt;
&lt;br /&gt;
* [[Logitech 700 series]] some&lt;br /&gt;
&lt;br /&gt;
* [[Ubiqiti]] some&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Compatible (with modifications)&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
* [[Aviosys]] some&lt;br /&gt;
&lt;br /&gt;
* [[Mobotix]]  all  &lt;br /&gt;
&lt;br /&gt;
* [[Conceptronic]]  some&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Compatible (with problems)&amp;#039;&amp;#039;&amp;#039; &lt;br /&gt;
&lt;br /&gt;
* [[Compro]] IP70. MPEG4 only, some reliability issues and general poor firmware quality.&lt;br /&gt;
&lt;br /&gt;
* [[Grandtec]] [[Grandtec_WLAN_Camera|WLAN Camera]] WiFi or III - acceptable indoor quality, no infrared-filter (better nightvision) cheap!&lt;br /&gt;
&lt;br /&gt;
* [[Intellinet]]  IPCamera with the new firmware.&lt;br /&gt;
&lt;br /&gt;
* Old Intellinet IPCamera (model MWNC-100) with this (http://www.zoneminder.com/forums/viewtopic.php?t=7500) protocol adapter. &lt;br /&gt;
&lt;br /&gt;
* OvisLink AirLive WL-5400CAM&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Useful Links&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
* Flash&amp;#039;s IP Camera Database:  https://digdilem.org/ip-cameras/ (Doesn&amp;#039;t seem to work when searching for &amp;#039;Works with Zoneminder?&amp;#039; option, though. - jpcy)&lt;br /&gt;
&lt;br /&gt;
== IP Video Encoder ==&lt;br /&gt;
&lt;br /&gt;
Like Network Cameras, these devices produce a video stream over tcp/ip - but they do so with input from an analog video camera or other video source. An easy way to find these are to search for video encoders or video servers, e.g. 8 channel video encoder, or 2 channel video server.  Newer video encoders may also support HD Analog either in addition, or instead of analog streams (how they implement HD analog, depends upon the brand. There are currently competing standards such as AHD, EX-SDI, HD-SDI, HD-CVI, HD-TVI, etc...).&lt;br /&gt;
&lt;br /&gt;
IP Video Encoders are generally easier to use and maintain than PCI / Capture cards. &lt;br /&gt;
&lt;br /&gt;
* [[Synectics E100]] encoder&lt;br /&gt;
&lt;br /&gt;
*The [[IP9100 | Aviosys IP9100, Models A, B and Plus]] has four analog video inputs.  It produces a ZM compatible video stream from one of the inputs, which is selectable via an HTTP GET command.  There might even be a control script for ZM that lets you select the active video input using &amp;#039;&amp;#039;ZM&amp;#039;s Camera Control Presets!&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
With the yoics Aviosys 9100 firmware at http://www.yoics.com/?p=28, ZoneMinder can directly access all four ports via /usr/yoicsX.jpg as the remote host path, where X is 0 - 3.&lt;br /&gt;
&lt;br /&gt;
* [[Axis]] Multiple&lt;br /&gt;
&lt;br /&gt;
* [[Bosch VIP X1 Single-channel]] video encoder [http://products.boschsecuritysystems.eu/en/EMEA/products/bxp/SKU15449253232961378955-CATMda7ec5dc0edf5b1a0b8cb619e2e11308]&lt;br /&gt;
&lt;br /&gt;
* [[GXV3504]] Grandstream 4 channel video encoder.&lt;br /&gt;
&lt;br /&gt;
* [[Hikvision]] HD Analog (With errors)&lt;br /&gt;
&lt;br /&gt;
* [[Samsung]] uses AHD cameras, and possibly NTSC/PAL cameras.&lt;br /&gt;
&lt;br /&gt;
== Capture Cards ==&lt;br /&gt;
&lt;br /&gt;
[[Anykeeper]] &lt;br /&gt;
&lt;br /&gt;
[[Avermedia]]&lt;br /&gt;
&lt;br /&gt;
[[Camsecure PCI Express video capture]]&lt;br /&gt;
&lt;br /&gt;
[[Digiflower]]&lt;br /&gt;
&lt;br /&gt;
[[Geovision GV250 - bt878a chip]]&lt;br /&gt;
&lt;br /&gt;
[[Grandtec Grand X Guard]] &lt;br /&gt;
&lt;br /&gt;
[[Hauppauge]]&lt;br /&gt;
&lt;br /&gt;
[[Howell-Tempest  VC 878B-Q]]&lt;br /&gt;
&lt;br /&gt;
[[Ituner Spectra 8]]&lt;br /&gt;
&lt;br /&gt;
[[Kodicom 4400r]]&lt;br /&gt;
&lt;br /&gt;
[[Kodicom 8800]]&lt;br /&gt;
&lt;br /&gt;
[[Tungson TE-8008]]&lt;br /&gt;
&lt;br /&gt;
Leadtek WinFast VC 100 - the cheapest bt878 model with no tuner on it, just Com/Svideo in.&lt;br /&gt;
&lt;br /&gt;
[[LinkDelight CCTV H.264 4CH DVR Card]]&lt;br /&gt;
&lt;br /&gt;
[[Linux Media Labs LMLBT44]] &lt;br /&gt;
&lt;br /&gt;
[[Osprey 100]]&lt;br /&gt;
&lt;br /&gt;
[[Provideo PV- series (Bluecherry)]] &lt;br /&gt;
[[ Bluecherry - BC-H16480A]] &lt;br /&gt;
[[TView 95/99]]&lt;br /&gt;
&lt;br /&gt;
[[UDP Technology NCP3200v2]]&lt;br /&gt;
&lt;br /&gt;
[[Videocards with Philips saa7134 chipset]]&lt;br /&gt;
&lt;br /&gt;
[[WinFast TV2000 XP]]&lt;br /&gt;
&lt;br /&gt;
[[Rapid OS]]&lt;br /&gt;
&lt;br /&gt;
[[KesCom PG104]]&lt;br /&gt;
&lt;br /&gt;
[[IEI Technology Corp. IVC-268G-R20]]&lt;br /&gt;
&lt;br /&gt;
== bt8x8 Cards ==&lt;br /&gt;
BT8x8 cards are handled by the Kernel module BTTV. A note on the bt8x8-based TV-tuner cards: these usually have beside the tuner input, also a Composite and an S-Video input. You can hook up 2 analog cameras to these, and access from ZoneMinder both of them as individual cameras, at max 15Fps. You don&amp;#039;t need two separate TV cards for two cameras!&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Pico2000]] - 4 port card, one chip bt878, around 2 fps when using all channels&lt;br /&gt;
&lt;br /&gt;
[[Bt878_4chip_8inputs]] -4 chips bt878, 8 inputs, around 5 fps when using 2 inputs per chip&lt;br /&gt;
&lt;br /&gt;
[[:Image:Karta.jpg| bt878 8 chip 8 input]] - This card is supplied with D-sub to 8 BNC connector and uses the bt878 chip for each input allowing full frame rates and quality. See [[Kodicom 8800]] for more information.&lt;br /&gt;
&lt;br /&gt;
Geovision GV250 bt878a single chip 4 inputs - This capture Card is supplied with 4 video inputs but with NO audio channel&lt;br /&gt;
&lt;br /&gt;
Geovision GV-800 8 inputs - [https://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=12327] Recommended to review forums. &lt;br /&gt;
&lt;br /&gt;
Most other BTTV (bt878, bt848) cards, see &amp;#039;&amp;#039;&amp;#039;/usr/src/linux/Documentation/video4linux/bttv/CARDLIST&amp;#039;&amp;#039;&amp;#039; on your system for a list. You can also find more details on the BTTV module, such as parameters to pass via insmod, [https://www.kernel.org/doc/html/latest/media/v4l-drivers/bttv.html in the kernel] and&lt;br /&gt;
[https://www.linuxtv.org/wiki/index.php/Bttv on the v4l wiki ]&lt;br /&gt;
[https://www.linuxtv.org/wiki/index.php/Bttv_devices_(bt848,_bt878) 2nd link]&lt;br /&gt;
&lt;br /&gt;
== Analog Cameras ==&lt;br /&gt;
&lt;br /&gt;
Any regular composite or S-video camera connected via a supported capture card.  Some analog cameras feature camera control - ZM supports several of these camera&amp;#039;s Pan/Tilt/Zoom functions via serial port control, as well as camera Presets, Focus, Iris, etc.&lt;br /&gt;
*[[PicturetelControlScript | PictureTel PTZ2N]].&lt;br /&gt;
&lt;br /&gt;
== USB Cameras ==&lt;br /&gt;
&lt;br /&gt;
*Just Zoom USB cam&lt;br /&gt;
&lt;br /&gt;
*Creative Webcam Pro, Webcam 3, LIVE! Cam OPTIA PRO (V4L2, Chan 0, PAL, YUYV)&lt;br /&gt;
&lt;br /&gt;
*&amp;#039;&amp;#039;Most&amp;#039;&amp;#039; UVCvideo cameras, including: Advent AWC213, Creative Labs VF0420, [[Logitech QuickCam Express]], Logitech HD C270, QuickCam Pro 3000, [[QuickCam Pro 4000]],  QuickCam Communicate STX/Deluxe, [[Logitech Webcam Pro 9000]], [[Webcam C250]], and [[Logitech C525]].&lt;br /&gt;
&lt;br /&gt;
*Logitech Quickcam Orbit/Sphere (experimental basic pan/tilt control has also published for testing and hacking [http://www.zoneminder.com/forums/viewtopic.php?t=9788])&lt;br /&gt;
&lt;br /&gt;
*[[Philips]] &lt;br /&gt;
&lt;br /&gt;
*Any OV511 based USB camera [http://alpha.dyndns.org/ov511/cameras.html]&lt;br /&gt;
&lt;br /&gt;
*Any CPIA based USB camera [http://webcam.sourceforge.net]&lt;br /&gt;
&lt;br /&gt;
*[[LabTec WebCam Pro]]&lt;br /&gt;
&lt;br /&gt;
*Confirmed basic functionality with Microsoft Lifecam VX 5000 using UVC Streaming method&lt;br /&gt;
&lt;br /&gt;
*Company name: PU`Aimetis model: PUAN-3656 (2MP / Max resolution: 1920*1080, MJPEG - 1920X1080 @ 30fps / YUV2 - 1920X1080 @ 5fps)&lt;br /&gt;
&lt;br /&gt;
Note that most USB cameras that can use Video4Linux/V4L2, and so can be used by ZoneMinder.  Some have older chipsets and can be hard to find new.&lt;br /&gt;
&lt;br /&gt;
Note that PWC drivers are not included in the kernel. Some distribution&amp;#039;s add them in and other may not. Here are some relevant links:&lt;br /&gt;
* [http://www.smcc.demon.nl/webcam/ Old Maintainer]&lt;br /&gt;
* [http://www.saillard.org/linux/pwc/ Current PWC Maintainer]&lt;br /&gt;
&lt;br /&gt;
== X10 Devices ==&lt;br /&gt;
The only device that really needs to be compatable with ZM is the Transceiver, all other x10 devices comunicate through that device.&lt;br /&gt;
*[[CM11]] Bi-Directional Transceiver&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Other X10 notes:&lt;br /&gt;
&lt;br /&gt;
[http://www.zoneminder.com/forums/viewtopic.php?t=6423&amp;amp;highlight=x10 Topic 6423]&lt;br /&gt;
&lt;br /&gt;
[http://www.zoneminder.com/forums/viewtopic.php?t=7082&amp;amp;highlight=x10 Topic 7082]&lt;br /&gt;
&lt;br /&gt;
== All other hardware as supported by Linux ==&lt;br /&gt;
To find out if your hardware is supported, check the [http://www.zoneminder.com/forums/viewforum.php?f=10 HCL]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Plug Computers ==&lt;br /&gt;
Guruplug Server Plus -&amp;gt; How to install Zoneminder&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Single Board Computers ==&lt;br /&gt;
&lt;br /&gt;
Single board computers such as the Raspberry Pi, Odroid, Beagleboard, and many others.&lt;br /&gt;
&lt;br /&gt;
See [[Single Board Computers]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=External_Live_Stream&amp;diff=16706</id>
		<title>External Live Stream</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=External_Live_Stream&amp;diff=16706"/>
		<updated>2021-11-02T04:44:33Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* Single Snapshot URL */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Here is an html file you might use in a ZM client [[Desktop SBC Camera Monitor]] to view the streams from the ZM Server. You will need to adjust the resolution, number of cameras, and monitor id of the URL to your setup.&lt;br /&gt;
&lt;br /&gt;
In my experience, Clients viewing the Streams (up to 3 clients, with 20+ cameras) do not slow down the ZM Server.&lt;br /&gt;
&lt;br /&gt;
For more details, see [[Dummies_Guide#Watching_the_Cameras]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;html&amp;gt;&amp;lt;body bgcolor=&amp;quot;black&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;img width=&amp;quot;412px&amp;quot; height=&amp;quot;268px&amp;quot; src=&amp;quot;http://IPOFZMSERVER/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=1&amp;amp;scale=100&amp;quot;&amp;amp;user=&amp;quot;watchinguser&amp;quot;&amp;amp;pass=&amp;quot;somepassword&amp;quot; &amp;gt;&lt;br /&gt;
&amp;lt;img width=&amp;quot;412px&amp;quot; height=&amp;quot;268px&amp;quot; src=&amp;quot;http://IPOFZMSERVER/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=2&amp;amp;scale=100&amp;quot;&amp;amp;user=&amp;quot;watchinguser&amp;quot;&amp;amp;pass=&amp;quot;somepassword&amp;quot; &amp;gt;&lt;br /&gt;
&amp;lt;img width=&amp;quot;412px&amp;quot; height=&amp;quot;268px&amp;quot; src=&amp;quot;http://IPOFZMSERVER/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=3&amp;amp;scale=100&amp;quot;&amp;amp;user=&amp;quot;watchinguser&amp;quot;&amp;amp;pass=&amp;quot;somepassword&amp;quot; &amp;gt;&lt;br /&gt;
&amp;lt;img width=&amp;quot;412px&amp;quot; height=&amp;quot;268px&amp;quot; src=&amp;quot;http://IPOFZMSERVER/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=4&amp;amp;scale=100&amp;quot;&amp;amp;user=&amp;quot;watchinguser&amp;quot;&amp;amp;pass=&amp;quot;somepassword&amp;quot; &amp;gt;&lt;br /&gt;
&amp;lt;img width=&amp;quot;412px&amp;quot; height=&amp;quot;268px&amp;quot; src=&amp;quot;http://IPOFZMSERVER/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=5&amp;amp;scale=100&amp;quot;&amp;amp;user=&amp;quot;watchinguser&amp;quot;&amp;amp;pass=&amp;quot;somepassword&amp;quot; &amp;gt;&lt;br /&gt;
&amp;lt;img width=&amp;quot;412px&amp;quot; height=&amp;quot;268px&amp;quot; src=&amp;quot;http://IPOFZMSERVER/zm/cgi-bin/nph-zms?mode=jpeg&amp;amp;monitor=6&amp;amp;scale=100&amp;quot;&amp;amp;user=&amp;quot;watchinguser&amp;quot;&amp;amp;pass=&amp;quot;somepassword&amp;quot; &amp;gt;&lt;br /&gt;
&amp;lt;/body&amp;gt;&lt;br /&gt;
&amp;lt;/html&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Setup==&lt;br /&gt;
In 1.32 and 1.34, you may have to adjust the following setting for auth_relay if authentication is used. Note that this conflicts with [[ZMNinja]], which requires auth_relay to be set to hashed, I believe. &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Post by rockedge» Fri Jun 30, 2017 8:09 pm&lt;br /&gt;
in a WordPress page or post I use something like this: Remember that &lt;br /&gt;
with certain authorizations set, the URL would be slightly different.&lt;br /&gt;
this URL works when :&lt;br /&gt;
Options-&amp;gt;System-&amp;gt;OPT_USE_AUTH = ON&lt;br /&gt;
Options-&amp;gt;System-&amp;gt;AUTH_TYPE = Builtin&lt;br /&gt;
Options-&amp;gt;System-&amp;gt;AUTH_RELAY = NONE&lt;br /&gt;
&lt;br /&gt;
Code: Select all&lt;br /&gt;
&lt;br /&gt;
&amp;lt;h2&amp;gt;&amp;lt;img class=&amp;quot;aligncenter&amp;quot; &lt;br /&gt;
src=&amp;quot;http://your_zm_server/cgi-bin/nph-zms?mode=jpeg&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;buffer=1000&amp;amp;monitor=1&amp;amp;user=admin&amp;quot; alt=&amp;quot;stream down&amp;quot; width=&amp;quot;420&amp;quot; height=&amp;quot;340&amp;quot; /&amp;gt;&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
ref:https://forums.zoneminder.com/viewtopic.php?f=36&amp;amp;t=26292&lt;br /&gt;
&lt;br /&gt;
&amp;lt;small&amp;gt;Note that this URL omits password. But it is given in the preface example.&amp;lt;/small&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Tips==&lt;br /&gt;
===Quickly Change pixel settings for page===&lt;br /&gt;
It should be possible to use CSS and have the videos fill the page appropriately (I haven&amp;#039;t gotten around to it. Contributions welcome.) but it&amp;#039;s also possible to use sed here to adjust the pixels as needed:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sed -e &amp;#039;s/oldpx/newpx/g&amp;#039; -i cameras.html&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Refresh Page Periodically===&lt;br /&gt;
Refreshing the page is a good idea, so that any streams don&amp;#039;t drop out for any reason. You can do this with xdotool (see [[Dedicated_SBC_Camera_Monitor#Refresh_Screen_Periodically]] )or possibly with html:[https://forums.zoneminder.com/viewtopic.php?f=39&amp;amp;t=28897]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;meta http-equiv=&amp;quot;refresh&amp;quot; content=&amp;quot;300&amp;quot;&amp;gt;&amp;lt;!-- EDIT: This may not work. Perhaps try js --&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Scale may be required for large numbers of cameras or SBCs===&lt;br /&gt;
&lt;br /&gt;
See that scale=100 option in the URL? That is used to downscale or downsample the video stream resolution. But, since you set the height and width, it won&amp;#039;t make the video smaller. If you have a 2K stream, but you are viewing it at 640x480, you don&amp;#039;t need 100% scaling. Lower the number to keep the bandwidth / memory usage down. &lt;br /&gt;
&lt;br /&gt;
Where this is required, is when you have a lot of monitors, say 20+ cameras. Or you have an SBC that can&amp;#039;t handle full res streams. In these scenarios, if you don&amp;#039;t scale, you will either see the CPU max out on the watching computer, or you will see video feeds drop in and out periodically. For more details, see how ZM handles the URL for montage.&lt;br /&gt;
&lt;br /&gt;
===Single Snapshot URL===&lt;br /&gt;
The URL for a single snapshot is:&lt;br /&gt;
 http://serverip/zm/cgi-bin/nph-zms?mode=single&amp;amp;monitor=2&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;buffer=1000&amp;amp;user=somename&amp;amp;pass=somepass&lt;br /&gt;
Adjust Monitor # as needed. (Also see note in setup section above).&lt;br /&gt;
&lt;br /&gt;
===Alternative Single Snapshop JPG via ZMU===&lt;br /&gt;
zmu is a binary, along with zma, and zmc that can do various functions. One of them is creating a jpeg.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/bin# zmu -h&lt;br /&gt;
zmu &amp;lt;-d device_path&amp;gt; [-v] [function] [-U&amp;lt;username&amp;gt; -P&amp;lt;password&amp;gt;]&lt;br /&gt;
zmu &amp;lt;-m monitor_id&amp;gt; [-v] [function] [-U&amp;lt;username&amp;gt; -P&amp;lt;password&amp;gt;]&lt;br /&gt;
General options:&lt;br /&gt;
  -h, --help           : This screen&lt;br /&gt;
  -v, --verbose          : Produce more verbose output&lt;br /&gt;
 ...&lt;br /&gt;
  -i, --image [image_index]    : Write captured image to disk as &amp;lt;monitor_name&amp;gt;.jpg, last image captured&lt;br /&gt;
                   or specified ring buffer index if given.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===ffplay===&lt;br /&gt;
It is possible to use ffplay to directly stream a single camera feed (bypassing ZM) to the desktop. Although refreshing may be more involved.&lt;br /&gt;
 ffplay -i rtsp://user:Password@ipaddress:554/video&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
* [[OpenVPN]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Dummies_Guide]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
	<entry>
		<id>http://wiki.staging.zoneminder.com/index.php?title=Hardware_Compatibility_List&amp;diff=16705</id>
		<title>Hardware Compatibility List</title>
		<link rel="alternate" type="text/html" href="http://wiki.staging.zoneminder.com/index.php?title=Hardware_Compatibility_List&amp;diff=16705"/>
		<updated>2021-11-02T04:43:38Z</updated>

		<summary type="html">&lt;p&gt;Snake: /* IP Network Cameras */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The ZoneMinder Wiki is community based. That means the list below is only as good as those who chose to maintain it. Did you find something outdated? Did you get a camera working, which is not shown in the list below? Please consider adding or improving this list.&lt;br /&gt;
&lt;br /&gt;
== IP Network Cameras ==&lt;br /&gt;
Most modern IP cameras are ONVIF compliant, which means they should work with ZoneMinder because ONVIF is a standard that is widely supported. However, not all cameras are compliant. Cameras which only work with &amp;quot;cloud&amp;quot; services or proprietary apps may not work with any third party recording software. Some &amp;quot;cloud&amp;quot; cameras fit into this category [examples?].&lt;br /&gt;
&lt;br /&gt;
You should verify you can adjust camera parameters such as frame rate, resolution, contrast, etc. from within the camera&amp;#039;s web portal. This, in itself, is not a show-stopper, but it will make your experience easier. Often you want to adjust the FPS or resolution to fit your needs. You do not need 4K to watch a hallway, and 320x240 is no good for reading license plates. &lt;br /&gt;
&lt;br /&gt;
The following list of IP cameras is not exhaustive. If your camera is not listed, it does not mean that it won&amp;#039;t work with ZoneMinder. Rather, it is likely that no one has taken the time to add it to the list. Please consider adding your camera to this list once you get it working. More details on obtaining stream paths can be found on [[Finding Camera Stream Paths]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Full Compatibility &amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
* [[7Links]](TM Trade Mark)&lt;br /&gt;
&lt;br /&gt;
* [[A-mtk]]&lt;br /&gt;
&lt;br /&gt;
* [[Abus]]  some&lt;br /&gt;
&lt;br /&gt;
* [[Airlink 101]] some &lt;br /&gt;
&lt;br /&gt;
* [[AirLive AirCam OD325HD]]&lt;br /&gt;
&lt;br /&gt;
* [[Amcrest]]&lt;br /&gt;
&lt;br /&gt;
* [[Amcrest QCam]]&lt;br /&gt;
&lt;br /&gt;
* [[Amovision AM-Q630M | Amovision]] some&lt;br /&gt;
&lt;br /&gt;
* [[Anpviz]]&lt;br /&gt;
&lt;br /&gt;
* [[Android]]&lt;br /&gt;
&lt;br /&gt;
* [[Anran VGB101-IP]]&lt;br /&gt;
&lt;br /&gt;
* [[Apexis]] most if not all (only tested some)&lt;br /&gt;
&lt;br /&gt;
* [[ArecontVision]] (AV3130M, probably other too)&lt;br /&gt;
&lt;br /&gt;
* [[Asgari]] 720pro&lt;br /&gt;
&lt;br /&gt;
* [[Astak Mole]] Some&lt;br /&gt;
&lt;br /&gt;
* [[Axis]] All&lt;br /&gt;
&lt;br /&gt;
* [[BesDERSEC]] HX WIFI - ONVIF&lt;br /&gt;
&lt;br /&gt;
* [[BesDERSEC]] A6 PTZ - ONVIF - Used Netcat ONVIF for control&lt;br /&gt;
&lt;br /&gt;
* [[Brickcom]] These have been tested&lt;br /&gt;
&lt;br /&gt;
* [[B-QTECH]] H.264 Camera&lt;br /&gt;
&lt;br /&gt;
* [[BSTI]] Some&lt;br /&gt;
&lt;br /&gt;
* [[Cisco]] some&lt;br /&gt;
&lt;br /&gt;
* [[COT Pro]] some&lt;br /&gt;
&lt;br /&gt;
* [[Dahua]] (IPC-HDB3200C, probably others)&lt;br /&gt;
&lt;br /&gt;
* [[DBPower]] (H.264 Model, possibly others)&lt;br /&gt;
&lt;br /&gt;
* [[Digoo]] At least M1Q, probably more. &lt;br /&gt;
&lt;br /&gt;
* [[D-Link]] Most&lt;br /&gt;
&lt;br /&gt;
* [[EasyN]] (Mini Speed Dome 1BF)&lt;br /&gt;
&lt;br /&gt;
* [[Edimax]] only tested some&lt;br /&gt;
&lt;br /&gt;
* [[EyeSpy247]] (Branded Sercomm RC8021)&lt;br /&gt;
&lt;br /&gt;
* [[EZVIZ]] (by Hikvision)&lt;br /&gt;
&lt;br /&gt;
* [[Flir]] (rebranded [[Lorex]] which are rebranded [[Dahua]])&lt;br /&gt;
&lt;br /&gt;
* [[Foscam]] (FI8908W, FI8904W, possibly others)&lt;br /&gt;
&lt;br /&gt;
* [[Gadspot]] Most&lt;br /&gt;
&lt;br /&gt;
* [[GBF_PL960PM_IP_Video_Door_Phone | GBF]] One reportedly (doorbell camera)&lt;br /&gt;
&lt;br /&gt;
* [[Generic]] Only tested one &lt;br /&gt;
&lt;br /&gt;
* [[Geovision]] (GV-FE420, possibly others)&lt;br /&gt;
&lt;br /&gt;
* [[Grandstream]] Grandstream (GXV-3672-FHD &amp;amp; GXV-3672-FHD-36 &amp;amp; GXV3611_HD tested)&lt;br /&gt;
&lt;br /&gt;
* [[Hikvision]] Most&lt;br /&gt;
&lt;br /&gt;
* [[Honeywell]] HD3MDIP&lt;br /&gt;
&lt;br /&gt;
* [[hootoo]] Some&lt;br /&gt;
&lt;br /&gt;
* [[Iguard]] IP390E&lt;br /&gt;
&lt;br /&gt;
* [[ieGeek]] CT0247UK&lt;br /&gt;
&lt;br /&gt;
* [[Instar]] (IN-2905, IN-5907HD, possibly others)&lt;br /&gt;
&lt;br /&gt;
* [[InternetEye]] M6840&lt;br /&gt;
&lt;br /&gt;
* [[Jennov]] (only tested model JE-A73WG20-E)&lt;br /&gt;
&lt;br /&gt;
* [[Keekoon]] KK002 (KK001 and 3 are probably the same)&lt;br /&gt;
&lt;br /&gt;
* [[LaView]]  many  LV-PB932F4&lt;br /&gt;
&lt;br /&gt;
* [[Level One]] some&lt;br /&gt;
&lt;br /&gt;
* [[Lilin]] LR7022&lt;br /&gt;
&lt;br /&gt;
* [[Linksys]] WVC-210 / WVC2300 / PVC2300 / WVC54GC&lt;br /&gt;
&lt;br /&gt;
* [[Loftek]] Sentinel PTZ&lt;br /&gt;
&lt;br /&gt;
* [[Lorex]] (rebranded [[Dahua]])&lt;br /&gt;
&lt;br /&gt;
* [[Maygion]] (IP-603, IP-604, possibly others)&lt;br /&gt;
&lt;br /&gt;
* [[Messoa]] (NCR870, probably others)&lt;br /&gt;
&lt;br /&gt;
* [[MPIX]] (40-IRBF-K28, probably others)&lt;br /&gt;
&lt;br /&gt;
* [[Netcat]] IP Cameras&lt;br /&gt;
&lt;br /&gt;
* [https://wiki.openwrt.org/tag/ip_camera?do=showtag&amp;amp;tag=ip_camera Openwrt] Webcam, or custom firmware on commercial cameras.&lt;br /&gt;
&lt;br /&gt;
* [[Panasonic]] IP Cameras&lt;br /&gt;
&lt;br /&gt;
* [[Pelco]] IP Cameras&lt;br /&gt;
&lt;br /&gt;
* [[Revotech]]&lt;br /&gt;
&lt;br /&gt;
* [[Reolink]]&lt;br /&gt;
&lt;br /&gt;
* [[Rimax]] Some&lt;br /&gt;
&lt;br /&gt;
* [[Rovio]]&lt;br /&gt;
&lt;br /&gt;
* [[Sercomm]] (ADT)&lt;br /&gt;
&lt;br /&gt;
* [[Sony]] Most&lt;br /&gt;
&lt;br /&gt;
* [[Sricam]]&lt;br /&gt;
&lt;br /&gt;
* [[SV3C]]&lt;br /&gt;
&lt;br /&gt;
* [[TMEZON]] Some&lt;br /&gt;
&lt;br /&gt;
* [[TP-LINK]] Some&lt;br /&gt;
&lt;br /&gt;
* [[Trendnet]] Most&lt;br /&gt;
&lt;br /&gt;
* [[Uokoo]] One&lt;br /&gt;
&lt;br /&gt;
* [[Vstar T7833WIP HD Dome Network Camera]]&lt;br /&gt;
&lt;br /&gt;
* [[Wanscam]] FR4020A2 (Foscam clone)&lt;br /&gt;
&lt;br /&gt;
* [[Wgcc]] One&lt;br /&gt;
&lt;br /&gt;
* [[Wyze Cam]]&lt;br /&gt;
&lt;br /&gt;
* [[x-vision]] Xvision cameras by y3k (some)&lt;br /&gt;
&lt;br /&gt;
* [[Xiongmai]]  They sell modules used in multiple Chinese cameras like Misecu IPC-DM07-20SC (with module IPG-50HV20PES-S)&lt;br /&gt;
&lt;br /&gt;
* [[Y-Cam]] (Sharx Ip) Most&lt;br /&gt;
&lt;br /&gt;
* [[Zavio]] Some&lt;br /&gt;
&lt;br /&gt;
* [[Zecumate]] JPT3815W&lt;br /&gt;
&lt;br /&gt;
* [[ZoneWay ZW-NC863M-P Megapixel IP]]&lt;br /&gt;
&lt;br /&gt;
* ZoneMinder can also be accessed as if it were another camera, using a Remote Path such as:&lt;br /&gt;
  &amp;#039;&amp;#039;&amp;#039;/cgi-bin/nph-zms?mode=single&amp;amp;monitor=&amp;lt;monitor id&amp;gt;&amp;amp;scale=100&amp;amp;maxfps=5&amp;amp;buffer=1000&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
Where the &amp;lt;monitor id&amp;gt; is the correct camera id on the remote system. This may work before authentication (passwords) are enabled. If you have enabled passwords see [[Example Camera View HTML]] for other settings needed. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Single JPEG Frames Only&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
* [[Airlink 101]] some&lt;br /&gt;
&lt;br /&gt;
* [[JVC]] some&lt;br /&gt;
&lt;br /&gt;
* [[Panasonic]] some&lt;br /&gt;
&lt;br /&gt;
* [[PLANET]] some   &lt;br /&gt;
&lt;br /&gt;
* [[Toshiba]] some&lt;br /&gt;
&lt;br /&gt;
* [[Veo Observer IP NetCam]] most&lt;br /&gt;
&lt;br /&gt;
* [[Vivotek]] All&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;MPEG (v1.24.0+)&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
* [[ABS_MegaCam]]&lt;br /&gt;
&lt;br /&gt;
* [[Axis]] All&lt;br /&gt;
&lt;br /&gt;
* [[ ACTi]] All&lt;br /&gt;
&lt;br /&gt;
* [[Vivotek]] Most&lt;br /&gt;
&lt;br /&gt;
* [[Logitech 700 series]] some&lt;br /&gt;
&lt;br /&gt;
* [[Ubiqiti]] some&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Compatible (with modifications)&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
* [[Aviosys]] some&lt;br /&gt;
&lt;br /&gt;
* [[Mobotix]]  all  &lt;br /&gt;
&lt;br /&gt;
* [[Conceptronic]]  some&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Compatible (with problems)&amp;#039;&amp;#039;&amp;#039; &lt;br /&gt;
&lt;br /&gt;
* [[Compro]] IP70. MPEG4 only, some reliability issues and general poor firmware quality.&lt;br /&gt;
&lt;br /&gt;
* [[Grandtec]] [[Grandtec_WLAN_Camera|WLAN Camera]] WiFi or III - acceptable indoor quality, no infrared-filter (better nightvision) cheap!&lt;br /&gt;
&lt;br /&gt;
* [[Intellinet]]  IPCamera with the new firmware.&lt;br /&gt;
&lt;br /&gt;
* Old Intellinet IPCamera (model MWNC-100) with this (http://www.zoneminder.com/forums/viewtopic.php?t=7500) protocol adapter. &lt;br /&gt;
&lt;br /&gt;
* OvisLink AirLive WL-5400CAM&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Useful Links&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
* Flash&amp;#039;s IP Camera Database:  https://digdilem.org/ip-cameras/ (Doesn&amp;#039;t seem to work when searching for &amp;#039;Works with Zoneminder?&amp;#039; option, though. - jpcy)&lt;br /&gt;
&lt;br /&gt;
== IP Video Encoder ==&lt;br /&gt;
&lt;br /&gt;
Like Network Cameras, these devices produce a video stream over tcp/ip - but they do so with input from an analog video camera or other video source. An easy way to find these are to search for video encoders or video servers, e.g. 8 channel video encoder, or 2 channel video server.  Newer video encoders may also support HD Analog either in addition, or instead of analog streams (how they implement HD analog, depends upon the brand. There are currently competing standards such as AHD, EX-SDI, HD-SDI, HD-CVI, HD-TVI, etc...).&lt;br /&gt;
&lt;br /&gt;
IP Video Encoders are generally easier to use and maintain than PCI / Capture cards. &lt;br /&gt;
&lt;br /&gt;
* [[Synectics E100]] encoder&lt;br /&gt;
&lt;br /&gt;
*The [[IP9100 | Aviosys IP9100, Models A, B and Plus]] has four analog video inputs.  It produces a ZM compatible video stream from one of the inputs, which is selectable via an HTTP GET command.  There might even be a control script for ZM that lets you select the active video input using &amp;#039;&amp;#039;ZM&amp;#039;s Camera Control Presets!&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
With the yoics Aviosys 9100 firmware at http://www.yoics.com/?p=28, ZoneMinder can directly access all four ports via /usr/yoicsX.jpg as the remote host path, where X is 0 - 3.&lt;br /&gt;
&lt;br /&gt;
* [[Axis]] Multiple&lt;br /&gt;
&lt;br /&gt;
* [[Bosch VIP X1 Single-channel]] video encoder [http://products.boschsecuritysystems.eu/en/EMEA/products/bxp/SKU15449253232961378955-CATMda7ec5dc0edf5b1a0b8cb619e2e11308]&lt;br /&gt;
&lt;br /&gt;
* [[GXV3504]] Grandstream 4 channel video encoder.&lt;br /&gt;
&lt;br /&gt;
* [[Hikvision]] HD Analog (With errors)&lt;br /&gt;
&lt;br /&gt;
* [[Samsung]] uses AHD cameras, and possibly NTSC/PAL cameras.&lt;br /&gt;
&lt;br /&gt;
== Capture Cards ==&lt;br /&gt;
&lt;br /&gt;
[[Anykeeper]] &lt;br /&gt;
&lt;br /&gt;
[[Avermedia]]&lt;br /&gt;
&lt;br /&gt;
[[Camsecure PCI Express video capture]]&lt;br /&gt;
&lt;br /&gt;
[[Digiflower]]&lt;br /&gt;
&lt;br /&gt;
[[Geovision GV250 - bt878a chip]]&lt;br /&gt;
&lt;br /&gt;
[[Grandtec Grand X Guard]] &lt;br /&gt;
&lt;br /&gt;
[[Hauppauge]]&lt;br /&gt;
&lt;br /&gt;
[[Howell-Tempest  VC 878B-Q]]&lt;br /&gt;
&lt;br /&gt;
[[Ituner Spectra 8]]&lt;br /&gt;
&lt;br /&gt;
[[Kodicom 4400r]]&lt;br /&gt;
&lt;br /&gt;
[[Kodicom 8800]]&lt;br /&gt;
&lt;br /&gt;
[[Tungson TE-8008]]&lt;br /&gt;
&lt;br /&gt;
Leadtek WinFast VC 100 - the cheapest bt878 model with no tuner on it, just Com/Svideo in.&lt;br /&gt;
&lt;br /&gt;
[[LinkDelight CCTV H.264 4CH DVR Card]]&lt;br /&gt;
&lt;br /&gt;
[[Linux Media Labs LMLBT44]] &lt;br /&gt;
&lt;br /&gt;
[[Osprey 100]]&lt;br /&gt;
&lt;br /&gt;
[[Provideo PV- series (Bluecherry)]] &lt;br /&gt;
[[ Bluecherry - BC-H16480A]] &lt;br /&gt;
[[TView 95/99]]&lt;br /&gt;
&lt;br /&gt;
[[UDP Technology NCP3200v2]]&lt;br /&gt;
&lt;br /&gt;
[[Videocards with Philips saa7134 chipset]]&lt;br /&gt;
&lt;br /&gt;
[[WinFast TV2000 XP]]&lt;br /&gt;
&lt;br /&gt;
[[Rapid OS]]&lt;br /&gt;
&lt;br /&gt;
[[KesCom PG104]]&lt;br /&gt;
&lt;br /&gt;
[[IEI Technology Corp. IVC-268G-R20]]&lt;br /&gt;
&lt;br /&gt;
== bt8x8 Cards ==&lt;br /&gt;
BT8x8 cards are handled by the Kernel module BTTV. A note on the bt8x8-based TV-tuner cards: these usually have beside the tuner input, also a Composite and an S-Video input. You can hook up 2 analog cameras to these, and access from ZoneMinder both of them as individual cameras, at max 15Fps. You don&amp;#039;t need two separate TV cards for two cameras!&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Pico2000]] - 4 port card, one chip bt878, around 2 fps when using all channels&lt;br /&gt;
&lt;br /&gt;
[[Bt878_4chip_8inputs]] -4 chips bt878, 8 inputs, around 5 fps when using 2 inputs per chip&lt;br /&gt;
&lt;br /&gt;
[[:Image:Karta.jpg| bt878 8 chip 8 input]] - This card is supplied with D-sub to 8 BNC connector and uses the bt878 chip for each input allowing full frame rates and quality. See [[Kodicom 8800]] for more information.&lt;br /&gt;
&lt;br /&gt;
Geovision GV250 bt878a single chip 4 inputs - This capture Card is supplied with 4 video inputs but with NO audio channel&lt;br /&gt;
&lt;br /&gt;
Geovision GV-800 8 inputs - [https://forums.zoneminder.com/viewtopic.php?f=14&amp;amp;t=12327] Recommended to review forums. &lt;br /&gt;
&lt;br /&gt;
Most other BTTV (bt878, bt848) cards, see &amp;#039;&amp;#039;&amp;#039;/usr/src/linux/Documentation/video4linux/bttv/CARDLIST&amp;#039;&amp;#039;&amp;#039; on your system for a list. You can also find more details on the BTTV module, such as parameters to pass via insmod, [https://www.kernel.org/doc/html/latest/media/v4l-drivers/bttv.html in the kernel] and&lt;br /&gt;
[https://www.linuxtv.org/wiki/index.php/Bttv on the v4l wiki ]&lt;br /&gt;
[https://www.linuxtv.org/wiki/index.php/Bttv_devices_(bt848,_bt878) 2nd link]&lt;br /&gt;
&lt;br /&gt;
== Analog Cameras ==&lt;br /&gt;
&lt;br /&gt;
Any regular composite or S-video camera connected via a supported capture card.  Some analog cameras feature camera control - ZM supports several of these camera&amp;#039;s Pan/Tilt/Zoom functions via serial port control, as well as camera Presets, Focus, Iris, etc.&lt;br /&gt;
*[[PicturetelControlScript | PictureTel PTZ2N]].&lt;br /&gt;
&lt;br /&gt;
== USB Cameras ==&lt;br /&gt;
&lt;br /&gt;
*Just Zoom USB cam&lt;br /&gt;
&lt;br /&gt;
*Creative Webcam Pro, Webcam 3, LIVE! Cam OPTIA PRO (V4L2, Chan 0, PAL, YUYV)&lt;br /&gt;
&lt;br /&gt;
*&amp;#039;&amp;#039;Most&amp;#039;&amp;#039; UVCvideo cameras, including: Advent AWC213, Creative Labs VF0420, [[Logitech QuickCam Express]], Logitech HD C270, QuickCam Pro 3000, [[QuickCam Pro 4000]],  QuickCam Communicate STX/Deluxe, [[Logitech Webcam Pro 9000]], [[Webcam C250]], and [[Logitech C525]].&lt;br /&gt;
&lt;br /&gt;
*Logitech Quickcam Orbit/Sphere (experimental basic pan/tilt control has also published for testing and hacking [http://www.zoneminder.com/forums/viewtopic.php?t=9788])&lt;br /&gt;
&lt;br /&gt;
*[[Philips]] &lt;br /&gt;
&lt;br /&gt;
*Any OV511 based USB camera [http://alpha.dyndns.org/ov511/cameras.html]&lt;br /&gt;
&lt;br /&gt;
*Any CPIA based USB camera [http://webcam.sourceforge.net]&lt;br /&gt;
&lt;br /&gt;
*[[LabTec WebCam Pro]]&lt;br /&gt;
&lt;br /&gt;
*Confirmed basic functionality with Microsoft Lifecam VX 5000 using UVC Streaming method&lt;br /&gt;
&lt;br /&gt;
*Company name: PU`Aimetis model: PUAN-3656 (2MP / Max resolution: 1920*1080, MJPEG - 1920X1080 @ 30fps / YUV2 - 1920X1080 @ 5fps)&lt;br /&gt;
&lt;br /&gt;
Note that most USB cameras that can use Video4Linux/V4L2, and so can be used by ZoneMinder.  Some have older chipsets and can be hard to find new.&lt;br /&gt;
&lt;br /&gt;
Note that PWC drivers are not included in the kernel. Some distribution&amp;#039;s add them in and other may not. Here are some relevant links:&lt;br /&gt;
* [http://www.smcc.demon.nl/webcam/ Old Maintainer]&lt;br /&gt;
* [http://www.saillard.org/linux/pwc/ Current PWC Maintainer]&lt;br /&gt;
&lt;br /&gt;
== X10 Devices ==&lt;br /&gt;
The only device that really needs to be compatable with ZM is the Transceiver, all other x10 devices comunicate through that device.&lt;br /&gt;
*[[CM11]] Bi-Directional Transceiver&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Other X10 notes:&lt;br /&gt;
&lt;br /&gt;
[http://www.zoneminder.com/forums/viewtopic.php?t=6423&amp;amp;highlight=x10 Topic 6423]&lt;br /&gt;
&lt;br /&gt;
[http://www.zoneminder.com/forums/viewtopic.php?t=7082&amp;amp;highlight=x10 Topic 7082]&lt;br /&gt;
&lt;br /&gt;
== All other hardware as supported by Linux ==&lt;br /&gt;
To find out if your hardware is supported, check the [http://www.zoneminder.com/forums/viewforum.php?f=10 HCL]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Plug Computers ==&lt;br /&gt;
Guruplug Server Plus -&amp;gt; How to install Zoneminder&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Single Board Computers ==&lt;br /&gt;
&lt;br /&gt;
Single board computers such as the Raspberry Pi, Odroid, Beagleboard, and many others.&lt;br /&gt;
&lt;br /&gt;
See [[Single Board Computers]]&lt;/div&gt;</summary>
		<author><name>Snake</name></author>
	</entry>
</feed>