Arch Linux

Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#24180 - [mysql] can't drop database "test"

Attached to Project: Arch Linux
Opened by Holoduke (Holoduke) - Monday, 09 May 2011, 11:23 GMT
Last edited by Andrea Scarpino (BaSh) - Monday, 09 May 2011, 19:51 GMT
Task Type Bug Report
Category Packages: Extra
Status Closed
Assigned To Andrea Scarpino (BaSh)
Architecture All
Severity Very Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

mysql 5.5.12-1

The utility mysql_secure_installation can't drop the database test, apparently because the package contains the file /var/lib/mysql/test/.empty so that the directory isn't empty.


Partial output of mysql_secure_installation:

By default, MySQL comes with a database named 'test' that anyone can
access. This is also intended only for testing, and should be removed
before moving into a production environment.

Remove test database and access to it? [Y/n]
- Dropping test database...
ERROR 1010 (HY000) at line 1: Error dropping database (can't rmdir './test/', errno: 17)
... Failed! Not critical, keep moving...
- Removing privileges on test database...
... Success!
This task depends upon

Closed by  Andrea Scarpino (BaSh)
Monday, 09 May 2011, 19:51 GMT
Reason for closing:  Fixed
Additional comments about closing:  in trunk
Comment by Holoduke (Holoduke) - Monday, 09 May 2011, 11:31 GMT
Erm... of course this is not only a problem while using mysql_secure_installation. Mysql can't drop the database at all as long as the directory isn't empty. I just noticed it while running mysql_secure_installation.
Comment by Jan de Groot (JGC) - Monday, 09 May 2011, 13:25 GMT
I don't see reason to ".keep" that test database when you remove mysql. When you reinstall mysql, the directory is created again anyways.
Comment by Evangelos Foutras (foutrelis) - Monday, 09 May 2011, 19:19 GMT
I would suggest completely removing the 'test' database from the package itself (i.e. remove the /var/lib/mysql/test directory).

What do you think, Andrea?
Comment by Andrea Scarpino (BaSh) - Monday, 09 May 2011, 19:38 GMT
yes, I agree foutrelis. Fixing in trunk.

Loading...