Zoneminder 1.24.3/1.24.4 on Fedora 15

Forum for questions and support relating to the 1.24.x releases only.
danodemano
Posts: 14
Joined: Mon Mar 14, 2011 10:00 pm
Location: Columbus, OH

Zoneminder 1.24.3/1.24.4 on Fedora 15

Post by danodemano »

Good evening all!

Last night I needed to scratch and itch and upgrade my Fedora 14 box to Fedora 15. For the most part the upgrade went well but I have a few things that need worked out, Zoneminder being one of them.

On Fedora 14 I had installed the ZoneMinder RPM from RPMFusion and this worked great. When the box upgraded it did upgrade ZoneMinder as well to version 1.24.3 (it was running 1.24.2) but the install seems broken. I am unable to start the zoneminder service from /etc/init.d/zoneminder and can find almost zero logs. I get this in the /var/log/messages:

Code: Select all

Jun  3 18:56:22 fedoraserver systemd[1]: zoneminder.service: control process exited, code=exited status=255
Jun  3 18:56:22 fedoraserver systemd[1]: Unit zoneminder.service entered failed state.
and this if I do a '/etc/init.d/zoneminder status' but nothing else useful.

Code: Select all

[root@fedoraserver ~]# /etc/init.d/zoneminder status
zoneminder.service - SYSV: ZoneMinder is the top Linux video camera security and surveillance solution. ZoneMinder is intended for use in single or multi-camera video security applications.Copyright: Philip Coombes, Corey DeLasaux 2003-2008
	  Loaded: loaded (/etc/rc.d/init.d/zoneminder)
	  Active: failed since Fri, 03 Jun 2011 16:44:23 -0400; 1h 42min ago
	 Process: 25719 ExecStart=/etc/rc.d/init.d/zoneminder start (code=exited, status=255)
	  CGroup: name=systemd:/system/zoneminder.service
zoneminder.service - SYSV: ZoneMinder is the top Linux video camera security and surveillance solution. ZoneMinder is intended for use in single or multi-camera video security applications.Copyright: Philip Coombes, Corey DeLasaux 2003-2008
	  Loaded: loaded (/etc/rc.d/init.d/zoneminder)
	  Active: failed since Fri, 03 Jun 2011 16:44:23 -0400; 1h 42min ago
	 Process: 25719 ExecStart=/etc/rc.d/init.d/zoneminder start (code=exited, status=255)
	  CGroup: name=systemd:/system/zoneminder.service
Bareword "PROT_READ" not allowed while "strict subs" in use at /usr/share/perl5/vendor_perl/ZoneMinder/Memory/Mapped.pm line 91.
Bareword "PROT_WRITE" not allowed while "strict subs" in use at /usr/share/perl5/vendor_perl/ZoneMinder/Memory/Mapped.pm line 91.
Bareword "MAP_SHARED" not allowed while "strict subs" in use at /usr/share/perl5/vendor_perl/ZoneMinder/Memory/Mapped.pm line 91.
Compilation failed in require at /usr/share/perl5/vendor_perl/ZoneMinder/Memory.pm line 120.
Compilation failed in require at /usr/share/perl5/vendor_perl/ZoneMinder.pm line 37.
BEGIN failed--compilation aborted at /usr/share/perl5/vendor_perl/ZoneMinder.pm line 37.
Compilation failed in require at /usr/bin/zmpkg.pl line 46.
BEGIN failed--compilation aborted at /usr/bin/zmpkg.pl line 46.
ZoneMinder is stopped
I then though well I will just build ZoneMinder 1.24.4 from source and go that route, but it won't even build properly. When I do the ./configure that works but when I do a make install (WITHOUT ffmpeg) it bombs:

Code: Select all

In file included from zm_mpeg.h:23:0,
                 from zm_stream.h:27,
                 from zm_event.h:39,
                 from zm_zone.h:27,
                 from zm_monitor.h:26,
                 from zmc.cpp:28:
zm_ffmpeg.h:33:2: error: #error "No location for avutils.h found"
zm_ffmpeg.h:40:2: error: #error "No location for avcodec.h found"
zm_ffmpeg.h:47:2: error: #error "No location for avformat.h found"
zm_ffmpeg.h:55:2: error: #error "No location for swscale.h found"
In file included from zm_stream.h:27:0,
                 from zm_event.h:39,
                 from zm_zone.h:27,
                 from zm_monitor.h:26,
                 from zmc.cpp:28:
