Richard G
Verified User
Fresh install, VPS with Debian 11.
It seemed all went fine during installation and configuration.
Until I wanted to restore an account from another server using the backup/transfer method, and then I got the above error. Which should'nt be /tmp/mysql.sock because I changed that in the my.cnf which looks like this now:
So I tried to rebuild
How can I fix this? Since rebuilding does not fix the problem.
It seemed all went fine during installation and configuration.
Until I wanted to restore an account from another server using the backup/transfer method, and then I got the above error. Which should'nt be /tmp/mysql.sock because I changed that in the my.cnf which looks like this now:
Code:
[mysqld]
max_allowed_packet=64M
local-infile=0
bind-address=127.0.0.1
max_connections = 300
sql_mode=
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
So I tried to rebuild
Code:
[root@srv100: /usr/local/directadmin/custombuild]# ./build mariadb
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)
using downloaded binary package
download_with_cache: using cached '/usr/local/directadmin/custombuild/cache/mariadb-10.5.21-linux-systemd-x86_64.tar.gz' file
Stopping mysqld ...
Ensuring local-infile is disabled for security reasons in MySQL configuration file...
Waiting for mariadb to start up...
Waiting for mariadb to start up...
Waiting for mariadb to start up...
Waiting for mariadb to start up...
Waiting for mariadb to start up...
Waiting for mariadb to start up...
Waiting for mariadb to start up...
Waiting for mariadb to start up...
etc.
Reading datadir from the MariaDB server failed. Got the following error when executing the 'mysql' command line client
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)
FATAL ERROR: Upgrade failed
failed to running '/usr/local/mysql/bin/mysql_upgrade --defaults-extra-file=/usr/local/directadmin/conf/my.cnf --skip-version-check' system tables might be malformed
Restarting MySQL.
Installation completed.
How can I fix this? Since rebuilding does not fix the problem.