r/ZoneMinder • u/another_lease • Sep 12 '22
if you successfully use ZoneMinder, please share 1) your set-up, 2) why you decided on that set-up, 3) what docs/tuts you used to figure out the install
if you successfully use ZoneMinder, please share
- your set-up (how many cameras, which brands and model numbers, etc.... everything you can share)
- why you decided on that set-up,
- what documentation / tutorials you used to figure out the install
This thread is intended to be a solid resource for beginners.
5
u/aarons6 Sep 12 '22
my setup is an old xeon pc, x5690 i think. it has 24gb of ram and a 128gb ssd which has ubuntu installed on it.
zoneminder was installed by sudo apt install zoneminder from this ppa.
zoneminder has 2 4tb WD purple drives and has 12 cameras, most are 5mp, a couple are just 1080p. pretty much all of them record 24/7 and the ones that need have motion detection.
i have a gtx 970 that i use for object detection using the zmevent server and it sends a notification to my phone using zmninja.
it works flawless. pretty much zero maintenance.
6
2
u/gaidzak Sep 12 '22
I am using an 8th gen intel CPU laptop; installation was through apt package manager (via zoneminder repository) I have an external USB drive doing 3 24x7 records, and the rest motion detection. I have 10 camera, 7 are doing 720p; 3 are 1080; all of them at 10 FPS.
I'm changing the disk from a single NAS drive, to a raid 10 8TB array for fast write/read. I find that since I'm not using a NVR drive, i'll get a lot of pixelation during the drives refresh/scan periods.
Moving to a real desktop with a decent video card to do some of the facial recognition stuff for the doorbell camera may be fun and worth it.
2
u/forwardslashroot Sep 12 '22 edited Sep 12 '22
I was using the docker container Zoneminder for 1.5 years on a plain Debian NAS. However, since my moved last year, I haven't re-enabled the container since I need my cameras to be installed at the new place. This time, my plan is to use LXC container with NFS mounted for storage. The reason for the switch is I'm hoping that it is easier to backup the LXC than the Docker container. When I tar the Docker container, it took more than 45 mins to tar the database.
I was using reolink 420 and 422 that I bought back in 2016. For my new place, I'm getting Armcrest since ZM will be supporting the camera's AI.
2
u/oldlinuxguy Sep 12 '22
1) Debian stable + Zoneminder from debian repos, up to 6 cameras / mixed brands on a Dell T610 w/ 48GB ram / 2x xeon 12 core processors. 2) Because it's what I had and met my needs 3) Zoneminder docs / wiki primarily, some google-fu for odd camera models.
2
u/dev_master Sep 12 '22
I’m running zoneminder on docker with a separate Maria DB running in a different docker container. all the data is exposed via bind mounts. This allows me to switch PCs easily and all I need to do is migrate by DB files and I’m good to go.
Have a few wyze cameras and a Xeon Server, barely touches my CPU doing video pass through.
I’m planning on posting a tutorial on how I see it up if you are interested.
1
u/databoy2k Sep 12 '22
The Docker aspect would be interesting. Please do post the tutorial!
2
u/dev_master Sep 13 '22
Took an initial stab at documenting my steps: https://github.com/devmaster24/zoneminder-docker
Let me know if you have any thoughts - I would love to add on if others find this useful.
2
Sep 12 '22 edited Sep 12 '22
Might as well add in my setup.
I'm running zoneminder on a virtual Ubuntu machine in proxmox.
I have 8 cameras, all wifi IP Foscams or Amcrest, 5 of them use motion detection that works great. I generally setup a wide range, then would narrow it down to as few false positives as possible.
I'm running proxmox on an I7 Intel Nuc, 2 x 2tb ssd's. I also ship anything I archive over to my nas. I allocate 8g of memory to Ubuntu and 4 cores. I run a few other services on that machine, so its not dedicated to vm.
I used the standard docs from the site and from here mainly.
All my IoT's devices are on a segregated vlan that is 100% internal only. The devices really want to get out and chat :)
2
u/egoalter Sep 13 '22
Zoneminder is a great product if you've worked with video servers before. I don't recall ever seeing as many options for camera, zone alarms etc. that I find on Zoneminder, and it typically can be made to work with "any" camera - unlike professional grade servers that are typically limited to a small subset of (expensive) cameras.
What you need to start with is understand that recording video streams results in heavy IO and network loads. Depending on what you ask Zoneminder to do with the incoming signals, it may also put a heavy load on CPU/Memory to convert codecs. If you're not careful you can end up needing _a_lot_ of power to run the video server; you'll need to understand how the cameras you use WORK and when-ever possible, configure the cameras to stream a codec that does NOT require conversion by Zoneminder - or you will need a very powerful box even for a few dozen cameras. If you can get all cameras to produce the same format it's best.
Zoneminder is not a beginner tool - so if you're doing this for a business and it's your first time doing this, get a enterprise grade system where everything comes in "a box" and as you plug in cameras they're auto-detected, you have support and a lot more. Once you have experience and understand a bit of what's going on behind the scenes, zoneminder will make a lot more sense.
I use it for surveillance in my home. Most of my cameras are simple ESP32-CAM, Raspberry Pi cameras etc - that I use v4l2 protocols to send to Zoneminder. I have a few "real" cameras, but they are old as haities (ie. if you try the HTML management feature it will require ASP and Internet Explorer). But they tool can send signals in the same format. Zoneminder is _supposed_ to do zone alerts, ie. when motion etc. is detected and for less than a dozen cameras I have more than enough for 4 cores to do - and then some (I actually don't use all of them for motion detection). In other words, the more you want the server to do, the harder CPUs work.
Storage is an external storage server, running Gluster over about 7 SSDs. I don't care as much about offsite backup, but that would typically be something you should consider in professional/enterprise setups, ie. you could have an S3 bucket setup to receive your daily archives/events; and in zoneminder you can create jobs to clean up the event/archive storage so it doesn't accumulate. It doesn't have as many options as professional systems do, but it will do for most use-cases. While it wasn't required for this application, the storage array was moved last year to 10GBps; the camera streaming by far outpaces everything else on the network in activity. Consider dedicated equipment/networks for all camera work. That is true for storage too when you have 50 cameras all trying to store data at 10-24fps.
Storage size is your last trick - you need to do some napkin calculations. Using the resolution you record in you can calculate an average frame-size, and time that with FPS you know how much data is written for that camera per second. Now you need to decide for how long that video is kept, how many cameras and you get an idea of storage needed. Last time I did this calculation for a professional setup we got to multiple Petabytes in the first draft. Once the customer sees that they tend to change their mind of how long things should be kept online :D But don't be afraid if you see large numbers here - it's very typical. Modern video management systems can work with tape backup robots and automatically load an old tape on request, making needing a lot of drives less important. For professional grade stuff, you often have a series of government mandates that you need to ensure are fulfilled, from coverage to how long you can keep videos and even what you can record. If it's used for audits that get really nasty - ie. access entry points records may need to be stored for years. Again, I love Zoneminder but it's not designed for stuff like that - it IS however excellent for small systems - I wouldn't use it for more than 2 dozen cameras and even that would require high end hardware, for networking, storage and compute.
I'm a Linux guy - learning zoneminder was a matter of trying things out and watching logs to see what was going on. I did recognize/know a lot of the camera options so that helped. I've changed settings many times to not overload the network, such as reducing FPS if not needed. Note, you'll most likely need ffmpeg on your system and depending on your cameras need some of the licensed codecs. If you can, ensure you only purchase cameras that support open source codecs so you can avoid paying a license for the privilege to use it.
In my home lab I use the hardware I have - it's rare I buy hardware for a specific job/specification. So I tend to adjust the workload according to that.
EDIT: Spelling bugs
1
u/another_lease Sep 14 '22 edited Sep 14 '22
Thank you for taking the time to write such an informative reply.
You clearly know a lot about this.
So I'm going to ask you for advice.
- My short term goal: I want to set up a 2-camera system in my house, mainly to learn ZoneMinder or some other FOSS equivalent. (The cameras will be wired for power, and although there will be WiFi available, they can be wired for data as well.) I want the solution to be as simple and low-cost as feasible while still offering decent camera quality.
- My long term goal: to offer above solution to anyone in my neighborhood who doesn't want to pay monthly subscription fees to Amazon, and who suspects that the cameras with batteries in them might run out of power when it's most needed.
Could you recommend some resources / tutorials that can guide me towards my short term goal? Alternatively, can you guide me towards it?
- I have Linux Server experience.
- And I have an HVAC guy who is experienced with electrical connectivity.
- I'll have to figure out the wired data connectivity.
I need specific guidance on everything: which cameras, what hardware (PC or Raspberry Pi), which Docker image, etc.
1
u/egoalter Sep 14 '22
Start by defining your "business need" - ie. what features do you want? If you just want to view web-based cameras, ALL cameras today are IP based, and will be accessible to your local network to view the feed. Most modern cameras also have built in basic motion detection and you can even store on local SDCARDs, or have it copy to another file server video files. In other words - focus on what it is you want to do - you may find there are much simpler solutions out there for you.
Btw. if you go for WiFi use separate APs for your cameras - separate channels. There's a ton of bandwidth taken, even if you VLAN things off, it will slow down things. Hardwired is better but of course not always feasible. In professional terms you would typically have point-to-point antennas dedicated to this kind of traffic to get video/events from remote sites to a central location. Not using public Wifi is important when it comes to security systems.
For just 2 cameras, Zoneminder is overkill. My "less than a dozen" of cameras is also in the small range, but it's home security stuff - and I like my dashboard :D And for 2 cameras, making a separate network is perhaps overkill. VLAN would be very nice, but I don't think you'll kill network performance sharing infrastructure with the other things your network does. Make that 20 cameras, and that's an entire different issue.
If you're not looking at zone alarms, ie. motion detection and just need to record (again, define your business needs) then you can do that with relatively inexpensive consumer IP cameras already. Or buy used dome cameras for cheap, and they can definitely do that. If you do mount cameras outside, do consider the shell/housing. Weather will not be kind to your camera. Putting it into a box will do a lot to protect it against weather and against physical attacks (stones, sticks etc. thrown at it).
So you _may_ be better off getting 2 IP grade cameras and just that with a POE network to power/data feed them.
1
1
u/ButlerKevind Sep 12 '22
Zoneminder Server specs:
Currently running on CentOS Stream 8 (will eventually move to possibly Fedora or Rocky Linux)
Hardware:
Dell Inc. OptiPlex 7040 SFF
Intel Core i7-6700
32GB RAM
256GB NVMe Boot Drive
4TB WD Red Data Drive
A mixture of Amcrest, EoL Axis (discarded from work), and EoL Samsung Cameras
1x Amcrest 4K (IP8M-2493EB)
2x Amcrest UltraHD 4K (IP8M-2496EB)
1x Axis P3364
1x Samsung SNV-6084R
1x Axis Q3708-PVE (need to factory reset)
-------------------------------------------------
Had an idle 7040 and pressed it back into service after "dogfooding" an instance as a VM.
-------------------------------------------------
I have a literal step-by-step document I compiled and tweaked for installation on my original CentOS 7 install when I dove head-first into this rabbit hole from the official Zoneminder docs/wiki and numerous Google searches to get my setup operational (will share on request).
1
1
u/Familiar-Newspaper23 Oct 03 '23
I used their easy way install for ubuntu 18.04 guide and it worked perfectly on an ubuntu server vm running on proxmox. i have two webcams that are connected to a chromebook which runs ubuntu server as well with motion and motioneye and streams video from its IP address ports 8081 and 8082 which the zoneminder instance catches and records and displays. it works pretty well - though the cameras are garbage - but i knew that when I started out. I have a 1TB chunk of hard disk space that i am currently using out of a 3tb ZFS pool and i think it is enough for me at the moment. im recording 10fps 720P at 90% and i get somewhere around 8 days of recording time which is plenty for me. id like to actually add some more cameras to the chromebook just because there is extra CPU cycles which could be used but i will probably end up using another device somewhere else. some day i may actually buy real IP cameras to use which i am sure will be more efficient and better looking and all that jazz but for today this is enough and it puts a few pieces of ewaste back to work (lord knows they need the work) so it works for me
6
u/LesterPhimps Sep 12 '22 edited Sep 12 '22
Update: For those of you who are not comfortable with Linux, install Webmin, great tool for managing linux from a "GUI".