From: Florian Forster Date: Sat, 11 May 2013 08:59:02 +0000 (+0200) Subject: collectd.conf(5): Add documentation for the MIC plugin. X-Git-Tag: collectd-5.4.0~42^2~7 X-Git-Url: https://git.verplant.org/?a=commitdiff_plain;h=6f66468e2d2f7f65bf811faf8d45d83b26d435de;p=collectd.git collectd.conf(5): Add documentation for the MIC plugin. --- diff --git a/src/collectd.conf.in b/src/collectd.conf.in index 270da310..e103863a 100644 --- a/src/collectd.conf.in +++ b/src/collectd.conf.in @@ -1028,18 +1028,17 @@ # # -# ShowTotalCPU true -# ShowPerCPU true +# ShowCPU true +# ShowCPUCores true # ShowMemory true -# ShowTemps true -#Temperature Sensors can be ignored/shown by repeaded -#TempSensor Lines, and then inverted with a IgnoreTempSelected -#Known Temperature sensors: die, devmem, fin, fout, vccp, vddg, vddq -# TempSensor vddg -# IgnoreTempSelected true +# ShowTemperatures true +## Temperature Sensors can be ignored/shown by repeaded #TempSensor lines, and +## then inverted with a IgnoreTempSelected. +## Known Temperature sensors: die, devmem, fin, fout, vccp, vddg, vddq +# Temperature vddg +# IgnoreSelectedTemperature true # - # # This tag support an argument if you want to # monitor the local instance just use diff --git a/src/collectd.conf.pod b/src/collectd.conf.pod index 8606d3e0..242c8f84 100644 --- a/src/collectd.conf.pod +++ b/src/collectd.conf.pod @@ -2207,7 +2207,7 @@ interpreted. For a description of match blocks, please see L<"Plugin tail">. =head2 Plugin C -The C connects to a memcached server and queries statistics +The B connects to a memcached server and queries statistics about cache utilization, memory and bandwidth used. L @@ -2239,6 +2239,82 @@ setting is given, the B and B settings are ignored. =back +=head2 Plugin C + +The B gathers CPU statistics, memory usage and temperatures from +Intel's Many Integrated Core (MIC) systems. + +B + + + ShowCPU true + ShowCPUCores true + ShowMemory true + + ShowTemperatures true + Temperature vddg + Temperature vddq + IgnoreSelectedTemperature true + + +The following options are valid inside the Bmic> block: + +=over 4 + +=item B B|B + +If enabled (the default) a sum of the CPU usage accross all cores is reported. + +=item B B|B + +If enabled (the default) per-core CPU usage is reported. + +=item B B|B + +If enabled (the default) the physical memory usage of the MIC system is +reported. + +=item B B|B + +If enabled (the default) various temperatures of the MIC system are reported. + +=item B I + +This option controls which temperatures are being reported. Whether matching +temperatures are being ignored or I matching temperatures are reported +depends on the B setting below. By default I +temperatures are reported. + +=item B B|B + +Controls the behavior of the B setting above. If set to B +(the default) only temperatures matching a B option are reported +or, if no B option is specified, all temperatures are reported. If +set to B, matching temperatures are I and all other temperatures +are reported. + +Known temperature names are: + +=over 4 + +=item die + +=item devmem + +=item fin + +=item fout + +=item vccp + +=item vddg + +=item vddq + +=back + +=back + =head2 Plugin C The B connects to a Modbus "slave" via Modbus/TCP and reads @@ -2246,7 +2322,7 @@ register values. It supports reading single registers (unsigned 16Ebit values), large integer values (unsigned 32Ebit values) and floating point values (two registers interpreted as IEEE floats in big endian notation). -Synopsis: +B RegisterBase 0 diff --git a/src/mic.c b/src/mic.c index a2d4dc33..b2eeeabb 100644 --- a/src/mic.c +++ b/src/mic.c @@ -45,22 +45,21 @@ static char const * const therm_names[] = { static const char *config_keys[] = { - "ShowTotalCPU", - "ShowPerCPU", - "ShowTemps", + "ShowCPU", + "ShowCPUCores", "ShowMemory", - "TempSensor", - "IgnoreTempSelected", + "ShowTemperatures", + "Temperature", + "IgnoreSelectedTemperature", }; static int config_keys_num = STATIC_ARRAY_SIZE (config_keys); -static _Bool show_total_cpu = 1; -static _Bool show_per_cpu = 1; -static _Bool show_temps = 1; +static _Bool show_cpu = 1; +static _Bool show_cpu_cores = 1; static _Bool show_memory = 1; +static _Bool show_temps = 1; static ignorelist_t *temp_ignore = NULL; - static int mic_init (void) { U32 ret; @@ -93,15 +92,15 @@ static int mic_config (const char *key, const char *value) { if (temp_ignore == NULL) return (1); - if (strcasecmp("ShowTotalCPU",key) == 0) + if (strcasecmp("ShowCPU",key) == 0) { - show_total_cpu = IS_TRUE(value); + show_cpu = IS_TRUE(value); } - else if (strcasecmp("ShowPerCPU",key) == 0) + else if (strcasecmp("ShowCPUCores",key) == 0) { - show_per_cpu = IS_TRUE(value); + show_cpu_cores = IS_TRUE(value); } - else if (strcasecmp("ShowTemps",key) == 0) + else if (strcasecmp("ShowTemperatures",key) == 0) { show_temps = IS_TRUE(value); } @@ -109,11 +108,11 @@ static int mic_config (const char *key, const char *value) { { show_memory = IS_TRUE(value); } - else if (strcasecmp("TempSensor",key) == 0) + else if (strcasecmp("Temperature",key) == 0) { ignorelist_add(temp_ignore,value); } - else if (strcasecmp("IgnoreTempSelected",key) == 0) + else if (strcasecmp("IgnoreSelectedTemperature",key) == 0) { int invert = 1; if (IS_TRUE(value)) @@ -256,14 +255,14 @@ static int mic_read_cpu(int mic) return(-1); } - if (show_total_cpu) { + if (show_cpu) { mic_submit_cpu(mic, "user", -1, core_util.sum.user); mic_submit_cpu(mic, "sys", -1, core_util.sum.sys); mic_submit_cpu(mic, "nice", -1, core_util.sum.nice); mic_submit_cpu(mic, "idle", -1, core_util.sum.idle); } - if (show_per_cpu) { + if (show_cpu_cores) { int j; for (j = 0; j < core_util.core; j++) { mic_submit_cpu(mic, "user", j, core_jiffs[j].user); @@ -296,7 +295,7 @@ static int mic_read (void) if (error == 0 && show_temps) error = mic_read_temps(i); - if (error == 0 && (show_total_cpu || show_per_cpu)) + if (error == 0 && (show_cpu || show_cpu_cores)) error = mic_read_cpu(i); ret = MicCloseAdapter(mic_handle);