Zone setup - no image

Support and queries relating to all previous versions of ZoneMinder
Locked
liderbugzm

Zone setup - no image

Post by liderbugzm »

Linux FC-4. Camera & events are working. I can watch an event. However when I click on Zones the window pops up - blank (broken img). If I copy an image from the events dir to cam-Zones.jpg - 'then' I have a image and can define an area (I think). This is not what I read in the Manual. It seems to, well ... automagicly appear.
A pointer or two please.

Tks
jameswilson
Posts: 5111
Joined: Wed Jun 08, 2005 8:07 pm
Location: Midlands UK

Post by jameswilson »

check your logs its usually a permission problem on the images folder
James Wilson

Disclaimer: The above is pure theory and may work on a good day with the wind behind it. etc etc.
http://www.securitywarehouse.co.uk
liderbugzm

Forgot to add

Post by liderbugzm »

Permissions on the image subdir are 777. Also if I see ".../zm_manual/images/console2.png" right the camera name is a link - except on my page, it's just the name
10. deck1 Modect /dev/video1 (2) 12
Not sure how to show as links but "deck1" ... ain't.

thanks
liderbugzm

Got some information

Post by liderbugzm »

As root - command line
/usr/local/bin/zmdc.pl check returns "running" as apache - stopped
and when zm_funcs.php:daemonCheck runs zmdc.pl check the line
my $server_up = connect ( CLIENT, $saddr ); returns 1, operation not permitted.
If I set the return in zm_func to "running" my camera name becomes a link. I can pop up the monitor window. I haven't been able to google or forum the ans. I've checked permissions, env. Drawing a blank.
Manwe
Posts: 16
Joined: Tue Nov 21, 2006 10:22 am

Post by Manwe »

I'm getting the same problem... any ideas?
Manwe
Posts: 16
Joined: Tue Nov 21, 2006 10:22 am

Post by Manwe »

additionally I've found an error in the zmdc.log file:

28/11/06 03:30:12 008921 zmdc[501].ERR ['zmc -m 1' exited abnormally, exit status 255]

that's the only error I have found in all logs.

:(
liderbugzm

ZMU call without monitor id

Post by liderbugzm »

Here's one problem I'm tracking. I start ZM, wait a few seconds then click
on one of the "zone" links and up pops the window - empty.
I added this (line 262 in zm_monitor)
Debug( 1, ( "1. %x %d %o %d", (config.shm_key&0xffffff00)|id, shm_size, IPC_CREAT|0700, errno ));
just after the shmget . The following is the DBout.
Notice the line I've marked <<< calling a zmu sans monitor.

zmc_m20[29496].DB1-zm_monitor.cpp/262 [1. 7a6d2014 36865188 1700 0]
zmf_m18[29514].DB1-zm_monitor.cpp/262 [1. 7a6d2012 23988 1700 0]
zmf_m18[29516].DB1-zm_monitor.cpp/262 [1. 7a6d2012 23988 1700 0]
zma_m18[29520].DB1-zm_monitor.cpp/262 [1. 7a6d2012 23988 1700 0]
zma_m18[29522].DB1-zm_monitor.cpp/262 [1. 7a6d2012 23988 1700 0]
zmf_m19[29530].DB1-zm_monitor.cpp/262 [1. 7a6d2013 36865188 1700 0]
zma_m19[29536].DB1-zm_monitor.cpp/262 [1. 7a6d2013 36865188 1700 0]
zmf_m18[29562].DB1-zm_monitor.cpp/262 [1. 7a6d2012 23988 1700 0]
zma_m18[29568].DB1-zm_monitor.cpp/262 [1. 7a6d2012 23988 1700 0]
zmu[29575].DB1-zm_monitor.cpp/262 [1. 7a6d2013 36865188 1700 13] <<<<<<<<
zmf_m18[29580].DB1-zm_monitor.cpp/262 [1. 7a6d2012 23988 1700 0]
zma_m18[29584].DB1-zm_monitor.cpp/262 [1. 7a6d2012 23988 1700 0]

Going to be late to work - more later.
:(
User avatar
zoneminder
Site Admin
Posts: 5215
Joined: Wed Jul 09, 2003 2:07 pm
Location: Bristol, UK
Contact:

Post by zoneminder »

Errno 13 is permission denied. Can you check using ipcs -m that your shared memory has not been created by root or anything like that?
Phil
liderbugzm

No zone img - know what problem is - just not soultion

Post by liderbugzm »

In zm_html_view_zones.php right off the bat the code does:
...... exec ("zmu -m $mid -z") >>>>>> NOT!

I can do exec ("ls /etc") and it returns a list a mile long, date, echo HelloWorld
FINE. zmu - nothing. I can put exec (zmu in a tst.php script and run it (http:127../tst.php) works great.

The $@^!#$ thing won't run from within zm_html_view_zones.php. I've tried php:SafeMode, Unsafemode - HELP!!!!!!! Out of ideas. Forehead bleeding..........
liderbugzm

minor error in above

Post by liderbugzm »

http...tst.php - zmu does not run - again everthing else does

also in zm_funcs.php: function daemonCheck gets "stopped". If I run it from the command line, "running" ??? Something in ENV ???
liderbugzm

zoneS.php won't write Zone.jpg - SELinux problem

Post by liderbugzm »

SELinux SELinux SELinux SELinux SELinux SELinux

I had to run "system-config-securitylevel" and tell it Don't worry about httpd"

I now have 206W1-Zones.jpg in zm/images.

:evil: :evil: :evil: :evil: :evil: :evil: :evil: :D

ave huge headache.
liderbugzm

I meant to add yesterday

Post by liderbugzm »

php.net : exec : 3d post
> When using Red Hat Fedora, beware of Security Enhanced Linux, SELinux.
> Quoted from Red Hat: "The security goal is to make sure that Apache HTTP is only
> reading the static Web content, and not doing anything else such as writing to the content,
> connecting to database sockets, reading user home directories, etc."

So the reason exec ("ls") etc works and exec ("zmu") doesn't is because zmu is using sockets and SELinux checks for http pages using sockets and says "Not today!". Turning off HTTP in the selinux.conf seems to leave a security hole. Maybe one of these days we can say CheckHTTP, except: zma, zmb ,mzc, ...
User avatar
zoneminder
Site Admin
Posts: 5215
Joined: Wed Jul 09, 2003 2:07 pm
Location: Bristol, UK
Contact:

Post by zoneminder »

Thanks for letting us know. It may be worth adding this to the FAQ I think, though it doesn't get asked very often as such. But obviously is a big pain when it happens. I just automatically disable selinux on any box I get, which is probably a bad habit.
Phil
liderbugzm

Post by liderbugzm »

Thought: FAQ's need ... faq:FC4, faq:Ubunta, faq:MS(ucks) [just kidd'n just kidd'n]

Also I posted the question at
http://www.fedoraforum.org/forum/forumd ... rune=&f=44
The ans, Yup, thats the way it works.

Hey, but now? Working just the way the book says it's suppose to work. I'm a happy camper. 1=fixed Bt878, 2=Axis2100, 3=Axis206W, 4=tbd :roll: (there is She, Who MUST be obeyed). The 2100 is publicly avail at http://www.blackforest-co.com/ (top right).
Locked