Install ZoneMinder Ubuntu 14.04


Start with a fresh Ubuntu install. Make sure OpenSSH server and LAMP is installed.

Download the latest 14.04.1 lts and install on your server.

Ssh to the new server …

Update and Upgrade your server and distro first..

  • sudo -i
  • apt-get update -y
  • apt-get upgrade -y
  • apt-get dist-upgrade -y

Install PPA Repository and update it.

  • apt-get install python-software-properties -y
  • add-apt-repository ppa:iconnor/zoneminder
  • apt-get update
Install Mysql and apache server if you did not during the installation.
  •  apt-get install mysql-server-5.5  mysql-client-5.5 -y
  • apt-get install apache2 -y

ZoneMinder Installation:

ZoneMinder 1.28 installation from the new added repository. During Installation, you will be asked to setup credentials for MySQL and mailing stuffs.

  • apt-get install zoneminder -y

Install “extra” VLC components to make libvlc work.

  • apt-get install libvlc-dev libvlccore-dev vlc -y

Add delay to allow MySQL to start before Zoneminder.

  • vi /etc/init.d/zoneminder and add sleep 15 just after the start

Create a directory in apache2 and Create two symbolic links.

  • mkdir /etc/apache2/conf.d
  • ln -s /etc/zm/apache.conf /etc/apache2/conf.d/zoneminder.conf
  • ln -s /etc/zm/apache.conf /etc/apache2/conf-enabled/zoneminder.conf

CGI is not enabled in Ubuntu 14.04 by default. Enable it this way:

  • a2enmod cgi

Create a new user and restart Apache

  • adduser www-data video
  • /etc/init.d/apache2 force-reload

Install Cambozola.

  • cd /usr/src && wget http://www.andywilcock.com/code/cambozola/cambozola-latest.tar.gz
  • tar -xzvf cambozola-latest.tar.gz

Replace 935 with cambozola version downloaded.

  • cp cambozola-0.935/dist/cambozola.jar /usr/share/zoneminder

You should now be able to access the web server using https://servername/zm or https://serverip/zm

If you get delays in opening the pages with errors like:” waiting for available socket”

Adding “ScriptAlias /cgi-bin /usr/share/zoneminder/cgi-bin” to the /etc/zm/apache.conf file seem to address the problem.

For better performance you should change:

 vi /etc/sysctl.conf

add: kernel.shmmax = 1073741824

Then initialize the change: sysctl -p

,

Leave a Reply