SYSTEM INFORMATION | |
---|---|
OS type and version | AlmaLinux 9.5 |
Webmin version | 2.202 |
Webmin → Servers → MariaDB Database server
and set key_buffer_size to 20% of available RAM (recommended at MariaDB website for MyISAM)
Now it errors:
“Error! MariaDB is not running on your system - database list could not be retrieved.”
MariaDB error message
The full MariaDB error message was : DBI connect failed : Can’t connect to local server through socket ‘/var/lib/mysql/mysql.sock’ (2) ?
Attempt to start MariaDB: Job for mariadb.service failed because the control process exited with error code.
See “systemctl status mariadb.service” and “journalctl -xeu mariadb.service” for details.
systemctl status mariadb.service:
× mariadb.service - MariaDB 10.5 database server
Loaded: loaded (/usr/lib/systemd/system/mariadb.service; enabled; preset: disabled)
Active: failed (Result: exit-code) since Sat 2024-12-28 09:08:41 AEDT; 1min 5s ago
Docs: man:mariadbd(8)
https://mariadb.com/kb/en/library/systemd/
Process: 4953 ExecStartPre=/usr/libexec/mariadb-check-socket (code=exited, status=0/SUCCESS)
Process: 4975 ExecStartPre=/usr/libexec/mariadb-prepare-db-dir mariadb.service (code=exited, status=0/SUCCESS)
Process: 5010 ExecStart=/usr/libexec/mariadbd --basedir=/usr $MYSQLD_OPTS $_WSREP_NEW_CLUSTER (code=exited, status=7)
Main PID: 5010 (code=exited, status=7)
Status: "MariaDB server is down"
CPU: 185ms
Dec 28 09:08:41 hostname.example.com.au systemd[1]: Starting MariaDB 10.5 database server...
Dec 28 09:08:41 hostname.example.com.au mariadb-prepare-db-dir[4975]: Database MariaDB is probably initialized in /var/lib/mysql already, nothing is done.
Dec 28 09:08:41 hostname.example.com.au mariadb-prepare-db-dir[4975]: If this is not the case, make sure the /var/lib/mysql is empty before running mariadb-prepare-db-dir.
Dec 28 09:08:41 hostname.example.com.au systemd[1]: mariadb.service: Main process exited, code=exited, status=7/NOTRUNNING
Dec 28 09:08:41 hostname.example.com.au systemd[1]: mariadb.service: Failed with result 'exit-code'.
Dec 28 09:08:41 hostname.example.com.au systemd[1]: Failed to start MariaDB 10.5 database server.
journalctl -xeu mariadb.service:
A start job for unit mariadb.service has begun execution.
The job identifier is 1019.
Dec 28 09:08:41 hostname.example.com.au mariadb-prepare-db-dir[4975]: Database MariaDB is probably initialized in /var/lib/mysql already, nothing is done.
Dec 28 09:08:41 hostname.example.com.au mariadb-prepare-db-dir[4975]: If this is not the case, make sure the /var/lib/mysql is empty before running mariadb-prepare-db-dir.
Dec 28 09:08:41 hostname.example.com.au systemd[1]: mariadb.service: Main process exited, code=exited, status=7/NOTRUNNING
Subject: Unit process exited
Defined-By: systemd
Support: https://wiki.almalinux.org/Help-and-Support
An ExecStart= process belonging to unit mariadb.service has exited.
The process' exit code is 'exited' and its exit status is 7.
Dec 28 09:08:41 hostname.example.com.au systemd[1]: mariadb.service: Failed with result 'exit-code'.
Subject: Unit failed
Defined-By: systemd
Support: https://wiki.almalinux.org/Help-and-Support
The unit mariadb.service has entered the 'failed' state with result 'exit-code'.
Dec 28 09:08:41 hostname.example.com.au systemd[1]: Failed to start MariaDB 10.5 database server.
Subject: A start job for unit mariadb.service has failed
Defined-By: systemd
Support: https://wiki.almalinux.org/Help-and-Support
A start job for unit mariadb.service has finished with a failure.
The job identifier is 1019 and the job result is failed.
Contents of /var/lib/MySQL:
aria_log.00000001 aria_log_control databasename ib_buffer_pool ib_logfile0 ibdata1 multi-master.info mysql mysql_upgrade_info performance_schema
The error message
“Dec 28 09:08:41 hostname.example.com.au mariadb-prepare-db-dir[4975]: Database MariaDB is probably initialized in /var/lib/mysql already, nothing is done.
Dec 28 09:08:41 hostname.example.com.au mariadb-prepare-db-dir[4975]: If this is not the case, make sure the /var/lib/mysql is empty before running mariadb-prepare-db-dir.”
appears to imply the /var/lib/MySQL directory should be empty?