Closed JashBook closed 6 months ago
Based on the reproduction steps, I found that there is no user named kbadmin
. It seems that kubeblocks did not automatically create the kbadmin
user.
MySQL [(none)]> SELECT user, host, plugin FROM mysql.user;
+------------------+-----------+-----------------------+
| user | host | plugin |
+------------------+-----------+-----------------------+
| root | % | mysql_native_password |
| u1 | % | mysql_native_password |
| mysql.infoschema | localhost | caching_sha2_password |
| mysql.session | localhost | caching_sha2_password |
| mysql.sys | localhost | caching_sha2_password |
| root | localhost | mysql_native_password |
+------------------+-----------+-----------------------+
6 rows in set (0.005 sec)
This issue has been marked as stale because it has been open for 30 days with no activity
Describe the bug
To Reproduce Steps to reproduce the behavior:
read_write_splitting_policy=random
kbcli bench sysbench benchtest-scale-xmrbjz --cluster scale-xmrbjz --host scale-xmrbjz-vtgate.default.svc --user kbadmin --password "Ss82sK91q2" --database benchtest --namespace default --port 15306 --threads 4 --type oltp_read_write --tables 4 --size 1000 --duration 10 --driver mysql --extra-args="--auto_inc=false"
kubectl get pod NAME READY STATUS RESTARTS AGE benchtest-scale-xmrbjz-precheck-wkpp5 0/1 Error 0 86s
kubectl logs benchtest-scale-xmrbjz-precheck-wkpp5 2024/04/02 03:42:22 failed to ping MySQL server: Error 2012 (HY000): No authentication methods available for authentication.
kbcli cluster connect scale-xmrbjz --component vtgate --as-user kbadmin Password: Connect to instance scale-xmrbjz-vtgate-0 Defaulted container "vtgate" out of: vtgate, wait-vtctld-ready (init) ERROR 2012 (HY000): No authentication methods available for authentication. command terminated with exit code 1
kbcli cluster connect scale-xmrbjz --component mysql --as-user kbadmin Password: Connect to instance scale-xmrbjz-mysql-1: out of scale-xmrbjz-mysql-1(leader), scale-xmrbjz-mysql-0(follower), scale-xmrbjz-mysql-2(follower) Defaulted container "mysql" out of: mysql, metrics, vttablet, lorry, init-data (init) mysql: [Warning] Using a password on the command line interface can be insecure. ERROR 1045 (28000): Access denied for user 'kbadmin'@'localhost' (using password: YES) command terminated with exit code 1