Monday, August 12, 2013

Fix MySQL Databases that won't delete on cPanel

If you get a customer who tries to add a MySQL database or restore a database with a . (period) mark in the name, the database will fail to be created, but under the customer's cPanel MySQL Databases, it will show up as a database. Clicking delete doesn't remove the database.

To delete this database, log into the server via SSH and run the following as root:
$ cd /var/cpanel/databases
$ nano -w customerusername.yaml

Then delete the line with the name of the broken database. Save and exit.

Optionally, you can run the following command to make sure it is working.


No comments:

Post a Comment