I have set up ZM on Debian a few times, and have a working 1.23.3 - so I'm not totally new at this. My issues come from compiling zm from source on Slackware 13.
These are the steps I've taken, and the order.
Code: Select all
./configure --with-webdir=/srv/httpd/htdocs/zm --with-cgidir=/srv/httpd/cgi-bin
[no errors]
make
make install
Code: Select all
create database zm
grant select,insert,update,delete on zm.* to 'z0neUSER'@localhost identified by 'z0nem1nder';
use zm;
source db/zm_create.sql
quit
Code: Select all
# ZoneMinder database user
ZM_DB_USER=z0neUSER
# ZoneMinder database password
ZM_DB_PASS=z0nem1nder
Code: Select all
chmod 644 /usr/local/etc/zm.conf
Code: Select all
cp /usr/local/src/ZoneMinder-1.24.2/scripts/zm /etc/rc.d/rc.zm
chmod +x /etc/rc.d/rc.zm
Code: Select all
/etc/rc.d/rc.zm start
Starting ZoneMinder: Warning, overriding installed ./zm.conf file with local copy
DBI connect('database=zm;host=localhost','zmuser',...) failed: Access denied for user 'zmuser'@'localhost' (using password: YES) at /usr/lib/perl5/site_perl/5.10.0/ZoneMinder/Config.pm line 89
Can't call method "prepare_cached" on an undefined value at /usr/lib/perl5/site_perl/5.10.0/ZoneMinder/Config.pm line 91.
BEGIN failed--compilation aborted at /usr/lib/perl5/site_perl/5.10.0/ZoneMinder/Config.pm line 100.
Compilation failed in require at /usr/lib/perl5/site_perl/5.10.0/ZoneMinder.pm line 33.
BEGIN failed--compilation aborted at /usr/lib/perl5/site_perl/5.10.0/ZoneMinder.pm line 33.
Compilation failed in require at /usr/local/bin/zmpkg.pl line 46.
BEGIN failed--compilation aborted at /usr/local/bin/zmpkg.pl line 46.
[FAILED]
To troubleshoot this I add the default MySQL user thus:
Code: Select all
grant select,insert,update,delete on zm.* to 'zmuser'@localhost identified by 'zmpass';
flush privileges;
Code: Select all
/etc/rc.d/rc.zm start
Starting ZoneMinder: Warning, overriding installed ./zm.conf file with local copy
[ OK ]
touch: cannot touch `/var/lock/subsys/zm': No such file or directory
I don't appear to have any issues with the MySQL users as I can log in using zmuser with password zmpass and view all the tables etc:Could not connect to database: Access denied for user 'zmuser'@'localhost' (using password: YES)
Code: Select all
mysql -u zmuser -p
Enter password:
...
mysql> use zm
Database changed
mysql> show tables;
+----------------+
| Tables_in_zm |
+----------------+
| Config |
| ControlPresets |
| Controls |
| Devices |
| Events |
| Filters |
| Frames |
| Groups |
| MonitorPresets |
| Monitors |
| States |
| Stats |
| TriggersX10 |
| Users |
| ZonePresets |
| Zones |
+----------------+
ZM_DB_PASS
ZM_DB_USER
But my understanding is these merely produce the template for zm.conf anyway and it should work with 'zmuser/zmpass'???
I've looked at this long and hard, I've got to be missing something really obvious here???? [/code]