Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create a metricset for swap and load #2072

Closed
Closed
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions CHANGELOG.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ https://github.com/elastic/beats/compare/v5.0.0-alpha4...master[Check the HEAD d
- The Elasticsearch template is now loaded by default. {pull}1993[1993]

*Metricbeat*
- Create a separate metricset for swap and load. {pull}2072[2072]
- Rename `system.memory.actual.free` with `system.memory.available` and remove `system.memory.actual.used`.
{pull}2072[2072]

*Packetbeat*
- Set `enabled` ` in `packetbeat.protocols.icmp` configuration to `true` by default. {pull}1988[1988]
Expand Down
112 changes: 60 additions & 52 deletions metricbeat/docs/fields.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -2402,111 +2402,81 @@ Total space (used plus free).


[float]
== memory Fields
== load Fields

`memory` contains local memory stats.
Load averages.



[float]
=== system.memory.total

type: long

Total memory.
=== system.load.1

type: half_float

[float]
=== system.memory.used.bytes

type: long

Used memory.
Load average for the last minute.


[float]
=== system.memory.free
=== system.load.5

type: long
type: half_float

Available memory.
Load average for the last 5 minutes.


[float]
=== system.memory.used.pct
=== system.load.15

type: half_float

The percentage of used memory.
Load average for the last 15 minutes.


[float]
== actual Fields
== memory Fields

Actual memory fields.
`memory` contains local memory stats.



[float]
=== system.memory.actual.used.bytes
=== system.memory.total

type: long

Actual used memory. This value is the "used" memory minus the memory used for disk caches and buffers. Available only on Unix.
Total memory.


[float]
=== system.memory.actual.free
=== system.memory.used.bytes

type: long

Actual available memory. This value is the "free" memory plus the memory used for disk caches and buffers. Available only on Unix.
Used memory.


[float]
=== system.memory.actual.used.pct
=== system.memory.used.pct

type: half_float

The percentage of actual used memory.


[float]
== swap Fields

This group contains statistics related to the swap memory usage on the system.


[float]
=== system.memory.swap.total

type: long

Total swap memory.
The percentage of used memory.


[float]
=== system.memory.swap.used.bytes
=== system.memory.free

type: long

Used swap memory.
Free memory. For a human readable value use Available.


[float]
=== system.memory.swap.free
=== system.memory.available

type: long

Available swap memory.


[float]
=== system.memory.swap.used.pct

type: half_float

The percentage of used swap memory.
Available memory is what it matters. It is calculated based on the OS. On Linux it is a sum of free memory and caches and buffers. On OSX consists of free and inactive memory.


[float]
Expand Down Expand Up @@ -2737,6 +2707,44 @@ type: long
The shared memory the process uses.


[float]
== swap Fields

This group contains statistics related to the swap memory usage on the system.


[float]
=== system.swap.total

type: long

Total swap memory.


[float]
=== system.swap.used.bytes

type: long

Used swap memory.


[float]
=== system.swap.free

type: long

Available swap memory.


[float]
=== system.swap.used.pct

type: half_float

The percentage of used swap memory.


[[exported-fields-zookeeper]]
== ZooKeeper Fields

Expand Down
16 changes: 15 additions & 1 deletion metricbeat/docs/modules/system.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,9 @@ metricbeat.modules:
# CPU stats
- cpu

# Load stats
- load

# Per CPU core stats
#- core

Expand All @@ -69,10 +72,13 @@ metricbeat.modules:

# File system summary stats
#- fsstat

# Memory stats
- memory

# Swap stats
- swap

# Network stats
- network

Expand Down Expand Up @@ -101,12 +107,16 @@ The following metricsets are available:

* <<metricbeat-metricset-system-fsstat,fsstat>>

* <<metricbeat-metricset-system-load,load>>

* <<metricbeat-metricset-system-memory,memory>>

* <<metricbeat-metricset-system-network,network>>

* <<metricbeat-metricset-system-process,process>>

* <<metricbeat-metricset-system-swap,swap>>

include::system/core.asciidoc[]

include::system/cpu.asciidoc[]
Expand All @@ -117,9 +127,13 @@ include::system/filesystem.asciidoc[]

include::system/fsstat.asciidoc[]

include::system/load.asciidoc[]

include::system/memory.asciidoc[]

include::system/network.asciidoc[]

include::system/process.asciidoc[]

include::system/swap.asciidoc[]

19 changes: 19 additions & 0 deletions metricbeat/docs/modules/system/load.asciidoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
////
This file is generated! See scripts/docs_collector.py
////

[[metricbeat-metricset-system-load]]
include::../../../module/system/load/_meta/docs.asciidoc[]


==== Fields

For a description of each field in the metricset, see the
<<exported-fields-system,exported fields>> section.

Here is an example document generated by this metricset:

[source,json]
----
include::../../../module/system/load/_meta/data.json[]
----
19 changes: 19 additions & 0 deletions metricbeat/docs/modules/system/swap.asciidoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
////
This file is generated! See scripts/docs_collector.py
////

[[metricbeat-metricset-system-swap]]
include::../../../module/system/swap/_meta/docs.asciidoc[]


==== Fields

For a description of each field in the metricset, see the
<<exported-fields-system,exported fields>> section.

Here is an example document generated by this metricset:

[source,json]
----
include::../../../module/system/swap/_meta/data.json[]
----
8 changes: 7 additions & 1 deletion metricbeat/etc/beat.full.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ metricbeat.modules:
# CPU stats
- cpu

# Load stats
- load

# Per CPU core stats
#- core

Expand All @@ -27,10 +30,13 @@ metricbeat.modules:

# File system summary stats
#- fsstat

# Memory stats
- memory

# Swap stats
- swap

# Network stats
- network

Expand Down
8 changes: 7 additions & 1 deletion metricbeat/etc/beat.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ metricbeat.modules:
# CPU stats
- cpu

# Load stats
- load

# Per CPU core stats
#- core

Expand All @@ -27,10 +30,13 @@ metricbeat.modules:

# File system summary stats
#- fsstat

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Trailing whitespace that can be removed.

# Memory stats
- memory

# Swap stats
- swap

# Network stats
- network

Expand Down
Loading