I can’t run to run MySQL Database Server as It gives me an error: DBI connect failed : Can’t connect to local MySQL server through socket ‘/var/run/mysqld/mysqld.sock’ (2).
So I ran “journalctl -xe” and received this:
– A start job for unit user-runtime-dir@1006.service has begun execution.
– The job identifier is 66752.
Apr 20 13:55:15 examle.me systemd[1]: Finished User Runtime Directory /run/use>
– Subject: A start job for unit user-runtime-dir@1006.service has finished suc>
– Defined-By: systemd
– Support: Enterprise open source support | Ubuntu
– A start job for unit user-runtime-dir@1006.service has finished successfully.
– The job identifier is 66752.
Apr 20 13:55:15 example.me systemd[1]: Starting User Manager for UID 1006…
– Subject: A start job for unit user@1006.service has begun execution
– Defined-By: systemd
– Support: Enterprise open source support | Ubuntu
– A start job for unit user@1006.service has begun execution.
– The job identifier is 66679.
Then for “systemctl status mysql.service” I received the following:
mysql.service - MySQL Community Server
Loaded: loaded (/lib/systemd/system/mysql.service; enabled; vendor preset:>
Active: activating (start) since Wed 2022-04-20 14:03:50 UTC; 155ms ago
Process: 31625 ExecStartPre=/usr/share/mysql/mysql-systemd-start pre (code=>
Main PID: 31635 (mysqld)
Status: “Server startup in progress”
Tasks: 1 (limit: 9442)
Memory: 9.2M
CGroup: /system.slice/mysql.service
└─31635 /usr/sbin/mysqld
Apr 20 14:03:50 example.me systemd[1]: Starting MySQL Community Server…
A simple reboot of my server usually start MySQL Database Server, however it doesn’t turn on now. I even followed these posts but no success:
I don’t see any obvious problem there. So, I don’t know.
Can you talk to it using the mysql CLI client? If you can’t even do that, you may need to take it up with the MySQL folks (as it would definitely not be a Virtualmin issue if even msql cannot connect).
It gives me the same error when I try CLI. When I go to the log file via a GUI. I see the error log file is 33GB. I can’t open it. Is there a command line that I can use to view the error log?
less can open any size log, though might be slow with one this size. 33GB is very, very, very big for a log. Something terrible is probably happening there.
tail can show just the last few lines.
These are basic UNIX/Linux commands you should familiarize yourself with, as they’re very helpful when troubleshooting, especially in cases where things have gone pathological, and reading 33GB into a Perl process (which is what Webmin log viewer probably has to do) is a pathological case. Usually you can get documentation for a command with man less or man tail.
Every time I try to run the MySQL database server it increases in size, taking up disk quota. I’ve checked online about this error and there’s nothing.
I have used less statement to view the error log and thanks for the tip btw. I received this from this command,
root@example:~# sudo less /var/log/mysql/error.log
2022-04-21T00:00:06.757253Z 0 [System] [MY-010116] [Server] /usr/sbin/mysqld (mysqld 8.0.28-0ubuntu0.20.04.3) starting as process 144946
2022-04-21T00:00:06.806485Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started.
2022-04-21T00:00:09.961008Z 1 [ERROR] [MY-011906] [InnoDB] Database page corruption on disk or a failed file read of page [page id: space=0, page number=5]. You may have to recover from a backup.
len 16384; hex 4c42ad300000000500000000000000000000000acc3a83b500070000000000000000000000000000000002759c01000000000000000200f20000000000000006ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
What about those errors makes you believe it is quota related? MySQL limits are set to unlimited in that screenshot.
Users may be running into quotas, but MySQL does not. (Though I guess user databases could hit quotas, you haven’t shown us any evidence of that, maybe you’re just hiding it under the blacked out section.)
I see what could indicate hardware failing, or some other filesystem corruption (maybe just an abrupt shutdown of the system/VM).
WTF? That’s not anything I would ever suggest you do. There is no reason to believe reinstalling the package would ever fix anything. Your problem was corrupt data files. The package does not contain those files (it’s your data, the stuff your apps put into the database).
We had kind of the same where Hoster changed wrong disk.
After they put things back as it should , there was a problem related to databases and shutdown.
For us a restart solved it, some checks and repairs for Databases , was swapfile related as error pointed.
Think not related to exact same topic cause, but for readers who find this here and server or mysql down, check if you have working backups of all Databases , then try first a restart , and check log files again.