Page 1 of 1

Zone images are blank - Event images are blank - in web brow

Posted: Sun Jul 19, 2009 2:40 pm
by pcpackrat
Installed Zoneminder 1.24.2 on centos 5. I can add cameras and see the video and the events trigger fine. When I click on the event I don't get the picture. Only an empty box where the picture should be. When I go to edit the zones, the same thing happens, no images. I initially installed 1.23.x and had the same issues and went to 1.24 after some digging to see if that would fix the issue. If I go into the directory where the images are stored using smb, the images good and contain the analyzed phots and everything.

I have tried searching various terms with zones and blank pictures and just come up empty handed. I have tried the FAQ with no results. Maybe I missed something but I followed an install tutorial to get it installed.

What am I missing?

Thanks,
-PCP

Posted: Sun Jul 19, 2009 8:17 pm
by kingofkya
open up and take a look at the zm logs

check the image directory to see if it is really soring events

Posted: Mon Jul 20, 2009 1:10 am
by pcpackrat
After finding the logs in /var/log/messages instead of /tmp (DOH!) I figured out what was going on. I have an mounted directory for the events and I was using absolute paths in the config. According to the logs it was trying to get the images from the zm web folder/mnt/zone. So I mounted the fs to a folder in zm and changed the config. This allowed the events to be replayed.

