Renamed vserver-<xid>/threads.rrd to vserver-<xid>/vs_threads.rrd.
[collectd.git] / src / collectd.pod
index 935f2fe..8227ed9 100644 (file)
@@ -16,10 +16,18 @@ settings. The following features may be available:
 
 =item
 
+Battery status (I<battery>)
+
+=item
+
 CPU utilization (I<cpu>)
 
 =item
 
+Mountpoint usage (I<df>)
+
+=item
+
 Disk and partition usage/throughput (I<disk>)
 
 =item
@@ -36,6 +44,10 @@ Memory usage (I<memory>)
 
 =item
 
+MySQL statistics (I<mysql>)
+
+=item
+
 NFS utilization (I<nfs>, Linux only)
 
 =item
@@ -70,27 +82,21 @@ Network traffic (I<traffic>)
 
 Number of users logged into the system (I<users>)
 
+=item
+
+System ressources used by VServers (I<vserver>)
+
 =back
 
 =head1 OPTIONS
 
 =over 4
 
-=item B<-l>
+=item B<-C> I<E<lt>config-fileE<gt>>
 
-Start in local mode. This is the default. No data will be sent or read to/from
-the network. Information will be read and written by the same process. See
-L<"MODES">.
-
-=item B<-c>
-
-Start in client (transmitter) mode. Data will be sent to the multicast group.
-See L<"MODES">.
-
-=item B<-s>
-
-Start in server (receiver) mode. Data sent to the multicast group will be read
-and stored in RRD files. See L<"MODES">.
+Specify an alternative config file. This is the place to go when you wish to
+change B<collectd>'s behavior. The path may be relative to the current working
+directory.
 
 =item B<-f>
 
@@ -98,31 +104,87 @@ Don't fork to the background. I<collectd> will also B<not> close standard file
 descriptors, detach from the session nor write a pid file. This is mainly
 thought for 'supervisioning' init replacements such as I<runit>.
 
-=item B<-D> I<E<lt>directoryE<gt>>
+=item B<-h>
+
+Output usage information and exit.
 
-Sets the directory collectd should work in. All F<.rrd>-files are created in
-this directory. Per default this is F</var/lib/collectd/>.
+=back
 
-=item B<-M> I<E<lt>directoryE<gt>>
+=head1 MODES
 
-Sets the directory collectd should look for plugins in. Per default this is
-F</usr/lib/collectd>.
+collectd can operate in three different operating modes. The modes are
+described below.
 
-=item B<-P> I<E<lt>fileE<gt>>
+The simplest mode is the so called B<local mode>. Data is collected locally and
+written in RRD files that reside in I<DataDir>. This is the default mode when
+collectd is linked against C<librrd>.
 
-Sets the PID-file.
+The other two modes, B<client mode> and B<server mode>, are used to send data
+over a network and receive it again.
 
-=item B<-h>
+In B<client mode> the daemon collects the data locally and sends it's results
+to one or more network addresses. No RRD files are written in this case. This
+is the only mode available if collectd is not linked against C<librrd>.
 
-Output usage information and exit.
+If started in B<server mode> the daemon will listen on one or more interfaces
+and write the data it receives to RRD files. No data is collected locally.
 
-=item B<-p> I<E<lt>hostE<gt>>
+Please refer to L<collectd.conf(5)> for the configuration options and default
+values.
 
-Sets the host to ping periodically. This option may be given more than once to
-ping multiple hosts. If this option is not given at least once no host will be
-pinged.
+=head1 SPECIAL PLUGINS
 