zm_mpeg.h:43:7: error: use of enum ‘PixelFormat’ without previous declaration
zm_mpeg.h:44:2: error: ‘AVOutputFormat’ does not name a type
zm_mpeg.h:45:2: error: ‘AVFormatContext’ does not name a type
zm_mpeg.h:46:2: error: ‘AVStream’ does not name a type
zm_mpeg.h:47:2: error: ‘AVFrame’ does not name a type
zm_mpeg.h:48:2: error: ‘AVFrame’ does not name a type
make[1]: *** [zmc.o] Error 1
Any help tracking down the problem(s) would be greatly appreciated cause I have had zero luck finding anything useful....and I don't really know where else to look. Thanks so much!!!
User avatar
cordel
Posts: 5210
Joined: Fri Mar 05, 2004 4:47 pm
Location: /USA/Washington/Seattle

Re: Zoneminder 1.24.3/1.24.4 on Fedora 15

Post by cordel »

Fedora has gone strait to using system unit and dropped the sysV startscripts.
I'll be working on a new Unit start script for ZM shortly.
Mean time you can start manually with zmpkg.pl start.
danodemano
Posts: 14
Joined: Mon Mar 14, 2011 10:00 pm
Location: Columbus, OH

Re: Zoneminder 1.24.3/1.24.4 on Fedora 15

Post by danodemano »

Thanks so much for the quick reply! I tried what you suggested however and it doesn't seem to work:

Code: Select all

[root@fedoraserver init.d]# /usr/bin/zmpkg.pl start
Bareword "PROT_READ" not allowed while "strict subs" in use at /usr/share/perl5/vendor_perl/ZoneMinder/Memory/Mapped.pm line 91.
Bareword "PROT_WRITE" not allowed while "strict subs" in use at /usr/share/perl5/vendor_perl/ZoneMinder/Memory/Mapped.pm line 91.
Bareword "MAP_SHARED" not allowed while "strict subs" in use at /usr/share/perl5/vendor_perl/ZoneMinder/Memory/Mapped.pm line 91.
Compilation failed in require at /usr/share/perl5/vendor_perl/ZoneMinder/Memory.pm line 120.
Compilation failed in require at /usr/share/perl5/vendor_perl/ZoneMinder.pm line 37.
BEGIN failed--compilation aborted at /usr/share/perl5/vendor_perl/ZoneMinder.pm line 37.
Compilation failed in require at /usr/bin/zmpkg.pl line 46.
BEGIN failed--compilation aborted at /usr/bin/zmpkg.pl line 46.
Thanks again.
User avatar
cordel
Posts: 5210
Joined: Fri Mar 05, 2004 4:47 pm
Location: /USA/Washington/Seattle

Re: Zoneminder 1.24.3/1.24.4 on Fedora 15

Post by cordel »

Check and make sure your database is running.
danodemano
Posts: 14
Joined: Mon Mar 14, 2011 10:00 pm
Location: Columbus, OH

Re: Zoneminder 1.24.3/1.24.4 on Fedora 15

Post by danodemano »

The MySQL service? Yes, it's running:

Code: Select all

[root@fedoraserver ~]# service mysqld status
mysqld.service - LSB: start and stop MySQL server
          Loaded: loaded (/etc/rc.d/init.d/mysqld)
          Active: active (running) since Thu, 02 Jun 2011 21:22:41 -0400; 3 days ago
        Main PID: 1814 (mysqld)
          CGroup: name=systemd:/system/mysqld.service
                  â 1465 /bin/sh /usr/bin/mysqld_safe --datadir=/var/lib/my...
                  â 1814 /usr/libexec/mysqld --basedir=/usr --datadir=/var/...
[root@fedoraserver ~]#
I don't have any trouble logging into the ZoneMinder web interface either. It just says the service is stopped at the top and I can't start it:

Code: Select all

ZoneMinder Console - Stopped - v1.24.3
Thanks again!
kolaCZek
Posts: 1
Joined: Tue Jun 07, 2011 8:47 am

