Valid point.
However I was under the impression that moving the entire directory and than editing /etc/my.cnf.d/mariadb-server.cnf:
Code: Select all
[mysqld]
datadir=/new/mysql
socket=/new/mysql/mysql.sock
would also solve the socket problem..
The mysqld service seems to be running fine (select @@datadir; gives me the proper new location).
httpd service seems to be running fine.
Only zoneminder service still fails while pointing at the old socket location --> /var/lib/mysql/mysql.sock in the error.
journalctl -xe:
Code: Select all
-- Unit zoneminder.service has begun starting up.
Oct 23 16:08:21 testserver zmpkg.pl[4130]: DBI connect('database=zm;host=localhost','test',...) failed: Can't connect to local MySQL server through socket >
Oct 23 16:08:21 testserver zmpkg.pl[4130]: DBI connect('database=zm;host=localhost','test',...) failed: Can't connect to local MySQL server through socket >
Oct 23 16:08:21 testserver zmpkg[4130]: ERR [Error reconnecting to db: errstr:Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' >
Oct 23 16:08:21 testserver zmpkg.pl[4130]: DBI connect('database=zm;host=localhost','test',...) failed: Can't connect to local MySQL server through socket >
Oct 23 16:08:21 testserver zmpkg[4130]: ERR [Error reconnecting to db: errstr:Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' >
Oct 23 16:08:21 testserver zmpkg.pl[4130]: Can't call method "prepare_cached" on an undefined value at /usr/share/perl5/vendor_perl/ZoneMinder/Config.pm line>
Oct 23 16:08:21 testserver zmpkg.pl[4130]: BEGIN failed--compilation aborted at /usr/share/perl5/vendor_perl/ZoneMinder/Config.pm line 147.
Oct 23 16:08:21 testserver zmpkg.pl[4130]: Compilation failed in require at /usr/share/perl5/vendor_perl/ZoneMinder.pm line 33.
Oct 23 16:08:21 testserver zmpkg.pl[4130]: BEGIN failed--compilation aborted at /usr/share/perl5/vendor_perl/ZoneMinder.pm line 33.
Oct 23 16:08:21 testserver zmpkg.pl[4130]: Compilation failed in require at /usr/bin/zmpkg.pl line 34.
Oct 23 16:08:21 testserver zmpkg.pl[4130]: BEGIN failed--compilation aborted at /usr/bin/zmpkg.pl line 34.
Oct 23 16:08:21 testserver systemd[1]: zoneminder.service: Control process exited, code=exited status=255
Oct 23 16:08:21 testserver systemd[1]: zoneminder.service: Failed with result 'exit-code'.
Oct 23 16:08:21 testserver systemd[1]: Failed to start ZoneMinder CCTV recording and security system.
-- Subject: Unit zoneminder.service has failed