prometheus / mysqld_exporter

Exporter for MySQL server metrics
http://prometheus.io/
Apache License 2.0
2.11k stars 745 forks source link

docker Exporter not connecting- SSL and certificate based login #569

Open cah-jyoti-prakash opened 3 years ago

cah-jyoti-prakash commented 3 years ago

What did you do that produced an error?

I am trying to run exporter which is ssl enabled and providing them certs in below docker command, and its not working for me

docker run -v /Users/jyoti.prakash/Documents/mysql:/etc/ssl/certs/ -p 9104:9104 -e DATA_SOURCE_NAME="userid:password@tcp(xx.xx.xx.xxx:3306)/mysql?ssl-ca=/etc/ssl/certs/qa-server-ca.pem&ssl-cert=/etc/ssl/certs/qa-client-cert.pem&ssl-key=/etc/ssl/certs/qa-client-key.pem" prom/mysqld-exporter

What did you expect to see? - Successful connection

What did you see instead? level=error ts=2021-08-13T21:09:58.668Z caller=exporter.go:136 msg="Error opening connection to database" err="invalid DSN: did you forget to escape a param value?"

cah-jyoti-prakash commented 3 years ago

any help?

cah-jyoti-prakash commented 3 years ago

any one?