diff options
author | Ben Kochie <superq@gmail.com> | 2020-02-19 15:52:47 +0100 |
---|---|---|
committer | Ben Kochie <superq@gmail.com> | 2020-02-19 15:52:47 +0100 |
commit | 1a75bc7b5039502641f41382a97031ae459455c5 (patch) | |
tree | 9a187bbd7b5a2dc4277b06b07006f5219418d011 | |
parent | 982853369737e9c81361bf2210f1f9a8cfd1cf14 (diff) | |
download | prometheus_node_collector-1a75bc7b5039502641f41382a97031ae459455c5.tar.bz2 prometheus_node_collector-1a75bc7b5039502641f41382a97031ae459455c5.tar.xz prometheus_node_collector-1a75bc7b5039502641f41382a97031ae459455c5.zip |
Fix up Darwin swap metrics
* Add a changelog entry.
* Remove redundant swap free metric.
Signed-off-by: Ben Kochie <superq@gmail.com>
-rw-r--r-- | CHANGELOG.md | 1 | ||||
-rw-r--r-- | collector/meminfo_darwin.go | 1 |
2 files changed, 1 insertions, 1 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md index e04c9ad..188906a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md | |||
@@ -24,6 +24,7 @@ | |||
24 | * [FEATURE] Add new softnet collector #1576 | 24 | * [FEATURE] Add new softnet collector #1576 |
25 | * [FEATURE] Add RAPL collector #1523 | 25 | * [FEATURE] Add RAPL collector #1523 |
26 | * [FEATURE] Add Btrfs collector #1512 | 26 | * [FEATURE] Add Btrfs collector #1512 |
27 | * [FEATURE] Add swap usage on darwin #1508 | ||
27 | * [ENHANCEMENT] Collect InfiniBand port state and physical state #1357 | 28 | * [ENHANCEMENT] Collect InfiniBand port state and physical state #1357 |
28 | * [ENHANCEMENT] Include additional XFS runtime statistics. #1423 | 29 | * [ENHANCEMENT] Include additional XFS runtime statistics. #1423 |
29 | * [ENHANCEMENT] Report non-fatal collection errors in the exporter metric. #1439 | 30 | * [ENHANCEMENT] Report non-fatal collection errors in the exporter metric. #1439 |
diff --git a/collector/meminfo_darwin.go b/collector/meminfo_darwin.go index 87f3e5a..da443cd 100644 --- a/collector/meminfo_darwin.go +++ b/collector/meminfo_darwin.go | |||
@@ -69,7 +69,6 @@ func (c *meminfoCollector) getMemInfo() (map[string]float64, error) { | |||
69 | "swapped_out_bytes_total": ps * float64(vmstat.pageouts), | 69 | "swapped_out_bytes_total": ps * float64(vmstat.pageouts), |
70 | "total_bytes": float64(total), | 70 | "total_bytes": float64(total), |
71 | "swap_used_bytes": float64(swap.xsu_used), | 71 | "swap_used_bytes": float64(swap.xsu_used), |
72 | "swap_free_bytes": float64(swap.xsu_avail), | ||
73 | "swap_total_bytes": float64(swap.xsu_total), | 72 | "swap_total_bytes": float64(swap.xsu_total), |
74 | }, nil | 73 | }, nil |
75 | } | 74 | } |