Open
Conversation
If mysqld_exporter runs on the same system as the database, socket based authentication removes the need to manage a password. Signed-off-by: Karsten Heymann <karsten.heymann@gmail.com>
SuperQ
requested changes
Mar 14, 2023
|
|
||
| ```shell | ||
| ## run as user mysqld_exporter: | ||
| export DATA_SOURCE_NAME="mysqld_exporter:@unix(/var/run/mysqld/mysqld.sock)/" |
Member
There was a problem hiding this comment.
Thanks, but we need to update this to use the new config file format or command line flag (--mysqld.address=).
There was a problem hiding this comment.
How would the new format look like?
i tried both, but it doesn't seem to work:
--mysqld.address="unix(/var/run/mariadb/mysql.sock)"
2023-07-05T16:16:30.833935+02:00 db mariadb_exporter[3181430]: ts=2023-07-05T14:16:30.832Z caller=mysqld_exporter.go:225 level=info msg="Error parsing host config" file=.my.cnf err="failed to parse address: address unix(/var/run/mariadb/mysql.sock): missing port in address"
--mysqld.address="unix:///var/run/mariadb/mysql.sock"
2023-07-05T16:17:31.077223+02:00 db mariadb_exporter[3181808]: ts=2023-07-05T14:17:31.075Z caller=config.go:146 level=error msg="failed to parse config" section=client err="set field \"port\": strconv.ParseInt: parsing \"///var/run/mariadb/mysql.sock\": invalid syntax"
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
If mysqld_exporter runs on the same system as the database, socket based authentication removes the need to manage a password.
Signed-off-by: Karsten Heymann karsten.heymann@gmail.com