Zoneminder, little issues

NethServer Version: 7.3
Module: Zoneminder, MariaDb

I recently installed Zoneminder on my Nethserver. It works pretty well beside a few minor issues.

  1. When MariaDb is running, Zoneminder would not start with the following log entries:
    Failed to start Maria DB database server.
    Dependency failed for ZoneMinder CCTV recording and security system.
    Job zoneminder.service/start failed with result ‘dependency’.
    Unit mariadb.service entered failed state.
    mariadb.service failed.

After turning Maria db off at the Nethserver control panel ZoneMinder would start and run normal. On the Nethserver control panel mysqld shows as stopped.

  1. I installed ZoneMinder following the steps from the wiki (https://wiki.nethserver.org/doku.php?id=userguide:zoneminder). I noticed the paths for images and events are on the / partition and not on the /home. Since ZoneMinder needs lots of disk space I suggest change the paths to /home/zoneminder.
    Maybe someone could add an explanation on how to change the paths correctly?

  2. Even I did the steps of changing php timezone there is still UTC-time logged in the DB.
    Does anyone know of how to change this?

  3. I read somewhere on the net to change the default jpeg library to get mmx support for better performance. How would this been done on Nethserver?

thank you
Peter

About issue #1: observed the same problem occasionally. If I can, will look into that over the weekend.

#2: /home is not used much in NethServer, most data is under /var/lib/nethserver. I join your call, if someone using zoneminder has changed the paths (or has some other useful tweaks) please share. :wink:

#3: Can you share your settings?

config getprop php DateTimezone
php -r 'print_r(date_default_timezone_get());'

I could solve issue 2 and 3 myself.
#2: I did the following:
I moved the already recordet content to a new location in /home

  1. stop Zoneminder
  2. mkdir /home/zoneminder
  3. mkdir events
  4. mv /var/lib/zoneminder/events/* /home/zoneminder/events/
  5. mkdir images
  6. mv /var/lib/zoneminder/images/* /home/zoneminder/images/
  7. chown -R apache:apache /home/zoneminder/

add into fstab:
/home/zoneminder/events /var/lib/zoneminder/events none defaults,bind 0 2
/home/zoneminder/images /var/lib/zoneminder/images none defaults,bind 0 2

restarte Zoneminder and everything is good :slight_smile:

#3:
after I did the Timezone command again it woked. probably a Typo somewhere

so beside of the mysql issue everything works fone for me now

Peter

1 Like

Hey, good to hear it! The wiki has been updated with your changes. Please check if it’s correct, and feel free to contribute to with your corrections.

#4 Maybe it was the libjpeg-turbo library, which was not used by default by older versions of zoneminder.


Back to issue #1: (cc/ @davidep @filippo_carletti @giacomo)

Zoneminder systemd service expects mariadb.service to be running, but fails to start it because the socket is being used by mysqld.service.

On a new minimal Centos installation it’s working without problems, as there’s only mariadb.service (no myslqd.service).

On NethServer there are mariadb and mysqld services. I can be wrong but think this is part of the issue (as well as it is/was for sogo).

2 Likes

You’re probably right. The mysqld service is an hack. Back to ns7 early days I produced this ugly workaround to make our mysqld configuration backward-compatible:

# cat /usr/lib/systemd/system/mysqld.service 
.include mariadb.service

I heard systemd has some kind of unit name “aliasing”. If true, configuring it would be the issue #1 solution.

Added a project card here.

1 Like

and what does this mean for me?

I tried to make unit aliasing work on CentOS 7 without success. If anybody can, please follow up here!

In the meanwhile I remove the project card.