Re: Zoneminder 1.24.3/1.24.4 on Fedora 15

Post by kolaCZek »

Same problem on Fedora 15.

Code: Select all

[root@pimserver ~]# /usr/bin/zmpkg.pl start
Bareword "PROT_READ" not allowed while "strict subs" in use at /usr/share/perl5/vendor_perl/ZoneMinder/Memory/Mapped.pm line 91.
Bareword "PROT_WRITE" not allowed while "strict subs" in use at /usr/share/perl5/vendor_perl/ZoneMinder/Memory/Mapped.pm line 91.
Bareword "MAP_SHARED" not allowed while "strict subs" in use at /usr/share/perl5/vendor_perl/ZoneMinder/Memory/Mapped.pm line 91.
Compilation failed in require at /usr/share/perl5/vendor_perl/ZoneMinder/Memory.pm line 120.
Compilation failed in require at /usr/share/perl5/vendor_perl/ZoneMinder.pm line 37.
BEGIN failed--compilation aborted at /usr/share/perl5/vendor_perl/ZoneMinder.pm line 37.
Compilation failed in require at /usr/bin/zmpkg.pl line 46.
BEGIN failed--compilation aborted at /usr/bin/zmpkg.pl line 46.
What to do? Help please... :cry:
RuZa
Posts: 1
Joined: Sat Jun 11, 2011 8:48 pm

Re: Zoneminder 1.24.3/1.24.4 on Fedora 15

Post by RuZa »

Try it in a file /usr/share/perl5/vendor_perl/ZoneMinder/Memory/Mapped.pm
at the beginning of line 27 to put #
#use strict;
danodemano
Posts: 14
Joined: Mon Mar 14, 2011 10:00 pm
Location: Columbus, OH

Re: Zoneminder 1.24.3/1.24.4 on Fedora 15

Post by danodemano »

Great idea, but no go:

Code: Select all

[root@fedoraserver ~]# /usr/bin/zmpkg.pl start
[root@fedoraserver ~]# 
There is no error on the command line but this is in /var/log/messages:

Code: Select all

Jun 20 20:06:40 fedoraserver zmpkg[11115]: INF [Command: start]
Jun 20 20:06:40 fedoraserver zmfix[11124]: ERR [Config mismatch, expected 197 items, read 183. Try running 'zmupdate.pl -f' to reload config.]
Jun 20 20:06:40 fedoraserver zmpkg[11115]: ERR [Unable to run "sudo -u apache /usr/bin/zmfix", output is ""]
I was afraid to run that command as I didn't know what it did. Will running this let the service start?
KeithB
Posts: 77
Joined: Thu Jun 07, 2007 4:23 pm
Location: uk

Re: Zoneminder 1.24.3/1.24.4 on Fedora 15

Post by KeithB »

I've not quite got it working on F15 yet but the compile errors you received are all fixed by putting
CFLAGS=-D__STDC_CONSTANT_MACROS
into the zoneminder ./configure parameters
User avatar
zoneminder
Site Admin
Posts: 5215
Joined: Wed Jul 09, 2003 2:07 pm
Location: Bristol, UK
Contact:

Re: Zoneminder 1.24.3/1.24.4 on Fedora 15

Post by zoneminder »

I have done trial builds on Fedora 15 without any issue so am curious as to what is causing these problems. Are you running 32 or 64 bit?

Even though Fedora 15 has gone to systemd the existing sysv init scripts appear to still work as well.
Phil
danodemano
Posts: 14
Joined: Mon Mar 14, 2011 10:00 pm
Location: Columbus, OH

Re: Zoneminder 1.24.3/1.24.4 on Fedora 15

Post by danodemano »

I'm running 64bit. It was an upgrade from Fedora 14 so maybe that has something to do with it?
KeithB
Posts: 77
Joined: Thu Jun 07, 2007 4:23 pm
Location: uk

Re: Zoneminder 1.24.3/1.24.4 on Fedora 15

Post by KeithB »

kolaCZek wrote:Same problem on Fedora 15.

Code: Select all

