Topic on Project:Support desk

Media Wiki isn't finding correct database after system reboot

2
BIitzkrieg (talkcontribs)

This may be a lot so please bear with me. I am a new-hire, maintaining multiple systems. One of these is a mediawiki server which I hadn't messed with until now. We had been using the web end to add content, but hadn't touched or rebooted the backend/OS in quite some time (apparently since June)

Upon system reboot, our media wiki running Centos 7.4 no longer worked. We are running:

mediawiki-1.26.2

php 5.4.16

In yum history, multiple updates were applied, one being:

Yum history:

Jun 11 05:43:40 Installed: 1:mariadb-libs-5.5.52-1.el7.x86_64

Jun 11 05:43:42 Installed: 1:mariadb-5.5.52-1.el7.x86_64

Sep 22 13:15:11 Updated: 1:mariadb-libs-5.5.56-2.el7.x86_64

Sep 22 13:18:42 Updated: 1:mariadb-5.5.56-2.el7.x86_64

Upon investigation, it appeared that SQL/MariaDB wasn't even installed (???) I could not start any sql service via the service or systemctl commands, and nothing was running when inspecting ps aux. However, when trying mysql -u root -p from the command line, I was prompted to login, but got an error: "can't connect to local mysql server through socket (2)" /var/lib/mysql didn't appear to have a mysql.sock file.

After some researching, I tried installing the maria-db-server-5.5.56-2 package, and what would you know, the wiki came up! However, it appears to be rolled back months and barely has any content, some styling appears to be messed up as well. Where should I look to start fixing this?? Could have something been overwritten and that data is gone? Let me know if I need to provide any more information.

Ciencia Al Poder (talkcontribs)

In the LocalSettings.php file you should see the connection settings for the database. $wgDBserver is probably the most useful to you, there you can see the database server IP or socket location. All the data is in the database (pages, users, etc), and uploaded images are on a specific folder (usually /images)

The database can't be overwritten unless by manual intervention... About styling issues, you may take a look at Manual:Errors and symptoms.