Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I just upgraded from 10.04 to 12.04.

Now, when I try to drop a database in phpmyadmin it gives me an error saying that DROP DATABASE statements are disabled.

After reading up on this I added this line

$cfg['AllowUserDropDatabase'] = true;

to the bottom of /etc/phpmyadmin/, but I still get the same message.

I logged out of phpmyadmin, rebooted and logged back in, but still no change.

Any ideas?


OK, I have discovered a few more details:

  • I can drop a database from PHPMyadmin by clicking on the DROP link. I can not, however, drop by typing the SQL directly.
  • I can drop a database from the command prompt, no problems
  • There is one particular database that seems to be screwed up. If I try to DROP from the command prompt, it says it has lost connection to the server. If I try from within PHPMyadmin, it errors out and logs me out instantly.
share|improve this question

if you are using version 4+ then you can simply drop a database just following these steps:

  1. go to mysql admin
  2. click database option (right side of your databases)
  3. here you will get all the databases you have and now click the checkbox at the left side of the databases you want to delete
  4. just the bottom of these databases you can see the option "Drop" so click the drop to delete the database permanently
share|improve this answer

You will need to update file


generally phpmyadmin's libraries folder

line 653 (may very depending on version)

$cfg['AllowUserDropDatabase'] = true;

(restart your MySQL once the value is changed to 'true')

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.