Skip to content

Commit

Permalink
Add filesystem stats to ES node_stats metricset (#5230)
Browse files Browse the repository at this point in the history
Closes #5209
  • Loading branch information
ruflin authored and kvch committed Oct 2, 2017
1 parent b98ba2d commit 3c075f7
Show file tree
Hide file tree
Showing 4 changed files with 144 additions and 66 deletions.
34 changes: 34 additions & 0 deletions metricbeat/docs/fields.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -2743,6 +2743,40 @@ type: long
[float]
== fs.summary fields
File system summary
[float]
=== `elasticsearch.node.stats.fs.summary.total.bytes`
type: long
format: bytes
[float]
=== `elasticsearch.node.stats.fs.summary.free.bytes`
type: long
format: bytes
[float]
=== `elasticsearch.node.stats.fs.summary.available.bytes`
type: long
format: bytes
[[exported-fields-golang]]
== Golang fields
Expand Down
145 changes: 79 additions & 66 deletions metricbeat/module/elasticsearch/node_stats/_meta/data.json
Original file line number Diff line number Diff line change
@@ -1,105 +1,118 @@
{
"@timestamp": "2016-05-23T08:05:34.853Z",
"beat": {
"hostname": "host.example.com",
"name": "host.example.com"
},
"elasticsearch": {
"cluster": {
"name": "elasticsearch"
},
"node": {
"name": "8zgOwJ24TMamDDH9amWINQ",
"stats": {
"indices": {
"docs": {
"count": 0,
"deleted": 0
},
"segments": {
"count": 0,
"memory": {
"bytes": 0
}
},
"store": {
"size": {
"bytes": 0
}
}
},
"jvm": {
"gc": {
"collectors": {
"old": {
"collection": {
"count": 1,
"ms": 80
}
},
"young": {
"collection": {
"count": 4,
"ms": 151
}
}
}
},
"mem": {
"pools": {
"old": {
"young": {
"used": {
"bytes": 125648960
},
"max": {
"bytes": 362414080
"bytes": 139591680
},
"peak": {
"bytes": 20109096
"bytes": 139591680
},
"peak_max": {
"bytes": 362414080
},
"used": {
"bytes": 20109096
"bytes": 139591680
}
},
"survivor": {
"max": {
"peak_max": {
"bytes": 17432576
},
"peak": {
"bytes": 17432576
"used": {
"bytes": 12279056
},
"peak_max": {
"max": {
"bytes": 17432576
},
"used": {
"bytes": 17432560
"peak": {
"bytes": 17432568
}
},
"young": {
"old": {
"used": {
"bytes": 176528696
},
"max": {
"bytes": 139591680
"bytes": 362414080
},
"peak": {
"bytes": 139591680
"bytes": 176528696
},
"peak_max": {
"bytes": 139591680
},
"used": {
"bytes": 98778408
"bytes": 362414080
}
}
}
},
"gc": {
"collectors": {
"old": {
"collection": {
"count": 3,
"ms": 693
}
},
"young": {
"collection": {
"ms": 10691,
"count": 209
}
}
}
}
},
"indices": {
"docs": {
"deleted": 42,
"count": 3093
},
"store": {
"size": {
"bytes": 2062479
}
},
"segments": {
"count": 17,
"memory": {
"bytes": 179535
}
}
},
"fs": {
"summary": {
"total": {
"bytes": 67371577344
},
"free": {
"bytes": 56422297600
},
"available": {
"bytes": 52969598976
}
}
}
}
},
"name": "2jwM3tNWSr6tFlL8fLKtSg"
},
"cluster": {
"name": "elasticsearch"
}
},
"metricset": {
"host": "127.0.0.1:9200",
"rtt": 115,
"namespace": "node.stats",
"module": "elasticsearch",
"name": "node_stats",
"namespace": "node.stats",
"rtt": 115
"host": "127.0.0.1:9200"
},
"beat": {
"hostname": "host.example.com",
"name": "host.example.com"
}
}
}
18 changes: 18 additions & 0 deletions metricbeat/module/elasticsearch/node_stats/_meta/fields.yml
Original file line number Diff line number Diff line change
Expand Up @@ -137,3 +137,21 @@
- name: ms
type: long
description: >
- name: fs.summary
type: group
description: >
File system summary
fields:
- name: total.bytes
type: long
format: bytes
description: >
- name: free.bytes
type: long
format: bytes
description: >
- name: available.bytes
type: long
format: bytes
description: >
13 changes: 13 additions & 0 deletions metricbeat/module/elasticsearch/node_stats/data.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,19 @@ var (
},
}),
}),
"fs": c.Dict("fs", s.Schema{
"summary": c.Dict("total", s.Schema{
"total": s.Object{
"bytes": c.Int("total_in_bytes"),
},
"free": s.Object{
"bytes": c.Int("free_in_bytes"),
},
"available": s.Object{
"bytes": c.Int("available_in_bytes"),
},
}),
}),
}

poolSchema = s.Schema{
Expand Down

0 comments on commit 3c075f7

Please sign in to comment.