Mysql 8.0

Theo Lodewijk

Verified User
Joined
Feb 5, 2020
Messages
14
After a fresh installation with mysql 8.0 the login details not work.

after opening a support ticket directadmin don't want to help so I hope someone have the solutions!

Installing Directadmin on a last version of Cent OS 8 with Nginx as server.

Reading the post https://help.directadmin.com/item.php?id=45 but also that wil not work.

Result ::


[root@mail custombuild]# systemctl stop mysqld
[root@mail custombuild]# systemctl set-environment MYSQLD_OPTS="--skip-grant-tables"
[root@mail custombuild]# systemctl start mysqld
[root@mail custombuild]#
[root@mail custombuild]# mysql mysql -e "UPDATE mysql.user SET authentication_string=PASSWORD('root_password') WHERE user='root'; FLUSH PRIVILEGES;"
ERROR 1064 (42000) at line 1: 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 '('root_password') WHERE user='root'' at line 1
[root@mail custombuild]# systemctl unset-environment MYSQLD_OPTS
[root@mail custombuild]# systemctl stop mysqld
[root@mail custombuild]# systemctl start mysqld
[root@mail custombuild]# mysql -uroot -p'root_password' -e "ALTER USER 'root'@'localhost' IDENTIFIED BY 'root_password';"
mysql: [Warning] Using a password on the command line interface can be insecure.
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)
[root@mail custombuild]# mysql -uroot -p
Enter password:
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)
[root@mail custombuild]# mysql -uroot -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 10
Server version: 8.0.17 MySQL Community Server - GPL

Copyright (c) 2000, 2019, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> GRANT ALL PRIVILEGES ON *.* TO da_admin@localhost IDENTIFIED BY 'da_admin_password' WITH GRANT OPTION;
ERROR 1064 (42000): 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 'Kw0CLFmv7SwqDKG' WITH GRANT OPTION' at line 1
mysql> FLUSH PRIVILEGES;
Query OK, 0 rows affected (0.00 sec)

mysql> quit
Bye
[root@mail custombuild]#
 

smtalk

Administrator
Staff member
Joined
Aug 22, 2006
Messages
9,305
Location
LT, EU
If that's a new installation, stop mysqld completely, rename /var/lib/mysql, and ./build mysql will re-install it for you.
 

Theo Lodewijk

Verified User
Joined
Feb 5, 2020
Messages
14
stopped mysql and rename the directory but still the same result ::
[root@mail custombuild]# ./build mysql
ERROR 1045 (28000): Access denied for user 'da_admin'@'localhost' (using password: YES)
Found /usr/local/directadmin/custombuild/mysql/mysql-community-client-8.0.17-1.el8.x86_64.rpm
Found /usr/local/directadmin/custombuild/mysql/mysql-community-devel-8.0.17-1.el8.x86_64.rpm
Found /usr/local/directadmin/custombuild/mysql/mysql-community-server-8.0.17-1.el8.x86_64.rpm
Found /usr/local/directadmin/custombuild/mysql/mysql-community-libs-8.0.17-1.el8.x86_64.rpm
Found /usr/local/directadmin/custombuild/mysql/mysql-community-common-8.0.17-1.el8.x86_64.rpm
Stopping mysqld ...
Updating MySQL 8.0.17 to 8.0.17
warning: mysql-community-client-8.0.17-1.el8.x86_64.rpm: Header V3 DSA/SHA1 Signature, key ID 5072e1f5: NOKEY
Verifying... ################################# [100%]
Preparing... ################################# [100%]
Updating / installing...
1:mysql-community-common-8.0.17-1.e################################# [ 20%]
2:mysql-community-libs-8.0.17-1.el8################################# [ 40%]
3:mysql-community-client-8.0.17-1.e################################# [ 60%]
4:mysql-community-server-8.0.17-1.e################################# [ 80%]
5:mysql-community-devel-8.0.17-1.el################################# [100%]
[/usr/lib/tmpfiles.d/mdadm.conf:1] Line references path below legacy directory /var/run/, updating /var/run/mdadm → /run/mdadm; please update the tmpfiles.d/ drop-in file accordingly.
[/usr/lib/tmpfiles.d/mysql.conf:23] Line references path below legacy directory /var/run/, updating /var/run/mysqld → /run/mysqld; please update the tmpfiles.d/ drop-in file accordingly.
[/usr/lib/tmpfiles.d/pesign.conf:1] Line references path below legacy directory /var/run/, updating /var/run/pesign → /run/pesign; please update the tmpfiles.d/ drop-in file accordingly.
[/usr/lib/tmpfiles.d/radvd.conf:1] Line references path below legacy directory /var/run/, updating /var/run/radvd → /run/radvd; please update the tmpfiles.d/ drop-in file accordingly.
Ensuring local-infile is disabled for security reasons in MySQL configuration file...
Giving mysqld a few seconds to start up...
The mysql_upgrade client is now deprecated. The actions executed by the upgrade client are now done by the server.
To upgrade, please start the new MySQL binary with the older data directory. Repairing user tables is done automatically. Restart is not required after upgrade.
The upgrade process automatically starts on running a new MySQL binary with an older data directory. To avoid accidental upgrades, please use the --upgrade=NONE option with the MySQL binary. The option --upgrade=FORCE is also provided to run the server upgrade sequence on demand.
It may be possible that the server upgrade fails due to a number of reasons. In that case, the upgrade sequence will run again during the next MySQL server start. If the server upgrade fails repeatedly, the server can be started with the --upgrade=MINIMAL option to start the server without executing the upgrade sequence, thus allowing users to manually rectify the problem.
mysqlcheck: Got error: 1045: Access denied for user 'da_admin'@'localhost' (using password: YES) when trying to connect
Restarting MySQL.
Installation completed.
 

