MariaDB allowing select only user to create databases I'm baffled. I have a select only user, but somehow, the user can create a new database, and create table inside the new database. It can't create tables inside other db. It's really odd.

This is MariaDB 5.5.28. 

$ mysql -upermtest -pxxx -h mysqlhost
...
Your MySQL connection id is 4355 to server version: 5.5.28-MariaDB-log
...
mysql&gt; show grants;
+----------------------------------------------------------------------------------------------------------+
| Grants for permtest@%                                                                                    |
+----------------------------------------------------------------------------------------------------------+
| GRANT SELECT ON *.* TO 'permtest'@'%' IDENTIFIED BY PASSWORD '*XXX' |
+----------------------------------------------------------------------------------------------------------+
1 row in set (0.00 sec)

mysql&gt; create database test_ddb_again;
Query OK, 1 row affected (0.00 sec)

mysql&gt; use test_ddb_again;
Database changed

mysql&gt; create table hello ( a int );
Query OK, 0 rows affected (0.01 sec)

mysql&gt; use previously_existing_db;
Database changed

mysql&gt; create table hello ( a int );
ERROR 1142 (42000): CREATE command denied to user 'permtest'@'10.30.25.51' for table 'hello'
mysql&gt;


I'm sure there is a good explanation for this.
After reading this (thanks @ypercube)

MySQL : Why are there &quot;test&quot; entries in mysql.db?

I removed the test entries from mysql.db and it fixed it. I then realized that all the test I'd ran were using database named like test_xxx. Creating database with a name not beginning in 'test_' was not working as expected.