├── LICENSE
├── README.md
├── etc
├── collectd.d
│ ├── apache.conf
│ ├── cassandra-22.conf
│ ├── cassandra.conf
│ ├── couchdb.conf
│ ├── elasticsearch-1.conf
│ ├── elasticsearch.conf
│ ├── hbase-095.conf
│ ├── hbase-098-standalone.conf
│ ├── hbase-098.conf
│ ├── hbase-thrift.conf
│ ├── jvm-sun-hotspot.conf
│ ├── kafka-082.conf
│ ├── memcached.conf
│ ├── mongodb.conf
│ ├── mysql.conf
│ ├── nginx.conf
│ ├── postgresql.conf
│ ├── rabbitmq.conf
│ ├── redis.conf
│ ├── riak.conf
│ ├── statsd.conf
│ ├── tomcat-7.conf
│ ├── varnish.conf
│ └── zookeeper.conf
├── httpd
│ └── conf.d
│ │ └── status.conf
└── nginx
│ └── conf.d
│ └── status.conf
└── templates
├── apache.conf.jinja
├── cassandra-22.conf.jinja
├── cassandra.conf.jinja
├── couchdb.conf.jinja
├── curl_json-metrics-base.jinja
├── elasticsearch-1.conf.jinja
├── elasticsearch.conf.jinja
├── hbase-095.conf.jinja
├── hbase-098-standalone.conf.jinja
├── hbase-098.conf.jinja
├── hbase-thrift.conf.jinja
├── jmx-metrics-base.jinja
├── jvm-sun-hotspot-macros.jinja
├── jvm-sun-hotspot.conf.jinja
├── kafka-082.conf.jinja
├── memcached.conf.jinja
├── mongodb.conf.jinja
├── mysql.conf.jinja
├── nginx.conf.jinja
├── postgresql.conf.jinja
├── rabbitmq.conf.jinja
├── redis.conf.jinja
├── render_templates.py
├── riak.conf.jinja
├── statsd.conf.jinja
├── tomcat-7.conf.jinja
├── varnish.conf.jinja
└── zookeeper.conf.jinja
/LICENSE:
--------------------------------------------------------------------------------
1 |
2 | Apache License
3 | Version 2.0, January 2004
4 | http://www.apache.org/licenses/
5 |
6 | TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
7 |
8 | 1. Definitions.
9 |
10 | "License" shall mean the terms and conditions for use, reproduction,
11 | and distribution as defined by Sections 1 through 9 of this document.
12 |
13 | "Licensor" shall mean the copyright owner or entity authorized by
14 | the copyright owner that is granting the License.
15 |
16 | "Legal Entity" shall mean the union of the acting entity and all
17 | other entities that control, are controlled by, or are under common
18 | control with that entity. For the purposes of this definition,
19 | "control" means (i) the power, direct or indirect, to cause the
20 | direction or management of such entity, whether by contract or
21 | otherwise, or (ii) ownership of fifty percent (50%) or more of the
22 | outstanding shares, or (iii) beneficial ownership of such entity.
23 |
24 | "You" (or "Your") shall mean an individual or Legal Entity
25 | exercising permissions granted by this License.
26 |
27 | "Source" form shall mean the preferred form for making modifications,
28 | including but not limited to software source code, documentation
29 | source, and configuration files.
30 |
31 | "Object" form shall mean any form resulting from mechanical
32 | transformation or translation of a Source form, including but
33 | not limited to compiled object code, generated documentation,
34 | and conversions to other media types.
35 |
36 | "Work" shall mean the work of authorship, whether in Source or
37 | Object form, made available under the License, as indicated by a
38 | copyright notice that is included in or attached to the work
39 | (an example is provided in the Appendix below).
40 |
41 | "Derivative Works" shall mean any work, whether in Source or Object
42 | form, that is based on (or derived from) the Work and for which the
43 | editorial revisions, annotations, elaborations, or other modifications
44 | represent, as a whole, an original work of authorship. For the purposes
45 | of this License, Derivative Works shall not include works that remain
46 | separable from, or merely link (or bind by name) to the interfaces of,
47 | the Work and Derivative Works thereof.
48 |
49 | "Contribution" shall mean any work of authorship, including
50 | the original version of the Work and any modifications or additions
51 | to that Work or Derivative Works thereof, that is intentionally
52 | submitted to Licensor for inclusion in the Work by the copyright owner
53 | or by an individual or Legal Entity authorized to submit on behalf of
54 | the copyright owner. For the purposes of this definition, "submitted"
55 | means any form of electronic, verbal, or written communication sent
56 | to the Licensor or its representatives, including but not limited to
57 | communication on electronic mailing lists, source code control systems,
58 | and issue tracking systems that are managed by, or on behalf of, the
59 | Licensor for the purpose of discussing and improving the Work, but
60 | excluding communication that is conspicuously marked or otherwise
61 | designated in writing by the copyright owner as "Not a Contribution."
62 |
63 | "Contributor" shall mean Licensor and any individual or Legal Entity
64 | on behalf of whom a Contribution has been received by Licensor and
65 | subsequently incorporated within the Work.
66 |
67 | 2. Grant of Copyright License. Subject to the terms and conditions of
68 | this License, each Contributor hereby grants to You a perpetual,
69 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable
70 | copyright license to reproduce, prepare Derivative Works of,
71 | publicly display, publicly perform, sublicense, and distribute the
72 | Work and such Derivative Works in Source or Object form.
73 |
74 | 3. Grant of Patent License. Subject to the terms and conditions of
75 | this License, each Contributor hereby grants to You a perpetual,
76 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable
77 | (except as stated in this section) patent license to make, have made,
78 | use, offer to sell, sell, import, and otherwise transfer the Work,
79 | where such license applies only to those patent claims licensable
80 | by such Contributor that are necessarily infringed by their
81 | Contribution(s) alone or by combination of their Contribution(s)
82 | with the Work to which such Contribution(s) was submitted. If You
83 | institute patent litigation against any entity (including a
84 | cross-claim or counterclaim in a lawsuit) alleging that the Work
85 | or a Contribution incorporated within the Work constitutes direct
86 | or contributory patent infringement, then any patent licenses
87 | granted to You under this License for that Work shall terminate
88 | as of the date such litigation is filed.
89 |
90 | 4. Redistribution. You may reproduce and distribute copies of the
91 | Work or Derivative Works thereof in any medium, with or without
92 | modifications, and in Source or Object form, provided that You
93 | meet the following conditions:
94 |
95 | (a) You must give any other recipients of the Work or
96 | Derivative Works a copy of this License; and
97 |
98 | (b) You must cause any modified files to carry prominent notices
99 | stating that You changed the files; and
100 |
101 | (c) You must retain, in the Source form of any Derivative Works
102 | that You distribute, all copyright, patent, trademark, and
103 | attribution notices from the Source form of the Work,
104 | excluding those notices that do not pertain to any part of
105 | the Derivative Works; and
106 |
107 | (d) If the Work includes a "NOTICE" text file as part of its
108 | distribution, then any Derivative Works that You distribute must
109 | include a readable copy of the attribution notices contained
110 | within such NOTICE file, excluding those notices that do not
111 | pertain to any part of the Derivative Works, in at least one
112 | of the following places: within a NOTICE text file distributed
113 | as part of the Derivative Works; within the Source form or
114 | documentation, if provided along with the Derivative Works; or,
115 | within a display generated by the Derivative Works, if and
116 | wherever such third-party notices normally appear. The contents
117 | of the NOTICE file are for informational purposes only and
118 | do not modify the License. You may add Your own attribution
119 | notices within Derivative Works that You distribute, alongside
120 | or as an addendum to the NOTICE text from the Work, provided
121 | that such additional attribution notices cannot be construed
122 | as modifying the License.
123 |
124 | You may add Your own copyright statement to Your modifications and
125 | may provide additional or different license terms and conditions
126 | for use, reproduction, or distribution of Your modifications, or
127 | for any such Derivative Works as a whole, provided Your use,
128 | reproduction, and distribution of the Work otherwise complies with
129 | the conditions stated in this License.
130 |
131 | 5. Submission of Contributions. Unless You explicitly state otherwise,
132 | any Contribution intentionally submitted for inclusion in the Work
133 | by You to the Licensor shall be under the terms and conditions of
134 | this License, without any additional terms or conditions.
135 | Notwithstanding the above, nothing herein shall supersede or modify
136 | the terms of any separate license agreement you may have executed
137 | with Licensor regarding such Contributions.
138 |
139 | 6. Trademarks. This License does not grant permission to use the trade
140 | names, trademarks, service marks, or product names of the Licensor,
141 | except as required for reasonable and customary use in describing the
142 | origin of the Work and reproducing the content of the NOTICE file.
143 |
144 | 7. Disclaimer of Warranty. Unless required by applicable law or
145 | agreed to in writing, Licensor provides the Work (and each
146 | Contributor provides its Contributions) on an "AS IS" BASIS,
147 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
148 | implied, including, without limitation, any warranties or conditions
149 | of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
150 | PARTICULAR PURPOSE. You are solely responsible for determining the
151 | appropriateness of using or redistributing the Work and assume any
152 | risks associated with Your exercise of permissions under this License.
153 |
154 | 8. Limitation of Liability. In no event and under no legal theory,
155 | whether in tort (including negligence), contract, or otherwise,
156 | unless required by applicable law (such as deliberate and grossly
157 | negligent acts) or agreed to in writing, shall any Contributor be
158 | liable to You for damages, including any direct, indirect, special,
159 | incidental, or consequential damages of any character arising as a
160 | result of this License or out of the use or inability to use the
161 | Work (including but not limited to damages for loss of goodwill,
162 | work stoppage, computer failure or malfunction, or any and all
163 | other commercial damages or losses), even if such Contributor
164 | has been advised of the possibility of such damages.
165 |
166 | 9. Accepting Warranty or Additional Liability. While redistributing
167 | the Work or Derivative Works thereof, You may choose to offer,
168 | and charge a fee for, acceptance of support, warranty, indemnity,
169 | or other liability obligations and/or rights consistent with this
170 | License. However, in accepting such obligations, You may act only
171 | on Your own behalf and on Your sole responsibility, not on behalf
172 | of any other Contributor, and only if You agree to indemnify,
173 | defend, and hold each Contributor harmless for any liability
174 | incurred by, or claims asserted against, such Contributor by reason
175 | of your accepting any such warranty or additional liability.
176 |
177 | END OF TERMS AND CONDITIONS
178 |
179 | APPENDIX: How to apply the Apache License to your work.
180 |
181 | To apply the Apache License to your work, attach the following
182 | boilerplate notice, with the fields enclosed by brackets "[]"
183 | replaced with your own identifying information. (Don't include
184 | the brackets!) The text should be enclosed in the appropriate
185 | comment syntax for the file format. We also recommend that a
186 | file or class name and description of purpose be included on the
187 | same "printed page" as the copyright notice for easier
188 | identification within third-party archives.
189 |
190 | Copyright [yyyy] [name of copyright owner]
191 |
192 | Licensed under the Apache License, Version 2.0 (the "License");
193 | you may not use this file except in compliance with the License.
194 | You may obtain a copy of the License at
195 |
196 | http://www.apache.org/licenses/LICENSE-2.0
197 |
198 | Unless required by applicable law or agreed to in writing, software
199 | distributed under the License is distributed on an "AS IS" BASIS,
200 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
201 | See the License for the specific language governing permissions and
202 | limitations under the License.
203 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | This repo contains sample configuration files for setting up
2 | the Stackdriver monitoring agent to access various services.
3 |
4 | More information on the Stackdriver monitoring agent can be found at
5 | https://cloud.google.com/monitoring/agent/
6 |
--------------------------------------------------------------------------------
/etc/collectd.d/apache.conf:
--------------------------------------------------------------------------------
1 | # This is the monitoring configuration for the Apache web server.
2 | # Make sure mod_status is enabled in your Apache configuration.
3 | # Look for APACHE_HOST and APACHE_PORT to adjust your configuration file.
4 | LoadPlugin apache
5 |
6 |
7 | # When using non-standard Apache configurations, replace the below with
8 | #URL "http://APACHE_HOST:APACHE_PORT/server-status/?auto"
9 | URL "http://local-stackdriver-agent.stackdriver.com:80/server-status/?auto"
10 |
11 |
12 |
--------------------------------------------------------------------------------
/etc/collectd.d/couchdb.conf:
--------------------------------------------------------------------------------
1 | # This is the monitoring configuration for CouchDB.
2 | # Look for COUCHDB_HOST and COUCHDB_PORT to adjust your configuration file.
3 | LoadPlugin curl_json
4 |
5 | # When using non-standard CouchDB configurations, replace the below with
6 | #
7 |
8 | Instance "couchdb"
9 |
10 |
11 | Type "counter"
12 |
13 |
14 | Type "counter"
15 |
16 |
17 | Type "gauge"
18 |
19 |
20 | Type "gauge"
21 |
22 |
23 | Type "gauge"
24 |
25 |
26 | Type "counter"
27 |
28 |
29 | Type "counter"
30 |
31 |
32 | Type "counter"
33 |
34 |
35 | Type "counter"
36 |
37 |
38 | Type "counter"
39 |
40 |
41 | Type "counter"
42 |
43 |
44 | Type "counter"
45 |
46 |
47 | Type "counter"
48 |
49 |
50 | Type "counter"
51 |
52 |
53 | Type "counter"
54 |
55 |
56 | Type "counter"
57 |
58 |
59 | Type "counter"
60 |
61 |
62 | Type "counter"
63 |
64 |
65 | Type "counter"
66 |
67 |
68 | Type "counter"
69 |
70 |
71 | Type "counter"
72 |
73 |
74 | Type "counter"
75 |
76 |
77 | Type "counter"
78 |
79 |
80 | Type "counter"
81 |
82 |
83 | Type "counter"
84 |
85 |
86 | Type "counter"
87 |
88 |
89 | Type "counter"
90 |
91 |
92 | Type "counter"
93 |
94 |
95 | Type "counter"
96 |
97 |
98 |
99 |
100 | LoadPlugin match_regex
101 | LoadPlugin target_set
102 | LoadPlugin target_replace
103 |
104 |
105 |
106 | Plugin "^curl_json$"
107 | PluginInstance "^couchdb.*$"
108 |
109 |
110 | PluginInstance "^couchdb" ""
111 |
112 |
113 | Plugin "couchdb"
114 |
115 |
116 |
117 |
118 | PluginInstance "^$"
119 |
120 |
121 | PluginInstance "localhost"
122 |
123 |
124 |
125 | Target "return"
126 |
127 |
128 |
129 |
130 |
131 |
132 | Chain "curl_json_couchdb"
133 |
134 |
135 |
136 | PreCacheChain "PreCache"
137 |
138 |
--------------------------------------------------------------------------------
/etc/collectd.d/elasticsearch-1.conf:
--------------------------------------------------------------------------------
1 | # This is the monitoring configuration for Elasticsearch 1.0.x and later.
2 | # Look for ELASTICSEARCH_HOST and ELASTICSEARCH_PORT to adjust your configuration file.
3 | LoadPlugin curl_json
4 |
5 | # When using non-standard Elasticsearch configurations, replace the below with
6 | #
7 |
8 | Instance "elasticsearch"
9 |
10 |
11 | Type "gauge"
12 |
13 |
14 | Type "gauge"
15 |
16 |
17 | Type "gauge"
18 |
19 |
20 | Type "counter"
21 |
22 |
23 | Type "counter"
24 |
25 |
26 | Type "counter"
27 |
28 |
29 | Type "counter"
30 |
31 |
32 | Type "counter"
33 |
34 |
35 | Type "counter"
36 |
37 |
38 | Type "counter"
39 |
40 |
41 | Type "counter"
42 |
43 |
44 | Type "counter"
45 |
46 |
47 | Type "counter"
48 |
49 |
50 | Type "counter"
51 |
52 |
53 | Type "counter"
54 |
55 |
56 | Type "counter"
57 |
58 |
59 | Type "counter"
60 |
61 |
62 | Type "gauge"
63 |
64 |
65 | Type "counter"
66 |
67 |
68 | Type "gauge"
69 |
70 |
71 | Type "counter"
72 |
73 |
74 | Type "gauge"
75 |
76 |
77 | Type "gauge"
78 |
79 |
80 | Type "gauge"
81 |
82 |
83 | Type "gauge"
84 |
85 |
86 | Type "gauge"
87 |
88 |
89 | Type "gauge"
90 |
91 |
92 | Type "gauge"
93 |
94 |
95 | Type "counter"
96 |
97 |
98 | Type "counter"
99 |
100 |
101 | Type "counter"
102 |
103 |
104 | Type "gauge"
105 |
106 |
107 | Type "gauge"
108 |
109 |
110 |
111 | # When using non-standard Elasticsearch configurations, replace the below with
112 | #
113 |
114 | Instance "elasticsearch"
115 |
116 |
117 | Type "gauge"
118 |
119 |
120 | Type "gauge"
121 |
122 |
123 | Type "gauge"
124 |
125 |
126 | Type "gauge"
127 |
128 |
129 | Type "gauge"
130 |
131 |
132 | Type "gauge"
133 |
134 |
135 | Type "gauge"
136 |
137 |
138 |
139 |
140 | LoadPlugin match_regex
141 | LoadPlugin target_set
142 | LoadPlugin target_replace
143 |
144 |
145 |
146 | Plugin "^curl_json$"
147 | PluginInstance "^elasticsearch.*$"
148 |
149 |
150 | PluginInstance "^elasticsearch" ""
151 |
152 |
153 | Plugin "elasticsearch"
154 |
155 |
156 |
157 |
158 | PluginInstance "^$"
159 |
160 |
161 | PluginInstance "localhost"
162 |
163 |
164 |
165 | Target "return"
166 |
167 |
168 |
169 |
170 |
171 |
172 | Chain "curl_json_elasticsearch"
173 |
174 |
175 |
176 | PreCacheChain "PreCache"
177 |
178 |
--------------------------------------------------------------------------------
/etc/collectd.d/elasticsearch.conf:
--------------------------------------------------------------------------------
1 | # This is the monitoring configuration for Elasticsearch 0.90.x and earlier.
2 | # Look for ELASTICSEARCH_HOST and ELASTICSEARCH_PORT to adjust your configuration file.
3 | LoadPlugin curl_json
4 |
5 | # When using non-standard Elasticsearch configurations, replace the below with
6 | #
7 |
8 | Instance "elasticsearch"
9 |
10 |
11 | Type "gauge"
12 |
13 |
14 | Type "gauge"
15 |
16 |
17 | Type "gauge"
18 |
19 |
20 | Type "counter"
21 |
22 |
23 | Type "counter"
24 |
25 |
26 | Type "counter"
27 |
28 |
29 | Type "counter"
30 |
31 |
32 | Type "counter"
33 |
34 |
35 | Type "counter"
36 |
37 |
38 | Type "counter"
39 |
40 |
41 | Type "counter"
42 |
43 |
44 | Type "counter"
45 |
46 |
47 | Type "counter"
48 |
49 |
50 | Type "counter"
51 |
52 |
53 | Type "counter"
54 |
55 |
56 | Type "counter"
57 |
58 |
59 | Type "counter"
60 |
61 |
62 | Type "gauge"
63 |
64 |
65 | Type "counter"
66 |
67 |
68 | Type "gauge"
69 |
70 |
71 | Type "counter"
72 |
73 |
74 | Type "gauge"
75 |
76 |
77 | Type "gauge"
78 |
79 |
80 | Type "gauge"
81 |
82 |
83 | Type "gauge"
84 |
85 |
86 | Type "gauge"
87 |
88 |
89 | Type "gauge"
90 |
91 |
92 | Type "gauge"
93 |
94 |
95 | Type "counter"
96 |
97 |
98 | Type "counter"
99 |
100 |
101 | Type "counter"
102 |
103 |
104 | Type "gauge"
105 |
106 |
107 | Type "gauge"
108 |
109 |
110 |
111 | # When using non-standard Elasticsearch configurations, replace the below with
112 | #
113 |
114 | Instance "elasticsearch"
115 |
116 |
117 | Type "gauge"
118 |
119 |
120 | Type "gauge"
121 |
122 |
123 | Type "gauge"
124 |
125 |
126 | Type "gauge"
127 |
128 |
129 | Type "gauge"
130 |
131 |
132 | Type "gauge"
133 |
134 |
135 | Type "gauge"
136 |
137 |
138 |
139 |
140 | LoadPlugin match_regex
141 | LoadPlugin target_set
142 | LoadPlugin target_replace
143 |
144 |
145 |
146 | Plugin "^curl_json$"
147 | PluginInstance "^elasticsearch.*$"
148 |
149 |
150 | PluginInstance "^elasticsearch" ""
151 |
152 |
153 | Plugin "elasticsearch"
154 |
155 |
156 |
157 |
158 | PluginInstance "^$"
159 |
160 |
161 | PluginInstance "localhost"
162 |
163 |
164 |
165 | Target "return"
166 |
167 |
168 |
169 |
170 |
171 |
172 | Chain "curl_json_elasticsearch"
173 |
174 |
175 |
176 | PreCacheChain "PreCache"
177 |
178 |
--------------------------------------------------------------------------------
/etc/collectd.d/hbase-095.conf:
--------------------------------------------------------------------------------
1 | # This is the monitoring configuration for HBase 0.95 and earlier.
2 | # Look for HBASE_HOST and HBASE_REGIONSERVER_PORT to adjust your configuration file.
3 | LoadPlugin java
4 |
5 | JVMARG "-Djava.class.path=/opt/stackdriver/collectd/share/collectd/java/collectd-api.jar:/opt/stackdriver/collectd/share/collectd/java/generic-jmx.jar"
6 | LoadPlugin "org.collectd.java.GenericJMX"
7 |
8 |
9 |
10 | ObjectName "hadoop:service=RegionServer,name=RegionServerStatistics"
11 | # The three attributes below are identical; they are renamed versions of each other.
12 |
13 | Type "gauge"
14 | InstancePrefix "regionserver-blockCacheHitPercent"
15 | Table false
16 | # This may be a name that was never used.
17 | Attribute "blockCacheExpressCachingRatio"
18 |
19 |
20 | Type "gauge"
21 | InstancePrefix "regionserver-blockCacheHitPercent"
22 | Table false
23 | # This is the name used in HBase 0.94 and earlier.
24 | Attribute "blockCacheHitCachingRatio"
25 |
26 |
27 | Type "gauge"
28 | InstancePrefix "regionserver-blockCacheHitPercent"
29 | Table false
30 | Attribute "blockCountHitPercent"
31 |
32 |
33 |
34 | Type "gauge"
35 | InstancePrefix "regionserver-callQueueLength"
36 | Table false
37 | Attribute "callQueueLength"
38 |
39 |
40 | # The two attributes below are identical; one is a renamed version of the other.
41 |
42 | Type "gauge"
43 | InstancePrefix "regionserver-compactionQueueLength"
44 | Table false
45 | # This is the name used in HBase 0.94 and earlier.
46 | Attribute "compactionQueueSize"
47 |
48 |
49 | Type "gauge"
50 | InstancePrefix "regionserver-compactionQueueLength"
51 | Table false
52 | Attribute "compactionQueueLength"
53 |
54 |
55 |
56 | Type "gauge"
57 | InstancePrefix "regionserver-flushQueueLength"
58 | Table false
59 | Attribute "flushQueueSize"
60 |
61 |
62 |
63 | Type "gauge"
64 | # Renamed for consistency with newer metrics.
65 | InstancePrefix "regionserver-memStoreSizeMB"
66 | Table false
67 | Attribute "memstoreSizeMB"
68 |
69 |
70 | Type "gauge"
71 | InstancePrefix "regionserver-numberOfOnlineRegions"
72 | Table false
73 | Attribute "numberOfOnlineRegions"
74 |
75 |
76 | Type "counter"
77 | # Renamed for consistency with newer metrics.
78 | InstancePrefix "regionserver-readRequestCount"
79 | Table false
80 | Attribute "readRequestsCount"
81 |
82 |
83 | Type "counter"
84 | # Renamed for consistency with newer metrics.
85 | InstancePrefix "regionserver-writeRequestCount"
86 | Table false
87 | Attribute "writeRequestsCount"
88 |
89 |
90 | Type "counter"
91 | # Renamed for consistency with newer metrics.
92 | InstancePrefix "regionserver-slowAppendCount"
93 | Table false
94 | Attribute "slowHLogAppendCount"
95 |
96 |
97 | Type "gauge"
98 | InstancePrefix "regionserver-usedHeapMB"
99 | Table false
100 | Attribute "usedHeapMB"
101 |
102 |
103 | Type "gauge"
104 | InstancePrefix "regionserver-blockCacheCount"
105 | Table false
106 | Attribute "blockCacheCount"
107 |
108 |
109 | # The two attributes below are identical; one is a renamed version of the other.
110 |
111 | Type "counter"
112 | InstancePrefix "regionserver-blockCacheEvictedCount"
113 | Table false
114 | # This is the name used in HBase 0.94 and earlier.
115 | Attribute "blockCacheEvictedCount"
116 |
117 |
118 | Type "counter"
119 | InstancePrefix "regionserver-blockCacheEvictionCount"
120 | Table false
121 | Attribute "blockCacheEvictionCount"
122 |
123 |
124 |
125 | Type "gauge"
126 | InstancePrefix "regionserver-blockCacheFreeMB"
127 | Table false
128 | Attribute "blockCacheFreeMB"
129 |
130 |
131 | Type "counter"
132 | InstancePrefix "regionserver-blockCacheHitCount"
133 | Table false
134 | Attribute "blockCacheHitCount"
135 |
136 |
137 | Type "counter"
138 | InstancePrefix "regionserver-blockCacheMissCount"
139 | Table false
140 | Attribute "blockCacheMissCount"
141 |
142 |
143 | Type "gauge"
144 | InstancePrefix "regionserver-blockCacheSizeMB"
145 | Table false
146 | Attribute "blockCacheSizeMB"
147 |
148 |
149 | Type "gauge"
150 | # Renamed for consistency with newer metrics.
151 | InstancePrefix "regionserver-storeCount"
152 | Table false
153 | Attribute "NumberOfStores"
154 |
155 |
156 | Type "gauge"
157 | InstancePrefix "regionserver-NumberOfStorefiles"
158 | Table false
159 | Attribute "NumberOfStorefiles"
160 |
161 |
162 | Type "gauge"
163 | InstancePrefix "regionserver-requestsPerSecond"
164 | Table false
165 | Attribute "requestsPerSecond"
166 |
167 |
168 | Type "gauge"
169 | InstancePrefix "regionserver-storeFileIndexSizeMB"
170 | Table false
171 | Attribute "storeFileIndexSizeMB"
172 |
173 |
174 |
175 |
176 |
177 | # When using non-standard HBase configurations, replace the below with
178 | #ServiceURL "service:jmx:rmi:///jndi/rmi://HBASE_HOST:HBASE_REGIONSERVER_PORT/jmxrmi"
179 | ServiceURL "service:jmx:rmi:///jndi/rmi://localhost:10102/jmxrmi"
180 | InstancePrefix "hbaseregionserver"
181 |
182 | Collect "hbase_regionserver_RegionServerStatistics"
183 |
184 |
185 |
186 |
187 | ObjectName "java.lang:type=Threading"
188 |
189 | Type "gauge"
190 | InstancePrefix "threading-daemon_thread_count"
191 | Table false
192 | Attribute "DaemonThreadCount"
193 |
194 |
195 | Type "gauge"
196 | InstancePrefix "threading-thread_count"
197 | Table false
198 | Attribute "ThreadCount"
199 |
200 |
201 | Type "gauge"
202 | InstancePrefix "threading-peak_thread_count"
203 | Table false
204 | Attribute "PeakThreadCount"
205 |
206 |
207 |
208 |
209 | ObjectName "java.lang:type=Memory"
210 |
211 | Type "memory"
212 | InstancePrefix "memory-heap_usage_committed"
213 | Table false
214 | Attribute "HeapMemoryUsage.committed"
215 |
216 |
217 | Type "memory"
218 | InstancePrefix "memory-non_heap_usage_committed"
219 | Table false
220 | Attribute "NonHeapMemoryUsage.committed"
221 |
222 |
223 | Type "memory"
224 | InstancePrefix "memory-heap_usage_used"
225 | Table false
226 | Attribute "HeapMemoryUsage.used"
227 |
228 |
229 | Type "memory"
230 | InstancePrefix "memory-non_heap_usage_used"
231 | Table false
232 | Attribute "NonHeapMemoryUsage.used"
233 |
234 |
235 | Type "memory"
236 | InstancePrefix "memory-heap_usage_max"
237 | Table false
238 | Attribute "HeapMemoryUsage.max"
239 |
240 |
241 | Type "memory"
242 | InstancePrefix "memory-non_heap_usage_max"
243 | Table false
244 | Attribute "NonHeapMemoryUsage.max"
245 |
246 |
247 |
248 |
249 | ObjectName "java.lang:type=Runtime"
250 |
251 | Type "counter"
252 | InstancePrefix "runtime-uptime"
253 | Table false
254 | Attribute "Uptime"
255 |
256 |
257 |
258 |
259 | ObjectName "java.lang:type=OperatingSystem"
260 |
261 | Type "gauge"
262 | InstancePrefix "os-open_fd_count"
263 | Table false
264 | Attribute "OpenFileDescriptorCount"
265 |
266 |
267 | Type "counter"
268 | InstancePrefix "os-process_cpu_time"
269 | Table false
270 | Attribute "ProcessCpuTime"
271 |
272 |
273 |
274 |
275 | ObjectName "java.lang:type=GarbageCollector,name=*"
276 | InstanceFrom "name"
277 |
278 | Type "counter"
279 | InstancePrefix "gc-collection_count"
280 | Table false
281 | Attribute "CollectionCount"
282 |
283 |
284 | Type "counter"
285 | InstancePrefix "gc-collection_time"
286 | Table false
287 | Attribute "CollectionTime"
288 |
289 |
290 |
291 |
292 | # When using non-standard HBase configurations, replace the below with
293 | #ServiceURL "service:jmx:rmi:///jndi/rmi://HBASE_HOST:HBASE_REGIONSERVER_PORT/jmxrmi"
294 | ServiceURL "service:jmx:rmi:///jndi/rmi://localhost:10102/jmxrmi"
295 | InstancePrefix "jvm"
296 |
297 | Collect "jvm_localhost_Threading"
298 | Collect "jvm_localhost_Memory"
299 | Collect "jvm_localhost_Runtime"
300 | Collect "jvm_localhost_os"
301 | Collect "jvm_localhost_gc"
302 |
303 |
304 |
305 |
306 | LoadPlugin match_regex
307 | LoadPlugin target_set
308 | LoadPlugin target_replace
309 | LoadPlugin target_scale
310 |
311 |
312 |
313 | Plugin "^GenericJMX$"
314 | PluginInstance "^hbase.*$"
315 |
316 |
317 | PluginInstance "hbase" ""
318 |
319 |
320 | Plugin "hbase"
321 |
322 |
323 |
324 |
325 | TypeInstance "^.*MB$"
326 |
327 |
328 | Factor 1048576 # 1024 * 1024
329 |
330 |
331 | TypeInstance "MB" ""
332 |
333 |
334 |
335 | Target "return"
336 |
337 |
338 |
339 |
340 |
341 |
342 | Chain "GenericJMX_hbase"
343 |
344 |
345 |
346 | PreCacheChain "PreCache"
347 |
348 |
349 |
350 |
351 | Plugin "^GenericJMX$"
352 | PluginInstance "^jvm.*$"
353 |
354 |
355 | PluginInstance "jvm" ""
356 |
357 |
358 | Plugin "jvm"
359 |
360 | Target "return"
361 |
362 |
363 |
364 |
365 |
366 |
367 | Chain "GenericJMX_jvm"
368 |
369 |
370 |
371 | PreCacheChain "PreCache"
372 |
--------------------------------------------------------------------------------
/etc/collectd.d/hbase-098-standalone.conf:
--------------------------------------------------------------------------------
1 | # This is the monitoring configuration for HBase 0.98 and later running in standalone mode
2 | # (all services on the same port).
3 | # Look for HBASE_HOST and HBASE_PORT to adjust your configuration file.
4 | LoadPlugin java
5 |
6 | JVMARG "-Djava.class.path=/opt/stackdriver/collectd/share/collectd/java/collectd-api.jar:/opt/stackdriver/collectd/share/collectd/java/generic-jmx.jar"
7 | LoadPlugin "org.collectd.java.GenericJMX"
8 |
9 |
10 |
11 | ObjectName "Hadoop:service=HBase,name=Master,sub=Server"
12 |
13 | Type "gauge"
14 | InstancePrefix "master-averageLoad"
15 | Table false
16 | Attribute "averageLoad"
17 |
18 |
19 | Type "gauge"
20 | InstancePrefix "master-numRegionServers"
21 | Table false
22 | Attribute "numRegionServers"
23 |
24 |
25 | Type "gauge"
26 | InstancePrefix "master-numDeadRegionServers"
27 | Table false
28 | Attribute "numDeadRegionServers"
29 |
30 |
31 |
32 |
33 | ObjectName "Hadoop:service=HBase,name=IPC,sub=IPC"
34 |
35 | Type "counter"
36 | InstancePrefix "ipc-sentBytes"
37 | Table false
38 | Attribute "sentBytes"
39 |
40 |
41 | Type "counter"
42 | InstancePrefix "ipc-receivedBytes"
43 | Table false
44 | Attribute "receivedBytes"
45 |
46 |
47 | Type "gauge"
48 | InstancePrefix "ipc-queueSize"
49 | Table false
50 | Attribute "queueSize"
51 |
52 |
53 | Type "gauge"
54 | InstancePrefix "ipc-numOpenConnections"
55 | Table false
56 | Attribute "numOpenConnections"
57 |
58 |
59 |
60 |
61 | ObjectName "Hadoop:service=HBase,name=RegionServer,sub=Server"
62 |
63 | Type "gauge"
64 | InstancePrefix "regionserver-blockCacheCount"
65 | Table false
66 | Attribute "blockCacheCount"
67 |
68 |
69 | Type "counter"
70 | InstancePrefix "regionserver-blockCacheEvictedCount"
71 | Table false
72 | Attribute "blockCacheEvictionCount"
73 |
74 |
75 | Type "gauge"
76 | InstancePrefix "regionserver-blockCacheFreeSize"
77 | Table false
78 | Attribute "blockCacheFreeSize"
79 |
80 |
81 | Type "counter"
82 | InstancePrefix "regionserver-blockCacheHitCount"
83 | Table false
84 | Attribute "blockCacheHitCount"
85 |
86 |
87 | # The two attributes below are identical; one is a renamed version of the other.
88 |
89 | Type "gauge"
90 | InstancePrefix "regionserver-blockCacheHitPercent"
91 | Table false
92 | # This is the name used in HBase 0.98 and earlier.
93 | Attribute "blockCountHitPercent"
94 |
95 |
96 | Type "gauge"
97 | InstancePrefix "regionserver-blockCacheHitPercent"
98 | Table false
99 | Attribute "blockCacheCountHitPercent"
100 |
101 |
102 |
103 | Type "counter"
104 | InstancePrefix "regionserver-blockCacheMissCount"
105 | Table false
106 | Attribute "blockCacheMissCount"
107 |
108 |
109 | Type "gauge"
110 | InstancePrefix "regionserver-blockCacheSize"
111 | Table false
112 | Attribute "blockCacheSize"
113 |
114 |
115 | Type "gauge"
116 | InstancePrefix "regionserver-compactionQueueLength"
117 | Table false
118 | Attribute "compactionQueueLength"
119 |
120 |
121 | Type "gauge"
122 | InstancePrefix "regionserver-flushQueueLength"
123 | Table false
124 | Attribute "flushQueueLength"
125 |
126 |
127 | Type "gauge"
128 | InstancePrefix "regionserver-memStoreSize"
129 | Table false
130 | Attribute "memStoreSize"
131 |
132 |
133 | Type "gauge"
134 | InstancePrefix "regionserver-storeCount"
135 | Table false
136 | Attribute "storeCount"
137 |
138 |
139 | Type "counter"
140 | InstancePrefix "regionserver-readRequestCount"
141 | Table false
142 | Attribute "readRequestCount"
143 |
144 |
145 | Type "gauge"
146 | InstancePrefix "regionserver-storeFileIndexSize"
147 | Table false
148 | Attribute "storeFileIndexSize"
149 |
150 |
151 | Type "counter"
152 | InstancePrefix "regionserver-writeRequestCount"
153 | Table false
154 | Attribute "writeRequestCount"
155 |
156 |
157 | Type "counter"
158 | InstancePrefix "regionserver-totalRequestCount"
159 | Table false
160 | Attribute "totalRequestCount"
161 |
162 |
163 | Type "counter"
164 | InstancePrefix "regionserver-slowAppendCount"
165 | Table false
166 | Attribute "slowAppendCount"
167 |
168 |
169 | Type "counter"
170 | InstancePrefix "regionserver-slowPutCount"
171 | Table false
172 | Attribute "slowPutCount"
173 |
174 |
175 | Type "counter"
176 | InstancePrefix "regionserver-slowGetCount"
177 | Table false
178 | Attribute "slowGetCount"
179 |
180 |
181 |
182 |
183 |
184 | # When using non-standard HBase configurations, replace the below with
185 | #ServiceURL "service:jmx:rmi:///jndi/rmi://HBASE_HOST:HBASE_PORT/jmxrmi"
186 | ServiceURL "service:jmx:rmi:///jndi/rmi://localhost:10101/jmxrmi"
187 | InstancePrefix "hbasemaster"
188 |
189 | Collect "hbase_master_Server"
190 | Collect "hbase_ipc_IPC"
191 |
192 |
193 |
194 | # When using non-standard HBase configurations, replace the below with
195 | #ServiceURL "service:jmx:rmi:///jndi/rmi://HBASE_HOST:HBASE_PORT/jmxrmi"
196 | ServiceURL "service:jmx:rmi:///jndi/rmi://localhost:10101/jmxrmi"
197 | InstancePrefix "hbaseregionserver"
198 |
199 | Collect "hbase_regionserver_RegionServerStatistics"
200 |
201 |
202 |
203 |
204 | ObjectName "java.lang:type=Threading"
205 |
206 | Type "gauge"
207 | InstancePrefix "threading-daemon_thread_count"
208 | Table false
209 | Attribute "DaemonThreadCount"
210 |
211 |
212 | Type "gauge"
213 | InstancePrefix "threading-thread_count"
214 | Table false
215 | Attribute "ThreadCount"
216 |
217 |
218 | Type "gauge"
219 | InstancePrefix "threading-peak_thread_count"
220 | Table false
221 | Attribute "PeakThreadCount"
222 |
223 |
224 |
225 |
226 | ObjectName "java.lang:type=Memory"
227 |
228 | Type "memory"
229 | InstancePrefix "memory-heap_usage_committed"
230 | Table false
231 | Attribute "HeapMemoryUsage.committed"
232 |
233 |
234 | Type "memory"
235 | InstancePrefix "memory-non_heap_usage_committed"
236 | Table false
237 | Attribute "NonHeapMemoryUsage.committed"
238 |
239 |
240 | Type "memory"
241 | InstancePrefix "memory-heap_usage_used"
242 | Table false
243 | Attribute "HeapMemoryUsage.used"
244 |
245 |
246 | Type "memory"
247 | InstancePrefix "memory-non_heap_usage_used"
248 | Table false
249 | Attribute "NonHeapMemoryUsage.used"
250 |
251 |
252 | Type "memory"
253 | InstancePrefix "memory-heap_usage_max"
254 | Table false
255 | Attribute "HeapMemoryUsage.max"
256 |
257 |
258 | Type "memory"
259 | InstancePrefix "memory-non_heap_usage_max"
260 | Table false
261 | Attribute "NonHeapMemoryUsage.max"
262 |
263 |
264 |
265 |
266 | ObjectName "java.lang:type=Runtime"
267 |
268 | Type "counter"
269 | InstancePrefix "runtime-uptime"
270 | Table false
271 | Attribute "Uptime"
272 |
273 |
274 |
275 |
276 | ObjectName "java.lang:type=OperatingSystem"
277 |
278 | Type "gauge"
279 | InstancePrefix "os-open_fd_count"
280 | Table false
281 | Attribute "OpenFileDescriptorCount"
282 |
283 |
284 | Type "counter"
285 | InstancePrefix "os-process_cpu_time"
286 | Table false
287 | Attribute "ProcessCpuTime"
288 |
289 |
290 |
291 |
292 | ObjectName "java.lang:type=GarbageCollector,name=*"
293 | InstanceFrom "name"
294 |
295 | Type "counter"
296 | InstancePrefix "gc-collection_count"
297 | Table false
298 | Attribute "CollectionCount"
299 |
300 |
301 | Type "counter"
302 | InstancePrefix "gc-collection_time"
303 | Table false
304 | Attribute "CollectionTime"
305 |
306 |
307 |
308 |
309 | # When using non-standard HBase configurations, replace the below with
310 | #ServiceURL "service:jmx:rmi:///jndi/rmi://HBASE_HOST:HBASE_PORT/jmxrmi"
311 | ServiceURL "service:jmx:rmi:///jndi/rmi://localhost:10101/jmxrmi"
312 | InstancePrefix "jvm"
313 |
314 | Collect "jvm_localhost_Threading"
315 | Collect "jvm_localhost_Memory"
316 | Collect "jvm_localhost_Runtime"
317 | Collect "jvm_localhost_os"
318 | Collect "jvm_localhost_gc"
319 |
320 |
321 |
322 |
323 | LoadPlugin match_regex
324 | LoadPlugin target_set
325 | LoadPlugin target_replace
326 |
327 |
328 |
329 | Plugin "^GenericJMX$"
330 | PluginInstance "^hbase.*$"
331 |
332 |
333 | PluginInstance "hbase" ""
334 |
335 |
336 | Plugin "hbase"
337 |
338 |
339 |
340 | Target "return"
341 |
342 |
343 |
344 |
345 |
346 |
347 | Chain "GenericJMX_hbase"
348 |
349 |
350 |
351 | PreCacheChain "PreCache"
352 |
353 |
354 |
355 |
356 | Plugin "^GenericJMX$"
357 | PluginInstance "^jvm.*$"
358 |
359 |
360 | PluginInstance "jvm" ""
361 |
362 |
363 | Plugin "jvm"
364 |
365 | Target "return"
366 |
367 |
368 |
369 |
370 |
371 |
372 | Chain "GenericJMX_jvm"
373 |
374 |
375 |
376 | PreCacheChain "PreCache"
377 |
--------------------------------------------------------------------------------
/etc/collectd.d/hbase-098.conf:
--------------------------------------------------------------------------------
1 | # This is the monitoring configuration for HBase 0.98 and later running in distributed mode.
2 | # Look for HBASE_HOST, HBASE_MASTER_PORT, and HBASE_REGIONSERVER_PORT to adjust your configuration file.
3 | LoadPlugin java
4 |
5 | JVMARG "-Djava.class.path=/opt/stackdriver/collectd/share/collectd/java/collectd-api.jar:/opt/stackdriver/collectd/share/collectd/java/generic-jmx.jar"
6 | LoadPlugin "org.collectd.java.GenericJMX"
7 |
8 |
9 |
10 | ObjectName "Hadoop:service=HBase,name=Master,sub=Server"
11 |
12 | Type "gauge"
13 | InstancePrefix "master-averageLoad"
14 | Table false
15 | Attribute "averageLoad"
16 |
17 |
18 | Type "gauge"
19 | InstancePrefix "master-numRegionServers"
20 | Table false
21 | Attribute "numRegionServers"
22 |
23 |
24 | Type "gauge"
25 | InstancePrefix "master-numDeadRegionServers"
26 | Table false
27 | Attribute "numDeadRegionServers"
28 |
29 |
30 |
31 |
32 | ObjectName "Hadoop:service=HBase,name=IPC,sub=IPC"
33 |
34 | Type "counter"
35 | InstancePrefix "ipc-sentBytes"
36 | Table false
37 | Attribute "sentBytes"
38 |
39 |
40 | Type "counter"
41 | InstancePrefix "ipc-receivedBytes"
42 | Table false
43 | Attribute "receivedBytes"
44 |
45 |
46 | Type "gauge"
47 | InstancePrefix "ipc-queueSize"
48 | Table false
49 | Attribute "queueSize"
50 |
51 |
52 | Type "gauge"
53 | InstancePrefix "ipc-numOpenConnections"
54 | Table false
55 | Attribute "numOpenConnections"
56 |
57 |
58 |
59 |
60 | ObjectName "Hadoop:service=HBase,name=RegionServer,sub=Server"
61 |
62 | Type "gauge"
63 | InstancePrefix "regionserver-blockCacheCount"
64 | Table false
65 | Attribute "blockCacheCount"
66 |
67 |
68 | Type "counter"
69 | InstancePrefix "regionserver-blockCacheEvictedCount"
70 | Table false
71 | Attribute "blockCacheEvictionCount"
72 |
73 |
74 | Type "gauge"
75 | InstancePrefix "regionserver-blockCacheFreeSize"
76 | Table false
77 | Attribute "blockCacheFreeSize"
78 |
79 |
80 | Type "counter"
81 | InstancePrefix "regionserver-blockCacheHitCount"
82 | Table false
83 | Attribute "blockCacheHitCount"
84 |
85 |
86 | # The two attributes below are identical; one is a renamed version of the other.
87 |
88 | Type "gauge"
89 | InstancePrefix "regionserver-blockCacheHitPercent"
90 | Table false
91 | # This is the name used in HBase 0.98 and earlier.
92 | Attribute "blockCountHitPercent"
93 |
94 |
95 | Type "gauge"
96 | InstancePrefix "regionserver-blockCacheHitPercent"
97 | Table false
98 | Attribute "blockCacheCountHitPercent"
99 |
100 |
101 |
102 | Type "counter"
103 | InstancePrefix "regionserver-blockCacheMissCount"
104 | Table false
105 | Attribute "blockCacheMissCount"
106 |
107 |
108 | Type "gauge"
109 | InstancePrefix "regionserver-blockCacheSize"
110 | Table false
111 | Attribute "blockCacheSize"
112 |
113 |
114 | Type "gauge"
115 | InstancePrefix "regionserver-compactionQueueLength"
116 | Table false
117 | Attribute "compactionQueueLength"
118 |
119 |
120 | Type "gauge"
121 | InstancePrefix "regionserver-flushQueueLength"
122 | Table false
123 | Attribute "flushQueueLength"
124 |
125 |
126 | Type "gauge"
127 | InstancePrefix "regionserver-memStoreSize"
128 | Table false
129 | Attribute "memStoreSize"
130 |
131 |
132 | Type "gauge"
133 | InstancePrefix "regionserver-storeCount"
134 | Table false
135 | Attribute "storeCount"
136 |
137 |
138 | Type "counter"
139 | InstancePrefix "regionserver-readRequestCount"
140 | Table false
141 | Attribute "readRequestCount"
142 |
143 |
144 | Type "gauge"
145 | InstancePrefix "regionserver-storeFileIndexSize"
146 | Table false
147 | Attribute "storeFileIndexSize"
148 |
149 |
150 | Type "counter"
151 | InstancePrefix "regionserver-writeRequestCount"
152 | Table false
153 | Attribute "writeRequestCount"
154 |
155 |
156 | Type "counter"
157 | InstancePrefix "regionserver-totalRequestCount"
158 | Table false
159 | Attribute "totalRequestCount"
160 |
161 |
162 | Type "counter"
163 | InstancePrefix "regionserver-slowAppendCount"
164 | Table false
165 | Attribute "slowAppendCount"
166 |
167 |
168 | Type "counter"
169 | InstancePrefix "regionserver-slowPutCount"
170 | Table false
171 | Attribute "slowPutCount"
172 |
173 |
174 | Type "counter"
175 | InstancePrefix "regionserver-slowGetCount"
176 | Table false
177 | Attribute "slowGetCount"
178 |
179 |
180 |
181 |
182 |
183 | # When using non-standard HBase configurations, replace the below with
184 | #ServiceURL "service:jmx:rmi:///jndi/rmi://HBASE_HOST:HBASE_MASTER_PORT/jmxrmi"
185 | ServiceURL "service:jmx:rmi:///jndi/rmi://localhost:10101/jmxrmi"
186 | InstancePrefix "hbasemaster"
187 |
188 | Collect "hbase_master_Server"
189 | Collect "hbase_ipc_IPC"
190 |
191 |
192 |
193 | # When using non-standard HBase configurations, replace the below with
194 | #ServiceURL "service:jmx:rmi:///jndi/rmi://HBASE_HOST:HBASE_REGIONSERVER_PORT/jmxrmi"
195 | ServiceURL "service:jmx:rmi:///jndi/rmi://localhost:10102/jmxrmi"
196 | InstancePrefix "hbaseregionserver"
197 |
198 | Collect "hbase_regionserver_RegionServerStatistics"
199 |
200 |
201 |
202 |
203 | ObjectName "java.lang:type=Threading"
204 |
205 | Type "gauge"
206 | InstancePrefix "threading-daemon_thread_count"
207 | Table false
208 | Attribute "DaemonThreadCount"
209 |
210 |
211 | Type "gauge"
212 | InstancePrefix "threading-thread_count"
213 | Table false
214 | Attribute "ThreadCount"
215 |
216 |
217 | Type "gauge"
218 | InstancePrefix "threading-peak_thread_count"
219 | Table false
220 | Attribute "PeakThreadCount"
221 |
222 |
223 |
224 |
225 | ObjectName "java.lang:type=Memory"
226 |
227 | Type "memory"
228 | InstancePrefix "memory-heap_usage_committed"
229 | Table false
230 | Attribute "HeapMemoryUsage.committed"
231 |
232 |
233 | Type "memory"
234 | InstancePrefix "memory-non_heap_usage_committed"
235 | Table false
236 | Attribute "NonHeapMemoryUsage.committed"
237 |
238 |
239 | Type "memory"
240 | InstancePrefix "memory-heap_usage_used"
241 | Table false
242 | Attribute "HeapMemoryUsage.used"
243 |
244 |
245 | Type "memory"
246 | InstancePrefix "memory-non_heap_usage_used"
247 | Table false
248 | Attribute "NonHeapMemoryUsage.used"
249 |
250 |
251 | Type "memory"
252 | InstancePrefix "memory-heap_usage_max"
253 | Table false
254 | Attribute "HeapMemoryUsage.max"
255 |
256 |
257 | Type "memory"
258 | InstancePrefix "memory-non_heap_usage_max"
259 | Table false
260 | Attribute "NonHeapMemoryUsage.max"
261 |
262 |
263 |
264 |
265 | ObjectName "java.lang:type=Runtime"
266 |
267 | Type "counter"
268 | InstancePrefix "runtime-uptime"
269 | Table false
270 | Attribute "Uptime"
271 |
272 |
273 |
274 |
275 | ObjectName "java.lang:type=OperatingSystem"
276 |
277 | Type "gauge"
278 | InstancePrefix "os-open_fd_count"
279 | Table false
280 | Attribute "OpenFileDescriptorCount"
281 |
282 |
283 | Type "counter"
284 | InstancePrefix "os-process_cpu_time"
285 | Table false
286 | Attribute "ProcessCpuTime"
287 |
288 |
289 |
290 |
291 | ObjectName "java.lang:type=GarbageCollector,name=*"
292 | InstanceFrom "name"
293 |
294 | Type "counter"
295 | InstancePrefix "gc-collection_count"
296 | Table false
297 | Attribute "CollectionCount"
298 |
299 |
300 | Type "counter"
301 | InstancePrefix "gc-collection_time"
302 | Table false
303 | Attribute "CollectionTime"
304 |
305 |
306 |
307 |
308 | # When using non-standard HBase configurations, replace the below with
309 | #ServiceURL "service:jmx:rmi:///jndi/rmi://HBASE_HOST:HBASE_REGIONSERVER_PORT/jmxrmi"
310 | ServiceURL "service:jmx:rmi:///jndi/rmi://localhost:10102/jmxrmi"
311 | InstancePrefix "jvm"
312 |
313 | Collect "jvm_localhost_Threading"
314 | Collect "jvm_localhost_Memory"
315 | Collect "jvm_localhost_Runtime"
316 | Collect "jvm_localhost_os"
317 | Collect "jvm_localhost_gc"
318 |
319 |
320 |
321 |
322 | LoadPlugin match_regex
323 | LoadPlugin target_set
324 | LoadPlugin target_replace
325 |
326 |
327 |
328 | Plugin "^GenericJMX$"
329 | PluginInstance "^hbase.*$"
330 |
331 |
332 | PluginInstance "hbase" ""
333 |
334 |
335 | Plugin "hbase"
336 |
337 |
338 |
339 | Target "return"
340 |
341 |
342 |
343 |
344 |
345 |
346 | Chain "GenericJMX_hbase"
347 |
348 |
349 |
350 | PreCacheChain "PreCache"
351 |
352 |
353 |
354 |
355 | Plugin "^GenericJMX$"
356 | PluginInstance "^jvm.*$"
357 |
358 |
359 | PluginInstance "jvm" ""
360 |
361 |
362 | Plugin "jvm"
363 |
364 | Target "return"
365 |
366 |
367 |
368 |
369 |
370 |
371 | Chain "GenericJMX_jvm"
372 |
373 |
374 |
375 | PreCacheChain "PreCache"
376 |
--------------------------------------------------------------------------------
/etc/collectd.d/hbase-thrift.conf:
--------------------------------------------------------------------------------
1 | # This is the monitoring configuration for HBase Thrift.
2 | # Look for HBASE_HOST and HBASE_THRIFT_PORT to adjust your configuration file.
3 | LoadPlugin java
4 |
5 | JVMARG "-Djava.class.path=/opt/stackdriver/collectd/share/collectd/java/collectd-api.jar:/opt/stackdriver/collectd/share/collectd/java/generic-jmx.jar"
6 | LoadPlugin "org.collectd.java.GenericJMX"
7 |
8 |
9 |
10 | ObjectName "Hadoop:service=HBase,name=Thrift,sub=ThriftOne"
11 |
12 | Type "gauge"
13 | InstancePrefix "thrift_one-callQueueLen"
14 | Table false
15 | Attribute "callQueueLen"
16 |
17 |
18 | Type "gauge"
19 | InstancePrefix "thrift_one-SlowThriftCall_mean"
20 | Table false
21 | Attribute "SlowThriftCall_mean"
22 |
23 |
24 | Type "gauge"
25 | InstancePrefix "thrift_one-TimeInQueue_mean"
26 | Table false
27 | Attribute "TimeInQueue_mean"
28 |
29 |
30 | Type "gauge"
31 | InstancePrefix "thrift_one-ThriftCall_mean"
32 | Table false
33 | Attribute "ThriftCall_mean"
34 |
35 |
36 | Type "gauge"
37 | InstancePrefix "thrift_one-BatchGet_mean"
38 | Table false
39 | Attribute "BatchGet_mean"
40 |
41 |
42 | Type "gauge"
43 | InstancePrefix "thrift_one-BatchMutate_mean"
44 | Table false
45 | Attribute "BatchMutate_mean"
46 |
47 |
48 |
49 |
50 | ObjectName "Hadoop:service=HBase,name=Thrift,sub=ThriftTwo"
51 |
52 | Type "gauge"
53 | InstancePrefix "thrift_two-callQueueLen"
54 | Table false
55 | Attribute "callQueueLen"
56 |
57 |
58 | Type "gauge"
59 | InstancePrefix "thrift_two-SlowThriftCall_mean"
60 | Table false
61 | Attribute "SlowThriftCall_mean"
62 |
63 |
64 | Type "gauge"
65 | InstancePrefix "thrift_two-TimeInQueue_mean"
66 | Table false
67 | Attribute "TimeInQueue_mean"
68 |
69 |
70 | Type "gauge"
71 | InstancePrefix "thrift_two-ThriftCall_mean"
72 | Table false
73 | Attribute "ThriftCall_mean"
74 |
75 |
76 | Type "gauge"
77 | InstancePrefix "thrift_two-BatchGet_mean"
78 | Table false
79 | Attribute "BatchGet_mean"
80 |
81 |
82 | Type "gauge"
83 | InstancePrefix "thrift_two-BatchMutate_mean"
84 | Table false
85 | Attribute "BatchMutate_mean"
86 |
87 |
88 |
89 |
90 |
91 | # When using non-standard HBase configurations, replace the below with
92 | #ServiceURL "service:jmx:rmi:///jndi/rmi://HBASE_HOST:HBASE_THRIFT_PORT/jmxrmi"
93 | ServiceURL "service:jmx:rmi:///jndi/rmi://localhost:10103/jmxrmi"
94 | InstancePrefix "hbasethrift"
95 |
96 | Collect "hbase_thrift_ThriftOne"
97 | Collect "hbase_thrift_ThriftTwo"
98 |
99 |
100 |
101 |
102 |
103 |
104 | LoadPlugin match_regex
105 | LoadPlugin target_set
106 | LoadPlugin target_replace
107 |
108 |
109 |
110 | Plugin "^GenericJMX$"
111 | PluginInstance "^hbase.*$"
112 |
113 |
114 | PluginInstance "hbase" ""
115 |
116 |
117 | Plugin "hbase"
118 |
119 |
120 |
121 | Target "return"
122 |
123 |
124 |
125 |
126 |
127 |
128 | Chain "GenericJMX_hbase"
129 |
130 |
131 |
132 | PreCacheChain "PreCache"
133 |
134 |
135 |
--------------------------------------------------------------------------------
/etc/collectd.d/jvm-sun-hotspot.conf:
--------------------------------------------------------------------------------
1 | # This is the monitoring configuration for standalone JVMs.
2 | # Look for JMX_HOST and JMX_PORT to adjust your configuration file.
3 | # Replace JMX_PORT below with the value configured in your JVM deployment.
4 | LoadPlugin java
5 |
6 | JVMARG "-Djava.class.path=/opt/stackdriver/collectd/share/collectd/java/collectd-api.jar:/opt/stackdriver/collectd/share/collectd/java/generic-jmx.jar"
7 | LoadPlugin "org.collectd.java.GenericJMX"
8 |
9 |
10 |
11 | ObjectName "java.lang:type=Threading"
12 |
13 | Type "gauge"
14 | InstancePrefix "threading-daemon_thread_count"
15 | Table false
16 | Attribute "DaemonThreadCount"
17 |
18 |
19 | Type "gauge"
20 | InstancePrefix "threading-thread_count"
21 | Table false
22 | Attribute "ThreadCount"
23 |
24 |
25 | Type "gauge"
26 | InstancePrefix "threading-peak_thread_count"
27 | Table false
28 | Attribute "PeakThreadCount"
29 |
30 |
31 |
32 |
33 | ObjectName "java.lang:type=Memory"
34 |
35 | Type "memory"
36 | InstancePrefix "memory-heap_usage_committed"
37 | Table false
38 | Attribute "HeapMemoryUsage.committed"
39 |
40 |
41 | Type "memory"
42 | InstancePrefix "memory-non_heap_usage_committed"
43 | Table false
44 | Attribute "NonHeapMemoryUsage.committed"
45 |
46 |
47 | Type "memory"
48 | InstancePrefix "memory-heap_usage_used"
49 | Table false
50 | Attribute "HeapMemoryUsage.used"
51 |
52 |
53 | Type "memory"
54 | InstancePrefix "memory-non_heap_usage_used"
55 | Table false
56 | Attribute "NonHeapMemoryUsage.used"
57 |
58 |
59 | Type "memory"
60 | InstancePrefix "memory-heap_usage_max"
61 | Table false
62 | Attribute "HeapMemoryUsage.max"
63 |
64 |
65 | Type "memory"
66 | InstancePrefix "memory-non_heap_usage_max"
67 | Table false
68 | Attribute "NonHeapMemoryUsage.max"
69 |
70 |
71 |
72 |
73 | ObjectName "java.lang:type=Runtime"
74 |
75 | Type "counter"
76 | InstancePrefix "runtime-uptime"
77 | Table false
78 | Attribute "Uptime"
79 |
80 |
81 |
82 |
83 | ObjectName "java.lang:type=OperatingSystem"
84 |
85 | Type "gauge"
86 | InstancePrefix "os-open_fd_count"
87 | Table false
88 | Attribute "OpenFileDescriptorCount"
89 |
90 |
91 | Type "counter"
92 | InstancePrefix "os-process_cpu_time"
93 | Table false
94 | Attribute "ProcessCpuTime"
95 |
96 |
97 |
98 |
99 | ObjectName "java.lang:type=GarbageCollector,name=*"
100 | InstanceFrom "name"
101 |
102 | Type "counter"
103 | InstancePrefix "gc-collection_count"
104 | Table false
105 | Attribute "CollectionCount"
106 |
107 |
108 | Type "counter"
109 | InstancePrefix "gc-collection_time"
110 | Table false
111 | Attribute "CollectionTime"
112 |
113 |
114 |
115 |
116 | # When using non-standard JVM configurations, replace the below with
117 | #ServiceURL "service:jmx:rmi:///jndi/rmi://JMX_HOST:JMX_PORT/jmxrmi"
118 | ServiceURL "service:jmx:rmi:///jndi/rmi://localhost:JMX_PORT/jmxrmi"
119 | InstancePrefix "jvm"
120 |
121 | Collect "jvm_localhost_Threading"
122 | Collect "jvm_localhost_Memory"
123 | Collect "jvm_localhost_Runtime"
124 | Collect "jvm_localhost_os"
125 | Collect "jvm_localhost_gc"
126 |
127 |
128 |
129 |
130 | LoadPlugin match_regex
131 | LoadPlugin target_set
132 | LoadPlugin target_replace
133 |
134 |
135 |
136 | Plugin "^GenericJMX$"
137 | PluginInstance "^jvm.*$"
138 |
139 |
140 | PluginInstance "jvm" ""
141 |
142 |
143 | Plugin "jvm"
144 |
145 | Target "return"
146 |
147 |
148 |
149 |
150 |
151 |
152 | Chain "GenericJMX_jvm"
153 |
154 |
155 |
156 | PreCacheChain "PreCache"
157 |
--------------------------------------------------------------------------------
/etc/collectd.d/kafka-082.conf:
--------------------------------------------------------------------------------
1 | # This is the monitoring configuration for Apache Kafka 0.8.2 and later.
2 | # Look for KAFKA_HOST and KAFKA_PORT to adjust your configuration file.
3 | LoadPlugin java
4 |
5 | JVMARG "-Djava.class.path=/opt/stackdriver/collectd/share/collectd/java/collectd-api.jar:/opt/stackdriver/collectd/share/collectd/java/generic-jmx.jar"
6 | LoadPlugin "org.collectd.java.GenericJMX"
7 |
8 |
9 |
10 | ObjectName "kafka.log:type=LogFlushStats,name=LogFlushRateAndTimeMs"
11 |
12 | Type "counter"
13 | InstancePrefix "log-LogFlushes"
14 | Table false
15 | Attribute "Count"
16 |
17 |
18 |
19 |
20 | ObjectName "kafka.server:type=BrokerTopicMetrics,name=BytesInPerSec"
21 |
22 | Type "counter"
23 | InstancePrefix "server_broker_topics-AllTopicsBytesIn"
24 | Table false
25 | Attribute "Count"
26 |
27 |
28 |
29 | ObjectName "kafka.server:type=BrokerTopicMetrics,name=FailedFetchRequestsPerSec"
30 |
31 | Type "counter"
32 | InstancePrefix "server_broker_topics-AllTopicsFailedFetchRequests"
33 | Table false
34 | Attribute "Count"
35 |
36 |
37 |
38 | ObjectName "kafka.server:type=BrokerTopicMetrics,name=FailedProduceRequestsPerSec"
39 |
40 | Type "counter"
41 | InstancePrefix "server_broker_topics-AllTopicsFailedProduceRequests"
42 | Table false
43 | Attribute "Count"
44 |
45 |
46 |
47 | ObjectName "kafka.server:type=BrokerTopicMetrics,name=MessagesInPerSec"
48 |
49 | Type "counter"
50 | InstancePrefix "server_broker_topics-AllTopicsMessagesIn"
51 | Table false
52 | Attribute "Count"
53 |
54 |
55 |
56 | ObjectName "kafka.server:type=BrokerTopicMetrics,name=BytesOutPerSec"
57 |
58 | Type "counter"
59 | InstancePrefix "server_broker_topics-AllTopicsBytesOut"
60 | Table false
61 | Attribute "Count"
62 |
63 |
64 |
65 |
66 | ObjectName "kafka.server:type=ReplicaManager,name=UnderReplicatedPartitions"
67 |
68 | Type "gauge"
69 | InstancePrefix "server_replica_manager-UnderReplicatedPartitions"
70 | Table false
71 | Attribute "Value"
72 |
73 |
74 |
75 | ObjectName "kafka.server:type=ReplicaManager,name=PartitionCount"
76 |
77 | Type "gauge"
78 | InstancePrefix "server_replica_manager-PartitionCount"
79 | Table false
80 | Attribute "Value"
81 |
82 |
83 |
84 | ObjectName "kafka.server:type=ReplicaManager,name=LeaderCount"
85 |
86 | Type "gauge"
87 | InstancePrefix "server_replica_manager-LeaderCount"
88 | Table false
89 | Attribute "Value"
90 |
91 |
92 |
93 | ObjectName "kafka.server:type=ReplicaManager,name=IsrShrinksPerSec"
94 |
95 | Type "counter"
96 | InstancePrefix "server_replica_manager-ISRShrinks"
97 | Table false
98 | Attribute "Count"
99 |
100 |
101 |
102 | ObjectName "kafka.server:type=ReplicaManager,name=IsrExpandsPerSec"
103 |
104 | Type "counter"
105 | InstancePrefix "server_replica_manager-ISRExpands"
106 | Table false
107 | Attribute "Count"
108 |
109 |
110 |
111 |
112 | ObjectName "kafka.server:type=ReplicaFetcherManager,name=MaxLag,clientId=Replica"
113 |
114 | Type "gauge"
115 | InstancePrefix "server_replica_fetcher-MaxLag"
116 | Table false
117 | Attribute "Value"
118 |
119 |
120 |
121 | ObjectName "kafka.server:type=ReplicaFetcherManager,name=MinFetchRate,clientId=Replica"
122 |
123 | Type "gauge"
124 | InstancePrefix "server_replica_fetcher-MinFetchRate"
125 | Table false
126 | Attribute "Value"
127 |
128 |
129 |
130 |
131 | ObjectName "kafka.server:type=ProducerRequestPurgatory,name=NumDelayedRequests"
132 |
133 | Type "gauge"
134 | InstancePrefix "server_purgatory-Producer-NumDelayedRequests"
135 | Table false
136 | Attribute "Value"
137 |
138 |
139 |
140 | ObjectName "kafka.server:type=ProducerRequestPurgatory,name=PurgatorySize"
141 |
142 | Type "gauge"
143 | InstancePrefix "server_purgatory-Producer-PurgatorySize"
144 | Table false
145 | Attribute "Value"
146 |
147 |
148 |
149 |
150 | ObjectName "kafka.server:type=FetchRequestPurgatory,name=NumDelayedRequests"
151 |
152 | Type "gauge"
153 | InstancePrefix "server_purgatory-Fetch-NumDelayedRequests"
154 | Table false
155 | Attribute "Value"
156 |
157 |
158 |
159 | ObjectName "kafka.server:type=FetchRequestPurgatory,name=PurgatorySize"
160 |
161 | Type "gauge"
162 | InstancePrefix "server_purgatory-Fetch-PurgatorySize"
163 | Table false
164 | Attribute "Value"
165 |
166 |
167 |
168 |
169 | ObjectName "kafka.network:type=RequestMetrics,name=RequestsPerSec,request=Produce"
170 |
171 | Type "counter"
172 | InstancePrefix "network-ProduceRequests"
173 | Table false
174 | Attribute "Count"
175 |
176 |
177 |
178 | ObjectName "kafka.network:type=RequestMetrics,name=RequestsPerSec,request=FetchFollower"
179 |
180 | Type "counter"
181 | InstancePrefix "network-FetchFollowerRequests"
182 | Table false
183 | Attribute "Count"
184 |
185 |
186 |
187 | ObjectName "kafka.network:type=RequestMetrics,name=RequestsPerSec,request=FetchConsumer"
188 |
189 | Type "counter"
190 | InstancePrefix "network-FetchConsumerRequests"
191 | Table false
192 | Attribute "Count"
193 |
194 |
195 |
196 |
197 | ObjectName "kafka.controller:type=KafkaController,name=ActiveControllerCount"
198 |
199 | Type "gauge"
200 | InstancePrefix "controller_kafka-ActiveControllerCount"
201 | Table false
202 | Attribute "Value"
203 |
204 |
205 |
206 | ObjectName "kafka.controller:type=KafkaController,name=OfflinePartitionsCount"
207 |
208 | Type "gauge"
209 | InstancePrefix "controller_kafka-OfflinePartitionsCount"
210 | Table false
211 | Attribute "Value"
212 |
213 |
214 |
215 |
216 | ObjectName "kafka.controller:type=ControllerStats,name=LeaderElectionRateAndTimeMs"
217 |
218 | Type "counter"
219 | InstancePrefix "controller-LeaderElections"
220 | Table false
221 | Attribute "Count"
222 |
223 |
224 |
225 | ObjectName "kafka.controller:type=ControllerStats,name=UncleanLeaderElectionsPerSec"
226 |
227 | Type "counter"
228 | InstancePrefix "controller-UncleanLeaderElections"
229 | Table false
230 | Attribute "Count"
231 |
232 |
233 |
234 |
235 |
236 | # When using non-standard Kafka configurations, replace the below with
237 | #ServiceURL "service:jmx:rmi:///jndi/rmi://KAFKA_HOST:KAFKA_PORT/jmxrmi"
238 | ServiceURL "service:jmx:rmi:///jndi/rmi://localhost:9999/jmxrmi"
239 | InstancePrefix "kafka"
240 |
241 | Collect "kafka_log-LogFlushStats_LogFlush"
242 | Collect "kafka_server-BrokerTopicMetrics_AllTopicsBytesIn"
243 | Collect "kafka_server-BrokerTopicMetrics_AllTopicsFailedFetchRequests"
244 | Collect "kafka_server-BrokerTopicMetrics_AllTopicsFailedProduceRequests"
245 | Collect "kafka_server-BrokerTopicMetrics_AllTopicsMessagesIn"
246 | Collect "kafka_server-BrokerTopicMetrics_AllTopicsBytesOut"
247 | Collect "kafka_server-ReplicaManager_UnderReplicatedPartitions"
248 | Collect "kafka_server-ReplicaManager_PartitionCount"
249 | Collect "kafka_server-ReplicaManager_LeaderCount"
250 | Collect "kafka_server-ReplicaManager_ISRShrinks"
251 | Collect "kafka_server-ReplicaManager_ISRExpands"
252 | Collect "kafka_server-ReplicaFetcherManager_MaxLag"
253 | Collect "kafka_server-ReplicaFetcherManager_MinFetchRate"
254 | Collect "kafka_server-ProducerRequestPurgatory_NumDelayedRequests"
255 | Collect "kafka_server-ProducerRequestPurgatory_PurgatorySize"
256 | Collect "kafka_server-FetchRequestPurgatory_NumDelayedRequests"
257 | Collect "kafka_server-FetchRequestPurgatory_PurgatorySize"
258 | Collect "kafka_network-RequestMetrics_ProduceRequests"
259 | Collect "kafka_network-RequestMetrics_FetchFollowerRequests"
260 | Collect "kafka_network-RequestMetrics_FetchConsumerRequests"
261 | Collect "kafka_controller-KafkaController_ActiveControllerCount"
262 | Collect "kafka_controller-KafkaController_OfflinePartitionsCount"
263 | Collect "kafka_controller-ControllerStats_LeaderElections"
264 | Collect "kafka_controller-ControllerStats_UncleanLeaderElections"
265 |
266 |
267 |
268 |
269 | ObjectName "java.lang:type=Threading"
270 |
271 | Type "gauge"
272 | InstancePrefix "threading-daemon_thread_count"
273 | Table false
274 | Attribute "DaemonThreadCount"
275 |
276 |
277 | Type "gauge"
278 | InstancePrefix "threading-thread_count"
279 | Table false
280 | Attribute "ThreadCount"
281 |
282 |
283 | Type "gauge"
284 | InstancePrefix "threading-peak_thread_count"
285 | Table false
286 | Attribute "PeakThreadCount"
287 |
288 |
289 |
290 |
291 | ObjectName "java.lang:type=Memory"
292 |
293 | Type "memory"
294 | InstancePrefix "memory-heap_usage_committed"
295 | Table false
296 | Attribute "HeapMemoryUsage.committed"
297 |
298 |
299 | Type "memory"
300 | InstancePrefix "memory-non_heap_usage_committed"
301 | Table false
302 | Attribute "NonHeapMemoryUsage.committed"
303 |
304 |
305 | Type "memory"
306 | InstancePrefix "memory-heap_usage_used"
307 | Table false
308 | Attribute "HeapMemoryUsage.used"
309 |
310 |
311 | Type "memory"
312 | InstancePrefix "memory-non_heap_usage_used"
313 | Table false
314 | Attribute "NonHeapMemoryUsage.used"
315 |
316 |
317 | Type "memory"
318 | InstancePrefix "memory-heap_usage_max"
319 | Table false
320 | Attribute "HeapMemoryUsage.max"
321 |
322 |
323 | Type "memory"
324 | InstancePrefix "memory-non_heap_usage_max"
325 | Table false
326 | Attribute "NonHeapMemoryUsage.max"
327 |
328 |
329 |
330 |
331 | ObjectName "java.lang:type=Runtime"
332 |
333 | Type "counter"
334 | InstancePrefix "runtime-uptime"
335 | Table false
336 | Attribute "Uptime"
337 |
338 |
339 |
340 |
341 | ObjectName "java.lang:type=OperatingSystem"
342 |
343 | Type "gauge"
344 | InstancePrefix "os-open_fd_count"
345 | Table false
346 | Attribute "OpenFileDescriptorCount"
347 |
348 |
349 | Type "counter"
350 | InstancePrefix "os-process_cpu_time"
351 | Table false
352 | Attribute "ProcessCpuTime"
353 |
354 |
355 |
356 |
357 | ObjectName "java.lang:type=GarbageCollector,name=*"
358 | InstanceFrom "name"
359 |
360 | Type "counter"
361 | InstancePrefix "gc-collection_count"
362 | Table false
363 | Attribute "CollectionCount"
364 |
365 |
366 | Type "counter"
367 | InstancePrefix "gc-collection_time"
368 | Table false
369 | Attribute "CollectionTime"
370 |
371 |
372 |
373 |
374 | # When using non-standard Kafka configurations, replace the below with
375 | #ServiceURL "service:jmx:rmi:///jndi/rmi://KAFKA_HOST:KAFKA_PORT/jmxrmi"
376 | ServiceURL "service:jmx:rmi:///jndi/rmi://localhost:9999/jmxrmi"
377 | InstancePrefix "jvm"
378 |
379 | Collect "jvm_localhost_Threading"
380 | Collect "jvm_localhost_Memory"
381 | Collect "jvm_localhost_Runtime"
382 | Collect "jvm_localhost_os"
383 | Collect "jvm_localhost_gc"
384 |
385 |
386 |
387 |
388 | LoadPlugin match_regex
389 | LoadPlugin target_set
390 | LoadPlugin target_replace
391 |
392 |
393 |
394 | Plugin "^GenericJMX$"
395 | PluginInstance "^kafka.*$"
396 |
397 |
398 | PluginInstance "kafka" ""
399 |
400 |
401 | Plugin "kafka"
402 |
403 |
404 |
405 | Target "return"
406 |
407 |
408 |
409 |
410 |
411 |
412 | Chain "GenericJMX_kafka"
413 |
414 |
415 |
416 | PreCacheChain "PreCache"
417 |
418 |
419 |
420 |
421 | Plugin "^GenericJMX$"
422 | PluginInstance "^jvm.*$"
423 |
424 |
425 | PluginInstance "jvm" ""
426 |
427 |
428 | Plugin "jvm"
429 |
430 | Target "return"
431 |
432 |
433 |
434 |
435 |
436 |
437 | Chain "GenericJMX_jvm"
438 |
439 |
440 |
441 | PreCacheChain "PreCache"
442 |
--------------------------------------------------------------------------------
/etc/collectd.d/memcached.conf:
--------------------------------------------------------------------------------
1 | # This is the monitoring configuration for memcached.
2 | # Look for MEMCACHED_HOST and MEMCACHED_PORT to adjust your configuration file.
3 | LoadPlugin memcached
4 |
5 | # When using non-standard memcached configurations, replace the below with
6 | #Host "MEMCACHED_HOST"
7 | #Port "MEMCACHED_PORT"
8 | Host "localhost"
9 | Port "11211"
10 |
11 |
--------------------------------------------------------------------------------
/etc/collectd.d/mongodb.conf:
--------------------------------------------------------------------------------
1 | # This is the monitoring configuration for MongoDB.
2 | # Look for STATS_USER, STATS_PASS, MONGODB_HOST and MONGODB_PORT to adjust your configuration file.
3 | LoadPlugin mongodb
4 |
5 | # When using non-standard MongoDB configurations, replace the below with
6 | #Host "MONGODB_HOST"
7 | #Port "MONGODB_PORT"
8 | Host "localhost"
9 | Port "27017"
10 |
11 | # If you restricted access to the database, you can set the username and
12 | # password here:
13 | #User "STATS_USER"
14 | #Password "STATS_PASS"
15 |
16 |
--------------------------------------------------------------------------------
/etc/collectd.d/mysql.conf:
--------------------------------------------------------------------------------
1 | # This is the monitoring configuration for MySQL.
2 | # NOTE: This configuration needs to be hand-edited in order to work.
3 | # Look for DATABASE_NAME, STATS_USER, STATS_PASS, MYSQL_HOST and MYSQL_PORT to adjust your configuration file.
4 | LoadPlugin mysql
5 |
6 | # Each database needs a separate Database section.
7 | # Replace DATABASE_NAME in the Database section with the name of the database.
8 |
9 | # When using non-standard MySQL configurations, replace the below with
10 | #Host "MYSQL_HOST"
11 | #Port "MYSQL_PORT"
12 | Host "localhost"
13 | Port 3306
14 | User "STATS_USER"
15 | Password "STATS_PASS"
16 | MasterStats true
17 | SlaveStats true
18 | # Uncomment the following line if you want to collect InnoDB metrics.
19 | #InnodbStats true
20 |
21 |
22 |
--------------------------------------------------------------------------------
/etc/collectd.d/nginx.conf:
--------------------------------------------------------------------------------
1 | # This is the monitoring configuration for Nginx.
2 | # Make sure to enable stub_status in your Nginx configuration.
3 | # Look for NGINX_HOST and NGINX_PORT to adjust your configuration file.
4 | LoadPlugin nginx
5 |
6 | # When using non-standard Nginx configurations, replace the below with
7 | #URL "http://NGINX_HOST:NGINX_PORT/nginx_status"
8 | URL "http://local-stackdriver-agent.stackdriver.com:80/nginx_status"
9 |
10 |
--------------------------------------------------------------------------------
/etc/collectd.d/postgresql.conf:
--------------------------------------------------------------------------------
1 | # This is the monitoring configuration for PostgreSQL.
2 | # Make sure the statistics collector is enabled in your PostgreSQL configuration.
3 | # NOTE: This configuration needs to be hand-edited in order to work.
4 | # Look for DATABASE_NAME, STATS_USER, STATS_PASS, POSTGRESQL_HOST and POSTGRESQL_PORT to adjust your configuration file.
5 | LoadPlugin postgresql
6 |
7 | # Each database needs a separate Database section.
8 | # Replace DATABASE_NAME in the Database section with the name of the database.
9 |
10 | # Host and port are only used for TCP/IP connections.
11 | # Leaving them out indicates you wish to connect via domain sockets.
12 | # When using non-standard PostgreSQL configurations, replace the below with
13 | ##Host "POSTGRESQL_HOST"
14 | ##Port "POSTGRESQL_PORT"
15 | #Host "localhost"
16 | #Port "5432"
17 | User "STATS_USER"
18 | Password "STATS_PASS"
19 | Query backends
20 | Query transactions
21 | Query queries
22 | Query table_states
23 | Query disk_io
24 | Query disk_usage
25 |
26 |
27 |
--------------------------------------------------------------------------------
/etc/collectd.d/rabbitmq.conf:
--------------------------------------------------------------------------------
1 | # This is the monitoring configuration for RabbitMQ.
2 | # Look for RABBITMQ_HOST and RABBITMQ_PORT to adjust your configuration file.
3 | LoadPlugin curl_json
4 |
5 | # Each queue needs a separate URL section that points to
6 | # http://localhost:15672/api/queues/vhost/QUEUE_NAME .
7 | # Replace QUEUE_NAME in the URL section with the name of the queue.
8 | #
9 | # NOTE: The vhost and queue name must be URL-encoded.
10 | # Being that the default vhost is a forward slash "/",
11 | # we encode this as "%2F".
12 |
13 | # When using non-standard RabbitMQ configurations, replace the below with
14 | #
15 |
16 | User "guest"
17 | Password "guest"
18 | Instance "rabbitmq-QUEUE_NAME"
19 |
20 |
21 | Type "gauge"
22 |
23 |
24 | Type "gauge"
25 |
26 |
27 | Type "gauge"
28 |
29 |
30 | Type "gauge"
31 |
32 |
33 | Type "gauge"
34 |
35 |
36 | Type "gauge"
37 |
38 |
39 |
40 |
41 | LoadPlugin match_regex
42 | LoadPlugin target_set
43 | LoadPlugin target_replace
44 |
45 |
46 |
47 | Plugin "^curl_json$"
48 | PluginInstance "^rabbitmq-.*$"
49 |
50 |
51 | PluginInstance "^rabbitmq-" ""
52 |
53 |
54 | Plugin "rabbitmq"
55 |
56 |
57 |
58 |
59 | PluginInstance "^$"
60 |
61 |
62 | PluginInstance "localhost"
63 |
64 |
65 |
66 | Target "return"
67 |
68 |
69 |
70 |
71 |
72 |
73 | Chain "curl_json_rabbitmq"
74 |
75 |
76 |
77 | PreCacheChain "PreCache"
78 |
79 |
--------------------------------------------------------------------------------
/etc/collectd.d/redis.conf:
--------------------------------------------------------------------------------
1 | # This is the monitoring configuration for Redis.
2 | # Make sure you've installed the hiredis/libhiredis packages.
3 | # Look for REDIS_PASS, REDIS_HOST and REDIS_PORT to adjust your configuration file.
4 | LoadPlugin redis
5 |
6 |
7 | # When using non-standard Redis configurations, replace the below with
8 | #Host "REDIS_HOST"
9 | #Port "REDIS_PORT"
10 | Host "localhost"
11 | Port "6379"
12 | Timeout 2000
13 |
14 | # If you password-protected your server, set the password here:
15 | #Password "REDIS_PASS"
16 |
17 |
18 |
--------------------------------------------------------------------------------
/etc/collectd.d/riak.conf:
--------------------------------------------------------------------------------
1 | # This is the monitoring configuration for Riak.
2 | # Look for RIAK_HOST and RIAK_PORT to adjust your configuration file.
3 | LoadPlugin curl_json
4 |
5 | # When using non-standard Riak configurations, replace the below with
6 | #
7 |
8 | Instance "riak"
9 |
10 |
11 | Type "counter"
12 |
13 |
14 | Type "counter"
15 |
16 |
17 | Type "counter"
18 |
19 |
20 | Type "counter"
21 |
22 |
23 | Type "counter"
24 |
25 |
26 | Type "counter"
27 |
28 |
29 | Type "counter"
30 |
31 |
32 | Type "counter"
33 |
34 |
35 | Type "counter"
36 |
37 |
38 | Type "counter"
39 |
40 |
41 | Type "gauge"
42 |
43 |
44 | Type "gauge"
45 |
46 |
47 | Type "gauge"
48 |
49 |
50 | Type "gauge"
51 |
52 |
53 | Type "gauge"
54 |
55 |
56 | Type "gauge"
57 |
58 |
59 | Type "gauge"
60 |
61 |
62 | Type "gauge"
63 |
64 |
65 | Type "gauge"
66 |
67 |
68 | Type "gauge"
69 |
70 |
71 | Type "gauge"
72 |
73 |
74 | Type "gauge"
75 |
76 |
77 | Type "gauge"
78 |
79 |
80 | Type "gauge"
81 |
82 |
83 | Type "gauge"
84 |
85 |
86 | Type "gauge"
87 |
88 |
89 | Type "gauge"
90 |
91 |
92 | Type "gauge"
93 |
94 |
95 |
96 |
97 | LoadPlugin match_regex
98 | LoadPlugin target_set
99 | LoadPlugin target_replace
100 |
101 |
102 |
103 | Plugin "^curl_json$"
104 | PluginInstance "^riak.*$"
105 |
106 |
107 | PluginInstance "^riak" ""
108 |
109 |
110 | Plugin "riak"
111 |
112 |
113 |
114 |
115 | PluginInstance "^$"
116 |
117 |
118 | PluginInstance "localhost"
119 |
120 |
121 |
122 | Target "return"
123 |
124 |
125 |
126 |
127 |
128 |
129 | Chain "curl_json_riak"
130 |
131 |
132 |
133 | PreCacheChain "PreCache"
134 |
135 |
--------------------------------------------------------------------------------
/etc/collectd.d/statsd.conf:
--------------------------------------------------------------------------------
1 | # This is the monitoring configuration for StatsD.
2 | # Look for STATSD_HOST and STATSD_PORT to adjust your configuration file.
3 | LoadPlugin statsd
4 |
5 |
6 | # When using non-standard StatsD configurations, replace the below with
7 | #Host "STATSD_HOST"
8 | #Port "STATSD_PORT"
9 | Host "127.0.0.1"
10 | Port "8125"
11 | DeleteSets true
12 | TimerPercentile 50.0
13 | TimerPercentile 95.0
14 | TimerLower true
15 | TimerUpper true
16 | TimerSum true
17 | TimerCount true
18 |
19 |
20 | LoadPlugin match_regex
21 | LoadPlugin target_set
22 | LoadPlugin target_replace
23 |
24 | PreCacheChain "PreCache"
25 |
26 |
27 |
28 | Plugin "^statsd$"
29 |
30 |
31 | MetaData "stackdriver_metric_type" "custom.googleapis.com/statsd/%{type}"
32 | MetaData "label:metric" "%{type_instance}"
33 |
34 |
35 |
36 |
--------------------------------------------------------------------------------
/etc/collectd.d/tomcat-7.conf:
--------------------------------------------------------------------------------
1 | # This is the monitoring configuration for Apache Tomcat 7.x and earlier.
2 | # Make sure to enable JMX in your Tomcat configuration.
3 | # Look for TOMCAT_HOST and TOMCAT_PORT to adjust your configuration file.
4 | LoadPlugin java
5 |
6 | JVMARG "-Djava.class.path=/opt/stackdriver/collectd/share/collectd/java/collectd-api.jar:/opt/stackdriver/collectd/share/collectd/java/generic-jmx.jar"
7 | LoadPlugin "org.collectd.java.GenericJMX"
8 |
9 |
10 |
11 | ObjectName "Catalina:type=ThreadPool,name=*"
12 | InstanceFrom "name"
13 |
14 | Type "gauge"
15 | InstancePrefix "connectors-current_threads"
16 | Table false
17 | Attribute "currentThreadCount"
18 |
19 |
20 | Type "gauge"
21 | InstancePrefix "connectors-busy_threads"
22 | Table false
23 | Attribute "currentThreadsBusy"
24 |
25 |
26 |
27 |
28 | ObjectName "Catalina:type=Manager,context=*,host=*"
29 | InstanceFrom "context"
30 |
31 | Type "gauge"
32 | InstancePrefix "manager-active_sessions"
33 | Table false
34 | Attribute "activeSessions"
35 |
36 |
37 |
38 |
39 | ObjectName "Catalina:type=GlobalRequestProcessor,name=*"
40 | InstanceFrom "name"
41 |
42 | Type "counter"
43 | InstancePrefix "request_processor-bytes_received"
44 | Table false
45 | Attribute "bytesReceived"
46 |
47 |
48 | Type "counter"
49 | InstancePrefix "request_processor-bytes_sent"
50 | Table false
51 | Attribute "bytesSent"
52 |
53 |
54 | Type "counter"
55 | InstancePrefix "request_processor-processing_time"
56 | Table false
57 | Attribute "processingTime"
58 |
59 |
60 | Type "counter"
61 | InstancePrefix "request_processor-request_count"
62 | Table false
63 | Attribute "requestCount"
64 |
65 |
66 | Type "counter"
67 | InstancePrefix "request_processor-error_count"
68 | Table false
69 | Attribute "errorCount"
70 |
71 |
72 |
73 |
74 |
75 | # When using non-standard Tomcat configurations, replace the below with
76 | #ServiceURL "service:jmx:rmi:///jndi/rmi://TOMCAT_HOST:TOMCAT_PORT/jmxrmi"
77 | ServiceURL "service:jmx:rmi:///jndi/rmi://localhost:9012/jmxrmi"
78 | InstancePrefix "tomcat"
79 |
80 | Collect "tomcat_connectors"
81 | Collect "tomcat_manager"
82 | Collect "tomcat_requestProcessor"
83 |
84 |
85 |
86 |
87 | ObjectName "java.lang:type=Threading"
88 |
89 | Type "gauge"
90 | InstancePrefix "threading-daemon_thread_count"
91 | Table false
92 | Attribute "DaemonThreadCount"
93 |
94 |
95 | Type "gauge"
96 | InstancePrefix "threading-thread_count"
97 | Table false
98 | Attribute "ThreadCount"
99 |
100 |
101 | Type "gauge"
102 | InstancePrefix "threading-peak_thread_count"
103 | Table false
104 | Attribute "PeakThreadCount"
105 |
106 |
107 |
108 |
109 | ObjectName "java.lang:type=Memory"
110 |
111 | Type "memory"
112 | InstancePrefix "memory-heap_usage_committed"
113 | Table false
114 | Attribute "HeapMemoryUsage.committed"
115 |
116 |
117 | Type "memory"
118 | InstancePrefix "memory-non_heap_usage_committed"
119 | Table false
120 | Attribute "NonHeapMemoryUsage.committed"
121 |
122 |
123 | Type "memory"
124 | InstancePrefix "memory-heap_usage_used"
125 | Table false
126 | Attribute "HeapMemoryUsage.used"
127 |
128 |
129 | Type "memory"
130 | InstancePrefix "memory-non_heap_usage_used"
131 | Table false
132 | Attribute "NonHeapMemoryUsage.used"
133 |
134 |
135 | Type "memory"
136 | InstancePrefix "memory-heap_usage_max"
137 | Table false
138 | Attribute "HeapMemoryUsage.max"
139 |
140 |
141 | Type "memory"
142 | InstancePrefix "memory-non_heap_usage_max"
143 | Table false
144 | Attribute "NonHeapMemoryUsage.max"
145 |
146 |
147 |
148 |
149 | ObjectName "java.lang:type=Runtime"
150 |
151 | Type "counter"
152 | InstancePrefix "runtime-uptime"
153 | Table false
154 | Attribute "Uptime"
155 |
156 |
157 |
158 |
159 | ObjectName "java.lang:type=OperatingSystem"
160 |
161 | Type "gauge"
162 | InstancePrefix "os-open_fd_count"
163 | Table false
164 | Attribute "OpenFileDescriptorCount"
165 |
166 |
167 | Type "counter"
168 | InstancePrefix "os-process_cpu_time"
169 | Table false
170 | Attribute "ProcessCpuTime"
171 |
172 |
173 |
174 |
175 | ObjectName "java.lang:type=GarbageCollector,name=*"
176 | InstanceFrom "name"
177 |
178 | Type "counter"
179 | InstancePrefix "gc-collection_count"
180 | Table false
181 | Attribute "CollectionCount"
182 |
183 |
184 | Type "counter"
185 | InstancePrefix "gc-collection_time"
186 | Table false
187 | Attribute "CollectionTime"
188 |
189 |
190 |
191 |
192 | # When using non-standard Tomcat configurations, replace the below with
193 | #ServiceURL "service:jmx:rmi:///jndi/rmi://TOMCAT_HOST:TOMCAT_PORT/jmxrmi"
194 | ServiceURL "service:jmx:rmi:///jndi/rmi://localhost:9012/jmxrmi"
195 | InstancePrefix "jvm"
196 |
197 | Collect "jvm_localhost_Threading"
198 | Collect "jvm_localhost_Memory"
199 | Collect "jvm_localhost_Runtime"
200 | Collect "jvm_localhost_os"
201 | Collect "jvm_localhost_gc"
202 |
203 |
204 |
205 |
206 | LoadPlugin match_regex
207 | LoadPlugin target_set
208 | LoadPlugin target_replace
209 |
210 |
211 |
212 | Plugin "^GenericJMX$"
213 | PluginInstance "^tomcat.*$"
214 |
215 |
216 | PluginInstance "tomcat" ""
217 |
218 |
219 | Plugin "tomcat"
220 |
221 |
222 |
223 | Target "return"
224 |
225 |
226 |
227 |
228 |
229 |
230 | Chain "GenericJMX_tomcat"
231 |
232 |
233 |
234 | PreCacheChain "PreCache"
235 |
236 |
237 |
238 |
239 | Plugin "^GenericJMX$"
240 | PluginInstance "^jvm.*$"
241 |
242 |
243 | PluginInstance "jvm" ""
244 |
245 |
246 | Plugin "jvm"
247 |
248 | Target "return"
249 |
250 |
251 |
252 |
253 |
254 |
255 | Chain "GenericJMX_jvm"
256 |
257 |
258 |
259 | PreCacheChain "PreCache"
260 |
--------------------------------------------------------------------------------
/etc/collectd.d/varnish.conf:
--------------------------------------------------------------------------------
1 | # This is the monitoring configuration for Varnish.
2 | LoadPlugin varnish
3 |
4 |
5 |
--------------------------------------------------------------------------------
/etc/collectd.d/zookeeper.conf:
--------------------------------------------------------------------------------
1 | # This is the monitoring configuration for ZooKeeper.
2 | # Look for ZOOKEEPER_HOST and ZOOKEEPER_PORT to adjust your configuration file.
3 | LoadPlugin zookeeper
4 |
5 | # When using non-standard ZooKeeper configurations, replace the below with
6 | #Host "ZOOKEEPER_HOST"
7 | #Port "ZOOKEEPER_PORT"
8 | Host "localhost" # default
9 | Port "2181" # default
10 |
11 |
--------------------------------------------------------------------------------
/etc/httpd/conf.d/status.conf:
--------------------------------------------------------------------------------
1 | ExtendedStatus on
2 |
3 | ServerName local-stackdriver-agent.stackdriver.com
4 |
5 | SetHandler server-status
6 | Order deny,allow
7 | Deny from all
8 | Allow from 127.0.0.1
9 |
10 |
11 |
--------------------------------------------------------------------------------
/etc/nginx/conf.d/status.conf:
--------------------------------------------------------------------------------
1 | server {
2 | listen 80;
3 | server_name local-stackdriver-agent.stackdriver.com;
4 | location /nginx_status {
5 | stub_status on;
6 | access_log off;
7 | allow 127.0.0.1;
8 | deny all;
9 | }
10 | location / {
11 | root /dev/null;
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/templates/apache.conf.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2015 Google Inc. All Rights Reserved.
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | #}
16 | # This is the monitoring configuration for the Apache web server.
17 | # Make sure mod_status is enabled in your Apache configuration.
18 | # Look for APACHE_HOST and APACHE_PORT to adjust your configuration file.
19 | LoadPlugin apache
20 |
21 |
22 | # When using non-standard Apache configurations, replace the below with
23 | #URL "http://APACHE_HOST:APACHE_PORT/server-status/?auto"
24 | URL "http://local-stackdriver-agent.stackdriver.com:80/server-status/?auto"
25 |
26 |
27 |
--------------------------------------------------------------------------------
/templates/cassandra.conf.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2015 Google Inc. All Rights Reserved.
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | #}
16 | {% extends "jmx-metrics-base.jinja" %}
17 | {% block target %}Cassandra 2.1.x and earlier{% endblock %}
18 | {% block service %}Cassandra{% endblock %}
19 | {% block jmx_host_port_prefix %}CASSANDRA{% endblock %}
20 | {% block jmx_port %}7199{% endblock %}
21 | {% block mbean_list %}
22 | {% call mbean("cassandra_storageservice", mbeans) -%}
23 | ObjectName "org.apache.cassandra.db:type=StorageService"
24 |
25 | Type "gauge"
26 | InstancePrefix "storage_service-load"
27 | Table false
28 | Attribute "Load"
29 |
30 |
31 | Type "counter"
32 | InstancePrefix "storage_service-exception_count"
33 | Table false
34 | Attribute "ExceptionCount"
35 |
36 | {%- endcall %}
37 |
38 | {% call mbean("cassandra_commitlog", mbeans) -%}
39 | ObjectName "org.apache.cassandra.db:type=Commitlog"
40 |
41 | Type "gauge"
42 | InstancePrefix "commitlog-pending_tasks"
43 | Table false
44 | Attribute "PendingTasks"
45 |
46 |
47 | Type "counter"
48 | InstancePrefix "commitlog-completed_tasks"
49 | Table false
50 | Attribute "CompletedTasks"
51 |
52 |
53 | Type "gauge"
54 | InstancePrefix "commitlog-total_size"
55 | Table false
56 | Attribute "TotalCommitlogSize"
57 |
58 | {%- endcall %}
59 |
60 | {% call mbean("cassandra_compactionmanager", mbeans) -%}
61 | ObjectName "org.apache.cassandra.db:type=CompactionManager"
62 |
63 | Type "gauge"
64 | InstancePrefix "compaction_manager-pending_tasks"
65 | Table false
66 | Attribute "PendingTasks"
67 |
68 |
69 | Type "counter"
70 | InstancePrefix "compaction_manager-completed_tasks"
71 | Table false
72 | Attribute "CompletedTasks"
73 |
74 | {%- endcall %}
75 |
76 | {% call mbean("cassandra_stage_MutationStage", mbeans) -%}
77 | ObjectName "org.apache.cassandra.request:type=MutationStage"
78 |
79 | Type "gauge"
80 | InstancePrefix "mutation_stage-active_count"
81 | Table false
82 | Attribute "ActiveCount"
83 |
84 |
85 | Type "gauge"
86 | InstancePrefix "mutation_stage-currently_blocked_tasks"
87 | Table false
88 | Attribute "CurrentlyBlockedTasks"
89 |
90 |
91 | Type "gauge"
92 | InstancePrefix "mutation_stage-pending_tasks"
93 | Table false
94 | Attribute "PendingTasks"
95 |
96 |
97 | Type "counter"
98 | InstancePrefix "mutation_stage-completed_tasks"
99 | Table false
100 | Attribute "CompletedTasks"
101 |
102 | {%- endcall %}
103 |
104 | {% call mbean("cassandra_stage_ReadRepairStage", mbeans) -%}
105 | ObjectName "org.apache.cassandra.request:type=ReadRepairStage"
106 |
107 | Type "gauge"
108 | InstancePrefix "read_repair_stage-active_count"
109 | Table false
110 | Attribute "ActiveCount"
111 |
112 |
113 | Type "gauge"
114 | InstancePrefix "read_repair_stage-currently_blocked_tasks"
115 | Table false
116 | Attribute "CurrentlyBlockedTasks"
117 |
118 |
119 | Type "gauge"
120 | InstancePrefix "read_repair_stage-pending_tasks"
121 | Table false
122 | Attribute "PendingTasks"
123 |
124 |
125 | Type "counter"
126 | InstancePrefix "read_repair_stage-completed_tasks"
127 | Table false
128 | Attribute "CompletedTasks"
129 |
130 | {%- endcall %}
131 |
132 | {% call mbean("cassandra_stage_ReadStage", mbeans) -%}
133 | ObjectName "org.apache.cassandra.request:type=ReadStage"
134 |
135 | Type "gauge"
136 | InstancePrefix "read_stage-active_count"
137 | Table false
138 | Attribute "ActiveCount"
139 |
140 |
141 | Type "gauge"
142 | InstancePrefix "read_stage-currently_blocked_tasks"
143 | Table false
144 | Attribute "CurrentlyBlockedTasks"
145 |
146 |
147 | Type "gauge"
148 | InstancePrefix "read_stage-pending_tasks"
149 | Table false
150 | Attribute "PendingTasks"
151 |
152 |
153 | Type "counter"
154 | InstancePrefix "read_stage-completed_tasks"
155 | Table false
156 | Attribute "CompletedTasks"
157 |
158 | {%- endcall %}
159 |
160 | {% call mbean("cassandra_stage_ReplicateOnWriteStage", mbeans) -%}
161 | ObjectName "org.apache.cassandra.request:type=ReplicateOnWriteStage"
162 |
163 | Type "gauge"
164 | InstancePrefix "replicate_on_write_stage-active_count"
165 | Table false
166 | Attribute "ActiveCount"
167 |
168 |
169 | Type "gauge"
170 | InstancePrefix "replicate_on_write_stage-currently_blocked_tasks"
171 | Table false
172 | Attribute "CurrentlyBlockedTasks"
173 |
174 |
175 | Type "gauge"
176 | InstancePrefix "replicate_on_write_stage-pending_tasks"
177 | Table false
178 | Attribute "PendingTasks"
179 |
180 |
181 | Type "counter"
182 | InstancePrefix "replicate_on_write_stage-completed_tasks"
183 | Table false
184 | Attribute "CompletedTasks"
185 |
186 | {%- endcall %}
187 |
188 | {% call mbean("cassandra_stage_RequestResponseStage", mbeans) -%}
189 | ObjectName "org.apache.cassandra.request:type=RequestResponseStage"
190 |
191 | Type "gauge"
192 | InstancePrefix "request_response_stage-active_count"
193 | Table false
194 | Attribute "ActiveCount"
195 |
196 |
197 | Type "gauge"
198 | InstancePrefix "request_response_stage-currently_blocked_tasks"
199 | Table false
200 | Attribute "CurrentlyBlockedTasks"
201 |
202 |
203 | Type "gauge"
204 | InstancePrefix "request_response_stage-pending_tasks"
205 | Table false
206 | Attribute "PendingTasks"
207 |
208 |
209 | Type "counter"
210 | InstancePrefix "request_response_stage-completed_tasks"
211 | Table false
212 | Attribute "CompletedTasks"
213 |
214 | {%- endcall %}
215 |
216 | {% call mbean("cassandra_internal_AntiEntropySessions", mbeans) -%}
217 | ObjectName "org.apache.cassandra.internal:type=AntiEntropySessions"
218 |
219 | Type "gauge"
220 | InstancePrefix "anti_entropy_sessions-active_count"
221 | Table false
222 | Attribute "ActiveCount"
223 |
224 |
225 | Type "gauge"
226 | InstancePrefix "anti_entropy_sessions-currently_blocked_tasks"
227 | Table false
228 | Attribute "CurrentlyBlockedTasks"
229 |
230 |
231 | Type "gauge"
232 | InstancePrefix "anti_entropy_sessions-pending_tasks"
233 | Table false
234 | Attribute "PendingTasks"
235 |
236 |
237 | Type "counter"
238 | InstancePrefix "anti_entropy_sessions-completed_tasks"
239 | Table false
240 | Attribute "CompletedTasks"
241 |
242 | {%- endcall %}
243 |
244 | {% call mbean("cassandra_internal_AntiEntropyStage", mbeans) -%}
245 | ObjectName "org.apache.cassandra.internal:type=AntiEntropyStage"
246 |
247 | Type "gauge"
248 | InstancePrefix "anti_entropy_stage-active_count"
249 | Table false
250 | Attribute "ActiveCount"
251 |
252 |
253 | Type "gauge"
254 | InstancePrefix "anti_entropy_stage-currently_blocked_tasks"
255 | Table false
256 | Attribute "CurrentlyBlockedTasks"
257 |
258 |
259 | Type "gauge"
260 | InstancePrefix "anti_entropy_stage-pending_tasks"
261 | Table false
262 | Attribute "PendingTasks"
263 |
264 |
265 | Type "counter"
266 | InstancePrefix "anti_entropy_stage-completed_tasks"
267 | Table false
268 | Attribute "CompletedTasks"
269 |
270 | {%- endcall %}
271 |
272 | {% call mbean("cassandra_internal_FlushWriter", mbeans) -%}
273 | ObjectName "org.apache.cassandra.internal:type=FlushWriter"
274 |
275 | Type "gauge"
276 | InstancePrefix "flush_writer-active_count"
277 | Table false
278 | Attribute "ActiveCount"
279 |
280 |
281 | Type "gauge"
282 | InstancePrefix "flush_writer-currently_blocked_tasks"
283 | Table false
284 | Attribute "CurrentlyBlockedTasks"
285 |
286 |
287 | Type "gauge"
288 | InstancePrefix "flush_writer-pending_tasks"
289 | Table false
290 | Attribute "PendingTasks"
291 |
292 |
293 | Type "counter"
294 | InstancePrefix "flush_writer-completed_tasks"
295 | Table false
296 | Attribute "CompletedTasks"
297 |
298 | {%- endcall %}
299 |
300 | {% call mbean("cassandra_internal_GossipStage", mbeans) -%}
301 | ObjectName "org.apache.cassandra.internal:type=GossipStage"
302 |
303 | Type "gauge"
304 | InstancePrefix "gossip_stage-active_count"
305 | Table false
306 | Attribute "ActiveCount"
307 |
308 |
309 | Type "gauge"
310 | InstancePrefix "gossip_stage-currently_blocked_tasks"
311 | Table false
312 | Attribute "CurrentlyBlockedTasks"
313 |
314 |
315 | Type "gauge"
316 | InstancePrefix "gossip_stage-pending_tasks"
317 | Table false
318 | Attribute "PendingTasks"
319 |
320 |
321 | Type "counter"
322 | InstancePrefix "gossip_stage-completed_tasks"
323 | Table false
324 | Attribute "CompletedTasks"
325 |
326 | {%- endcall %}
327 |
328 | {% call mbean("cassandra_internal_HintedHandoff", mbeans) -%}
329 | ObjectName "org.apache.cassandra.internal:type=HintedHandoff"
330 |
331 | Type "gauge"
332 | InstancePrefix "hinted_handoff-active_count"
333 | Table false
334 | Attribute "ActiveCount"
335 |
336 |
337 | Type "gauge"
338 | InstancePrefix "hinted_handoff-currently_blocked_tasks"
339 | Table false
340 | Attribute "CurrentlyBlockedTasks"
341 |
342 |
343 | Type "gauge"
344 | InstancePrefix "hinted_handoff-pending_tasks"
345 | Table false
346 | Attribute "PendingTasks"
347 |
348 |
349 | Type "counter"
350 | InstancePrefix "hinted_handoff-completed_tasks"
351 | Table false
352 | Attribute "CompletedTasks"
353 |
354 | {%- endcall %}
355 |
356 | {% call mbean("cassandra_internal_InternalResponseStage", mbeans) -%}
357 | ObjectName "org.apache.cassandra.internal:type=InternalResponseStage"
358 |
359 | Type "gauge"
360 | InstancePrefix "internal_response_stage-active_count"
361 | Table false
362 | Attribute "ActiveCount"
363 |
364 |
365 | Type "gauge"
366 | InstancePrefix "internal_response_stage-currently_blocked_tasks"
367 | Table false
368 | Attribute "CurrentlyBlockedTasks"
369 |
370 |
371 | Type "gauge"
372 | InstancePrefix "internal_response_stage-pending_tasks"
373 | Table false
374 | Attribute "PendingTasks"
375 |
376 |
377 | Type "counter"
378 | InstancePrefix "internal_response_stage-completed_tasks"
379 | Table false
380 | Attribute "CompletedTasks"
381 |
382 | {%- endcall %}
383 |
384 | {% call mbean("cassandra_internal_MemtablePostFlusher", mbeans) -%}
385 | ObjectName "org.apache.cassandra.internal:type=MemtablePostFlusher"
386 |
387 | Type "gauge"
388 | InstancePrefix "memtable_post_flusher-active_count"
389 | Table false
390 | Attribute "ActiveCount"
391 |
392 |
393 | Type "gauge"
394 | InstancePrefix "memtable_post_flusher-currently_blocked_tasks"
395 | Table false
396 | Attribute "CurrentlyBlockedTasks"
397 |
398 |
399 | Type "gauge"
400 | InstancePrefix "memtable_post_flusher-pending_tasks"
401 | Table false
402 | Attribute "PendingTasks"
403 |
404 |
405 | Type "counter"
406 | InstancePrefix "memtable_post_flusher-completed_tasks"
407 | Table false
408 | Attribute "CompletedTasks"
409 |
410 | {%- endcall %}
411 |
412 | {% call mbean("cassandra_internal_MigrationStage", mbeans) -%}
413 | ObjectName "org.apache.cassandra.internal:type=MigrationStage"
414 |
415 | Type "gauge"
416 | InstancePrefix "migration_stage-active_count"
417 | Table false
418 | Attribute "ActiveCount"
419 |
420 |
421 | Type "gauge"
422 | InstancePrefix "migration_stage-currently_blocked_tasks"
423 | Table false
424 | Attribute "CurrentlyBlockedTasks"
425 |
426 |
427 | Type "gauge"
428 | InstancePrefix "migration_stage-pending_tasks"
429 | Table false
430 | Attribute "PendingTasks"
431 |
432 |
433 | Type "counter"
434 | InstancePrefix "migration_stage-completed_tasks"
435 | Table false
436 | Attribute "CompletedTasks"
437 |
438 | {%- endcall %}
439 |
440 | {% call mbean("cassandra_internal_MiscStage", mbeans) -%}
441 | ObjectName "org.apache.cassandra.internal:type=MiscStage"
442 |
443 | Type "gauge"
444 | InstancePrefix "misc_stage-active_count"
445 | Table false
446 | Attribute "ActiveCount"
447 |
448 |
449 | Type "gauge"
450 | InstancePrefix "misc_stage-currently_blocked_tasks"
451 | Table false
452 | Attribute "CurrentlyBlockedTasks"
453 |
454 |
455 | Type "gauge"
456 | InstancePrefix "misc_stage-pending_tasks"
457 | Table false
458 | Attribute "PendingTasks"
459 |
460 |
461 | Type "counter"
462 | InstancePrefix "misc_stage-completed_tasks"
463 | Table false
464 | Attribute "CompletedTasks"
465 |
466 | {%- endcall %}
467 |
468 | {% call mbean("cassandra_internal_StreamStage", mbeans) -%}
469 | ObjectName "org.apache.cassandra.internal:type=StreamStage"
470 |
471 | Type "gauge"
472 | InstancePrefix "stream_stage-active_count"
473 | Table false
474 | Attribute "ActiveCount"
475 |
476 |
477 | Type "gauge"
478 | InstancePrefix "stream_stage-currently_blocked_tasks"
479 | Table false
480 | Attribute "CurrentlyBlockedTasks"
481 |
482 |
483 | Type "gauge"
484 | InstancePrefix "stream_stage-pending_tasks"
485 | Table false
486 | Attribute "PendingTasks"
487 |
488 |
489 | Type "counter"
490 | InstancePrefix "stream_stage-completed_tasks"
491 | Table false
492 | Attribute "CompletedTasks"
493 |
494 | {%- endcall %}
495 | {% endblock mbean_list %}
496 |
--------------------------------------------------------------------------------
/templates/couchdb.conf.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2015 Google Inc. All Rights Reserved.
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | #}
16 | {% extends "curl_json-metrics-base.jinja" %}
17 | {% block target %}CouchDB{% endblock %}
18 | {% block service %}CouchDB{% endblock %}
19 | {% block host_port_prefix %}COUCHDB{% endblock %}
20 | {% block port %}5984{% endblock %}
21 | {% block url_suffix %}_stats{% endblock %}
22 | {% block key_list %}
23 |
24 | Type "counter"
25 |
26 |
27 | Type "counter"
28 |
29 |
30 | Type "gauge"
31 |
32 |
33 | Type "gauge"
34 |
35 |
36 | Type "gauge"
37 |
38 |
39 | Type "counter"
40 |
41 |
42 | Type "counter"
43 |
44 |
45 | Type "counter"
46 |
47 |
48 | Type "counter"
49 |
50 |
51 | Type "counter"
52 |
53 |
54 | Type "counter"
55 |
56 |
57 | Type "counter"
58 |
59 |
60 | Type "counter"
61 |
62 |
63 | Type "counter"
64 |
65 |
66 | Type "counter"
67 |
68 |
69 | Type "counter"
70 |
71 |
72 | Type "counter"
73 |
74 |
75 | Type "counter"
76 |
77 |
78 | Type "counter"
79 |
80 |
81 | Type "counter"
82 |
83 |
84 | Type "counter"
85 |
86 |
87 | Type "counter"
88 |
89 |
90 | Type "counter"
91 |
92 |
93 | Type "counter"
94 |
95 |
96 | Type "counter"
97 |
98 |
99 | Type "counter"
100 |
101 |
102 | Type "counter"
103 |
104 |
105 | Type "counter"
106 |
107 |
108 | Type "counter"
109 |
110 | {% endblock key_list %}
111 |
--------------------------------------------------------------------------------
/templates/curl_json-metrics-base.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2015 Google Inc. All Rights Reserved.
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | #}
16 | {% macro key(name, type) %}
17 |
18 | Type "{{ type }}"
19 |
20 | {% endmacro %}
21 | {% macro url(url_suffix) %}
22 | {% block service_url_start scoped %}
23 | # When using non-standard {% block service %}{% endblock %} configurations, replace the below with
24 | #
25 |
26 | {% endblock service_url_start %}
27 | Instance "{% block plugin_instance %}{{ self.service()|lower }}{% endblock %}"
28 |
29 | {{ caller() -}}
30 | {% block service_url_end %}
31 |
32 | {% endblock service_url_end %}
33 | {% endmacro %}
34 | {% block header_comment %}
35 | # This is the monitoring configuration for {% block target %}{% endblock %}.
36 | # Look for {% block host_port_variables %}{% block host_alt_name %}{% block host_port_prefix %}{% endblock %}_HOST{% endblock %} and {% block port_alt_name %}{{ self.host_port_prefix() }}_PORT{% endblock %}{% endblock host_port_variables %} to adjust your configuration file.
37 | {% endblock header_comment %}
38 | LoadPlugin curl_json
39 |
40 | {% block service_url %}
41 | {% set url_suffix %}{% block url_suffix %}{% endblock %}{% endset %}
42 | {% call url(url_suffix) %}
43 | {% block key_list %}{% endblock %}
44 | {% endcall %}
45 | {% endblock service_url %}
46 |
47 |
48 | LoadPlugin match_regex
49 | LoadPlugin target_set
50 | LoadPlugin target_replace
51 | {% block extra_plugins %}
52 | {% endblock %}
53 | {% block service_chains %}
54 |
55 |
56 |
57 | Plugin "^curl_json$"
58 | PluginInstance "{% block plugin_instance_regex %}^{% block plugin_instance_prefix %}{{ self.plugin_instance() }}{% endblock %}.*${% endblock %}"
59 |
60 |
61 | PluginInstance "^{{ self.plugin_instance_prefix() }}" ""
62 |
63 |
64 | Plugin "{{ self.service()|lower }}"
65 |
66 |
67 | {% block empty_plugininstance_rule %}
68 |
69 |
70 | PluginInstance "^$"
71 |
72 |
73 | PluginInstance "localhost"
74 |
75 |
76 | {% endblock empty_plugininstance_rule %}
77 | {% block extra_rules %}
78 | {% endblock %}
79 |
80 | Target "return"
81 |
82 |
83 |
84 |
85 |
86 |
87 | Chain "curl_json_{{ self.service()|lower }}"
88 |
89 |
90 |
91 | PreCacheChain "PreCache"
92 | {% endblock service_chains %}
93 |
--------------------------------------------------------------------------------
/templates/elasticsearch-1.conf.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2015 Google Inc. All Rights Reserved.
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | #}
16 | {% extends "curl_json-metrics-base.jinja" %}
17 | {% block target %}Elasticsearch 1.0.x and later{% endblock %}
18 | {% block service %}Elasticsearch{% endblock %}
19 | {% block host_port_prefix %}ELASTICSEARCH{% endblock %}
20 | {% block port %}9200{% endblock %}
21 | {% block url_suffix %}_nodes/_local/stats/{% endblock %}
22 | {% block service_url %}
23 | {% set url_suffix %}{{ self.url_suffix() }}{% endset %}
24 | {% call url(url_suffix) %}
25 |
26 | Type "gauge"
27 |
28 |
29 | Type "gauge"
30 |
31 |
32 | Type "gauge"
33 |
34 |
35 | Type "counter"
36 |
37 |
38 | Type "counter"
39 |
40 |
41 | Type "counter"
42 |
43 |
44 | Type "counter"
45 |
46 |
47 | Type "counter"
48 |
49 |
50 | Type "counter"
51 |
52 |
53 | Type "counter"
54 |
55 |
56 | Type "counter"
57 |
58 |
59 | Type "counter"
60 |
61 |
62 | Type "counter"
63 |
64 |
65 | Type "counter"
66 |
67 |
68 | Type "counter"
69 |
70 |
71 | Type "counter"
72 |
73 |
74 | Type "counter"
75 |
76 |
77 | Type "gauge"
78 |
79 |
80 | Type "counter"
81 |
82 |
83 | Type "gauge"
84 |
85 |
86 | Type "counter"
87 |
88 |
89 | Type "gauge"
90 |
91 |
92 | Type "gauge"
93 |
94 |
95 | Type "gauge"
96 |
97 |
98 | Type "gauge"
99 |
100 |
101 | Type "gauge"
102 |
103 |
104 | Type "gauge"
105 |
106 |
107 | Type "gauge"
108 |
109 |
110 | Type "counter"
111 |
112 |
113 | Type "counter"
114 |
115 |
116 | Type "counter"
117 |
118 |
119 | Type "gauge"
120 |
121 |
122 | Type "gauge"
123 |
124 | {% endcall %}
125 |
126 | {% call url("_cluster/health/") %}
127 |
128 | Type "gauge"
129 |
130 |
131 | Type "gauge"
132 |
133 |
134 | Type "gauge"
135 |
136 |
137 | Type "gauge"
138 |
139 |
140 | Type "gauge"
141 |
142 |
143 | Type "gauge"
144 |
145 |
146 | Type "gauge"
147 |
148 | {% endcall %}
149 | {% endblock %}
150 |
--------------------------------------------------------------------------------
/templates/elasticsearch.conf.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2015 Google Inc. All Rights Reserved.
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | #}
16 | {% extends 'elasticsearch-1.conf.jinja' -%}
17 | {% block target %}Elasticsearch 0.90.x and earlier{% endblock %}
18 | {% block url_suffix %}_cluster/nodes/_local/stats?all=true{% endblock %}
19 |
--------------------------------------------------------------------------------
/templates/hbase-095.conf.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2015 Google Inc. All Rights Reserved.
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | #}
16 | {% extends "jmx-metrics-base.jinja" %}
17 | {% block target %}HBase 0.95 and earlier{% endblock %}
18 | {% block service %}HBase{% endblock %}
19 | {% block jmx_host_alt_name %}HBASE_HOST{% endblock %}
20 | {% block jmx_port_alt_name %}HBASE_REGIONSERVER_PORT{% endblock %}
21 | {% block jmx_port %}10102{% endblock %}
22 | {% block instance_prefix %}hbaseregionserver{% endblock %}
23 | {% block mbean_list %}
24 | {% call mbean("hbase_regionserver_RegionServerStatistics", mbeans) -%}
25 | ObjectName "hadoop:service=RegionServer,name=RegionServerStatistics"
26 | # The three attributes below are identical; they are renamed versions of each other.
27 |
28 | Type "gauge"
29 | InstancePrefix "regionserver-blockCacheHitPercent"
30 | Table false
31 | # This may be a name that was never used.
32 | Attribute "blockCacheExpressCachingRatio"
33 |
34 |
35 | Type "gauge"
36 | InstancePrefix "regionserver-blockCacheHitPercent"
37 | Table false
38 | # This is the name used in HBase 0.94 and earlier.
39 | Attribute "blockCacheHitCachingRatio"
40 |
41 |
42 | Type "gauge"
43 | InstancePrefix "regionserver-blockCacheHitPercent"
44 | Table false
45 | Attribute "blockCountHitPercent"
46 |
47 |
48 |
49 | Type "gauge"
50 | InstancePrefix "regionserver-callQueueLength"
51 | Table false
52 | Attribute "callQueueLength"
53 |
54 |
55 | # The two attributes below are identical; one is a renamed version of the other.
56 |
57 | Type "gauge"
58 | InstancePrefix "regionserver-compactionQueueLength"
59 | Table false
60 | # This is the name used in HBase 0.94 and earlier.
61 | Attribute "compactionQueueSize"
62 |
63 |
64 | Type "gauge"
65 | InstancePrefix "regionserver-compactionQueueLength"
66 | Table false
67 | Attribute "compactionQueueLength"
68 |
69 |
70 |
71 | Type "gauge"
72 | InstancePrefix "regionserver-flushQueueLength"
73 | Table false
74 | Attribute "flushQueueSize"
75 |
76 |
77 |
78 | Type "gauge"
79 | # Renamed for consistency with newer metrics.
80 | InstancePrefix "regionserver-memStoreSizeMB"
81 | Table false
82 | Attribute "memstoreSizeMB"
83 |
84 |
85 | Type "gauge"
86 | InstancePrefix "regionserver-numberOfOnlineRegions"
87 | Table false
88 | Attribute "numberOfOnlineRegions"
89 |
90 |
91 | Type "counter"
92 | # Renamed for consistency with newer metrics.
93 | InstancePrefix "regionserver-readRequestCount"
94 | Table false
95 | Attribute "readRequestsCount"
96 |
97 |
98 | Type "counter"
99 | # Renamed for consistency with newer metrics.
100 | InstancePrefix "regionserver-writeRequestCount"
101 | Table false
102 | Attribute "writeRequestsCount"
103 |
104 |
105 | Type "counter"
106 | # Renamed for consistency with newer metrics.
107 | InstancePrefix "regionserver-slowAppendCount"
108 | Table false
109 | Attribute "slowHLogAppendCount"
110 |
111 |
112 | Type "gauge"
113 | InstancePrefix "regionserver-usedHeapMB"
114 | Table false
115 | Attribute "usedHeapMB"
116 |
117 |
118 | Type "gauge"
119 | InstancePrefix "regionserver-blockCacheCount"
120 | Table false
121 | Attribute "blockCacheCount"
122 |
123 |
124 | # The two attributes below are identical; one is a renamed version of the other.
125 |
126 | Type "counter"
127 | InstancePrefix "regionserver-blockCacheEvictedCount"
128 | Table false
129 | # This is the name used in HBase 0.94 and earlier.
130 | Attribute "blockCacheEvictedCount"
131 |
132 |
133 | Type "counter"
134 | InstancePrefix "regionserver-blockCacheEvictionCount"
135 | Table false
136 | Attribute "blockCacheEvictionCount"
137 |
138 |
139 |
140 | Type "gauge"
141 | InstancePrefix "regionserver-blockCacheFreeMB"
142 | Table false
143 | Attribute "blockCacheFreeMB"
144 |
145 |
146 | Type "counter"
147 | InstancePrefix "regionserver-blockCacheHitCount"
148 | Table false
149 | Attribute "blockCacheHitCount"
150 |
151 |
152 | Type "counter"
153 | InstancePrefix "regionserver-blockCacheMissCount"
154 | Table false
155 | Attribute "blockCacheMissCount"
156 |
157 |
158 | Type "gauge"
159 | InstancePrefix "regionserver-blockCacheSizeMB"
160 | Table false
161 | Attribute "blockCacheSizeMB"
162 |
163 |
164 | Type "gauge"
165 | # Renamed for consistency with newer metrics.
166 | InstancePrefix "regionserver-storeCount"
167 | Table false
168 | Attribute "NumberOfStores"
169 |
170 |
171 | Type "gauge"
172 | InstancePrefix "regionserver-NumberOfStorefiles"
173 | Table false
174 | Attribute "NumberOfStorefiles"
175 |
176 |
177 | Type "gauge"
178 | InstancePrefix "regionserver-requestsPerSecond"
179 | Table false
180 | Attribute "requestsPerSecond"
181 |
182 |
183 | Type "gauge"
184 | InstancePrefix "regionserver-storeFileIndexSizeMB"
185 | Table false
186 | Attribute "storeFileIndexSizeMB"
187 |
188 | {%- endcall %}
189 | {% endblock mbean_list %}
190 |
191 | {% block extra_plugins %}
192 | LoadPlugin target_scale
193 | {% endblock extra_plugins %}
194 | {% block extra_rules %}
195 |
196 |
197 | TypeInstance "^.*MB$"
198 |
199 |
200 | Factor 1048576 # 1024 * 1024
201 |
202 |
203 | TypeInstance "MB" ""
204 |
205 |
206 | {% endblock extra_rules %}
207 |
--------------------------------------------------------------------------------
/templates/hbase-098-standalone.conf.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2015 Google Inc. All Rights Reserved.
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | #}
16 | {% extends 'hbase-098.conf.jinja' -%}
17 | {% block target %}HBase 0.98 and later running in standalone mode
18 | # (all services on the same port){% endblock %}
19 | {% block jmx_port_alt_name %}HBASE_PORT{% endblock %}
20 | {% block host_port_variables %}HBASE_HOST and HBASE_PORT{% endblock %}
21 | {% block jmx_port %}10101{% endblock %}
22 |
--------------------------------------------------------------------------------
/templates/hbase-098.conf.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2015 Google Inc. All Rights Reserved.
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | #}
16 | {% extends "jmx-metrics-base.jinja" %}
17 | {% block target %}HBase 0.98 and later running in distributed mode{% endblock %}
18 | {% block service %}HBase{% endblock %}
19 | {% block instance_prefix %}%(instance_prefix)s{% endblock %}
20 | {% block jmx_host_alt_name %}HBASE_HOST{% endblock %}
21 | {% block jmx_port_alt_name %}%(jmx_port_alt_name)s{% endblock %}
22 | {% block jmx_port %}%(jmx_port)s{% endblock %}
23 | {% block host_port_variables %}HBASE_HOST, HBASE_MASTER_PORT, and HBASE_REGIONSERVER_PORT{% endblock %}
24 | {% set master_mbeans = [] %}
25 | {% set regionserver_mbeans = [] %}
26 | {% block mbean_list %}
27 | {% call mbean("hbase_master_Server", master_mbeans) -%}
28 | ObjectName "Hadoop:service=HBase,name=Master,sub=Server"
29 |
30 | Type "gauge"
31 | InstancePrefix "master-averageLoad"
32 | Table false
33 | Attribute "averageLoad"
34 |
35 |
36 | Type "gauge"
37 | InstancePrefix "master-numRegionServers"
38 | Table false
39 | Attribute "numRegionServers"
40 |
41 |
42 | Type "gauge"
43 | InstancePrefix "master-numDeadRegionServers"
44 | Table false
45 | Attribute "numDeadRegionServers"
46 |
47 | {%- endcall %}
48 |
49 | {% call mbean("hbase_ipc_IPC", master_mbeans) -%}
50 | ObjectName "Hadoop:service=HBase,name=IPC,sub=IPC"
51 |
52 | Type "counter"
53 | InstancePrefix "ipc-sentBytes"
54 | Table false
55 | Attribute "sentBytes"
56 |
57 |
58 | Type "counter"
59 | InstancePrefix "ipc-receivedBytes"
60 | Table false
61 | Attribute "receivedBytes"
62 |
63 |
64 | Type "gauge"
65 | InstancePrefix "ipc-queueSize"
66 | Table false
67 | Attribute "queueSize"
68 |
69 |
70 | Type "gauge"
71 | InstancePrefix "ipc-numOpenConnections"
72 | Table false
73 | Attribute "numOpenConnections"
74 |
75 | {%- endcall %}
76 |
77 | {% call mbean("hbase_regionserver_RegionServerStatistics", regionserver_mbeans) -%}
78 | ObjectName "Hadoop:service=HBase,name=RegionServer,sub=Server"
79 |
80 | Type "gauge"
81 | InstancePrefix "regionserver-blockCacheCount"
82 | Table false
83 | Attribute "blockCacheCount"
84 |
85 |
86 | Type "counter"
87 | InstancePrefix "regionserver-blockCacheEvictedCount"
88 | Table false
89 | Attribute "blockCacheEvictionCount"
90 |
91 |
92 | Type "gauge"
93 | InstancePrefix "regionserver-blockCacheFreeSize"
94 | Table false
95 | Attribute "blockCacheFreeSize"
96 |
97 |
98 | Type "counter"
99 | InstancePrefix "regionserver-blockCacheHitCount"
100 | Table false
101 | Attribute "blockCacheHitCount"
102 |
103 |
104 | # The two attributes below are identical; one is a renamed version of the other.
105 |
106 | Type "gauge"
107 | InstancePrefix "regionserver-blockCacheHitPercent"
108 | Table false
109 | # This is the name used in HBase 0.98 and earlier.
110 | Attribute "blockCountHitPercent"
111 |
112 |
113 | Type "gauge"
114 | InstancePrefix "regionserver-blockCacheHitPercent"
115 | Table false
116 | Attribute "blockCacheCountHitPercent"
117 |
118 |
119 |
120 | Type "counter"
121 | InstancePrefix "regionserver-blockCacheMissCount"
122 | Table false
123 | Attribute "blockCacheMissCount"
124 |
125 |
126 | Type "gauge"
127 | InstancePrefix "regionserver-blockCacheSize"
128 | Table false
129 | Attribute "blockCacheSize"
130 |
131 |
132 | Type "gauge"
133 | InstancePrefix "regionserver-compactionQueueLength"
134 | Table false
135 | Attribute "compactionQueueLength"
136 |
137 |
138 | Type "gauge"
139 | InstancePrefix "regionserver-flushQueueLength"
140 | Table false
141 | Attribute "flushQueueLength"
142 |
143 |
144 | Type "gauge"
145 | InstancePrefix "regionserver-memStoreSize"
146 | Table false
147 | Attribute "memStoreSize"
148 |
149 |
150 | Type "gauge"
151 | InstancePrefix "regionserver-storeCount"
152 | Table false
153 | Attribute "storeCount"
154 |
155 |
156 | Type "counter"
157 | InstancePrefix "regionserver-readRequestCount"
158 | Table false
159 | Attribute "readRequestCount"
160 |
161 |
162 | Type "gauge"
163 | InstancePrefix "regionserver-storeFileIndexSize"
164 | Table false
165 | Attribute "storeFileIndexSize"
166 |
167 |
168 | Type "counter"
169 | InstancePrefix "regionserver-writeRequestCount"
170 | Table false
171 | Attribute "writeRequestCount"
172 |
173 |
174 | Type "counter"
175 | InstancePrefix "regionserver-totalRequestCount"
176 | Table false
177 | Attribute "totalRequestCount"
178 |
179 |
180 | Type "counter"
181 | InstancePrefix "regionserver-slowAppendCount"
182 | Table false
183 | Attribute "slowAppendCount"
184 |
185 |
186 | Type "counter"
187 | InstancePrefix "regionserver-slowPutCount"
188 | Table false
189 | Attribute "slowPutCount"
190 |
191 |
192 | Type "counter"
193 | InstancePrefix "regionserver-slowGetCount"
194 | Table false
195 | Attribute "slowGetCount"
196 |
197 | {%- endcall %}
198 | {% endblock mbean_list %}
199 | {% block connections %}
200 | {% do mbeans.extend(master_mbeans) %}
201 | {{- super()|format(jmx_port=10101, jmx_port_alt_name='HBASE_MASTER_PORT', instance_prefix='hbasemaster') }}
202 | {% for i in range(0, mbeans|count) %}{% do mbeans.pop() %}{% endfor %}
203 | {% do mbeans.extend(regionserver_mbeans) %}
204 | {{- super()|format(jmx_port=10102, jmx_port_alt_name='HBASE_REGIONSERVER_PORT', instance_prefix='hbaseregionserver') -}}
205 | {% endblock connections %}
206 | {% block jvm_metrics %}
207 | {# TODO: find a way to collect JVM metrics from both master and regionserver #}
208 | {{- super()|format(jmx_port=10102, jmx_port_alt_name='HBASE_REGIONSERVER_PORT') -}}
209 | {% endblock jvm_metrics %}
210 |
--------------------------------------------------------------------------------
/templates/hbase-thrift.conf.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2015 Google Inc. All Rights Reserved.
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | #}
16 | {% extends "jmx-metrics-base.jinja" %}
17 | {% block target %}HBase Thrift{% endblock %}
18 | {% block service %}HBase{% endblock %}
19 | {% block instance_prefix %}hbasethrift{% endblock %}
20 | {% block jmx_host_alt_name %}HBASE_HOST{% endblock %}
21 | {% block jmx_port_alt_name %}HBASE_THRIFT_PORT{% endblock %}
22 | {% block jmx_port %}10103{% endblock %}
23 | {% block mbean_list %}
24 | {% call mbean("hbase_thrift_ThriftOne", mbeans) -%}
25 | ObjectName "Hadoop:service=HBase,name=Thrift,sub=ThriftOne"
26 |
27 | Type "gauge"
28 | InstancePrefix "thrift_one-callQueueLen"
29 | Table false
30 | Attribute "callQueueLen"
31 |
32 |
33 | Type "gauge"
34 | InstancePrefix "thrift_one-SlowThriftCall_mean"
35 | Table false
36 | Attribute "SlowThriftCall_mean"
37 |
38 |
39 | Type "gauge"
40 | InstancePrefix "thrift_one-TimeInQueue_mean"
41 | Table false
42 | Attribute "TimeInQueue_mean"
43 |
44 |
45 | Type "gauge"
46 | InstancePrefix "thrift_one-ThriftCall_mean"
47 | Table false
48 | Attribute "ThriftCall_mean"
49 |
50 |
51 | Type "gauge"
52 | InstancePrefix "thrift_one-BatchGet_mean"
53 | Table false
54 | Attribute "BatchGet_mean"
55 |
56 |
57 | Type "gauge"
58 | InstancePrefix "thrift_one-BatchMutate_mean"
59 | Table false
60 | Attribute "BatchMutate_mean"
61 |
62 | {%- endcall %}
63 |
64 | {% call mbean("hbase_thrift_ThriftTwo", mbeans) -%}
65 | ObjectName "Hadoop:service=HBase,name=Thrift,sub=ThriftTwo"
66 |
67 | Type "gauge"
68 | InstancePrefix "thrift_two-callQueueLen"
69 | Table false
70 | Attribute "callQueueLen"
71 |
72 |
73 | Type "gauge"
74 | InstancePrefix "thrift_two-SlowThriftCall_mean"
75 | Table false
76 | Attribute "SlowThriftCall_mean"
77 |
78 |
79 | Type "gauge"
80 | InstancePrefix "thrift_two-TimeInQueue_mean"
81 | Table false
82 | Attribute "TimeInQueue_mean"
83 |
84 |
85 | Type "gauge"
86 | InstancePrefix "thrift_two-ThriftCall_mean"
87 | Table false
88 | Attribute "ThriftCall_mean"
89 |
90 |
91 | Type "gauge"
92 | InstancePrefix "thrift_two-BatchGet_mean"
93 | Table false
94 | Attribute "BatchGet_mean"
95 |
96 |
97 | Type "gauge"
98 | InstancePrefix "thrift_two-BatchMutate_mean"
99 | Table false
100 | Attribute "BatchMutate_mean"
101 |
102 | {%- endcall %}
103 | {% endblock mbean_list %}
104 | {% block jvm_metrics %}
105 | {# TODO: find a way to collect JVM metrics from the thrift JVM #}
106 | {% endblock jvm_metrics %}
107 | {% block jvm_chains %}{% endblock %}
108 |
--------------------------------------------------------------------------------
/templates/jmx-metrics-base.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2015 Google Inc. All Rights Reserved.
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | #}
16 | {% import 'jvm-sun-hotspot-macros.jinja' as jvm %}
17 | {% from 'jvm-sun-hotspot-macros.jinja' import mbean %}
18 | {% block header_comment %}
19 | # This is the monitoring configuration for {% block target %}standalone JVMs{% endblock %}.
20 | # Look for {% block host_port_variables %}{% block jmx_host_alt_name %}{% block jmx_host_port_prefix %}JMX{% endblock %}_HOST{% endblock %} and {% block jmx_port_alt_name %}{{ self.jmx_host_port_prefix() }}_PORT{% endblock %}{% endblock host_port_variables %} to adjust your configuration file.
21 | {% endblock header_comment %}
22 | LoadPlugin java
23 |
24 | JVMARG "-Djava.class.path=/opt/stackdriver/collectd/share/collectd/java/collectd-api.jar:/opt/stackdriver/collectd/share/collectd/java/generic-jmx.jar"
25 | LoadPlugin "org.collectd.java.GenericJMX"
26 |
27 |
28 | {% set mbeans = [] %}
29 | {% block non_java_metrics %}
30 | {% block mbean_list %}
31 | {% endblock %}
32 |
33 |
34 | {% block connections %}
35 |
36 | {% block service_url %}
37 | # When using non-standard {% block service %}JVM{% endblock %} configurations, replace the below with
38 | #ServiceURL "service:jmx:rmi:///jndi/rmi://{{ self.jmx_host_alt_name() }}:{{ self.jmx_port_alt_name() }}/jmxrmi"
39 | ServiceURL "service:jmx:rmi:///jndi/rmi://{% block jmx_host %}localhost{% endblock %}:{% block jmx_port %}{% endblock %}/jmxrmi"
40 | {% endblock service_url %}
41 | InstancePrefix "{% block instance_prefix %}{{ self.service()|lower }}{% endblock %}"
42 |
43 | {% for mbean in mbeans %}
44 | Collect "{{ mbean }}"
45 | {% endfor %}
46 |
47 | {% endblock connections %}
48 |
49 |
50 | {% endblock non_java_metrics %}
51 | {% block jvm_metrics %}
52 | {{- jvm.metrics(jmx_port=self.jmx_port(), jmx_port_alt_name=self.jmx_port_alt_name(), jmx_host_alt_name=self.jmx_host_alt_name(), service=self.service()) }}
53 | {% endblock jvm_metrics %}
54 |
55 |
56 |
57 | LoadPlugin match_regex
58 | LoadPlugin target_set
59 | LoadPlugin target_replace
60 | {% block extra_plugins %}
61 | {% endblock %}
62 | {% block service_chains %}
63 |
64 |
65 |
66 | Plugin "^GenericJMX$"
67 | PluginInstance "^{{ self.service()|lower }}.*$"
68 |
69 |
70 | PluginInstance "{{ self.service()|lower }}" ""
71 |
72 |
73 | Plugin "{{ self.service()|lower }}"
74 |
75 |
76 | {% block extra_rules %}
77 | {% endblock %}
78 |
79 | Target "return"
80 |
81 |
82 |
83 |
84 |
85 |
86 | Chain "GenericJMX_{{ self.service()|lower }}"
87 |
88 |
89 |
90 | PreCacheChain "PreCache"
91 |
92 | {% endblock service_chains %}
93 | {% block jvm_chains %}
94 | {{- jvm.chains() -}}
95 | {% endblock jvm_chains %}
96 |
--------------------------------------------------------------------------------
/templates/jvm-sun-hotspot-macros.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2015 Google Inc. All Rights Reserved.
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | #}
16 | {% macro mbean(name, mbean_list) %}
17 | {% do mbean_list.append(name) %}
18 |
19 | {{ caller() }}
20 |
21 | {% endmacro %}
22 | {% set jvm_mbeans = [] %}
23 | {% macro metrics(jmx_port='', jmx_host='localhost', jmx_port_alt_name='JMX_PORT', jmx_host_alt_name='JMX_HOST', service='JVM') -%}
24 | {% call mbean("jvm_localhost_Threading", jvm_mbeans) -%}
25 | ObjectName "java.lang:type=Threading"
26 |
27 | Type "gauge"
28 | InstancePrefix "threading-daemon_thread_count"
29 | Table false
30 | Attribute "DaemonThreadCount"
31 |
32 |
33 | Type "gauge"
34 | InstancePrefix "threading-thread_count"
35 | Table false
36 | Attribute "ThreadCount"
37 |
38 |
39 | Type "gauge"
40 | InstancePrefix "threading-peak_thread_count"
41 | Table false
42 | Attribute "PeakThreadCount"
43 |
44 | {%- endcall %}
45 |
46 | {% call mbean("jvm_localhost_Memory", jvm_mbeans) -%}
47 | ObjectName "java.lang:type=Memory"
48 |
49 | Type "memory"
50 | InstancePrefix "memory-heap_usage_committed"
51 | Table false
52 | Attribute "HeapMemoryUsage.committed"
53 |
54 |
55 | Type "memory"
56 | InstancePrefix "memory-non_heap_usage_committed"
57 | Table false
58 | Attribute "NonHeapMemoryUsage.committed"
59 |
60 |
61 | Type "memory"
62 | InstancePrefix "memory-heap_usage_used"
63 | Table false
64 | Attribute "HeapMemoryUsage.used"
65 |
66 |
67 | Type "memory"
68 | InstancePrefix "memory-non_heap_usage_used"
69 | Table false
70 | Attribute "NonHeapMemoryUsage.used"
71 |
72 |
73 | Type "memory"
74 | InstancePrefix "memory-heap_usage_max"
75 | Table false
76 | Attribute "HeapMemoryUsage.max"
77 |
78 |
79 | Type "memory"
80 | InstancePrefix "memory-non_heap_usage_max"
81 | Table false
82 | Attribute "NonHeapMemoryUsage.max"
83 |
84 | {%- endcall %}
85 |
86 | {% call mbean("jvm_localhost_Runtime", jvm_mbeans) -%}
87 | ObjectName "java.lang:type=Runtime"
88 |
89 | Type "counter"
90 | InstancePrefix "runtime-uptime"
91 | Table false
92 | Attribute "Uptime"
93 |
94 | {%- endcall %}
95 |
96 | {% call mbean("jvm_localhost_os", jvm_mbeans) -%}
97 | ObjectName "java.lang:type=OperatingSystem"
98 |
99 | Type "gauge"
100 | InstancePrefix "os-open_fd_count"
101 | Table false
102 | Attribute "OpenFileDescriptorCount"
103 |
104 |
105 | Type "counter"
106 | InstancePrefix "os-process_cpu_time"
107 | Table false
108 | Attribute "ProcessCpuTime"
109 |
110 | {%- endcall %}
111 |
112 | {% call mbean("jvm_localhost_gc", jvm_mbeans) -%}
113 | ObjectName "java.lang:type=GarbageCollector,name=*"
114 | InstanceFrom "name"
115 |
116 | Type "counter"
117 | InstancePrefix "gc-collection_count"
118 | Table false
119 | Attribute "CollectionCount"
120 |
121 |
122 | Type "counter"
123 | InstancePrefix "gc-collection_time"
124 | Table false
125 | Attribute "CollectionTime"
126 |
127 | {%- endcall %}
128 |
129 |
130 | {% if jmx_port %}
131 | # When using non-standard {{service}} configurations, replace the below with
132 | #ServiceURL "service:jmx:rmi:///jndi/rmi://{{jmx_host_alt_name}}:{{jmx_port_alt_name}}/jmxrmi"
133 | ServiceURL "service:jmx:rmi:///jndi/rmi://{{jmx_host}}:{{jmx_port}}/jmxrmi"
134 | {% else %}
135 | ServiceURL "service:jmx:rmi:///jndi/rmi://{{jmx_host_alt_name}}:{{jmx_port_alt_name}}/jmxrmi"
136 | {% endif %}
137 | InstancePrefix "jvm"
138 |
139 | {% for mbean in jvm_mbeans %}
140 | Collect "{{ mbean }}"
141 | {% endfor %}
142 |
143 | {%- endmacro %}
144 |
145 | {% macro chains() -%}
146 |
147 |
148 |
149 | Plugin "^GenericJMX$"
150 | PluginInstance "^jvm.*$"
151 |
152 |
153 | PluginInstance "jvm" ""
154 |
155 |
156 | Plugin "jvm"
157 |
158 | Target "return"
159 |
160 |
161 |
162 |
163 |
164 |
165 | Chain "GenericJMX_jvm"
166 |
167 |
168 |
169 | PreCacheChain "PreCache"
170 | {%- endmacro %}
171 |
--------------------------------------------------------------------------------
/templates/jvm-sun-hotspot.conf.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2015 Google Inc. All Rights Reserved.
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | #}
16 | {% extends "jmx-metrics-base.jinja" %}
17 | {% block header_comment %}
18 | {{ super() -}}
19 | # Replace {{ self.jmx_port_alt_name() }} below with the value configured in your JVM deployment.
20 | {% endblock header_comment %}
21 | {% block service %}JVM{% endblock %}
22 | {% block jmx_port %}{{ self.jmx_port_alt_name() }}{% endblock %}
23 | {% block non_java_metrics %}{% endblock %}
24 | {% block service_chains %}{% endblock %}
25 |
--------------------------------------------------------------------------------
/templates/kafka-082.conf.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2015 Google Inc. All Rights Reserved.
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | #}
16 | {% extends "jmx-metrics-base.jinja" %}
17 | {% block target %}Apache Kafka 0.8.2 and later{% endblock %}
18 | {% block service %}Kafka{% endblock %}
19 | {% block jmx_host_port_prefix %}KAFKA{% endblock %}
20 | {% block jmx_port %}9999{% endblock %}
21 | {% block mbean_list %}
22 | {% call mbean("kafka_log-LogFlushStats_LogFlush", mbeans) -%}
23 | ObjectName "kafka.log:type=LogFlushStats,name=LogFlushRateAndTimeMs"
24 |
25 | Type "counter"
26 | InstancePrefix "log-LogFlushes"
27 | Table false
28 | Attribute "Count"
29 |
30 | {%- endcall %}
31 |
32 | {% call mbean("kafka_server-BrokerTopicMetrics_AllTopicsBytesIn", mbeans) -%}
33 | ObjectName "kafka.server:type=BrokerTopicMetrics,name=BytesInPerSec"
34 |
35 | Type "counter"
36 | InstancePrefix "server_broker_topics-AllTopicsBytesIn"
37 | Table false
38 | Attribute "Count"
39 |
40 | {%- endcall %}
41 | {% call mbean("kafka_server-BrokerTopicMetrics_AllTopicsFailedFetchRequests", mbeans) -%}
42 | ObjectName "kafka.server:type=BrokerTopicMetrics,name=FailedFetchRequestsPerSec"
43 |
44 | Type "counter"
45 | InstancePrefix "server_broker_topics-AllTopicsFailedFetchRequests"
46 | Table false
47 | Attribute "Count"
48 |
49 | {%- endcall %}
50 | {% call mbean("kafka_server-BrokerTopicMetrics_AllTopicsFailedProduceRequests", mbeans) -%}
51 | ObjectName "kafka.server:type=BrokerTopicMetrics,name=FailedProduceRequestsPerSec"
52 |
53 | Type "counter"
54 | InstancePrefix "server_broker_topics-AllTopicsFailedProduceRequests"
55 | Table false
56 | Attribute "Count"
57 |
58 | {%- endcall %}
59 | {% call mbean("kafka_server-BrokerTopicMetrics_AllTopicsMessagesIn", mbeans) -%}
60 | ObjectName "kafka.server:type=BrokerTopicMetrics,name=MessagesInPerSec"
61 |
62 | Type "counter"
63 | InstancePrefix "server_broker_topics-AllTopicsMessagesIn"
64 | Table false
65 | Attribute "Count"
66 |
67 | {%- endcall %}
68 | {% call mbean("kafka_server-BrokerTopicMetrics_AllTopicsBytesOut", mbeans) -%}
69 | ObjectName "kafka.server:type=BrokerTopicMetrics,name=BytesOutPerSec"
70 |
71 | Type "counter"
72 | InstancePrefix "server_broker_topics-AllTopicsBytesOut"
73 | Table false
74 | Attribute "Count"
75 |
76 | {%- endcall %}
77 |
78 | {% call mbean("kafka_server-ReplicaManager_UnderReplicatedPartitions", mbeans) -%}
79 | ObjectName "kafka.server:type=ReplicaManager,name=UnderReplicatedPartitions"
80 |
81 | Type "gauge"
82 | InstancePrefix "server_replica_manager-UnderReplicatedPartitions"
83 | Table false
84 | Attribute "Value"
85 |
86 | {%- endcall %}
87 | {% call mbean("kafka_server-ReplicaManager_PartitionCount", mbeans) -%}
88 | ObjectName "kafka.server:type=ReplicaManager,name=PartitionCount"
89 |
90 | Type "gauge"
91 | InstancePrefix "server_replica_manager-PartitionCount"
92 | Table false
93 | Attribute "Value"
94 |
95 | {%- endcall %}
96 | {% call mbean("kafka_server-ReplicaManager_LeaderCount", mbeans) -%}
97 | ObjectName "kafka.server:type=ReplicaManager,name=LeaderCount"
98 |
99 | Type "gauge"
100 | InstancePrefix "server_replica_manager-LeaderCount"
101 | Table false
102 | Attribute "Value"
103 |
104 | {%- endcall %}
105 | {% call mbean("kafka_server-ReplicaManager_ISRShrinks", mbeans) -%}
106 | ObjectName "kafka.server:type=ReplicaManager,name=IsrShrinksPerSec"
107 |
108 | Type "counter"
109 | InstancePrefix "server_replica_manager-ISRShrinks"
110 | Table false
111 | Attribute "Count"
112 |
113 | {%- endcall %}
114 | {% call mbean("kafka_server-ReplicaManager_ISRExpands", mbeans) -%}
115 | ObjectName "kafka.server:type=ReplicaManager,name=IsrExpandsPerSec"
116 |
117 | Type "counter"
118 | InstancePrefix "server_replica_manager-ISRExpands"
119 | Table false
120 | Attribute "Count"
121 |
122 | {%- endcall %}
123 |
124 | {% call mbean("kafka_server-ReplicaFetcherManager_MaxLag", mbeans) -%}
125 | ObjectName "kafka.server:type=ReplicaFetcherManager,name=MaxLag,clientId=Replica"
126 |
127 | Type "gauge"
128 | InstancePrefix "server_replica_fetcher-MaxLag"
129 | Table false
130 | Attribute "Value"
131 |
132 | {%- endcall %}
133 | {% call mbean("kafka_server-ReplicaFetcherManager_MinFetchRate", mbeans) -%}
134 | ObjectName "kafka.server:type=ReplicaFetcherManager,name=MinFetchRate,clientId=Replica"
135 |
136 | Type "gauge"
137 | InstancePrefix "server_replica_fetcher-MinFetchRate"
138 | Table false
139 | Attribute "Value"
140 |
141 | {%- endcall %}
142 |
143 | {% call mbean("kafka_server-ProducerRequestPurgatory_NumDelayedRequests", mbeans) -%}
144 | ObjectName "kafka.server:type=ProducerRequestPurgatory,name=NumDelayedRequests"
145 |
146 | Type "gauge"
147 | InstancePrefix "server_purgatory-Producer-NumDelayedRequests"
148 | Table false
149 | Attribute "Value"
150 |
151 | {%- endcall %}
152 | {% call mbean("kafka_server-ProducerRequestPurgatory_PurgatorySize", mbeans) -%}
153 | ObjectName "kafka.server:type=ProducerRequestPurgatory,name=PurgatorySize"
154 |
155 | Type "gauge"
156 | InstancePrefix "server_purgatory-Producer-PurgatorySize"
157 | Table false
158 | Attribute "Value"
159 |
160 | {%- endcall %}
161 |
162 | {% call mbean("kafka_server-FetchRequestPurgatory_NumDelayedRequests", mbeans) -%}
163 | ObjectName "kafka.server:type=FetchRequestPurgatory,name=NumDelayedRequests"
164 |
165 | Type "gauge"
166 | InstancePrefix "server_purgatory-Fetch-NumDelayedRequests"
167 | Table false
168 | Attribute "Value"
169 |
170 | {%- endcall %}
171 | {% call mbean("kafka_server-FetchRequestPurgatory_PurgatorySize", mbeans) -%}
172 | ObjectName "kafka.server:type=FetchRequestPurgatory,name=PurgatorySize"
173 |
174 | Type "gauge"
175 | InstancePrefix "server_purgatory-Fetch-PurgatorySize"
176 | Table false
177 | Attribute "Value"
178 |
179 | {%- endcall %}
180 |
181 | {% call mbean("kafka_network-RequestMetrics_ProduceRequests", mbeans) -%}
182 | ObjectName "kafka.network:type=RequestMetrics,name=RequestsPerSec,request=Produce"
183 |
184 | Type "counter"
185 | InstancePrefix "network-ProduceRequests"
186 | Table false
187 | Attribute "Count"
188 |
189 | {%- endcall %}
190 | {% call mbean("kafka_network-RequestMetrics_FetchFollowerRequests", mbeans) -%}
191 | ObjectName "kafka.network:type=RequestMetrics,name=RequestsPerSec,request=FetchFollower"
192 |
193 | Type "counter"
194 | InstancePrefix "network-FetchFollowerRequests"
195 | Table false
196 | Attribute "Count"
197 |
198 | {%- endcall %}
199 | {% call mbean("kafka_network-RequestMetrics_FetchConsumerRequests", mbeans) -%}
200 | ObjectName "kafka.network:type=RequestMetrics,name=RequestsPerSec,request=FetchConsumer"
201 |
202 | Type "counter"
203 | InstancePrefix "network-FetchConsumerRequests"
204 | Table false
205 | Attribute "Count"
206 |
207 | {%- endcall %}
208 |
209 | {% call mbean("kafka_controller-KafkaController_ActiveControllerCount", mbeans) -%}
210 | ObjectName "kafka.controller:type=KafkaController,name=ActiveControllerCount"
211 |
212 | Type "gauge"
213 | InstancePrefix "controller_kafka-ActiveControllerCount"
214 | Table false
215 | Attribute "Value"
216 |
217 | {%- endcall %}
218 | {% call mbean("kafka_controller-KafkaController_OfflinePartitionsCount", mbeans) -%}
219 | ObjectName "kafka.controller:type=KafkaController,name=OfflinePartitionsCount"
220 |
221 | Type "gauge"
222 | InstancePrefix "controller_kafka-OfflinePartitionsCount"
223 | Table false
224 | Attribute "Value"
225 |
226 | {%- endcall %}
227 |
228 | {% call mbean("kafka_controller-ControllerStats_LeaderElections", mbeans) -%}
229 | ObjectName "kafka.controller:type=ControllerStats,name=LeaderElectionRateAndTimeMs"
230 |
231 | Type "counter"
232 | InstancePrefix "controller-LeaderElections"
233 | Table false
234 | Attribute "Count"
235 |
236 | {%- endcall %}
237 | {% call mbean("kafka_controller-ControllerStats_UncleanLeaderElections", mbeans) -%}
238 | ObjectName "kafka.controller:type=ControllerStats,name=UncleanLeaderElectionsPerSec"
239 |
240 | Type "counter"
241 | InstancePrefix "controller-UncleanLeaderElections"
242 | Table false
243 | Attribute "Count"
244 |
245 | {%- endcall %}
246 | {% endblock mbean_list %}
247 |
--------------------------------------------------------------------------------
/templates/memcached.conf.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2015 Google Inc. All Rights Reserved.
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | #}
16 | # This is the monitoring configuration for memcached.
17 | # Look for MEMCACHED_HOST and MEMCACHED_PORT to adjust your configuration file.
18 | LoadPlugin memcached
19 |
20 | # When using non-standard memcached configurations, replace the below with
21 | #Host "MEMCACHED_HOST"
22 | #Port "MEMCACHED_PORT"
23 | Host "localhost"
24 | Port "11211"
25 |
26 |
--------------------------------------------------------------------------------
/templates/mongodb.conf.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2015 Google Inc. All Rights Reserved.
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | #}
16 | # This is the monitoring configuration for MongoDB.
17 | # Look for STATS_USER, STATS_PASS, MONGODB_HOST and MONGODB_PORT to adjust your configuration file.
18 | LoadPlugin mongodb
19 |
20 | # When using non-standard MongoDB configurations, replace the below with
21 | #Host "MONGODB_HOST"
22 | #Port "MONGODB_PORT"
23 | Host "localhost"
24 | Port "27017"
25 |
26 | # If you restricted access to the database, you can set the username and
27 | # password here:
28 | #User "STATS_USER"
29 | #Password "STATS_PASS"
30 |
31 |
--------------------------------------------------------------------------------
/templates/mysql.conf.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2015 Google Inc. All Rights Reserved.
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | #}
16 | # This is the monitoring configuration for MySQL.
17 | # NOTE: This configuration needs to be hand-edited in order to work.
18 | # Look for DATABASE_NAME, STATS_USER, STATS_PASS, MYSQL_HOST and MYSQL_PORT to adjust your configuration file.
19 | LoadPlugin mysql
20 |
21 | # Each database needs a separate Database section.
22 | # Replace DATABASE_NAME in the Database section with the name of the database.
23 |
24 | # When using non-standard MySQL configurations, replace the below with
25 | #Host "MYSQL_HOST"
26 | #Port "MYSQL_PORT"
27 | Host "localhost"
28 | Port 3306
29 | User "STATS_USER"
30 | Password "STATS_PASS"
31 | MasterStats true
32 | SlaveStats true
33 | # Uncomment the following line if you want to collect InnoDB metrics.
34 | #InnodbStats true
35 |
36 |
37 |
--------------------------------------------------------------------------------
/templates/nginx.conf.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2015 Google Inc. All Rights Reserved.
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | #}
16 | # This is the monitoring configuration for Nginx.
17 | # Make sure to enable stub_status in your Nginx configuration.
18 | # Look for NGINX_HOST and NGINX_PORT to adjust your configuration file.
19 | LoadPlugin nginx
20 |
21 | # When using non-standard Nginx configurations, replace the below with
22 | #URL "http://NGINX_HOST:NGINX_PORT/nginx_status"
23 | URL "http://local-stackdriver-agent.stackdriver.com:80/nginx_status"
24 |
25 |
--------------------------------------------------------------------------------
/templates/postgresql.conf.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2015 Google Inc. All Rights Reserved.
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | #}
16 | # This is the monitoring configuration for PostgreSQL.
17 | # Make sure the statistics collector is enabled in your PostgreSQL configuration.
18 | # NOTE: This configuration needs to be hand-edited in order to work.
19 | # Look for DATABASE_NAME, STATS_USER, STATS_PASS, POSTGRESQL_HOST and POSTGRESQL_PORT to adjust your configuration file.
20 | LoadPlugin postgresql
21 |
22 | # Each database needs a separate Database section.
23 | # Replace DATABASE_NAME in the Database section with the name of the database.
24 |
25 | # Host and port are only used for TCP/IP connections.
26 | # Leaving them out indicates you wish to connect via domain sockets.
27 | # When using non-standard PostgreSQL configurations, replace the below with
28 | ##Host "POSTGRESQL_HOST"
29 | ##Port "POSTGRESQL_PORT"
30 | #Host "localhost"
31 | #Port "5432"
32 | User "STATS_USER"
33 | Password "STATS_PASS"
34 | Query backends
35 | Query transactions
36 | Query queries
37 | Query table_states
38 | Query disk_io
39 | Query disk_usage
40 |
41 |
42 |
--------------------------------------------------------------------------------
/templates/rabbitmq.conf.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2015 Google Inc. All Rights Reserved.
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | #}
16 | {% extends "curl_json-metrics-base.jinja" %}
17 | {% block target %}RabbitMQ{% endblock %}
18 | {% block service %}RabbitMQ{% endblock %}
19 | {% block host_port_prefix %}RABBITMQ{% endblock %}
20 | {% block port %}15672{% endblock %}
21 | {% block url_suffix %}api/queues/%2F/QUEUE_NAME{% endblock %}
22 | {% block plugin_instance %}rabbitmq-QUEUE_NAME{% endblock %}
23 | {% block plugin_instance_prefix %}rabbitmq-{% endblock %}
24 | {% block service_url_start %}
25 | # Each queue needs a separate URL section that points to
26 | # http://localhost:15672/api/queues/vhost/QUEUE_NAME .
27 | # Replace QUEUE_NAME in the URL section with the name of the queue.
28 | #
29 | # NOTE: The vhost and queue name must be URL-encoded.
30 | # Being that the default vhost is a forward slash "/",
31 | # we encode this as "%2F".
32 |
33 | {# FIXME: ugly whitespace control hack. #}
34 | {% if true -%}{{ super() }}{%- endif %}
35 | User "guest"
36 | Password "guest"
37 | {% endblock service_url_start %}
38 | {% block key_list %}
39 |
40 | Type "gauge"
41 |
42 |
43 | Type "gauge"
44 |
45 |
46 | Type "gauge"
47 |
48 |
49 | Type "gauge"
50 |
51 |
52 | Type "gauge"
53 |
54 |
55 | Type "gauge"
56 |
57 | {% endblock key_list %}
58 |
--------------------------------------------------------------------------------
/templates/redis.conf.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2015 Google Inc. All Rights Reserved.
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | #}
16 | # This is the monitoring configuration for Redis.
17 | # Make sure you've installed the hiredis/libhiredis packages.
18 | # Look for REDIS_PASS, REDIS_HOST and REDIS_PORT to adjust your configuration file.
19 | LoadPlugin redis
20 |
21 |
22 | # When using non-standard Redis configurations, replace the below with
23 | #Host "REDIS_HOST"
24 | #Port "REDIS_PORT"
25 | Host "localhost"
26 | Port "6379"
27 | Timeout 2000
28 |
29 | # If you password-protected your server, set the password here:
30 | #Password "REDIS_PASS"
31 |
32 |
33 |
--------------------------------------------------------------------------------
/templates/render_templates.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/python3
2 |
3 | # Copyright 2015 Google Inc. All Rights Reserved.
4 | #
5 | # Licensed under the Apache License, Version 2.0 (the "License");
6 | # you may not use this file except in compliance with the License.
7 | # You may obtain a copy of the License at
8 | #
9 | # http://www.apache.org/licenses/LICENSE-2.0
10 | #
11 | # Unless required by applicable law or agreed to in writing, software
12 | # distributed under the License is distributed on an "AS IS" BASIS,
13 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | # See the License for the specific language governing permissions and
15 | # limitations under the License.
16 |
17 | """
18 | Renders a template to a collectd config.
19 |
20 | Example usage:
21 | cd etc/collectd.d; \
22 | for f in *.conf; do \
23 | python3 ../../templates/render_templates.py $f.jinja > $f; \
24 | done
25 | """
26 |
27 | import jinja2
28 | import os.path
29 | import sys
30 |
31 | env = jinja2.Environment(
32 | loader=jinja2.FileSystemLoader(os.path.dirname(sys.argv[0]) or "."),
33 | trim_blocks=True,
34 | lstrip_blocks=True,
35 | extensions=['jinja2.ext.do'])
36 |
37 | print(env.get_template(sys.argv[1]).render())
38 |
--------------------------------------------------------------------------------
/templates/riak.conf.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2015 Google Inc. All Rights Reserved.
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | #}
16 | {% extends "curl_json-metrics-base.jinja" %}
17 | {% block target %}Riak{% endblock %}
18 | {% block service %}Riak{% endblock %}
19 | {% block host_port_prefix %}RIAK{% endblock %}
20 | {% block port %}8098{% endblock %}
21 | {% block url_suffix %}stats{% endblock %}
22 | {% block key_list %}
23 |
24 | Type "counter"
25 |
26 |
27 | Type "counter"
28 |
29 |
30 | Type "counter"
31 |
32 |
33 | Type "counter"
34 |
35 |
36 | Type "counter"
37 |
38 |
39 | Type "counter"
40 |
41 |
42 | Type "counter"
43 |
44 |
45 | Type "counter"
46 |
47 |
48 | Type "counter"
49 |
50 |
51 | Type "counter"
52 |
53 |
54 | Type "gauge"
55 |
56 |
57 | Type "gauge"
58 |
59 |
60 | Type "gauge"
61 |
62 |
63 | Type "gauge"
64 |
65 |
66 | Type "gauge"
67 |
68 |
69 | Type "gauge"
70 |
71 |
72 | Type "gauge"
73 |
74 |
75 | Type "gauge"
76 |
77 |
78 | Type "gauge"
79 |
80 |
81 | Type "gauge"
82 |
83 |
84 | Type "gauge"
85 |
86 |
87 | Type "gauge"
88 |
89 |
90 | Type "gauge"
91 |
92 |
93 | Type "gauge"
94 |
95 |
96 | Type "gauge"
97 |
98 |
99 | Type "gauge"
100 |
101 |
102 | Type "gauge"
103 |
104 |
105 | Type "gauge"
106 |
107 | {% endblock key_list %}
108 |
--------------------------------------------------------------------------------
/templates/statsd.conf.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2017 Google Inc. All Rights Reserved.
3 | Licensed under the Apache License, Version 2.0 (the "License");
4 | you may not use this file except in compliance with the License.
5 | You may obtain a copy of the License at
6 | http://www.apache.org/licenses/LICENSE-2.0
7 | Unless required by applicable law or agreed to in writing, software
8 | distributed under the License is distributed on an "AS IS" BASIS,
9 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | See the License for the specific language governing permissions and
11 | limitations under the License.
12 | #}
13 | # This is the monitoring configuration for StatsD.
14 | # Look for STATSD_HOST and STATSD_PORT to adjust your configuration file.
15 | LoadPlugin statsd
16 |
17 |
18 | # When using non-standard StatsD configurations, replace the below with
19 | #Host "STATSD_HOST"
20 | #Port "STATSD_PORT"
21 | Host "127.0.0.1"
22 | Port "8125"
23 | DeleteSets true
24 | TimerPercentile 50.0
25 | TimerPercentile 95.0
26 | TimerLower true
27 | TimerUpper true
28 | TimerSum true
29 | TimerCount true
30 |
31 |
32 | LoadPlugin match_regex
33 | LoadPlugin target_set
34 | LoadPlugin target_replace
35 |
36 | PreCacheChain "PreCache"
37 |
38 |
39 |
40 | Plugin "^statsd$"
41 |
42 |
43 | MetaData "stackdriver_metric_type" "custom.googleapis.com/statsd/%{type}"
44 | MetaData "label:metric" "%{type_instance}"
45 |
46 |
47 |
48 |
--------------------------------------------------------------------------------
/templates/tomcat-7.conf.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2015 Google Inc. All Rights Reserved.
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | #}
16 | {% extends "jmx-metrics-base.jinja" %}
17 | {% block target %}Apache Tomcat 7.x and earlier.
18 | # Make sure to enable JMX in your Tomcat configuration{% endblock %}
19 | {% block service %}Tomcat{% endblock %}
20 | {% block jmx_host_port_prefix %}TOMCAT{% endblock %}
21 | {% block jmx_port %}9012{% endblock %}
22 | {% block mbean_list %}
23 | {% call mbean("tomcat_connectors", mbeans) -%}
24 | ObjectName "Catalina:type=ThreadPool,name=*"
25 | InstanceFrom "name"
26 |
27 | Type "gauge"
28 | InstancePrefix "connectors-current_threads"
29 | Table false
30 | Attribute "currentThreadCount"
31 |
32 |
33 | Type "gauge"
34 | InstancePrefix "connectors-busy_threads"
35 | Table false
36 | Attribute "currentThreadsBusy"
37 |
38 | {%- endcall %}
39 |
40 | {% call mbean("tomcat_manager", mbeans) -%}
41 | ObjectName "Catalina:type=Manager,context=*,host=*"
42 | InstanceFrom "context"
43 |
44 | Type "gauge"
45 | InstancePrefix "manager-active_sessions"
46 | Table false
47 | Attribute "activeSessions"
48 |
49 | {%- endcall %}
50 |
51 | {% call mbean("tomcat_requestProcessor", mbeans) -%}
52 | ObjectName "Catalina:type=GlobalRequestProcessor,name=*"
53 | InstanceFrom "name"
54 |
55 | Type "counter"
56 | InstancePrefix "request_processor-bytes_received"
57 | Table false
58 | Attribute "bytesReceived"
59 |
60 |
61 | Type "counter"
62 | InstancePrefix "request_processor-bytes_sent"
63 | Table false
64 | Attribute "bytesSent"
65 |
66 |
67 | Type "counter"
68 | InstancePrefix "request_processor-processing_time"
69 | Table false
70 | Attribute "processingTime"
71 |
72 |
73 | Type "counter"
74 | InstancePrefix "request_processor-request_count"
75 | Table false
76 | Attribute "requestCount"
77 |
78 |
79 | Type "counter"
80 | InstancePrefix "request_processor-error_count"
81 | Table false
82 | Attribute "errorCount"
83 |
84 | {%- endcall %}
85 | {% endblock mbean_list %}
86 |
--------------------------------------------------------------------------------
/templates/varnish.conf.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2015 Google Inc. All Rights Reserved.
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | #}
16 | # This is the monitoring configuration for Varnish.
17 | LoadPlugin varnish
18 |
19 |
20 |
--------------------------------------------------------------------------------
/templates/zookeeper.conf.jinja:
--------------------------------------------------------------------------------
1 | {#
2 | Copyright 2015 Google Inc. All Rights Reserved.
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | #}
16 | # This is the monitoring configuration for ZooKeeper.
17 | # Look for ZOOKEEPER_HOST and ZOOKEEPER_PORT to adjust your configuration file.
18 | LoadPlugin zookeeper
19 |
20 | # When using non-standard ZooKeeper configurations, replace the below with
21 | #Host "ZOOKEEPER_HOST"
22 | #Port "ZOOKEEPER_PORT"
23 | Host "localhost" # default
24 | Port "2181" # default
25 |
26 |
--------------------------------------------------------------------------------