Linux memory over SSH (ssh_memory)
Reads /proc/meminfo over SSH. Memory in use is the total minus MemAvailable, the kernel's own estimate of what can be used without swapping, so page cache is not counted as used. On kernels before 3.14, which have no MemAvailable, free memory plus buffers and cache stands in for it.
Channels
| Key | Name | Unit | Default limits |
|---|---|---|---|
used_pct | Memory used | % | warning above 90, error above 97 |
used_bytes | Memory used | B | none |
available_bytes | Memory available | B | none |
total_bytes | Memory total | B | none |
swap_used_pct | Swap used | % | warning above 50, error above 90. Unknown when there is no swap. |
swap_used_bytes | Swap used | B | none |
Parameters
| Parameter | Default | Meaning |
|---|---|---|
port | 22 | TCP port of the SSH server. |
Suggested interval: 60 seconds. Credential: SSH. Discovery adds it to a Linux host that accepts the SSH credential.
On the target
An SSH account that can run cat /proc/meminfo, which every account can. The command run is exactly cat /proc/meminfo. See Linux over SSH. The first connection records the host key; see ssh_disk.
Failures
| Message | Meaning |
|---|---|
/proc/meminfo has no MemTotal (is the target a Linux host?) (kind protocol) | Not Linux, or an unusual /proc. |
| SSH errors | As for ssh_disk. |