summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: fa25bf3)
raw | patch | inline | side by side (parent: fa25bf3)
author | Sebastian Harl <sh@tokkee.org> | |
Fri, 20 Mar 2009 20:36:01 +0000 (21:36 +0100) | ||
committer | Sebastian Harl <sh@tokkee.org> | |
Fri, 20 Mar 2009 20:53:51 +0000 (21:53 +0100) |
Also, updated the sample configuration in collectd.conf.in.
src/collectd.conf.in | patch | blob | history | |
src/collectd.conf.pod | patch | blob | history |
diff --git a/src/collectd.conf.in b/src/collectd.conf.in
index 3abc24d1869ba047fb3a344c9b690b0649d7f4c7..44eaa974d250ffb90caa90a775cd8e765ee6a00a 100644 (file)
--- a/src/collectd.conf.in
+++ b/src/collectd.conf.in
#</Plugin>
#<Plugin mysql>
-# Host "database.serv.er"
-# User "db_user"
-# Password "secret"
-# Database "db_name"
+# <Database db_name>
+# Host "database.serv.er"
+# User "db_user"
+# Password "secret"
+# Database "db_name"
+# </Database>
+#
+# <Database db_name2>
+# Host "localhost"
+# Socket "/var/run/mysql/mysqld.sock"
+# </Database>
#</Plugin>
#<Plugin netlink>
diff --git a/src/collectd.conf.pod b/src/collectd.conf.pod
index 19ca6c50442f3299fa3c914bd23f1b68548c733a..00854ef6d82a96bc817408ebd4114a47f5f927ba 100644 (file)
--- a/src/collectd.conf.pod
+++ b/src/collectd.conf.pod
=head2 Plugin C<mysql>
-The C<mysql plugin> requires B<mysqlclient> to be installed. It connects to the
-database when started and keeps the connection up as long as possible. When the
-connection is interrupted for whatever reason it will try to re-connect. The
-plugin will complaint loudly in case anything goes wrong.
+The C<mysql plugin> requires B<mysqlclient> to be installed. It connects to
+one or more databases when started and keeps the connection up as long as
+possible. When the connection is interrupted for whatever reason it will try
+to re-connect. The plugin will complaint loudly in case anything goes wrong.
This plugin issues the MySQL C<SHOW STATUS> command and collects information
about MySQL network traffic, executed statements, requests, the query cache
@@ -1387,7 +1387,26 @@ C<Handler_*>, C<Qcache_*> and C<Threads_*> return values. Please refer to the
B<MySQL reference manual>, I<5.1.6. Server Status Variables> for an
explanation of these values.
-Use the following options to configure the plugin:
+Synopsis:
+
+ <Plugin mysql>
+ <Database foo>
+ Host "hostname"
+ User "username"
+ Password "password"
+ Port "3306"
+ </Database>
+
+ <Database bar>
+ Host "localhost"
+ Socket "/var/run/mysql/mysqld.sock"
+ </Database>
+ </Plugin>
+
+A B<Database> block defines one connection to a MySQL database. It accepts a
+single argument which specifies the name of the database. None of the other
+options are required. MySQL will use default values as documented in the
+section "mysql_real_connect()" in the B<MySQL reference manual>.
=over 4