Theo Lodewijk

Verified User
Joined
Feb 5, 2020
Messages
14
No it is a clean installation from scratch without moving anny data. by installation selected mysql 8.0 as default.

it is already the second time completely new installation, first time with default mariadb and upgrade to mysql not work second installation selected mysql 8.0 but same results.

it seems directadmin installation makes some mistakes I dont know what but I cant fix it after alot of seartsing on the internet and directadmin itself don't want help, yes after pay 199 dolar!
 

smtalk

Administrator
Staff member
Joined
Aug 22, 2006
Messages
9,305
Location
LT, EU
I guess you might have a license without support, that's why :) I could assist (without any rush though) this single time if you want. Just PM me access details.
 

Theo Lodewijk

Verified User
Joined
Feb 5, 2020
Messages
14
@smtalk I have send you an message.

yes I use Directadmin already many years. I use 2 servers and manage some servers for customers.

if I make mistakes myself and that something no longer works and is broken due to my own fault, it is normal that I pay for it but something that has an installation template and as soon as it is ready and it does not work it would seem to the maker but unfortunately they don't give respons.

hopefully you can figure out what's wrong so maybe someone else can read or how to solve such problems. I myself have tried a lot and searched the internet, but unfortunately nothing has helped so far.
 

smtalk

Administrator
Staff member
Joined
Aug 22, 2006
Messages
9,305
Location
LT, EU
I've fixed it for you. When licenses without support were purchased - I think you knew what you're purchasing :) And if you'd like to support development/future of DA - purchasing support is the way to do it. Anyway, that's a bit off-topic.
 

Theo Lodewijk

Verified User
Joined
Feb 5, 2020
Messages
14
@smtalk yes you have right, after better times it is a good idea to purchase it.

Thanks for the support, after the suport I have fixed the login to phpmyadmin by remove da_admin and add them agen.

I can't figiritout what da_admin can't login in to phpmyadmin. login form ssh to da_admin with the giffen password works fine.

DROP USER 'da_admin'@'localhost';
CREATE USER 'da_admin'@'localhost' IDENTIFIED BY '2I7NfyhMK3BGr';
GRANT ALL PRIVILEGES ON * . * TO 'da_admin'@'localhost';
FLUSH PRIVILEGES;
 

Theo Lodewijk

Verified User
Joined
Feb 5, 2020
Messages
14
I have figiritout where it goes wrong.

The installation was valid but I have test the login to mysql form phpmyadmin and test it not from command line. (testid and after installation da_admin is not correct and need be changed from root mysql user (after reset the password still not able to login in to phpmyadmin)).

I have do the follow to fix it

[root@mail ]# mysql -uroot -p

mysql> DROP USER 'da_admin'@'localhost';

mysql> CREATE USER 'da_admin'@'localhost' IDENTIFIED BY 'my_password';

mysql> GRANT ALL PRIVILEGES ON * . * TO 'da_admin'@'localhost';

mysql> FLUSH PRIVILEGES;

ALTER USER 'da_admin'@'localhost' IDENTIFIED BY 'my_password';

I think there are some changes for mysql 8.0 and https://help.directadmin.com/item.php?id=45 seems not work.

Everything works fine now.
 
Top