I've been struggling with this mysql error for a day or so, and tried searching the forums, but am now stuck.
I've tried both the rpm for Suse 10.3 and building from source with the pre-requisites. Both behave the same.
I get
Code: Select all
Feb 17 16:15:07 ha-server zmfix[17676]: ERR [Can't connect to server: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)]
Feb 17 16:15:07 ha-server zmpkg[17666]: ERR [Unable to run "sudo -u wwwrun /usr/local/bin/zmfix", output is ""]
Code: Select all
02/17/08 16:15:07.452446 zmpkg[17666].INF [Command: start]
02/17/08 16:15:07.452953 zmpkg[17666].DBG [Testing valid shell syntax]
02/17/08 16:15:07.453061 zmpkg[17666].DBG [Testing "sudo -u wwwrun true"]
02/17/08 16:15:07.461883 zmpkg[17666].DBG [Test ok, using format "sudo -u wwwrun <command>"]
02/17/08 16:15:07.462011 zmpkg[17666].DBG [Command: sudo -u wwwrun /usr/local/bin/zmdc.pl check]
02/17/08 16:15:07.608870 zmpkg[17666].DBG [Output: stopped]
02/17/08 16:15:07.608993 zmpkg[17666].DBG [Removing shared memory]
02/17/08 16:15:07.609053 zmpkg[17666].DBG [Checking for shared memory with 'ipcs -m | grep '^0x7a6d00'']
02/17/08 16:15:07.613977 zmpkg[17666].DBG [Command: sudo -u wwwrun /usr/local/bin/zmfix]
02/17/08 16:15:07.623394 zmpkg[17666].ERR [Unable to run "sudo -u wwwrun /usr/local/bin/zmfix", output is ""]
So I tried editing my.cnf to change the socket location to /tmp/mysql.sock, restarted mysql (the socket location changes as expected), but now zmpkg gives the following error:
Code: Select all
DBI connect('database=zm;host=localhost','zm_admin',...) failed: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) at /usr/lib/perl5/site_perl/5.8.8/ZoneMinder/Config.pm line 89
Can't call method "prepare_cached" on an undefined value at /usr/lib/perl5/site_perl/5.8.8/ZoneMinder/Config.pm line 91.
BEGIN failed--compilation aborted at /usr/lib/perl5/site_perl/5.8.8/ZoneMinder/Config.pm line 100.
Compilation failed in require at /usr/lib/perl5/site_perl/5.8.8/ZoneMinder.pm line 33.
BEGIN failed--compilation aborted at /usr/lib/perl5/site_perl/5.8.8/ZoneMinder.pm line 33.
Compilation failed in require at /usr/local/bin/zmpkg.pl line 45.
BEGIN failed--compilation aborted at /usr/local/bin/zmpkg.pl line 45.
Can I change where zmfix is looking for the socket - can't see anything obvious in the source.
But maybe it's some kind of simple permissions problem instead?
Help much appreciated