logstash-output-zabbix 3.0.1 → 3.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +9 -0
- data/docs/index.asciidoc +160 -0
- data/logstash-output-zabbix.gemspec +2 -2
- metadata +4 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 798303567d6d3ed015cc6eeec555f9e0efaf2b2f
|
4
|
+
data.tar.gz: a3099cc0d8fa48a31976bdac8fa9e32acdfb7f0c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9188dc2c31a862a5f0f22b76e20f8cb22643a80b2f16a43c14c1dace1ed13066dd8635ffa8985dd4be7066f47f9bccabc860a4193991385ee5509b77afd0a951
|
7
|
+
data.tar.gz: 9fa32fc9d74f096e182c9ee6edb616201fa4a0eea56b3c7eac03edb79a0becd675598951e03c252cd4a547cc9766f9ba84ee79812f522d1c6f8868ca3a7518f4
|
data/Gemfile
CHANGED
@@ -1,2 +1,11 @@
|
|
1
1
|
source 'https://rubygems.org'
|
2
|
+
|
2
3
|
gemspec
|
4
|
+
|
5
|
+
logstash_path = ENV["LOGSTASH_PATH"] || "../../logstash"
|
6
|
+
use_logstash_source = ENV["LOGSTASH_SOURCE"] && ENV["LOGSTASH_SOURCE"].to_s == "1"
|
7
|
+
|
8
|
+
if Dir.exist?(logstash_path) && use_logstash_source
|
9
|
+
gem 'logstash-core', :path => "#{logstash_path}/logstash-core"
|
10
|
+
gem 'logstash-core-plugin-api', :path => "#{logstash_path}/logstash-core-plugin-api"
|
11
|
+
end
|
data/docs/index.asciidoc
ADDED
@@ -0,0 +1,160 @@
|
|
1
|
+
:plugin: zabbix
|
2
|
+
:type: output
|
3
|
+
|
4
|
+
///////////////////////////////////////////
|
5
|
+
START - GENERATED VARIABLES, DO NOT EDIT!
|
6
|
+
///////////////////////////////////////////
|
7
|
+
:version: %VERSION%
|
8
|
+
:release_date: %RELEASE_DATE%
|
9
|
+
:changelog_url: %CHANGELOG_URL%
|
10
|
+
:include_path: ../../../../logstash/docs/include
|
11
|
+
///////////////////////////////////////////
|
12
|
+
END - GENERATED VARIABLES, DO NOT EDIT!
|
13
|
+
///////////////////////////////////////////
|
14
|
+
|
15
|
+
[id="plugins-{type}-{plugin}"]
|
16
|
+
|
17
|
+
=== Zabbix output plugin
|
18
|
+
|
19
|
+
include::{include_path}/plugin_header.asciidoc[]
|
20
|
+
|
21
|
+
==== Description
|
22
|
+
|
23
|
+
The Zabbix output is used to send item data (key/value pairs) to a Zabbix
|
24
|
+
server. The event `@timestamp` will automatically be associated with the
|
25
|
+
Zabbix item data.
|
26
|
+
|
27
|
+
The Zabbix Sender protocol is described at
|
28
|
+
https://www.zabbix.org/wiki/Docs/protocols/zabbix_sender/2.0
|
29
|
+
Zabbix uses a kind of nested key/value store.
|
30
|
+
|
31
|
+
[source,txt]
|
32
|
+
host
|
33
|
+
├── item1
|
34
|
+
│ └── value1
|
35
|
+
├── item2
|
36
|
+
│ └── value2
|
37
|
+
├── ...
|
38
|
+
│ └── ...
|
39
|
+
├── item_n
|
40
|
+
│ └── value_n
|
41
|
+
|
42
|
+
Each "host" is an identifier, and each item is associated with that host.
|
43
|
+
Items are typed on the Zabbix side. You can send numbers as strings and
|
44
|
+
Zabbix will Do The Right Thing.
|
45
|
+
|
46
|
+
In the Zabbix UI, ensure that your hostname matches the value referenced by
|
47
|
+
`zabbix_host`. Create the item with the key as it appears in the field
|
48
|
+
referenced by `zabbix_key`. In the item configuration window, ensure that the
|
49
|
+
type dropdown is set to Zabbix Trapper. Also be sure to set the type of
|
50
|
+
information that Zabbix should expect for this item.
|
51
|
+
|
52
|
+
This plugin does not currently send in batches. While it is possible to do
|
53
|
+
so, this is not supported. Be careful not to flood your Zabbix server with
|
54
|
+
too many events per second.
|
55
|
+
|
56
|
+
NOTE: This plugin will log a warning if a necessary field is missing. It will
|
57
|
+
not attempt to resend if Zabbix is down, but will log an error message.
|
58
|
+
|
59
|
+
[id="plugins-{type}s-{plugin}-options"]
|
60
|
+
==== Zabbix Output Configuration Options
|
61
|
+
|
62
|
+
This plugin supports the following configuration options plus the <<plugins-{type}s-{plugin}-common-options>> described later.
|
63
|
+
|
64
|
+
[cols="<,<,<",options="header",]
|
65
|
+
|=======================================================================
|
66
|
+
|Setting |Input type|Required
|
67
|
+
| <<plugins-{type}s-{plugin}-multi_value>> |<<array,array>>|No
|
68
|
+
| <<plugins-{type}s-{plugin}-timeout>> |<<number,number>>|No
|
69
|
+
| <<plugins-{type}s-{plugin}-zabbix_host>> |<<string,string>>|Yes
|
70
|
+
| <<plugins-{type}s-{plugin}-zabbix_key>> |<<string,string>>|No
|
71
|
+
| <<plugins-{type}s-{plugin}-zabbix_server_host>> |<<string,string>>|No
|
72
|
+
| <<plugins-{type}s-{plugin}-zabbix_server_port>> |<<number,number>>|No
|
73
|
+
| <<plugins-{type}s-{plugin}-zabbix_value>> |<<string,string>>|No
|
74
|
+
|=======================================================================
|
75
|
+
|
76
|
+
Also see <<plugins-{type}s-{plugin}-common-options>> for a list of options supported by all
|
77
|
+
output plugins.
|
78
|
+
|
79
|
+
|
80
|
+
|
81
|
+
[id="plugins-{type}s-{plugin}-multi_value"]
|
82
|
+
===== `multi_value`
|
83
|
+
|
84
|
+
* Value type is <<array,array>>
|
85
|
+
* There is no default value for this setting.
|
86
|
+
|
87
|
+
Use the `multi_value` directive to send multiple key/value pairs.
|
88
|
+
This can be thought of as an array, like:
|
89
|
+
|
90
|
+
`[ zabbix_key1, zabbix_value1, zabbix_key2, zabbix_value2, ... zabbix_keyN, zabbix_valueN ]`
|
91
|
+
|
92
|
+
...where `zabbix_key1` is an instance of `zabbix_key`, and `zabbix_value1`
|
93
|
+
is an instance of `zabbix_value`. If the field referenced by any
|
94
|
+
`zabbix_key` or `zabbix_value` does not exist, that entry will be ignored.
|
95
|
+
|
96
|
+
This directive cannot be used in conjunction with the single-value directives
|
97
|
+
`zabbix_key` and `zabbix_value`.
|
98
|
+
|
99
|
+
[id="plugins-{type}s-{plugin}-timeout"]
|
100
|
+
===== `timeout`
|
101
|
+
|
102
|
+
* Value type is <<number,number>>
|
103
|
+
* Default value is `1`
|
104
|
+
|
105
|
+
The number of seconds to wait before giving up on a connection to the Zabbix
|
106
|
+
server. This number should be very small, otherwise delays in delivery of
|
107
|
+
other outputs could result.
|
108
|
+
|
109
|
+
[id="plugins-{type}s-{plugin}-zabbix_host"]
|
110
|
+
===== `zabbix_host`
|
111
|
+
|
112
|
+
* This is a required setting.
|
113
|
+
* Value type is <<string,string>>
|
114
|
+
* There is no default value for this setting.
|
115
|
+
|
116
|
+
The field name which holds the Zabbix host name. This can be a sub-field of
|
117
|
+
the @metadata field.
|
118
|
+
|
119
|
+
[id="plugins-{type}s-{plugin}-zabbix_key"]
|
120
|
+
===== `zabbix_key`
|
121
|
+
|
122
|
+
* Value type is <<string,string>>
|
123
|
+
* There is no default value for this setting.
|
124
|
+
|
125
|
+
A single field name which holds the value you intend to use as the Zabbix
|
126
|
+
item key. This can be a sub-field of the @metadata field.
|
127
|
+
This directive will be ignored if using `multi_value`
|
128
|
+
|
129
|
+
IMPORTANT: `zabbix_key` is required if not using `multi_value`.
|
130
|
+
|
131
|
+
|
132
|
+
[id="plugins-{type}s-{plugin}-zabbix_server_host"]
|
133
|
+
===== `zabbix_server_host`
|
134
|
+
|
135
|
+
* Value type is <<string,string>>
|
136
|
+
* Default value is `"localhost"`
|
137
|
+
|
138
|
+
The IP or resolvable hostname where the Zabbix server is running
|
139
|
+
|
140
|
+
[id="plugins-{type}s-{plugin}-zabbix_server_port"]
|
141
|
+
===== `zabbix_server_port`
|
142
|
+
|
143
|
+
* Value type is <<number,number>>
|
144
|
+
* Default value is `10051`
|
145
|
+
|
146
|
+
The port on which the Zabbix server is running
|
147
|
+
|
148
|
+
[id="plugins-{type}s-{plugin}-zabbix_value"]
|
149
|
+
===== `zabbix_value`
|
150
|
+
|
151
|
+
* Value type is <<string,string>>
|
152
|
+
* Default value is `"message"`
|
153
|
+
|
154
|
+
The field name which holds the value you want to send.
|
155
|
+
This directive will be ignored if using `multi_value`
|
156
|
+
|
157
|
+
|
158
|
+
|
159
|
+
[id="plugins-{type}s-{plugin}-common-options"]
|
160
|
+
include::{include_path}/{type}.asciidoc[]
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Gem::Specification.new do |s|
|
2
2
|
s.name = 'logstash-output-zabbix'
|
3
|
-
s.version = '3.0.
|
3
|
+
s.version = '3.0.2'
|
4
4
|
s.licenses = ["Apache License (2.0)"]
|
5
5
|
s.summary = "This output sends key/value pairs to a Zabbix server."
|
6
6
|
s.description = "This gem is a Logstash plugin required to be installed on top of the Logstash core pipeline using $LS_HOME/bin/logstash-plugin install gemname. This gem is not a stand-alone program"
|
@@ -10,7 +10,7 @@ Gem::Specification.new do |s|
|
|
10
10
|
s.require_paths = ["lib"]
|
11
11
|
|
12
12
|
# Files
|
13
|
-
s.files = Dir[
|
13
|
+
s.files = Dir["lib/**/*","spec/**/*","*.gemspec","*.md","CONTRIBUTORS","Gemfile","LICENSE","NOTICE.TXT", "vendor/jar-dependencies/**/*.jar", "vendor/jar-dependencies/**/*.rb", "VERSION", "docs/**/*"]
|
14
14
|
# Tests
|
15
15
|
s.test_files = s.files.grep(%r{^(test|spec|features)/})
|
16
16
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: logstash-output-zabbix
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.0.
|
4
|
+
version: 3.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Elastic
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2017-06-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
requirement: !ruby/object:Gem::Requirement
|
@@ -113,6 +113,7 @@ files:
|
|
113
113
|
- LICENSE
|
114
114
|
- NOTICE.TXT
|
115
115
|
- README.md
|
116
|
+
- docs/index.asciidoc
|
116
117
|
- lib/logstash/outputs/zabbix.rb
|
117
118
|
- logstash-output-zabbix.gemspec
|
118
119
|
- spec/helpers/zabbix_helper.rb
|
@@ -139,7 +140,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
139
140
|
version: '0'
|
140
141
|
requirements: []
|
141
142
|
rubyforge_project:
|
142
|
-
rubygems_version: 2.
|
143
|
+
rubygems_version: 2.4.8
|
143
144
|
signing_key:
|
144
145
|
specification_version: 4
|
145
146
|
summary: This output sends key/value pairs to a Zabbix server.
|