I still don't have images for zones though. When I go into a zone I see the following error message in the log:
Jul 19 18:09:34 centos zmu[4253]: ERR [Can't open Zones4.jpg: Permission denied]

There are no ZonesX.jpg images on the filesystem. What would the path to this file be?

Posted: Mon Jul 20, 2009 10:36 pm
by kingofkya
did you make sure that apache user has full access to the directory/filesystem chown and chmod

Posted: Thu Jul 30, 2009 2:20 am
by pcpackrat
drwxrwxrwx 5 apache apache 4096 Jul 29 19:13 zone

Cant get much more open than that. Is there a way to get it to tell me the path which Zones9.jpg is supposed to be at?

The shows:

Code: Select all

Jul 29 19:13:28 centos zmu[23626]: ERR [Can't open Zones9.jpg: Permission denied]
Jul 29 19:13:32 centos zmu[23629]: ERR [Can't open Zones9.jpg: Permission denied]
When I try to access the zones.

Posted: Wed Aug 05, 2009 6:17 pm
by cordel
zone images should be located at:
{web_directroy}/images

Posted: Wed Aug 05, 2009 10:36 pm
by Duckie
I am having a similar problem. I just installed a machine with 1.24.2 on Ubuntu. I get alarms and can generate Video's and see still images but can not see live windows, Zone setup images, etc.

Previous on another machine I had 1.24.1 installed and didn't have this problem.

I have no errors in the message log. Any suggestions?

Thanks

Posted: Mon Aug 10, 2009 10:45 pm
by mcleandl
nstalled Zoneminder 1.24.2 on Fedora 10 x86_64. I can also add cameras and see the video and the events trigger fine. When I click on the event I don't get even the blank picture window. Camera is set to Mocord. When I select the events associated with the camera and "Events windows" opens and I select "Show Timeline" everything appears as expected. Still unable to play back any events.

I have tried searching various terms with zones and blank pictures and just come up empty handed. I have tried the FAQ with no results. Maybe I missed something but I followed an install tutorial to get it installed.

ffmpeg

./configure --enable-gpl

FFmpeg version SVN-r19624, Copyright (c) 2000-2009 Fabrice Bellard, et al.
configuration: --enable-gpl
libavutil 50. 3. 0 / 50. 3. 0
libavcodec 52.32. 0 / 52.32. 0
libavformat 52.37. 0 / 52.37. 0
libavdevice 52. 2. 0 / 52. 2. 0
libswscale 0. 7. 1 / 0. 7. 1
built on Aug 10 2009 17:14:49, gcc: 4.3.2 20081105 (Red Hat 4.3.2-7)

./configure --with-webdir=/var/www/html/zm --with-cgidir=/var/www/html/cgi-bin --with-webuser=apache --with-webgroup=apache ZM_DB_HOST=localhost ZM_DB_NAME=zm ZM_DB_USER=zmuser ZM_DB_PASS=zmpass --with-extralibs="-L/usr/lib64 -L/usr/lib64/mysql" ZM_SSL_LIB=openssl --with-ffmpeg=/usr/include

Any thoughts,

Thanks in advance

Posted: Tue Aug 11, 2009 11:58 pm
by overly
I was having a similar problem where zone images were blank.

When I looked in {web_directory}/images I found images like Zones1.jpg, however the Apache log indicated it was looking for files named like <monitor_name>-Zones.jpg.

I tracked the problem down to zm_monitor.cpp where it was naming the image files differently than what zm_html_view_zones.php was expecting.

So I changed zm_monitor.cpp as follows and zone images are working for me again.

I haven't been keeping up with ZM for a while. Is there a way I can submit this so it gets rolled into trunk? (Assuming my analysis was correct of course)

Code: Select all

Index: src/zm_monitor.cpp
===================================================================
--- src/zm_monitor.cpp  (revision 24)
+++ src/zm_monitor.cpp  (working copy)
@@ -968,7 +968,7 @@
     }

     static char filename[PATH_MAX];
-    snprintf( filename, sizeof(filename), "Zones%d.jpg", id );
+    snprintf( filename, sizeof(filename), "%s-Zones.jpg", name );
     zone_image.WriteJpeg( filename );
 }

Posted: Mon Aug 17, 2009 7:20 pm
by overly
You can disregard my previous post. The problem I had was that when I upgraded from 1.23.3 to 1.24.2 all the original web interface files from 1.23.3 remained in the web directory. I renamed the existing web directory then did a make install to copy the 1.24.2 files over again. This cured the majority of problems I was having.

images folder had wrong ownership

Posted: Thu Nov 26, 2009 5:09 pm
by chrisp
I had the issue where the zoneeditor was not displaying the image and going to http://127.0.0.1/zm/images showed an empty directory.

This forum article helped (thanks kingofkya). I found that the images folder ownership was 'root' rather than 'www-data' (I'm running the debian package on ubuntu as it's more up-to-date): -
chrisp:/usr/share/zoneminder % ll
total 104K
drwxr-xr-x 2 root 4.0K 2009-11-24 00:42 ajax/
-rw-r--r-- 1 root 56K 2009-07-21 02:25 cambozola.jar
lrwxrwxrwx 1 root 17 2009-11-24 00:35 cgi-bin -> ../../lib/cgi-bin/
drwxr-xr-x 2 root 4.0K 2009-11-24 00:42 css/
drwxr-xr-x 2 root 4.0K 2009-11-24 00:42 db/
lrwxrwxrwx 1 root 28 2009-11-24 00:35 events -> /var/cache/zoneminder/events/
drwxr-xr-x 2 root 4.0K 2009-11-24 00:42 graphics/
lrwxrwxrwx 1 root 28 2009-11-24 00:35 images -> /var/cache/zoneminder/images/
drwxr-xr-x 2 root 4.0K 2009-11-24 00:42 includes/
-rw-r--r-- 1 root 3.7K 2009-11-16 01:39 index.php
drwxr-xr-x 2 root 4.0K 2009-11-24 00:42 js/
drwxr-xr-x 2 root 4.0K 2009-11-24 00:42 lang/
drwxr-xr-x 4 root 4.0K 2009-11-24 00:35 skins/
drwxr-xr-x 2 root 4.0K 2009-11-16 01:39 sounds/
lrwxrwxrwx 1 root 26 2009-11-24 00:35 temp -> /var/cache/zoneminder/temp/
drwxr-xr-x 4 root 4.0K 2009-11-24 00:45 tools/
drwxr-xr-x 2 root 4.0K 2009-11-16 01:39 views/
chrisp:/var/cache/zoneminder % ll
total 12K
drwxr-xr-x 6 www-data 4.0K 2009-11-26 01:11 events/
drwxr-xr-x 2 root 4.0K 2009-11-16 01:39 images/
drwxr-xr-x 2 www-data 4.0K 2009-11-16 01:39 temp/
I altered the ownership thusly and now see zoneimages as expected/desired: -
chrisp:/var/cache % sudo chown -R www-data zoneminder

Posted: Thu Mar 25, 2010 11:05 pm
by craig1234
Thanks, i had the same issues with no zones and no events. Thought i would have to re-install zoneminder.

Changed the owner to www-data and it solved the issues. Great :D