phpmyadmin shows MySQL database but localhost uses MariaDB

Problems with the Mac OS X version of XAMPP, questions, comments, and anything related.

phpmyadmin shows MySQL database but localhost uses MariaDB

Postby JansenSensei » 26. November 2018 09:39

Hi all

I am not server setup savvy at all and specifically use XAMPP because it will install everything for me without me having to know what the heck is going on. Thus, please don't assume I have any clue when you tell me to copy this or move that or enable so and such and please go easy on me on that front...

So the issue is this... I installed XAMPP a few years back and have been using it since. No clue what version, just whichever was the current version back then. I am not entirely sure whether I installed MySQL or Maria but I'm almost definite it was MySQL. Fast forward a few years and I am now running OSX Mojave. Suddenly my Manager-OSX app no longer shows any text on any of the buttons, making it very hard to use considering I just returned to this system after just over a year away using a PC. So I installed the latest version of the installer and installed it 7.2.12.

I didn't uninstall anything beforehand but just made a copy of my htdocs folder. After I installed XAMPP the app worked as normal again with the buttons now displaying text again. Yeay. localhost/phpmyadmin still showed my old database so all was good so far only localhost/ redirected me to localhost/dashboard/. I then moved over my old index.php and wp-config.php files and now localhost/ prompts me to install WordPress. This is the part that confuses me... if localhost/phpmyadmin still shows my old database with all my tables and data intact and if my localhost/wp-config.php is still using the same "root" user and blank password as before, trying to access the same database as before, why is it not telling me that it can't access the database but instead telling me to install WordPress?

To the best of my reasoning it would be that my old database is still stored somewhere but the new installation of XAMPP installed MariaDB to somewhere else and now localhost/ and localhost/phpmyadmin/ are using two completely separate databases. This is the only thing that makes sense to me... only, why didn't the XAMPP installation make phpmyadmin point to the database location that it is using?

Anyway, so I can simply setup WordPress and begin my site anew since I was able to export my WordPress tables from phpmyadmin but.... my mind is in a flat spin here... I am accessing WordPress from the same folder as before and all the files (images, plugins etc) will be in the same place as before only my database will be someplace else.... some place where phpmyadmin is NOT pointing to. So what I would like to know is how to do one of two things:
1. Make XAMPP use the old database that has everything already where it should be OR
2. understand where XAMPP is now storing my tables since it's clearly not storing it in the same place as the old one or else it will have picked up the old one, wouldn't it?

Basically, I was happy with what I had but had to upgrade because the XAMPP app was not compatible with Mojave. Now I just want to get back to where I was when I woke up this morning. That's it. I just want to go to localhost/ and see the WordPress website that was there before the XAMPP upgrade. What do I do?

Thanks in advance
JansenSensei
 
Posts: 4
Joined: 26. November 2018 09:00
XAMPP version: 7.2.12
Operating System: OSX Mojave

Re: phpmyadmin shows MySQL database but localhost uses Maria

Postby JansenSensei » 26. November 2018 13:35

Quick update since I made this post...

Turns out I was wrong. Yes, phpmyadmin DID still show my database and all my tables and I was able to export the database from there, sure, but when I tried to install Wordpress I got the strange contradiction where WordPress was telling me it could not create the tables because they already exist and then telling me it couldn't add data to the tables because they DON'T exist. :?: so I had a look in phpmyadmin and found that my tables had no data in them. I then had a look at the data I had exported earlier and found the file filled with errors. Who knew an export file could be filled with error messages? :O

So it seems the answer to my question is simple: When I installed the new version of XAMPP I corrupted my database. Perhaps due to folder permissions the installer wasn't able to delete the existing stuff? Well whatever the reason, there was stuff there, only it WASN'T actually there... no idea how to explain it better. phpmyadmin could see the database and it's tables but couldn't access the tables nor delete the databases. I had to manually adjust the permissions and delete the content and still have to reboot my system to see if phpmyadmin now forgives me. Due to circumstances beyond my control I cannot reboot till tomorrow morning so I'll only know then what the current state of things is but I just thought I'd drop this note and stop anyone from wasting their time on trying to answer my question when it turns out my information was incorrect.

TLDR summary: Installing XAMPP corrupted my existing database. It didn't recreate it nor leave it alone. My database is busted. I ended up uninstalling XAMPP completely and reinstalling it and that allowed me to install WordPress again, go to my dashboard, install the plugins, configure WooCommerce and basically believe that all is well with the world now. Now I just have to figure out why going to localhost/ gives me a file listing for the top part of the page and then displays part of the WordPress install page for the other half of the page. Considering I can't manually stop or restart Apache I am assuming this issue will be solved after a system restart. Will see tomorrow.
JansenSensei
 
Posts: 4
Joined: 26. November 2018 09:00
XAMPP version: 7.2.12
Operating System: OSX Mojave

Re: phpmyadmin shows MySQL database but localhost uses Maria

Postby JansenSensei » 27. November 2018 07:06

Okay, it's official. You can ignore this thread. Installing XAMPP simply corrupted my database. That is what it boils down to. Manually changing the permissions on the database files, deleting them and then doing a clean install and reboot means everything works as expected again. I just lost everything I had in the database before.

Moral of the story: Make backups before you install stuff.
JansenSensei
 
Posts: 4
Joined: 26. November 2018 09:00
XAMPP version: 7.2.12
Operating System: OSX Mojave


Return to XAMPP for macOS

Who is online

Users browsing this forum: No registered users and 23 guests