ZM 1.24.3 + ffmpeg w/ libx264 install script for Ubuntu

Forum for questions and support relating to the 1.24.x releases only.
User avatar
asturgeon
Posts: 23
Joined: Fri Apr 15, 2011 12:10 am

ZM 1.24.3 + ffmpeg w/ libx264 install script for Ubuntu

Post by asturgeon »

This is a crude script, but should work for a FRESH install of Ubuntu, anywhere from Lucid forward (haven't tested on prior versions). It install ZM 1.24.3 from source, along with FFMPEG w/ libx264 in a clean fashion. It needs work as this is a rough cut, but you should be able to fire it up on a fresh install and succeed in less than 5 minutes. If you want any extra codecs to be installed, update FFMPEG_EXTRAS variable, but make sure you have their packages installed first.

Code: Select all

#!/bin/bash
HOMEDIR=~
FFMPEG_EXTRAS=
echo "Enter MYSQL root password to use"
read -s MYSQL_ROOTPW
cd $HOMEDIR
sudo apt-get update
sudo tasksel install lamp-server
sudo apt-get install build-essential git-core checkinstall yasm texi2html libx11-dev libxfixes-dev libxvidcore-dev zlib1g-dev pkg-config
git clone git://git.videolan.org/x264
cd x264
./configure --enable-shared
make
sudo make install
sudo ldconfig
cd $HOMEDIR
git clone git://git.videolan.org/ffmpeg.git
cd ffmpeg/
git checkout oldabi
./configure --enable-gpl --enable-version3 --enable-nonfree --enable-postproc --enable-pthreads --enable-libx264 --enable-libxvid --enable-x11grab --enable-shared $FFMPEG_EXTRAS
make
sudo make install
sudo ldconfig
ffmpeg -codecs | grep 264
cd $HOMEDIR
wget http://www2.zoneminder.com/downloads/ZoneMinder-1.24.3.tar.gz
tar xvf ./ZoneMinder-1.24.3.tar.gz
cd ZoneMinder-1.24.3/
sudo apt-get install mysql-client libmysqlclient-dev libjpeg-dev openssl libssl-dev libdate-manip-perl libphp-serialization-perl libcache-mmap-perl libgnutls-dev
sudo perl -MCPAN -e "install Sys::Mmap"
./configure --with-webdir=/usr/share/zoneminder --with-cgidir=/usr/lib/cgi-bin --with-webuser=www-data --with-webgroup=www-data --with-ffmpeg=/usr/local/lib CPPFLAGS="-D__STDC_CONSTANT_MACROS"
make
sudo make install
echo "create database zm" | mysql -u root -p$MYSQL_ROOTPW mysql
mysql -u root -p$MYSQL_ROOTPW mysql < ./db/zm_create.sql
echo "grant select,insert,update,delete on zm.* to 'zmuser'@localhost identified by 'zmpass'" | mysql -u root -p$MYSQL_ROOTPW zm
mysqladmin -u root -p$MYSQL_ROOTPW reload
sudo zmpkg.pl start
cd $HOMEDIR
Native iPhone and iPad control for ZoneMinder with eyeZm, the premiere iOS app for use with ZoneMinder.

Visit http://eyezm.com for more info, and subscribe to our RSS feed at http://eyezm.com/rssfeed.xml for news and updates.
vraa
Posts: 31
Joined: Mon May 23, 2011 6:28 am

Re: ZM 1.24.3 + ffmpeg w/ libx264 install script for Ubuntu

Post by vraa »

I am going through your typed up tutorial and comparing it to the one here
http://www.zoneminder.com/wiki/index.ph ... _Cambozola

Does yours not setup ZM as a service?
Thanks for your time!
User avatar
erict35
Posts: 12
Joined: Thu May 26, 2011 9:08 am
Location: Rennes FRANCE

Re: ZM 1.24.3 + ffmpeg w/ libx264 install script for Ubuntu

Post by erict35 »

Hi

I have installed Ubuntu 11.04 and the old ZoneMinder package with success but I try to compile the last version (1.24.4) on a new Ubuntu 11.04

I'm using your script but I have this message :
ffmpeg -codecs | grep 264
ffmpeg: relocation error: ffmpeg: symbol av_log_set_flags, version LIBAVUTIL_50 not defined in file libavutil.so.50 with link time reference


Did you try to compile ZoneMinder 1.24.4 on Ubuntu 11.04 ?

Best Regards
Eric
User avatar
asturgeon
Posts: 23
Joined: Fri Apr 15, 2011 12:10 am

Re: ZM 1.24.3 + ffmpeg w/ libx264 install script for Ubuntu

Post by asturgeon »

erict35 wrote:Hi

I have installed Ubuntu 11.04 and the old ZoneMinder package with success but I try to compile the last version (1.24.4) on a new Ubuntu 11.04

I'm using your script but I have this message :
ffmpeg -codecs | grep 264
ffmpeg: relocation error: ffmpeg: symbol av_log_set_flags, version LIBAVUTIL_50 not defined in file libavutil.so.50 with link time reference


Did you try to compile ZoneMinder 1.24.4 on Ubuntu 11.04 ?

Best Regards
Eric
Just fired up a fresh Ubuntu Natty (11.04) 64-bit and installed perfectly with the script:

Code: Select all

ubuntu@ip-10-168-157-25:~$ ffmpeg -codecs | grep 264
ffmpeg version git-N-29954-g33651e3, Copyright (c) 2000-2011 the FFmpeg developers
  built on Jun  2 2011 06:41:48 with gcc 4.5.2
  configuration: --enable-gpl --enable-version3 --enable-nonfree --enable-postproc --enable-pthreads --enable-libx264 --enable-libxvid --enable-x11grab --enable-shared
  libavutil    50. 41. 0 / 50. 41. 0
  libavcodec   52.121. 0 / 52.121. 0
  libavformat  52.108. 0 / 52.108. 0
  libavdevice  52.  4. 0 / 52.  4. 0
  libavfilter   1. 78. 0 /  1. 78. 0
  libswscale    0. 14. 0 /  0. 14. 0
  libpostproc  51.  2. 0 / 51.  2. 0
 D V D  h264            H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10
  EV    libx264         libx264 H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10
I just edited the script to fetch 1.24.4 instead. Based on your error message, it looks like you may have had libav* already installed, and then you recompiled ffmpeg which compiled against a new version of libav* that is now causing a problem. This script will only work for a fresh Ubuntu install that does not have FFMPEG installed (or anything else for that matter).

For reference, I am using Ubuntu's Amazon EC2 images... there may be differences in their Server and Client distributions, so let me know if you tried this on a brand new install.
Native iPhone and iPad control for ZoneMinder with eyeZm, the premiere iOS app for use with ZoneMinder.

Visit http://eyezm.com for more info, and subscribe to our RSS feed at http://eyezm.com/rssfeed.xml for news and updates.
rangerbob
Posts: 61
Joined: Sat Jun 06, 2009 3:40 am

Re: ZM 1.24.3 + ffmpeg w/ libx264 install script for Ubuntu

Post by rangerbob »

I tried this on my Debian
2.6.26-2-686
squeeze

I grabbed the odd warnings. it gives you a idea where mine was failing. with out the long drawn out parts.. I am missing a step.. you will note all the warrnings are with libavformat libavcodec libavutil libavfilter libswscale. I have simular with my 1.24.4 attempt.

Code: Select all

libxvidcore4-dev is already the newest version.
The following packages were automatically installed and are no longer required:
  libstdc++6-4.3-dev g++-4.3
Use 'apt-get autoremove' to remove them.
The following extra packages will be installed:
  git liberror-perl libpopt-dev libpopt0 libx11-6 libxcb1 libxcb1-dev libxfixes3 rsync zlib1g
Suggested packages:
  git-doc git-arch git-cvs git-svn git-email git-daemon-run git-gui gitk gitweb latex2html
The following packages will be REMOVED:
  libxcb-xlib0 libxcb-xlib0-dev
The following NEW packages will be installed:
  checkinstall git git-core liberror-perl rsync texi2html yasm
The following packages will be upgraded:
  libpopt-dev libpopt0 libx11-6 libx11-dev libxcb1 libxcb1-dev libxfixes-dev libxfixes3 pkg-config zlib1g zlib1g-dev
11 upgraded, 7 newly installed, 2 to remove and 608 not upgraded.
Need to get 11.2MB of archives.
After this operation, 13.8MB of additional disk space will be used.
Do you want to continue [Y/n]? y
WARNING: The following packages cannot be authenticated!
  libxcb1-dev libx11-dev libx11-6 libxcb1 zlib1g-dev zlib1g libpopt-dev libpopt0 checkinstall git git-core libxfixes-dev libxfixes3
  pkg-config rsync texi2html yasm

:134: warning: âtrackâ is deprecated (declared at libavformat/avformat.h:719)
libavformat/metadata_compat.c:135: warning: âgenreâ is deprecated (declared at libavformat/avformat.h:720)
libavformat/metadata_compat.c:135: warning: âgenreâ is deprecated (declared at libavformat/avformat.h:720)
libavformat/metadata_compat.c:135: warning: âgenreâ is deprecated (declared at libavformat/avformat.h:720)
libavformat/metadata_compat.c:137: warning: âtitleâ is deprecated (declared at libavformat/avformat.h:680)
libavformat/metadata_compat.c:137: warning: âtitleâ is deprecated (declared at libavformat/avformat.h:680)
libavformat/metadata_compat.c:137: warning: âtitleâ is deprecated (declared at libavformat/avformat.h:680)
libavformat/metadata_compat.c:139: warning: ânameâ is deprecated (declared at libavformat/avformat.h:663)
libavformat/metadata_compat.c:139: warning: ânameâ is deprecated (declared at libavformat/avformat.h:663)
libavformat/metadata_compat.c:139: warning: ânameâ is deprecated (declared at libavformat/avformat.h:663)
libavformat/metadata_compat.c:140: warning: âprovider_nameâ is deprecated (declared at libavformat/avformat.h:662)
libavformat/metadata_compat.c:140: warning: âprovider_nameâ is deprecated (declared at libavformat/avformat.h:662)
libavformat/metadata_compat.c:140: warning: âprovider_nameâ is deprecated (declared at libavformat/avformat.h:662)
libavformat/metadata_compat.c:143: warning: âlanguageâ is deprecated (declared at libavformat/avformat.h:552)
libavformat/metadata_compat.c:143: warning: âlanguageâ is deprecated (declared at libavformat/avformat.h:552)
libavformat/metadata_compat.c:143: warning: âlanguageâ is deprecated (declared at libavformat/avformat.h:552)
libavformat/metadata_compat.c:144: warning: âfilenameâ is deprecated (declared at libavformat/avformat.h:575)
libavformat/metadata_compat.c:144: warning: âfilenameâ is deprecated (declared at libavformat/avformat.h:575)
libavformat/metadata_compat.c:144: warning: âfilenameâ is deprecated (declared at libavformat/avformat.h:575)
CC      libavformat/microdvddec.o
CC      libavformat/microdvdenc.o


o
CC      libavformat/psxstr.o
CC      libavformat/pva.o
CC      libavformat/qcp.o
CC      libavformat/r3d.o
CC      libavformat/rawdec.o
CC      libavformat/rawenc.o
CC      libavformat/rawvideodec.o
CC      libavformat/rdt.o
libavformat/rdt.c: In function ârdt_parse_packetâ:
libavformat/rdt.c:304: warning: passing argument 2 of âffio_init_contextâ discards qualifiers from pointer target type
libavformat/avio_internal.h:26: note: expected âunsigned char *â but argument is of type âconst uint8_t *â
CC      libavformat/riff.o
CC      libavformat/rl2.o
CC      libavformat/rm.o
CC      libavformat/rmdec.o
libavformat/rmdec.c: In function ârm_read_packetâ:
libavformat/rmdec.c:823: warning: âstâ may be used uninitialized in this function
CC      libavformat/rmenc.o
CC      libavformat/rpl.o
CC      libavformat/rso.o
CC      libavformat/rsodec.o
CC      libavformat/rsoenc.o
CC      libavformat/rtmppkt.o
CC      libavformat/rtmpproto.o
libavformat/rtmpproto.c: In function âget_packetâ:
libavformat/rtmpproto.c:754: warning: assignment discards qualifiers from pointer target type
CC      libavformat/rtp.o
CC      libavformat/rtpdec.o
CC      libavformat/rtpdec_amr.o
CC      libavformat/rtpdec_asf.o
libavformat/rtpdec_asf.c: In function âasfrtp_parse_packetâ:
libavformat/rtpdec_asf.c:180: warning: passing argument 2 of âffio_init_contextâ discards qualifiers from pointer target type
libavformat/avio_internal.h:26: note: expected âunsigned char *â but argument is of type âconst uint8_t *â

CC      libavformat/rtpenc_xiph.o
CC      libavformat/rtpproto.o
CC      libavformat/rtsp.o
libavformat/rtsp.c: In function ârtsp_parse_rangeâ:
libavformat/rtsp.c:591: warning: cast discards qualifiers from pointer target type
libavformat/rtsp.c:595: warning: cast discards qualifiers from pointer target type
libavformat/rtsp.c: In function ârtsp_parse_transportâ:
libavformat/rtsp.c:680: warning: cast discards qualifiers from pointer target type
libavformat/rtsp.c: In function âff_rtsp_make_setup_requestâ:
libavformat/rtsp.c:1062: warning: ârtxâ may be used uninitialized in this function
CC      libavformat/rtspdec.o
CC      libavformat/rtspenc.o
CC      libavformat/sapdec.o

CC      libavcodec/aac_adtstoasc_bsf.o
libavcodec/aac_adtstoasc_bsf.c: In function âaac_adtstoasc_filterâ:
libavcodec/aac_adtstoasc_bsf.c:51: warning: cast discards qualifiers from pointer target type
libavcodec/aac_adtstoasc_bsf.c:104: warning: cast discards qualifiers from pointer target type
CC      libavcodec/aac_parser.o
CC      libavcodec/aacadtsdec.o
CC      libavcodec/aaccoder.o
libavcodec/aaccoder.c: In function âsearch_for_quantizers_faacâ:
libavcodec/aaccoder.c:948: warning: âbâ may be used uninitialized in this function
CC      libavcodec/aacdec.o
CC      libavcodec/aacenc.o
CC      libavcodec/aacps.o
libavcodec/aacps.c: In function âhybrid_analysisâ:
libavcodec/aacps.c:369: warning: passing argument 3 of âhybrid4_8_12_cxâ from incompatible pointer type
libavcodec/aacps.c:338: note: expected âconst float (*)[7][2]â but argument is of type âfloat (*)[7][2]â
libavcodec/aacps.c:370: warning: passing argument 3 of âhybrid4_8_12_cxâ from incompatible pointer type
libavcodec/aacps.c:338: note: expected âconst float (*)[7][2]â but argument is of type âfloat (*)[7][2]â
libavcodec/aacps.c:371: warning: passing argument 3 of âhybrid4_8_12_cxâ from incompatible pointer type
libavcodec/aacps.c:338: note: expected âconst float (*)[7][2]â but argument is of type âfloat (*)[7][2]â
libavcodec/aacps.c:372: warning: passing argument 3 of âhybrid4_8_12_cxâ from incompatible pointer type
libavcodec/aacps.c:338: note: expected âconst float (*)[7][2]â but argument is of type âfloat (*)[7][2]â
libavcodec/aacps.c:373: warning: passing argument 3 of âhybrid4_8_12_cxâ from incompatible pointer type
libavcodec/aacps.c:338: note: expected âconst float (*)[7][2]â but argument is of type âfloat (*)[7][2]â
libavcodec/aacps.c:381: warning: passing argument 3 of âhybrid6_cxâ from incompatible pointer type
libavcodec/aacps.c:303: note: expected âconst float (*)[7][2]â but argument is of type âfloat (*)[7][2]â
libavcodec/aacps.c: In function âstereo_processingâ:
libavcodec/aacps.c:813: warning: initialization from incompatible pointer type
libavcodec/aacps.c: In function âff_ps_applyâ:
libavcodec/aacps.c:986: warning: passing argument 3 of âdecorrelationâ from incompatible pointer type

CC      libavutil/md5.o
CC      libavutil/mem.o
CC      libavutil/opt.o
CC      libavutil/parseutils.o
libavutil/parseutils.c: In function âav_parse_video_sizeâ:
libavutil/parseutils.c:109: warning: assignment discards qualifiers from pointer target type
libavutil/parseutils.c: In function âav_parse_timeâ:
libavutil/parseutils.c:566: warning: cast discards qualifiers from pointer target type
CC      libavutil/pixdesc.o
CC      libavutil/random_seed.o
CC      libavutil/rational.o
CC      libavutil/rc4.o
CC      libavutil/samplefmt.o

libavfilter/libmpcodecs/vf_spp.c:301: warning: dereferencing pointer â({anonymous})â does break strict-aliasing rules
libavfilter/libmpcodecs/vf_spp.c:301: note: initialized from here
CC      libavfilter/libmpcodecs/vf_swapuv.o
CC      libavfilter/libmpcodecs/vf_telecine.o
CC      libavfilter/libmpcodecs/vf_test.o
CC      libavfilter/libmpcodecs/vf_tile.o
libavfilter/libmpcodecs/vf_tile.c: In function âvf_openâ:
libavfilter/libmpcodecs/vf_tile.c:289: warning: assignment discards qualifiers from pointer target type
CC      libavfilter/libmpcodecs/vf_tinterlace.o
CC      libavfilter/libmpcodecs/vf_unsharp.o
libavfilter/libmpcodecs/vf_unsharp.c: In function âconfigâ:
libavfilter/libmpcodecs/vf_unsharp.c:140: warning: assignment discards qualifiers from pointer target type
libavfilter/libmpcodecs/vf_unsharp.c:149: warning: assignment discards qualifiers from pointer target type
CC      libavfilter/libmpcodecs/vf_uspp.o
CC      libavfilter/l

In file included from libswscale/swscale.c:1451:
libswscale/swscale_template.c: In function âhyscale_fast_MMX2â:
libswscale/swscale_template.c:2290: warning: initialization from incompatible pointer type
libswscale/swscale_template.c: In function âhcscale_fast_MMX2â:
libswscale/swscale_template.c:2440: warning: initialization from incompatible pointer type
libswscale/swscale_template.c: In function âsws_init_swScale_MMX2â:
libswscale/swscale_template.c:2987: warning: assignment from incompatible pointer type
libswscale/swscale_template.c:2988: warning: assignment from incompatible pointer type
libswscale/swscale_template.c:2990: warning: assignment from incompatible pointer type
libswscale/swscale_template.c:2992: warning: assignment from incompatible pointer type
libswscale/swscale_template.c:3039: warning: assignment from incompatible pointer type
libswscale/swscale_template.c:3040: warning: assignment from incompatible pointer type
libswscale/swscale_template.c:3042: warning: assignment from incompatible pointer type
libswscale/swscale_template.c:3044: warning: assignment from incompatible pointer type
libswscale/swscale.c: In function âplanarCopyWrapperâ:
libswscale/swscale.c:1931: warning: initialization discards qualifiers from pointer target type
libswscale/swscale.c:1933: warning: initialization discards qualifiers from pointer target type
libswscale/swscale.c:1976: warning: initialization discards qualifiers from pointer target type

make[2]: Entering directory `/root/ZoneMinder-1.24.3'
test -z "/usr/local/etc" || /bin/mkdir -p "/usr/local/etc"
 /usr/bin/install -c -m 644 zm.conf '/usr/local/etc'
make  install-data-hook
make[3]: Entering directory `/root/ZoneMinder-1.24.3'
( cd /usr/local/etc; chown asterisk:asterisk zm.conf; chmod 600 zm.conf )
( if ! test -e /var/run/zm; then mkdir -p /var/run/zm; fi; chown asterisk:asterisk /var/run/zm; chmod u+w /var/run/zm )
( if ! test -e /tmp/zm; then mkdir -p /tmp/zm; fi; chown asterisk:asterisk /tmp/zm; chmod u+w /tmp/zm )
( if ! test -e /var/log/zm; then mkdir -p /var/log/zm; fi; chown asterisk:asterisk /var/log/zm; chmod u+w /var/log/zm )
make[3]: Leaving directory `/root/ZoneMinder-1.24.3'
make[2]: Leaving directory `/root/ZoneMinder-1.24.3'
make[1]: Leaving directory `/root/ZoneMinder-1.24.3'
ERROR 1007 (HY000) at line 1: Can't create database 'zm'; database exists
Can't locate ZoneMinder.pm in @INC (@INC contains: /etc/perl /usr/local/lib/perl/5.10.1 /usr/local/share/perl/5.10.1 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.10 /usr/share/perl/5.10 /usr/local/lib/site_perl /usr/local/lib/perl/5.10.0 /usr/local/share/perl/5.10.0) at /usr/local/bin/zmpkg.pl line 46.
BEGIN failed--compilation aborted at /usr/local/bin/zmpkg.pl line 46.
User avatar
asturgeon
Posts: 23
Joined: Fri Apr 15, 2011 12:10 am

Re: ZM 1.24.3 + ffmpeg w/ libx264 install script for Ubuntu

Post by asturgeon »

Nah the warnings have nothing to do with it... they are just normal compilation warnings for FFMPEG, and it looked like it compiled fine.

The error is pretty straightforward by the looks of it... can't fine ZoneMinder.pm. Is it on your system? Where is it located?
Native iPhone and iPad control for ZoneMinder with eyeZm, the premiere iOS app for use with ZoneMinder.

Visit http://eyezm.com for more info, and subscribe to our RSS feed at http://eyezm.com/rssfeed.xml for news and updates.
rangerbob
Posts: 61
Joined: Sat Jun 06, 2009 3:40 am

Re: ZM 1.24.3 + ffmpeg w/ libx264 install script for Ubuntu

Post by rangerbob »

ZoneMinder.pm when I searched was in my Zoneminder dir

line 46

Code: Select all

# Include from system perl paths only
use ZoneMinder;
I am guessing this was the make install portion of the script but I am not sure. So what do I do from here

Code: Select all

:~/ZoneMinder-1.24.3/scripts/ZoneMinder/blib/lib# ls -lha
total 20K
drwxr-xr-x 4 root root 4.0K 2011-06-06 14:41 .
drwxr-xr-x 8 root root 4.0K 2011-06-06 14:41 ..
drwxr-xr-x 3 root root 4.0K 2011-06-06 14:41 auto
-rw-r--r-- 1 root root    0 2011-06-06 14:41 .exists
drwxr-xr-x 5 root root 4.0K 2011-06-06 14:41 ZoneMinder
-r--r--r-- 1 root root 3.6K 2008-07-25 05:48 ZoneMinder.pm
:~/ZoneMinder-1.24.3/scripts/ZoneMinder/blib/lib# 
User avatar
asturgeon
Posts: 23
Joined: Fri Apr 15, 2011 12:10 am

Re: ZM 1.24.3 + ffmpeg w/ libx264 install script for Ubuntu

Post by asturgeon »

rangerbob wrote:ZoneMinder.pm when I searched was in my Zoneminder dir

line 46

Code: Select all

# Include from system perl paths only
use ZoneMinder;
I am guessing this was the make install portion of the script but I am not sure. So what do I do from here

Code: Select all

:~/ZoneMinder-1.24.3/scripts/ZoneMinder/blib/lib# ls -lha
total 20K
drwxr-xr-x 4 root root 4.0K 2011-06-06 14:41 .
drwxr-xr-x 8 root root 4.0K 2011-06-06 14:41 ..
drwxr-xr-x 3 root root 4.0K 2011-06-06 14:41 auto
-rw-r--r-- 1 root root    0 2011-06-06 14:41 .exists
drwxr-xr-x 5 root root 4.0K 2011-06-06 14:41 ZoneMinder
-r--r--r-- 1 root root 3.6K 2008-07-25 05:48 ZoneMinder.pm
:~/ZoneMinder-1.24.3/scripts/ZoneMinder/blib/lib# 
If that's where ZoneMinder.pm is located, then it's not installed in your system... that's your home directory, so zmpkg won't find it there.

Did you run make install? If you run sudo make install in your ~/ZoneMinder-1.24.3 directory, what happens?
Native iPhone and iPad control for ZoneMinder with eyeZm, the premiere iOS app for use with ZoneMinder.

Visit http://eyezm.com for more info, and subscribe to our RSS feed at http://eyezm.com/rssfeed.xml for news and updates.
rangerbob
Posts: 61
Joined: Sat Jun 06, 2009 3:40 am

Re: ZM 1.24.3 + ffmpeg w/ libx264 install script for Ubuntu

Post by rangerbob »

to make sure I re ran everything step by step.

I configure, make, make install all with no issues

but when I try to run
:~/ZoneMinder-1.24.3# /usr/local/bin/zmpkg.pl start

Code: Select all

~/ZoneMinder-1.24.3# /usr/local/bin/zmpkg.pl start
Can't locate ZoneMinder.pm in @INC (@INC contains: /etc/perl /usr/local/lib/perl/5.10.1 /usr/local/share/perl/5.10.1 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.10 /usr/share/perl/5.10 /usr/local/lib/site_perl /usr/local/lib/perl/5.10.0 /usr/local/share/perl/5.10.0) at /usr/local/bin/zmpkg.pl line 46.
BEGIN failed--compilation aborted at /usr/local/bin/zmpkg.pl line 46.
:~/ZoneMinder-1.24.3#
maybe I need to reboot

you can see above line 46 calls use zoneminder

not sure what that means where it calls this..

anyone?
nojstevens
Posts: 22
Joined: Sat Jul 04, 2009 4:53 pm

Re: ZM 1.24.3 + ffmpeg w/ libx264 install script for Ubuntu

Post by nojstevens »

Hello,

This runs ok up to the CPAN bit where I get the message that I need to specify a CPAN Mirror as I would not allow it to connect to the internet. I'm not sure what to do - the guest can see the internet?

Thanks for any help - I just purchased the eyeZM product for my iPad so I am keen to get this working with ZM.

Jon
nojstevens
Posts: 22
Joined: Sat Jul 04, 2009 4:53 pm

Re: ZM 1.24.3 + ffmpeg w/ libx264 install script for Ubuntu

Post by nojstevens »

I did it again from scratch on a brand new natty server and it worked. Just need to figure out what the url is now? Should zm start automatically at boot?

If I type sudo /usr/local/bin/zmpkg.pl start then i get no error message, all the logs look like all is ok, but in my past zm installs ive gone to http://<myipaddress/zm and got the ZM interface, i'm not getting that here. What url do I need to use to get this page?

Jon
User avatar
asturgeon
Posts: 23
Joined: Fri Apr 15, 2011 12:10 am

Re: ZM 1.24.3 + ffmpeg w/ libx264 install script for Ubuntu

Post by asturgeon »

nojstevens wrote:I did it again from scratch on a brand new natty server and it worked. Just need to figure out what the url is now? Should zm start automatically at boot?

If I type sudo /usr/local/bin/zmpkg.pl start then i get no error message, all the logs look like all is ok, but in my past zm installs ive gone to http://<myipaddress/zm and got the ZM interface, i'm not getting that here. What url do I need to use to get this page?

Jon
Ya, I have seen that from time to time before... it's usually best to let CPAN answer questions for you, so it looks like that worked for you the second time.

For ZM starting at boot, I didn't include anything to do that in my script.. but you can just add sudo zmpkg.pl start at the end of /etc/rc.local (or equivalent) and it should start it for you.

Going to the ZM page is independent of zmpkg starting successfully or not, so if you aren't seeing it there, it's an Apache configuration problem. You will have the ZM part to your apache configuration since everyone's configuration is different. An example block that you can add in your apache configuration is:

Alias /zm "/usr/share/zoneminder"
<Directory "/usr/share/zoneminder">
Options FollowSymLinks
AllowOverride All
</Directory>

this will setup /zm to point to /usr/share/zoneminder, which is probably where it's installed for you. Try adding that to your apache configuration and restarting apache. I can probably augment the script to include that portion.
Native iPhone and iPad control for ZoneMinder with eyeZm, the premiere iOS app for use with ZoneMinder.

Visit http://eyezm.com for more info, and subscribe to our RSS feed at http://eyezm.com/rssfeed.xml for news and updates.
bb99
Posts: 943
Joined: Wed Apr 02, 2008 12:04 am

Re: ZM 1.24.3 + ffmpeg w/ libx264 install script for Ubuntu

Post by bb99 »

Just curious: does the zoneminder.conf (/etc/httpd/conf.d/zoneminder.conf ?) still have the 'Deny from All' line in 1.24.3; I haven't upgraded yet.
nojstevens
Posts: 22
Joined: Sat Jul 04, 2009 4:53 pm

Re: ZM 1.24.3 + ffmpeg w/ libx264 install script for Ubuntu

Post by nojstevens »

Thanks - that got it working. I edited the /etc/apache2/apache2.conf file with the text you supplied and it works. Thank you - on to the next bit now....

Jon
User avatar
asturgeon
Posts: 23
Joined: Fri Apr 15, 2011 12:10 am

Re: ZM 1.24.3 + ffmpeg w/ libx264 install script for Ubuntu

Post by asturgeon »

bb99 wrote:Just curious: does the zoneminder.conf (/etc/httpd/conf.d/zoneminder.conf ?) still have the 'Deny from All' line in 1.24.3; I haven't upgraded yet.
Don't see anything like that in their example zoneminder.conf file

Code: Select all

<VirtualHost *:80>
    ServerName zm.local
    ServerAdmin webmaster@localhost

    DocumentRoot "/usr/share/zoneminder"
    <Directory "/usr/share/zoneminder">
        Options FollowSymLinks
        AllowOverride All
    </Directory>

    ScriptAlias /cgi-bin/ "/usr/lib/cgi-bin"
    <Directory "/usr/lib/cgi-bin">
        Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
        AllowOverride All
    </Directory>

    # Use the first option to have Apache logs written to the general log
    # directory, or the second to have them written to the regular Apache
    # directory (you may have to change the path to that used on your system)
    ErrorLog /var/log/zm/apache-error.log
    ErrorLog /var/log/httpd/zm-error.log

    # Possible values include: debug, info, notice, warn, error, crit,
    # alert, emerg.
    LogLevel warn

    # Use the first option to have Apache logs written to the general log
    # directory, or the second to have them written to the regular Apache
    # directory (you may have to change the path to that used on your system)
    CustomLog /var/log/zm/apache-access.log combined
    CustomLog /var/log/httpd/zm-access.log combined

</VirtualHost>
Native iPhone and iPad control for ZoneMinder with eyeZm, the premiere iOS app for use with ZoneMinder.

Visit http://eyezm.com for more info, and subscribe to our RSS feed at http://eyezm.com/rssfeed.xml for news and updates.
Locked