server-status 1.2.2 → 1.2.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/server-status/report.rb +1 -1
- data/lib/server-status/status_command.rb +1 -1
- data/lib/server-status/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 39ff1e3798fc96930dd6ddd6b0bb6630f85b833e218479678df81df1ed0d2ed7
|
4
|
+
data.tar.gz: 2bf400538ae8311ce1bc1cf632392f9ce58b317e2630c262e7c50a827edee799
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: '0576533758a95c012637d5f26b7a432698522f1751c04389ce5388999d30df58911cc9dc2d35dc452aa83802967017da572e464173b9c9f3a8ba174f66389a1f'
|
7
|
+
data.tar.gz: 875860c18b27dd2124d26e2877016af180958d63e3b155c8870cffa947e743d9bf13f8f3da546febe22643361a346cc8b3d7114841453fe20b60e0c860436a4f
|
data/lib/server-status/report.rb
CHANGED
@@ -102,7 +102,7 @@ module ServerStatus
|
|
102
102
|
meminfo = Hash[meminfo_values]
|
103
103
|
|
104
104
|
total_memory = meminfo['MemTotal']
|
105
|
-
available_memory = meminfo['MemFree'] + meminfo['Buffers'] + meminfo['Cached']
|
105
|
+
available_memory = meminfo['MemAvailable'] || (meminfo['MemFree'] + meminfo['Buffers'] + meminfo['Cached'])
|
106
106
|
|
107
107
|
format_percentage((total_memory - available_memory) / total_memory.to_f)
|
108
108
|
end
|
@@ -35,7 +35,7 @@ module ServerStatus
|
|
35
35
|
end
|
36
36
|
|
37
37
|
if @options.memory
|
38
|
-
parts << "cat /proc/meminfo | grep -P '^(MemTotal|MemFree|Cached|Buffers):'"
|
38
|
+
parts << "cat /proc/meminfo | grep -P '^(MemTotal|MemAvailable|MemFree|Cached|Buffers):'"
|
39
39
|
end
|
40
40
|
|
41
41
|
if @options.clock_drift
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: server-status
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.2.
|
4
|
+
version: 1.2.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- James Brooks
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-
|
11
|
+
date: 2018-09-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: commander
|
@@ -129,7 +129,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
129
129
|
version: '0'
|
130
130
|
requirements: []
|
131
131
|
rubyforge_project:
|
132
|
-
rubygems_version: 2.7.
|
132
|
+
rubygems_version: 2.7.7
|
133
133
|
signing_key:
|
134
134
|
specification_version: 4
|
135
135
|
summary: Command line tool for quickly fetching and displaying vital host metrics
|