[root@pimserver ~]# /usr/bin/zmpkg.pl start
Bareword "PROT_READ" not allowed while "strict subs" in use at /usr/share/perl5/vendor_perl/ZoneMinder/Memory/Mapped.pm line 91.
Bareword "PROT_WRITE" not allowed while "strict subs" in use at /usr/share/perl5/vendor_perl/ZoneMinder/Memory/Mapped.pm line 91.
Bareword "MAP_SHARED" not allowed while "strict subs" in use at /usr/share/perl5/vendor_perl/ZoneMinder/Memory/Mapped.pm line 91.
Compilation failed in require at /usr/share/perl5/vendor_perl/ZoneMinder/Memory.pm line 120.
Compilation failed in require at /usr/share/perl5/vendor_perl/ZoneMinder.pm line 37.
BEGIN failed--compilation aborted at /usr/share/perl5/vendor_perl/ZoneMinder.pm line 37.
Compilation failed in require at /usr/bin/zmpkg.pl line 46.
BEGIN failed--compilation aborted at /usr/bin/zmpkg.pl line 46.
What to do? Help please... :cry:
In perl5/vendor_perl/ZoneMinder/Memory/Mapped.pm
change

Code: Select all

my $mmap_addr = mmap( $mmap, $size, PROT_READ|PROT_WRITE, MAP_SHARED, \*MMAP );

Code: Select all

to my $mmap_addr = mmap( $mmap, $size, *PROT_READ|*PROT_WRITE, *MAP_SHARED, \*MMAP );
That should at least get zoneminder to start.
danodemano
Posts: 14
Joined: Mon Mar 14, 2011 10:00 pm
Location: Columbus, OH

Re: Zoneminder 1.24.3/1.24.4 on Fedora 15

Post by danodemano »

Still no dice:

Code: Select all

Jun 21 14:18:49 fedoraserver zmpkg[11612]: INF [Command: start]
Jun 21 14:18:50 fedoraserver zmfix[11621]: ERR [Config mismatch, expected 197 items, read 183. Try running 'zmupdate.pl -f' to reload config.]
Jun 21 14:18:50 fedoraserver zmpkg[11612]: ERR [Unable to run "sudo -u apache /usr/bin/zmfix", output is ""]
Jun 21 14:18:53 fedoraserver zmpkg[11623]: INF [Command: status]
Jun 21 14:19:46 fedoraserver zmpkg[11644]: INF [Command: start]
Jun 21 14:19:46 fedoraserver zmfix[11653]: ERR [Config mismatch, expected 197 items, read 183. Try running 'zmupdate.pl -f' to reload config.]
Jun 21 14:19:46 fedoraserver zmpkg[11644]: ERR [Unable to run "sudo -u apache /usr/bin/zmfix", output is ""]
Jun 21 14:19:48 fedoraserver zmpkg[11680]: INF [Command: status]
I tried it both ways with the use strict; commented out and with it uncommented and it throws the above error either way.
User avatar
zoneminder
Site Admin
Posts: 5215
Joined: Wed Jul 09, 2003 2:07 pm
Location: Bristol, UK
Contact:

Re: Zoneminder 1.24.3/1.24.4 on Fedora 15

Post by zoneminder »

Have you tried actually running 'zmupdate.pl -f' as it suggests? It should do it automatically when you run zmpkg.pl but you can do it manually as well.
Phil
danodemano
Posts: 14
Joined: Mon Mar 14, 2011 10:00 pm
Location: Columbus, OH

Re: Zoneminder 1.24.3/1.24.4 on Fedora 15

Post by danodemano »

I hadn't because I didn't know what it did but I just ran it and the service appears to have finally fired up:

Code: Select all

[root@fedoraserver ~]# /usr/bin/zmpkg.pl start
[root@fedoraserver ~]# /usr/bin/zmpkg.pl status
running
[root@fedoraserver ~]#
Seems to be running fine also, I can see my video. I wasn't sure about this error though if it was anything to worry about, ERR ['zmwatch.pl ' exited abnormally, exit status 9:

Code: Select all

