Getting Started – Ubuntu
5 Configure the system
5 Configure the system
5.1 Dispatcher configuration
Devices with AVHS firmware uses Axis dispatcher service to connect to your AVHS system. In order to take control of the devices
belonging to your system, your ST servers must be able to contact the dispatcher servers.
If
you have been given specific information from Axis, edit the file
# vi /home/sts/current/config/dispatcher-conf.php
Change these lines to the values provided by Axis:
$provider_name=’demo’; // Provided by Axis
$provider_password=’demopassword’; // Provided by Axis
$provider_brandspec=’012345689’; // Provided by Axis
Also, for the ST server, add the
provider_name
to the file
home/sts/current/etc/stserver_<stserver_id>.conf
Otherwise
, that is, if you have not been given specific information from Axis, leave these lines as they are.
To get a fault tolerant system if the DNS servers are down, add the following lines to
/etc/hosts
:
87.237.210.63 dispatcher.sts.axis.com
206.71.169.185 dispatchus1.sts.axis.com
195.60.68.116 dispatchse1.avhs.axis.com
195.60.68.117 dispatchse2.avhs.axis.com
5.2 Periodic routines
5.2.1 Quota cleanup
The
current/bin/cleanup.php
script deletes media events (alarms and recordings) for users that have exceeded their storage
quota. This script should preferably be run once per minute on the AVHS host as user
sts
.
The
current/bin/time_cleanup.php
script goes through all media events (alarms and recordings) in the database and
compares the events age to the time set for deleting old events. This script should preferably be run once per day on the AVHS host
as user
sts
.
Sample entry for
/etc/crontab
(see the crontab(5) man page):
* * * * * sts /usr/bin/php /home/sts/current/bin/cleanup.php >/dev/null
0 0 * * * sts /usr/bin/php /home/sts/current/bin/time_cleanup.php >/dev/null
Ensure that the path to PHP matches the path where your PHP is installed.
20