I've bought an AVTech AVI201 IP Camera to integrate into the home automation system.

To manage it, I plan to run Zoneminder. The idea is to have it automatically trigger lights at night, and generate alarms when the house is unattended.

Update 17th July 2009

I've created a new Fedora 11 VM and installed Zoneminder & MySQL server on it. I've configured the database for zoneminder but was unable to start the server. Looking at the logs, zmfilter was failing with a missing Perl module (perl-MIME-Lite in yum). After installing this module, the filter script succeeds, but the web interface is still reporting the server as stopped.

Update 18th July 2009

Looks like SELinux was getting in the way - the zmdc script could not connect to the socket when called through the web interface, even though it worked fine when called from the command line (when running as the web server's user). Disabling SELinux (SELINUX=disabled in /etc/sysconfig/selinux) fixed the problem, and the web interface now shows the daemon status correctly.

Of course, this was all documented on the wiki :)

Next up is getting the camera streaming video to Zoneminder properly.

Update 21st July 2009

I got video streaming from the camera, and motion detection working.

  1. Build FFMPEG from SVN: ./configure --prefix=/usr/local --libdir=/usr/local/lib64 --shlibdir=/usr/local/lib64 --enable-shared
  2. Bump shared memory up (in /etc/sysctl.conf): kernel.shmall=134217728  kernel.shmmax=134217728
  3. Add /usr/local/lib64 to your library path: echo /usr/local/lib64 >> /etc/ld.so.conf
  4. Compile ZoneMinder (I used 1.24.2) with FFMPEG support (you could also use the SPRM attached, its a butchered version of 1.24.1): ./configure --prefix=/usr/local --with-libarch=lib64 --with-ffmpeg=/usr/local --with-webdir=/usr/local/share/zoneminder/www/ --with-cgidir=/usr/local/share/zoneminder/cgi-bin
  5. Configure the camera with no authentication
  6. Configure ZoneMinder to access the camera as an FFMPEG source: rtsp://<camera hostname>/live/mpeg4

Now to figure out how to get authentication working.