Circleci/mysql: Authentication plugin 'caching_sha2_password' cannot be loaded

We’ve just recently got into trouble with all our tests because of an error when running mysql --host 127.0.0.1:

ERROR 2059 (HY000): Authentication plugin 'caching_sha2_password' cannot be loaded: Error loading shared library /usr/lib/mysql/plugin/caching_sha2_password.so: No such file or directory Exited with code 1

Parts of our config.yml:

jobs:
  build:
    environment:
    docker:
      - image: circleci/mysql:5.5
      - image: rabbitmq:3-alpine
      ...
    working_directory: ~/webapp

    steps:
      ...
      - run:
          name: Prepare DB
          command: echo "create database" | mysql --host 127.0.0.1

This did only occured the last couple of days, and we did not make any changes related to circle or mysql.
Any idea how to fix this?

I don’t use circleci/mysql:5.5, but something to try: track down the source of it on GitHub, and see if some changes have been made to it recently. You could try pinning to a specific digest instead of the general version 5.5, since presently you’d be pulling any patch-level changes with every build.

And, of course, if you get completely stuck, try a different MySQL image from Docker Hub, or roll your own. I expect a basic MySQL server on Alpine is 10 lines or so in a Dockerfile.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.