Error creating new user or database

This is it

Verified User
Joined
Feb 12, 2017
Messages
27
custombuild 1.0.29
DirectAdmin 1.58.1
MySQL 8.0.13

This is a new user, but all other users with existing mysql db have the same problem, cant add new ones

Error after try to create db:


Error creating the database

Details

Unable to add user vacatures_deb. You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'IDENTIFIED BY 'this is the password'' at line 1

log gives something that might be te problem, there is a "" after vacatures :
2019:08:25-12:35:34: createDB(vacatures_deb): unable to add user: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'IDENTIFIED BY 'this is the password'' at line 1. Query: GRANT ALL PRIVILEGES ON `vacatures\_deb`.* TO 'vacatures_vacatures'@localhost IDENTIFIED BY 'this is the password'
 
custombuild 1.0.29
DirectAdmin 1.58.1
MySQL 8.0.13

Why are you running the very old and not supported Custombuild version 1.x? And even worse, you are running the old Custombuild version in combination with the very newest MySQL 8.x - I am sorry, but you can't expect that to work. Before debugging any more, you should upgrade to Custombuild 2.x
 
Why are you running the very old and not supported Custombuild version 1.x? And even worse, you are running the old Custombuild version in combination with the very newest MySQL 8.x - I am sorry, but you can't expect that to work. Before debugging any more, you should upgrade to Custombuild 2.x

sorry i might not be clear:

it is plugin version 1.0.29, but it is custumbuild 2.0.0 (rev: 2148)
 
Sorry, my mistake then (I do not use the plugin, only shell). You should be able to solve the problem by adding the following to /usr/local/directadmin/conf/directadmin.conf:

Code:
mysql_use_new_user_methods=1

Remember to restart DirectAdmin after you add the code above to directadmin.conf, also remember that there should always be one empty line at the bottom of directadmin.conf

Documentation of the feature from changelog:

MySQL: new user methods: ALTER USER, DROP USER, etc. (SCRIPTS): https://www.directadmin.com/features.php?id=2274

Support for MySQL 8.0: https://directadmin.com/features.php?id=2314
 
Sorry, my mistake then (I do not use the plugin, only shell). You should be able to solve the problem by adding the following to /usr/local/directadmin/conf/directadmin.conf:

Code:
mysql_use_new_user_methods=1

Remember to restart DirectAdmin after you add the code above to directadmin.conf, also remember that there should always be one empty line at the bottom of directadmin.conf

Documentation of the feature from changelog:

MySQL: new user methods: ALTER USER, DROP USER, etc. (SCRIPTS): https://www.directadmin.com/features.php?id=2274

Support for MySQL 8.0: https://directadmin.com/features.php?id=2314

Yep that worked thanks!, however i had to change te password with my root phpmyadmin account of the new account maybe i did something wrong, or the auto generated password has a flaw.
 
I am not sure I understand you, however if I guess correct of what you are talking about, then the reason is:

On a new user account in DirectAdmin, if your create the very first database by "log in as user", then you will not be able to login to phpMyAdmin using the same username/password as the DirectAdmin account. However, if the the very first database is created by logging into DirectAdmin with the user account username/password (not by using "log in as user"), then it will work to log into phpMyAdmin using the same username/password as the DirectAdmin account.

This is only true for the very first database that is created in a user account. So I always avoid "log in as user" when creating the first database in the account.
 
when i create a new database as a user of a domain/account, i cant login with my username and password in phpmyadmin. I guess something goes wrong with the storage of the password or the type of login.
If i check phpmadmin with my admin login is see that te new created user has "caching sha2 authentication plugin" i have to change that to mysql authentication, and change the password. then it will work
 
Back
Top