Broken Links in thumbnail and timeline

Support and queries relating to all previous versions of ZoneMinder
Locked
reidar094
Posts: 5
Joined: Wed May 14, 2008 3:32 pm
Location: Las Vegas NV

Broken Links in thumbnail and timeline

Post by reidar094 »

I just recently got ZoneMinder up and running. GREAT SYSTEM, by the way.

I ran out of room quick with my 8 cameras, so I added a LaCie 1TB USB drive to my SuSE 10.3 Dell PowerEdge 2550 server.
-I formated the LaCie drive to ext3
-Gave it permissions by doing a sudo chmod -R 2777
-Mounted it from /dev/sdb1 /media/LaCie
-Made sure it was in the fstab, it was
-rebooted
-deleted events folder under the /srv/www/htdocs/zm (new system, didn't really need the old files
-Linked the old spot to the new drive doing 'ln -s /media/LaCie/zm/events /srv/www/htdocs/zm/events

Events are working pefectly, however if you click on the thumbnail view under the events, you get a broken link. Same thing happens in the "Show Timeline" view.

Any idea's? The LaCie drive works great by the way.

Again, great work. I've used a Windows Lorex machine, and a Swann system, this is by far superior, and it was easy to configure.
User avatar
cordel
Posts: 5210
Joined: Fri Mar 05, 2004 4:47 pm
Location: /USA/Washington/Seattle

Post by cordel »

Should work, Take a look at your apache error_log, Should be in /var/log/ [httpd | apache]
I would have to guess either still a permissions issue, or maybe you changed the path for events in ZM. The error log should tell you though.

The other possibility, is you might need to configure apache to allow following symlinks.
reidar094
Posts: 5
Joined: Wed May 14, 2008 3:32 pm
Location: Las Vegas NV

Broken Links in thumbnails and timeline

Post by reidar094 »

I forgot to mention I'm using ZM v1.23.3

Here is a copy of my logs from apache

ttp://192.168.0.108/zm/index.php?view=timeline&filter[terms][0][attr]=MonitorId&filter[terms][0][op]==&filter[terms][0][val]=1
[Wed May 14 08:33:52 2008] [error] [client 192.168.0.143] Symbolic link not allowed or link target not accessible: /srv/www/htdocs/zm/events, referer: http://192.168.0.108/zm/index.php?view= ... [0][val]=1
[Wed May 14 08:33:52 2008] [error] [client 192.168.0.143] Symbolic link not allowed or link target not accessible: /srv/www/htdocs/zm/events, referer: http://192.168.0.108/zm/index.php?view= ... [0][val]=1
[Wed May 14 08:33:52 2008] [error] [client 192.168.0.143] Symbolic link not allowed or link target not accessible: /srv/www/htdocs/zm/events, referer: http://192.168.0.108/zm/index.php?view= ... [0][val]=1
[Wed May 14 08:33:52 2008] [error] [client 192.168.0.143] Symbolic link not allowed or link target not accessible: /srv/www/htdocs/zm/events, referer: http://192.168.0.108/zm/index.php?view= ... [0][val]=1
[Wed May 14 08:33:52 2008] [error] [client 192.168.0.143] Symbolic link not allowed or link target not accessible: /srv/www/htdocs/zm/events, referer: http://192.168.0.108/zm/index.php?view= ... [0][val]=1
[Wed May 14 08:33:52 2008] [error] [client 192.168.0.143] Symbolic link not allowed or link target not accessible: /srv/www/htdocs/zm/events, referer: http://192.168.0.108/zm/index.php?view= ... [0][val]=1
[Wed May 14 08:33:52 2008] [error] [client 192.168.0.143] Symbolic link not allowed or link target not accessible: /srv/www/htdocs/zm/events, referer: http://192.168.0.108/zm/index.php?view= ... [0][val]=1
[Wed May 14 08:33:52 2008] [error] [client 192.168.0.143] Symbolic link not allowed or link target not accessible: /srv/www/htdocs/zm/events, referer: http://192.168.0.108/zm/index.php?view= ... [0][val]=1
[Wed May 14 08:33:52 2008] [error] [client 192.168.0.143] Symbolic link not allowed or link target not accessible: /srv/www/htdocs/zm/events, referer: http://192.168.0.108/zm/index.php?view= ... [0][val]=1
[Wed May 14 08:33:52 2008] [error] [client 192.168.0.143] Symbolic link not allowed or link target not accessible: /srv/www/htdocs/zm/events, referer: http://192.168.0.108/zm/index.php?view= ... [0][val]=1
[Wed May 14 08:33:52 2008] [error] [client 192.168.0.143] Symbolic link not allowed or link target not accessible: /srv/www/htdocs/zm/events, referer: http://192.168.0.108/zm/index.php?view= ... [0][val]=1
[Wed May 14 08:33:52 2008] [error] [client 192.168.0.143] Symbolic link not allowed or link target not accessible: /srv/www/htdocs/zm/events, referer: http://192.168.0.108/zm/index.php?view= ... [0][val]=1
[Wed May 14 08:33:52 2008] [error] [client 192.168.0.143] Symbolic link not allowed or link target not accessible: /srv/www/htdocs/zm/events, referer: http://192.168.0.108/zm/index.php?view= ... [0][val]=1
[Wed May 14 08:33:53 2008] [error] [client ::1] Directory index forbidden by Options directive: /srv/www/htdocs/
[Wed May 14 08:33:54 2008] [error] [client ::1] Directory index forbidden by Options directive: /srv/www/htdocs/
[Wed May 14 08:33:55 2008] [error] [client ::1] Directory index forbidden by Options directive: /srv/www/htdocs/
[Wed May 14 08:34:10 2008] [error] [client ::1] Directory index forbidden by Options directive: /srv/www/htdocs/
[Wed May 14 08:49:19 2008] [error] [client 192.168.0.143] Symbolic link not allowed or link target not accessible: /srv/www/htdocs/zm/events, referer: http://192.168.0.108/zm/index.php?view= ... 210&fid=17

It does appear that i have a symbolic link error, but i have no idea how to fix it.

Thanks for your help.
User avatar
cordel
Posts: 5210
Joined: Fri Mar 05, 2004 4:47 pm
Location: /USA/Washington/Seattle

Post by cordel »

In httpd.conf you need to add to the options for your web root, FollowSymLinks for the options directive.
http://httpd.apache.org/docs/2.2/mod/core.html
reidar094
Posts: 5
Joined: Wed May 14, 2008 3:32 pm
Location: Las Vegas NV

Broken Links in thumbnail and timeline

Post by reidar094 »

Can you give me an example on how to do that?

I found it under options on the apache website, but how do I add it to the httpd.conf.

I opened httpd.conf under vi, and I was expecting to find an options section.

Do I just say 'Options FollowSymLinks'?

Again, thanks for your help.
User avatar
cordel
Posts: 5210
Joined: Fri Mar 05, 2004 4:47 pm
Location: /USA/Washington/Seattle

Post by cordel »

There should already be an options directive for the root directory, something like
<Directory>
Options Indexes

You just have to append FollowSymLinks to it:
Options Indexes FollowSymLinks
reidar094
Posts: 5
Joined: Wed May 14, 2008 3:32 pm
Location: Las Vegas NV

Broken Links in thumbnails and timeline

Post by reidar094 »

There should already be an options directive for the root directory, something like
<Directory>
Options Indexes

You just have to append FollowSymLinks to it:
Options Indexes FollowSymLinks

Thank-you cordel, you are a genious.
It worked perfectly. I found it in the default-server.conf, it had a 'none' after Options, I just added the 'Indexes FollowSymLinks' saved it, then restarted zm, mysql and apache2. Worked beautifully aftewords.
we4zonM
Posts: 56
Joined: Fri May 30, 2008 7:21 am

please add wiki solution!

Post by we4zonM »

cordel wrote:There should already be an options directive for the root directory, something like
<Directory>
Options Indexes

You just have to append FollowSymLinks to it:
Options Indexes FollowSymLinks
This solution is buried in the Forum, and it should be in the Wiki as it is a common problem with Zoneminder to run out of disk space or to change the image or events directory and then to get errors such as 403 access errors and in the apache error logs "Symbolic link not allowed or link target not accessible". It should also be in the documentation that installs with Zoneminder, so that you do not need to spend a lot of time and frustration to find it by searching the forums! If I understand it better, I can add a Wiki, but hopefully someone will update it and also add it to the installable documentation for Zoneminder.

Zoneminder uses Apache, MySQL, and PHP, and these are a part of Zoneminder, so the use and changes to their configuration for such common tasks as changing image or events directories should be well documented. It is not enough to just point people to the Web sites for Apahe, MySQL and PHP...they need to know what to do to complete common tasks in Zoneminder without spending enormous amounts of time reading about Apache, MySQL, and PHP administration.
Locked