ZoneMinder "Cluster" based operation

Anything you want added or changed in future versions of ZoneMinder? Post here and there's a chance it will get in! Search to make sure it hasn't already been requested.
Post Reply
Solar
Posts: 13
Joined: Fri Aug 18, 2006 11:11 pm
Location: South Africa

ZoneMinder "Cluster" based operation

Post by Solar »

Hi,

I've been using Zoneminder at the Electrical Engineering department (University of Stellenbosch in South Africa) for quite a while now. I've integrated it with our Active Directory for user authentication (with LDAP), and also linked it to our Access Control system so that everything can be viewed from the ZoneMinder console.

We have been running 20 IP cameras at 320 x 240 on a Pentium 4 Dual Core System with 2 GB of RAM and a 320GB drive. System load is under 2.0 most of the time, which is quite good for a computer with 2 active processors.

The cameras can all support 640 x 480 (they are cheap D-Link DCS-900's), but the system is a bit overloaded when running 20 cameras at this high resolution. My idea was to change ZoneMinder so that you can have x amount of "servers" doing the actual capturing and analysis of frames, but when logging in to the ZoneMinder frontend, it looks like there is only one system running: The streams automatically get loaded from the correct machines.

I started work on it about 2 days ago, and am pleased to announce that the first "alpha" release of my changes are ready. I've tested it here at home with 3 machines in a ZM cluster, and everything (from live stream viewing to thumbnail generation) seems to be working properly.

Please let me know if anyone is interested in my initial release. I'm currently working on a detailed CHANGELOG and HOWTO.

Regards,
Christiaan
jameswilson
Posts: 5111
Joined: Wed Jun 08, 2005 8:07 pm
Location: Midlands UK

Post by jameswilson »

yes im interested. Good work
James Wilson

Disclaimer: The above is pure theory and may work on a good day with the wind behind it. etc etc.
http://www.securitywarehouse.co.uk
pathway
Posts: 64
Joined: Wed Nov 29, 2006 6:29 pm

Post by pathway »

May I add: Yes, I would be quite interested in this. If there's anything we can do to help test it, let us know!

--Pathway
Solar
Posts: 13
Joined: Fri Aug 18, 2006 11:11 pm
Location: South Africa

Post by Solar »

Hi guys,

I've run into a little snag... Everything seems to be working fine, except the extra polling script I needed to implement to keep everything synchronized.

Maybe James or Phil can help with this one:
I created a new perl script (with much the same content as zmwatch.pl). I added this file to the list of daemons in zmdc.pl.
Starting this script from the command line, works perfectly, but as soon as I try to start it using zmdc.pl start zmpoll.pl, I get the following output:

[root@cctv bin]# zmdc.pl start zmpoll.pl
'zmpoll.pl' starting at 07/05/22 01:57:42, pid = 2489

When I do a status request, I get the following:
[root@cctv bin]# zmdc.pl status zmpoll.pl
'zmpoll.pl' pending at 07/05/22 01:54:54
'zmpoll.pl' running since 07/05/22 01:54:44, pid =

And obviously, the script isn't running. I found out that, after executing "zmdc.pl start zmpoll.pl" about 20 times, I get the following output:
[root@cctv zm]# zmdc.pl start zmpoll.pl
Can't find child with pid of '1333'
'zmpoll.pl' starting at 07/05/22 01:50:25, pid = 1333

At this point, the script is running at LAST.

I thought that it might be something in my zmpoll.pl code, and copied zmwatch.pl over zmpoll.pl. Trying to start zmpoll.pl (with the zmwatch's code) gave EXACTLY the same problem. The real zmwatch.pl however continued to start absolutely without any problems.

I'm running Fedora Core 6 on a Pentium 4 3Ghz Dual Core machine.

Does anyone have ANY idea what could cause something like this?

Regards,
Christiaan
mchapman
Posts: 10
Joined: Fri Mar 24, 2006 2:12 pm

Post by mchapman »

Hi,

I am interested as well.

Thanks,

MIke
skafrank
Posts: 3
Joined: Sun Feb 25, 2007 3:19 am

Post by skafrank »

this is exactly what i'm looking for, but i don't know how to do this... don't stop!

frank
quietas
Posts: 102
Joined: Wed May 23, 2007 5:30 pm

Post by quietas »

I would definitely be in this as well. I've got 4 locations planned with 6-8 cams each. Connected them via our internal network with just one interface would be rather nice. Also as locations expand I can add more boxes locally to cluster each site to share the load.
Solar
Posts: 13
Joined: Fri Aug 18, 2006 11:11 pm
Location: South Africa

Post by Solar »

Hi everyone.

I've been running my "Beta Version" here at our University for a few weeks now and everything seems to be working fine... The only problem I'm still having is the one a mentioned a few posts up.. about the starting of new deamons...
It just stays in the pending AND running queues, without ever starting up. I got around that by putting my own script in the computers crontab at startup, but the better solution would be to have zmdc.pl handle it. Again, I'm asking anyone with ZoneMinder coding experience to see if they can reproduce my problem and have any ideas on fixing it.

I'll upload my Beta version with Cluster Support as soon as I can iron that problem out...

Regards,
Christiaan
User avatar
cordel
Posts: 5210
Joined: Fri Mar 05, 2004 4:47 pm
Location: /USA/Washington/Seattle

Post by cordel »

I have been watching this thread with interest. Please don't think the lack of our involvement is a sign on non-interest. I just started getting parts in for a new server for development as well as test. Soon as I have it up I will get involved and help you work things out.
Kudo's BTW for getting this far ;)
Solar
Posts: 13
Joined: Fri Aug 18, 2006 11:11 pm
Location: South Africa

Post by Solar »

Cool. Let me know as soon as you have some time, and perhaps we can just see if we can get that deamon problem sorted. Everything else seems to be working great.
Kumba
Posts: 4
Joined: Thu Jan 25, 2007 4:04 pm

Post by Kumba »

How is your beta clustered? Is it a front-end capture/analyze with a back-end events/zones/files split? Would like to hear some details on your particular implementation. THanks.
ampp
Posts: 9
Joined: Tue Dec 05, 2006 6:16 am

Post by ampp »

I would be interested in looking over the code and possibly debugging it. Just put it up, it doesn't need to be perfect first time around.
Post Reply