query-exporter
query-exporter copied to clipboard
Unable to set ssl_mode on the dsn for mysql
Describe the bug
When adding ?ssl_mode=PREFERRED to a mysql DSN using the docker image, I get:
MySQL client library does not support ssl_mode specification
Installation details
- operating system: CentOS 7.9
- query-exporter installation type:
- docker image: docker
To Reproduce
If possible, please provide detailed steps to reproduce the behavior: MySQL configured with SSL. Local connections work, yet get Access Denied with query_exporter. So attempted to set ssl_mode=PREFERRED
-
Config file content (redacted of secrets if needed)
databasenamehere: dsn: mysql://user:pass@<host>/<database>?ssl_mode=PREFERRED
-
Ran query-exporter with the following command line ...
docker run -p 9560:9560/tcp -v "/etc/query_exporter.yaml:/config.yaml" --rm -it adonato/query-exporter:latest
-
Got the error when ... When attempting to do connections, see in the log:
MySQL client library does not support ssl_mode specification