Jun 21 17:43:02 fedoraserver zmpkg[3485]: INF [Command: start]
Jun 21 17:43:02 fedoraserver zmfix[3494]: INF [New Debug Level = 5, New Debug Log = /tmp/zm_debug.log.03494]
Jun 21 17:43:02 fedoraserver zmfix[3494]: INF [Resetting permissions on /dev/video0 to 20666]
Jun 21 17:43:02 fedoraserver zmdc[3499]: INF [Server starting at 11/06/21 17:43:02]
Jun 21 17:43:05 fedoraserver zmdc[3499]: INF ['zmc -d /dev/video0' starting at 11/06/21 17:43:05, pid = 3523]
Jun 21 17:43:05 fedoraserver zmdc[3523]: INF ['zmc -d /dev/video0' started at 11/06/21 17:43:05]
Jun 21 17:43:05 fedoraserver zmc_dvideo0[3523]: INF [Debug Level = 0, Debug Log = <none>]
Jun 21 17:43:05 fedoraserver zmc_dvideo0[3523]: INF [New Debug Level = 5, New Debug Log = /tmp/zm_debug.log.03523]
Jun 21 17:43:05 fedoraserver zmc_dvideo0[3523]: INF [Starting Capture]
Jun 21 17:43:05 fedoraserver zmc_dvideo0[3523]: WAR [Hue control is not suppported]
Jun 21 17:43:06 fedoraserver zmdc[3499]: INF ['zmfilter.pl' starting at 11/06/21 17:43:06, pid = 3528]
Jun 21 17:43:06 fedoraserver zmdc[3528]: INF ['zmfilter.pl' started at 11/06/21 17:43:06]
Jun 21 17:43:06 fedoraserver zmdc[3499]: INF ['zmaudit.pl -c' starting at 11/06/21 17:43:06, pid = 3533]
Jun 21 17:43:06 fedoraserver zmdc[3533]: INF ['zmaudit.pl -c' started at 11/06/21 17:43:06]
Jun 21 17:43:06 fedoraserver zmdc[3499]: INF ['zmwatch.pl' starting at 11/06/21 17:43:06, pid = 3538]
Jun 21 17:43:06 fedoraserver zmdc[3538]: INF ['zmwatch.pl' started at 11/06/21 17:43:06]
Jun 21 17:43:06 fedoraserver zmdc[3499]: INF ['zmupdate.pl -c' starting at 11/06/21 17:43:06, pid = 3543]
Jun 21 17:43:06 fedoraserver zmwatch[3538]: INF [Watchdog starting]
Jun 21 17:43:06 fedoraserver zmwatch[3538]: INF [Watchdog pausing for 30 seconds]
Jun 21 17:43:06 fedoraserver zmdc[3543]: INF ['zmupdate.pl -c' started at 11/06/21 17:43:06]
Jun 21 17:43:06 fedoraserver zmupdate[3543]: INF [Checking for updates]
Jun 21 17:43:07 fedoraserver zmfilter[3528]: INF [Scanning for events]
Jun 21 17:43:11 fedoraserver zmpkg[3548]: INF [Command: status]
Jun 21 17:43:14 fedoraserver zmupdate[3543]: INF [Got version: '1.24.4']
Jun 21 17:43:25 fedoraserver zms[3566]: INF [Debug Level = 0, Debug Log = <none>]
Jun 21 17:43:25 fedoraserver zms[3566]: INF [New Debug Level = 5, New Debug Log = /tmp/zm_debug.log.03566]
Jun 21 17:43:25 fedoraserver zms[3566]: INF [Authenticated user 'admin']
Jun 21 17:43:27 fedoraserver zms[3566]: INF [Got signal 15 (Terminated), exiting]
Jun 21 17:43:36 fedoraserver zmdc[3499]: ERR ['zmwatch.pl ' exited abnormally, exit status 9]
Jun 21 17:43:36 fedoraserver zmdc[3499]: INF [Starting pending process, zmwatch.pl]
Jun 21 17:43:36 fedoraserver zmdc[3499]: INF ['zmwatch.pl' starting at 11/06/21 17:43:36, pid = 3581]
Jun 21 17:43:36 fedoraserver zmdc[3581]: INF ['zmwatch.pl' started at 11/06/21 17:43:36]
Jun 21 17:43:36 fedoraserver zmwatch[3581]: INF [Watchdog starting]
Jun 21 17:43:36 fedoraserver zmwatch[3581]: INF [Watchdog pausing for 30 seconds]
Thanks so much for everyone's help! Does this mean I will have to manually start it though each reboot? Thanks again.
Locked