From Indie IT Wiki
Jump to: navigation, search

Installation On Gentoo Linux

Add the zugaina overlay.

layman -a zugaina
eix-layman -a zugaina add

Install the software.

emerge =www-misc/zoneminder-1.24.3

Test the camera.

mplayer tv:// -tv driver=v4l2:width=320:height=240:device=/dev/video1

Check that ZoneMinder can see and use the camera.

zmu -d /dev/video1 -q -v

Video Device: /dev/video1
General Capabilities
 Driver: uvcvideo
 Card: UVC Camera (05ca:183b)
 Bus: usb-0000:00:1a.7-2
 Version: 1.0.0
 Type: 0x4000001
   Supports video capture (X)
   Does not support video output
   Does not support frame buffer overlay
   Does not support VBI capture
   Does not support VBI output
   Does not support sliced VBI capture
   Does not support sliced VBI output
   Does not support video output overlay
   Does not have tuner
   Does not have audio in and/or out
   Does not have radio
   Does not support read/write i/o (X)
   Does not support async i/o
   Supports streaming i/o (X)
   YUV 4:2:2 (YUYV) (YUYV)
Crop Capabilities
 Bounds: 320 x 240
 Default: 320 x 240
Inputs: 1
 Input 0
   Name: Camera 1
   Type: Camera
   Audioset: 00000000
   Standards: 0x0
   Power on  (X)
   Signal detected  (X)
   Colour Signal detected 
   Horizontal Lock detected 

Create mysql database.

mysql -uroot -p zm < /usr/share/zoneminder/db/zm_create.sql

Assign privileges.

mysql -uroot -p zm
mysql> grant select,insert,update,delete on zm.* to 'zmuser'@localhost identified by 'zmpass';
mysql> quit;
mysqladmin reload

Set your database settings in /etc/zm.conf.

nano /etc/zm.conf

Start the zoneminder daemon.

/etc/init.d/zoneminder start

Set time/date setting in PHP.

date.timezone = 'Europe/London'

Fix PHP setting in file /etc/php/apache2-php5.3/php.ini.

short_open_tag = On

Start apache.

/etc/init.d/apache2 start

Load in web browser.