I have a database that I would like to drop from the server but when I wanna drop it I am getting the above error.
Trying to look for the solution I found some answer the problem at this link Error in dropping a database in MySQL (can't rmdir '.\oro', errno: 41) but what I don't see the folder they are talking about. I went in the C:\Program Files\MySQL\MySQL Server 5.5\data folder but I coudn't see a folder with the name of my database not even when I did searching in the folder C:\Program Files\MySQL\MySQL Server 5.5\
Windows Error 41 is "directory not empty." https://msdn.microsoft.com/en-us/library/t3ayayh1.aspx
Proceed cautiously. You don't want MySQL's internal structures to become inconsistent with what's on the disk.
Run the query SELECT @@DATADIR;
to find the directory that should contain a folder for each of your databases, including one called abm
.
Contrary to the advice offered in the other question, don't delete the abm
folder once you find it. Instead, leave the folder there, and move the files inside it somewhere outside the datadir where MySQL can't see them.
Then try again to drop the database the normal way.
Finally, restart MySQL to be absolutely sure that its internal structures are consistent with the disk files, by reviewing the log for errors. If the server restarts with no errors, and the database is no longer listed, it should be safe to delete the stray files you copied out of harm's way, above.
If you are windows user. Go to your XAMPP directory -> Mysql directory -> data -> then you will be seeing your list of databases inside this folders. Just cut and paste the database outside somewhere in desktop which you want to remove. If you are using phpmyadmin refresh the page. If you are not finding any errors. you are good to go.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With