-=back
+=head2 cpufreq
+
+This module reads F</sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq> (for
+the first CPU installed) to get the current CPU frequency. If this file does
+not exist make sure B<cpufreqd> (L<http://cpufreqd.sourceforge.net/>) or a
+similar tool is installed.
+
+=head2 mysql
+
+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 syslog will
+contain loud complaints in case anything goes wrong.
+
+This plugin issues C<SHOW STATUS> and evaluates C<Bytes_{received,sent}>,
+C<Com_*> and C<Handler_*> which correspond to F<traffic-mysql.rrd>,
+F<mysql_commands-*.rrd> and F<mysql_handler-*.rrd>. Also, the values of
+C<Qcache_*> are put in F<mysql_qcache.rrd> and values of C<Threads_*> are put
+in F<mysql_threads.rrd>. Please refer to the B<MySQL reference manual>,
+I<5.2.4. Server Status Variables> for an explanation of these values.
+
+=head2 sensors
+
+The B<sensors> module uses lm_sensors to retrieve sensor-values. This means
+that all the needed modules have to be loaded and lm_sensors has to be
+configured (most likely by editing F</etc/sensors.conf>. Read
+L<sensors.conf(5)> for details.
+
+The B<lm_sensors> homepage can be found at
+L<http://secure.netroedge.com/~lm78/>.
+
+=head2 hddtemp
+
+To get values from B<hddtemp> collectd connects to B<localhost> (127.0.0.1),
+port B<7634/tcp>. The B<Host> and B<Port> options can be used to change these
+default values. See L<collectd.conf(5)> for details. C<hddtemp> has to be
+running to work correctly. If C<hddtemp> is not running timeouts may appear
+which may interfere with other statistics..
+
+The B<hddtemp> homepage can be found at
+L<http://www.guzu.net/linux/hddtemp.php>.
+
+=head2 vserver
+
+B<VServer> support is only available for Linux. It cannot yet be found in a 
+vanilla kernel, though. To make use of this plugin you need a kernel that has 
+B<VServer> support built in, i.e. you need to apply the patches and compile 
+your own kernel, which will then provide the /proc/virtual filesystem that is
+required by this plugin.
+
+The B<VServer> homepage can be found at L<http://linux-vserver.org/>.
 
 =head1 RRD FILES
 
@@ -151,6 +213,18 @@ The DS'es depend on the module creating the RRD files:
 
 =over 4
 
+=item Battery charge (F<battery-I<E<lt>nameE<gt>>/charge.rrd>)
+
+  DS:charge:GAUGE:25:0:U
+
+=item Battery current (F<battery-I<E<lt>nameE<gt>>/current.rrd>)
+
+  DS:current:GAUGE:25:U:U
+
+=item Battery voltage (F<battery-I<E<lt>nameE<gt>>/voltage.rrd>)
+
+  DS:voltage:GAUGE:25:U:U
+
 =item CPU (F<cpu-I<E<lt>numE<gt>>.rrd>)
 
   DS:user:COUNTER:25:0:100
@@ -159,6 +233,11 @@ The DS'es depend on the module creating the RRD files:
   DS:idle:COUNTER:25:0:100
   DS:wait:COUNTER:25:0:100
 
+=item Mountpoints (F<df-I<E<lt>pathE<gt>>.rrd>)
+
+  DS:used:GAUGE:25:0:U
+  DS:free:GAUGE:25:0:U
+
 =item Diskstats (F<disk-I<E<lt>majorE<gt>>-I<E<lt>minorE<gt>>.rrd>)
 
   DS:rcount:COUNTER:25:0:U
@@ -194,6 +273,25 @@ The DS'es depend on the module creating the RRD files:
   DS:buffers:GAUGE:25:0:9223372036854775807
   DS:cached:GAUGE:25:0:9223372036854775807
 
+=item MySQL commands and handlers (F<mysql_commands-I<E<lt>commandE<gt>>.rrd> and F<mysql_handler-I<E<lt>handlerE<gt>>.rrd>)
+
+  DS:value:COUNTER:25:0:U
+
+=item MySQL query cache (F<mysql_qcache.rrd>)
+
+  DS:hits:COUNTER:25:0:U
+  DS:inserts:COUNTER:25:0:U
+  DS:not_cached:COUNTER:25:0:U
+  DS:lowmem_prunes:COUNTER:25:0:U
+  DS:queries_in_cache:GAUGE:25:0:U
+
+=item MySQL threads (F<mysql_threads.rrd>)
+
+  DS:running:GAUGE:25:0:U
+  DS:connected:GAUGE:25:0:U
+  DS:cached:GAUGE:25:0:U
+  DS:created:COUNTER:25:0:U
+
 =item NFSv2 Procedures (F<nfs2_procedures-I<(client|server)>.rrd>)
 
   DS:null:COUNTER:25:0:U
@@ -289,76 +387,42 @@ The DS'es depend on the module creating the RRD files:
 
   DS:users:GAUGE:25:0:65535
 
-=back
-
-=head1 MODES
-
-By default collectd starts in the so called I<local mode> which is not very
-interesting. It collects data and writes it into RRD files in
-F</var/lib/collectd>. There's nothing special so I won't discuss that in more
-detail..
-
-Please be aware that B<client-, local- and server-mode are mutual exclusive>. A
-later declaration overrides earlier ones. I<collectd -l -c -s> will start in
-server-mode. If you want statistics of the server too you will have to start a
-client process as well.
-
-Starting with version 3 collectd may send data over a network. As common with
-network stuff there are two modes: A I<sender> and a I<listener>. Since one
-usually has many senders and only a few listeners the sender is also called
-I<client> (using the option B<-c>) and the listener is called I<server> (using
-the option B<-s>).
+=item VServer load (F<vserver-I<E<lt>xidE<gt>>/load.rrd>)
 
-Communication happends using the (IPv4) multicast group B<239.192.74.66> and
-packets sent to the port B<25826/udp>. Every ten seconds the I<client> queries
-all the modules and sends the collected data to the multicast group. The
-I<server> subscribes to the multicast group upon startup and then waits for
-incoming packets. As it receives the packets it checks wether it has the
-neccessary module and, if found, writes the data to an RRD file, creating
-directories and files as needed.
+  DS:shortterm:GAUGE:25:0:100
+  DS:midterm:GAUGE:25:0:100
+  DS:longterm:GAUGE:25:0:100
 
-The multicast group used is within the I<Organization Local Scope> as defined
-by L<RFC2365>. Addresses within that space are meant to be routed within an AS
-but not to the outside. However collectd cannot control this and won't try. So
-it's totally up to you to secure your net.
+=item VServer threads (F<vserver-I<E<lt>xidE<gt>>/threads.rrd>)
 
-The UDP port used has been checked to not be assigned by the IANA.
+  DS:total:GAUGE:25:0:65535
+  DS:running:GAUGE:25:0:65535
+  DS:uninterruptible:GAUGE:25:0:65535
+  DS:onhold:GAUGE:25:0:65535
 
-On multi-homed machines you may need to add a route to the multicast net
-(B<224.0.0.0/4>) if multicast packages take the wrong interface. The listener
-on the other hand listens on B<all> interfaces.
+=item VServer network traffic (F<vserver-I<E<lt>xidE<gt>>/traffic-I<E<lt>nameE<gt>>.rrd>)
 
-=head1 SPECIAL MODULES
+  DS:incoming:COUNTER:25:0:9223372036854775807
+  DS:outgoing:COUNTER:25:0:9223372036854775807
+  DS:failed:COUNTER:25:0:9223372036854775807
 
-=head2 cpufreq
+=item VServer processes (F<vserver-I<E<lt>xidE<gt>>/vs_processes.rrd>)
 
-This module reads F</sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_cur_freq> (for
-the first CPU installed) to get the current CPU frequency. If this file does
-not exist make sure B<cpufreqd> (L<http://cpufreqd.sourceforge.net/>) or a
-similar tool is installed.
+  DS:total:GAUGE:25:0:65535
 
-=head2 sensors
+=item VServer memory usage (F<vserver-I<E<lt>xidE<gt>>/vs_memory.rrd>)
 
-The B<sensors> module uses lm_sensors to retrieve sensor-values. This means
-that all the needed modules have to be loaded and lm_sensors has to be
-configured (most likely by editing F</etc/sensors.conf>. Read
-L<sensors.conf(5)> for details.
-
-The B<lm_sensors> homepage can be found at
-L<http://secure.netroedge.com/~lm78/>.
-
-=head2 hddtemp
+  DS:vm:GAUGE:25:0:9223372036854775807
+  DS:vml:GAUGE:25:0:9223372036854775807
+  DS:rss:GAUGE:25:0:9223372036854775807
+  DS:anon:GAUGE:25:0:9223372036854775807
 
-To get values from B<hddtemp> collectd connects to B<localhost> (127.0.0.1),
-port B<7634/tcp>. hddtemp has to be running to work correctly. If hddtemp is
-not running timeouts may appear which may interfere with other statistics..
-
-The B<hddtemp> homepage can be found at
-L<http://www.guzu.net/linux/hddtemp.php>.
+=back
 
 =head1 SEE ALSO
 
-L<rrdtool(1)>, L<sensors(1)>, L<hddtemp(8)>, L<kstat(3KSTAT)>
+L<collectd.conf(5)>, L<rrdtool(1)>, L<sensors(1)>, L<hddtemp(8)>,
+L<kstat(3KSTAT)>
 
 =head1 AUTHOR