im installing mysql-8.0.29 to linux
when i tried to start by this command bin/mysqld_safe --user=mysql & --default-authentication-plugin=mysql_native_passwor then use mysql -u root -p to connect to mysql but it throw
ERROR 2059 (HY000): Authentication plugin 'caching_sha2_password' cannot be loaded: /usr/lib64/mysql/plugin/caching_sha2_password.so: file too short
here is /etc/my.cnf
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
default-authentication-plugin=mysql_native_password
# Disabling symbolic-links is recommended to prevent assorted security risks
symbolic-links=0
# Settings user and group are ignored when systemd is used.
# If you need to run mysqld under a different user or group,
# customize your systemd unit file for mariadb according to the
# instructions in http://fedoraproject.org/wiki/Systemd
[mysqld_safe]
log-error=/var/log/mysql/mysql.log
pid-file=/var/run/mysqld/mysql.pid
default-authentication-plugin=mysql_native_password
#
# include all files from the config directory
#
!includedir /etc/my.cnf.d
Here is content of log file:
2022-05-04T12:55:43.099391Z 0 [Warning] [MY-011070] [Server] 'Disabling symbolic links using --skip-symbolic-links (or equivalent) is the default. Consider not using this option as it' is deprecated and will be removed in a future release.
2022-05-04T12:55:43.099544Z 0 [Warning] [MY-010918] [Server] 'default_authentication_plugin' is deprecated and will be removed in a future release. Please use authentication_policy instead.
2022-05-04T12:55:43.099568Z 0 [System] [MY-010116] [Server] /usr/local/mysql-8.0.29-linux-glibc2.12-x86_64/bin/mysqld (mysqld 8.0.29) starting as process 168373
2022-05-04T12:55:43.109360Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started.
2022-05-04T12:55:43.365377Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended.
2022-05-04T12:55:43.636896Z 0 [Warning] [MY-010068] [Server] CA certificate ca.pem is self signed.
2022-05-04T12:55:43.636955Z 0 [System] [MY-013602] [Server] Channel mysql_main configured to support TLS. Encrypted connections are now supported for this channel.
2022-05-04T12:55:43.666874Z 0 [System] [MY-011323] [Server] X Plugin ready for connections. Bind-address: '::' port: 33060, socket: /tmp/mysqlx.sock
2022-05-04T12:55:43.666940Z 0 [System] [MY-010931] [Server] /usr/local/mysql-8.0.29-linux-glibc2.12-x86_64/bin/mysqld: ready for connections. Version: '8.0.29' socket: '/var/lib/mysql/mysql.sock' port: 3306 MySQL Community Server - GPL.
and file /usr/lib64/mysql/plugin/caching_sha2_password.so is just an empty file. so i try to remove it then another issue come
ERROR 2059 (HY000): Authentication plugin 'caching_sha2_password' cannot be loaded: /usr/lib64/mysql/plugin/caching_sha2_password.so: cannot open shared object file: No such file or directory
Anybody know how to fix this issue? Look like mysqld_safe still running with config caching_sha2_password is enabled (https://dev.mysql.com/doc/refman/8.0/en/server-system-variables.html#sysvar_default_authentication_plugin)
Thanks