I've been stupid enough to delete too many databases in XAMPP with PHPMyAdmin and now my sites on localhost don't run properly anymore. Please see this screenshot of the main errors
I guess entirely reinstalling XAMPP will fix the problem but that might take much more time than necessary. Preferably, I'd like to just reinstall the MySQL component or perhaps recreate/repair some databases required for XAMPP to function properly. However, it looks as if I can only reinstall XAMPP entirely instead of separate components (and if that's correct, it's probably for a reason...).
Do I have a better option here than a complete reinstall of XAMPP?
OK, fixed it with the kind help of scones.
1) By default (XAMPP 1.8.1 on Windows XP), there seems to be a folder C:\xampp\mysql\backup\phpmyadmin. Just copy-paste this entire folder into C:\xampp\mysql\data.
2) Stop and restart MySQL
3) If you're using WordPress, your pages may be blank since it may think there are no themes available. Go to [frontpage url]/wp-admin/. Now just reactivate the theme you'd like to use and all seems up and running again!
You dropped the database for PHPMyAdmin. If you can just restore that (with a command line mysql tool or any tool that does not rely on a web-interface), you can use phpmyadmin again.
Related
after mysql wouldn't start, I searched, and found some advice, after following said advice, I deleted files in MAMP/db/mysql56 (not folders).
This solved the problem of mysql not loading. BUT... it now asks me to install wordpress again. Even if I try to do that, it won't let me. I get errors saying the database doesn't exist etc.
Does anyone know of anything I can try now to get the local site back up and running?
thanks so much!
Mike
You just deleted the whole MySQL database of MAMP.. thats your problem. Restore the files and debug further why MySQL is not starting. What you did can not fix the problem you are having. If you don't have a backup of those files consider your database lost and completely remove MAMP and reinstall to start over.
Whenever I use:
cat /etc/my.cnf
it looks like this:
As you can see it comes out blank. On top of this I tried to reset my password and I went and screwed everything up. NOW I Just want to restart from scratch. I don't need to save anything I have no database info that I am worried about losing I am just trying to get mySQL working.
TL;DR:
I just want to reset everything/delete all things to do with mySQL to get a fresh start. I have tried all of the rm commands and reinstalling it but that didn't even work. I don't have anything that I need to save or back up.
If you installed it from the MySQL Community Server everything should be in something like /usr/local/mysql-5.7.13-osx10.10-x86_64/. The exact directory name depends on your version of MySQL and OS X.
Delete that directory and reinstall the package. That should reset everything.
Alternatively you have multiple copies of MySQL installed and they're confusing each other. Check with which mysqladmin. If it points to somewhere other than inside /usr/local/mysql-5.7.13-osx10.10-x86_64/ then you have another version installed.
Last week my WAMP not working properly when I start it, it goes yellow.. and local host working fine but when I go though phpmyadmin its not working...
After that I try to go on mysql data folder in wamp and delete following files
ib_logfile0
ib_logfile1
ibdata1
And the restart all service it working and goes green but my all database not working.. daily I do that for starting the service and import all the database daily for working
please suggest me the solution of this....
if you are using the wampserver 2.5 uninstall it and
try to follow the instruction on the video (click here) better to understand and follow the instruction carefully
still got error's? I suggest use wampserver 2.2 because wampserver 2.5 has lots of bugs and errors
HOPE it helps you.
You deleted the files that MySQL uses to store the database -- of course your databases aren't going to work. I suggest you restore your databases from a backup. There's no way around it; as long as you are deleting the database files, you're going to have trouble using the database.
About the problems logging in through phpMyAdmin, you can search here for the actual error message or open another question and perhaps get that problem resolved as well.
I recently switched from using XAMPP to WAMP on my Windows 7 machine so I can do fast switching of PHP versions.
I completely uninstalled XAMPP, but first I backed up my htdocs, apache and mysql directories just in case.
After I installed WAMP and had everything up and running, I figured I could just drop some of my databases from my old XAMPP install into the "data" directory of the mysql directory in WAMP.
So that worked and the database shows up in phpMyadmin, but there are no tables. Is this a permissions thing? Like maybe I don't have the same user in the new install of mysql? Or am I missing something?
Am I allowed to just copy MySQL databases from one data folder to another or does it not work that way?
Both instances are using MySQL 5.5 (at least that's what both README files say in both MySQL directories).
THANKS
When using phpMyAdmin out of the box so to speak in WAMP, MYSQL is installed as per its default installation with the root userid setup to have NO PASSWORD.
Some people seem to think they should make one up when they see the login screen, is that what you are doing?
When you do this phpmyadmin allows you to APPEAR to login but then as you do not have root's privilages you see almost nothing on its other screens and are allowed to do nothing.
Use
username = root
password = (leave this blank)
Then set a password, there is a link on the next page it presents. AND DONT FORGET IT!!!!
This generally isn't a good idea. RiggsFolly was asking about your table type because some table types are more forgiving than others. Other possible trouble spots include file system permission problems or MySQL permission problems (as RiggsFolly asked).
I'd suggest to do an export (as an SQL file) and import that for a complete solution.
I am a a newbie to database programming and I want to try out MySQL.
I just installed MySQL from the official website, I am running mac 10.8.2.
Anyways, whenever I try to run a simple command like $>mysql.server start
it says Permission denied.
I am able to open it through sudo but I would love to get this fixed as this is annoying me, that it wont work properly. I have been searching for the last two hours without finding a fix, so I was hoping anyone could give me a helping hand.
The easiest way is to install the MySQL Startup Item. Then you get a Preference pane for MySQL.
See http://dev.mysql.com/doc/refman/5.5/en/macosx-installation-startupitem.html for full instructions.
Re your comment:
It's often required for services like mysql.server need to run as a uid other than your user login. For instance, the MySQL data directory may only be writeable by the mysql uid. So starting such a service must be done from a user that can change the uid of the process. The root uid can do that, so it's necessary to use sudo to launch service processes like mysql.server.
TL;DR: YOU HAVE TO USE SUDO.
If you a absolute newbie to MYSQL and you just want to use the MYSQL server to test your code on you local MAC I would advice you to take a look at XAMPP / MAMP. Xampp offers a complete out of the box install for everything you need for a development servers (Apache server, MySQL, PHP, etc). Note, that I XAMPP / MAMP is not suitable for production server setting.
I personally use the XAMPP Windows version. I haven't tried MAMP but I have come across it many times . The XAMPP for Mac version seem not to have been update for a while so I suggest you give MAMP a try.
You could of course try to get your current install to work but that might require some work. Also with regard to firewall / security issues. With the out of the box version you will have to do a lot less. Why reinvent the wheel if you can easily install a out of the box version.