Raspberry PI opensource video surveillance with Zoneminder

 

RaspberryRasperri Pi was mainly designed to be used by young people who want to learn and discover the electronics and programming world without investing big amount of money. The latest improved version which has a 512 MB RAM available can be used to perform more complicated tasks as the one we want to show you today: how to make your home opensource video surveillance system using Raspberry PI, Zoneminder and a IP cam. In this system the Rasperry Pi works as a DVR (Digital Video Recorder); the acquired video files will be stored into the SD memory card and can be reached from everywhere by using a FTP server like Vsftpd.

ZoneMinder (http://www.zoneminder.com/) is an integrated set of applications which provide a complete surveillance solution allowing capture, analysis, recording and monitoring of any CCTV or security cameras attached to a Linux based machine; it can be used in single or multi-camera video security applications however, to avoid overstress of the Rasperry PI hardware and to have a reliable system,  it’s preferred to use only one camera. Zoneminder can be downloaded from http://www.zoneminder.com/downloads or can be installed from the Raspian repositories using the console and the “sudo apt-get install zoneminder” command following the installation instructions. Raspbian is a Debian based distribution optimized for the Rasperry PI so we suggest you to follow the installation guide for Debian (http://www.zoneminder.com/wiki/index.php/Debian). The installation procedure requires few minutes during which the user has to insert some data like mysql password. At the end you can get access to the web interface at http://localhost/zm where you can set your camera parameters and define surveillance areas, recording path and motion detection:

ZM_RASPBERRY

There are tips and suggestions for many kind of cameras at http://www.zoneminder.com/wiki/index.php/Hardware_Compatibility_List

 To set the FTP path use “Options” and “Upload” and configure the fields in order to match with the  FTP server.

This entry was posted in Raspberry Pi. Bookmark the permalink.

22 Responses to Raspberry PI opensource video surveillance with Zoneminder

  1. Brian_H says:

    Hello, I tried doing the apt-get install zoneminder on my pi and I get mysql errors after entering a root password. the error is telling me that a mysql root user already exists. So i tried removing mysql-server-5.5 , then I did apt-get autoremove, then apt-get purge. After everything that dealt with mysql server was removed i tried apt-get install zoneminder again. I got the mysql error again after entering the root password. Does anybody know what the root password is for mysql when installed in raspbian?

    Brian

  2. David Carlson says:

    Geez, why isn’t it in the instructions that you need to make the link

    sudo ln -s /etc/zm/apache.conf /etc/apache2/conf.d/zoneminder.conf

    sudo /etc/init.d/apache2 reload

    Everything was going smoothly up too this the point. It was really frustrating lol

    • Ian says:

      Thank you kindly for coming back to share this important step after learning of it yourself. I was at a loss as to why localhost/zm returned a 404 and this solver the issue.

  3. Dirk says:

    Hi there, i’ll describe my planned Scenario for the use of a Raspberry Pi B+ with zoneminder:
    Video surveillance of a large room over night with two cams, one IP-based (in the compatibility list of zoneminder), the other usb wired (can be changed with an ip based).
    I run a MS AD Network and the Raspberry and the IP cam have to contact my DHCP-Server.
    I wish to save the captures into a Network share.
    The Raspberry should be controled only remotely.

    Have you any hints for me? Is this is a possible solution?

    Thanks for responses

    • admin says:

      Hi Dirk,

      you should perform some tests in order to make sure that the Raspberry Pi can manage both cams at a reasonable bitrate: don’t forget that it has limited capabilities for such kind of things.

      • Dirk says:

        I installed the apache2 and zoneminder on the pi and could open the Website on other machines.
        Then trying to establish a monitor (Remote IP-Cam) fails – I exactly used the instructions from the wiki, specially for my ip-cam model (Apexis J011 WS). Another try was the use of a USB cam. It was displayed as devce via dmesg | tail but configured as a monitor in zoneminder it fails. The errormessage with the probe-function in both configurations replied code 127.

        Help Wanted
        Thanks

  4. Michele says:

    I have a Foscam FI8910W currently working on Windows 7 with a his proprietary Windows 7 tool. It is possible to save the MJPEG stream on an hard disk.

    The questions:
    1. if i move to rapberry-zoneminder, is it possible with zoneminder to save the MJPEG stream on an hard disk?
    2. is is possible to save only video or audio-video stream?

    thanks

    • admin says:

      Hi,

      you can configure zoneminder to work as you like but obviously some features depend on the camera capabilities.

  5. Pablo says:

    Hi!
    I’ve been testing the solution using QEMU before buying the actual HW and finally made the purchase (being delivered in the next few days)

    My main question is, have you tested it with TWO IP cams instead of one?
    Is there a real performance degradation using two cammeras?
    I have no problem using only one, since it’s the camera I have outside home the one I attempt to monitor, but since I have another one inside as well, I was thinking in monitoring both.

    Second question, did you test it using WiFi dongle? Or wired via UTP?
    Did you see any significant difference between both scenarios?
    Thanks for the feedback!

    • admin says:

      Hi Pablo,

      we tested the system using one camera and a wired connection. The resources available on a Raspberry Pi are pretty limited so you have to try out if the result is as you aspect to be.

      Hardware Makers

  6. sethuper says:

    I have followed step by step in this tutorial, everything is describe, how to install and configure ZoneMinder on Debian/Ubuntu.
    http://terminal28.com/how-to-install-and-configure-zoneminder-linux-cctv-debian/

  7. Joe says:

    Have you tried to connect to a USB cam? I don’t get it working. Are there missing driver or packages?

  8. Román says:

    I installed in a RaspberryPi with debian and made ​​it to the login screen. But when I’m at …. zm/index.php I can only see some options and the page cycled and begin refreshing a lot of times, after that it send me to a page that says:

    Not Found

    The requested URL / zm / undefined was not found on this server.

    What do you think that it’s the problem?

  9. Charles says:

    Hi,
    Thanks. I found instructions on the zoneminder website and wiki for my brand of ipcamera. Zoneminder seems to be running on the Pi and I seem to be logged into the ip camera but I can’t get the video to display on the screen. Can you point me to somewhere that might help me to troubleshoot this problem?
    Thanks for your help.
    Charles

  10. Charles says:

    Wait! I got the console running! Thank you for the instructions. I had mistyped one of the commands…

    Now, how do I add an IP camera on my local network? If you can guide me to a tutorial or instructions for zoneminder I would appreciate it.

    Thanks,
    Charles

    • admin says:

      Hi,

      you can find useful information on the official zoneminder website where you can find also tips related to many ipcam brands and models.

  11. Charles says:

    Followed your instructions and (apparently) got Zoneminder installed successfully on my Pi. However, when I start Midori and enter http://localhost/zm I get “Not Found: The requested URL /zm was not found on this server”.

    Any suggestions?

  12. Pingback: Using the Raspberry Pi for something other than XBMC?

Leave a Reply

Your email address will not be published. Required fields are marked *