Available memory: Available memory=free+buffers+cached, i.e. 2021=235+394+1392
Memory used: Used memory=used-buffers-cached, 30217=32003-394-1392
When using Zabbix's own template OS Linux template to monitor the server, used memory is found to be too high.
This is because Zabbix uses the vm.memory.size[used] key to get the server's used memory (used memories). But vm.memory.size[used] Gets the value (shown below as used 32003) also contains buffers, cached this part. Buffers, cached This part is also available to the server. But Linux itself uses as much memory as possible, freeing buffers, cached space only when memory is low.
Vm.memory.size[available] Get the available memory is quite accurate, that is to say Zabbix get available is added buffers and cached, get used also add buffers and cached, So we're going to change the key value of the used memory so that the total RAM minus the available memory gets the exact memory used.
Used Memory key: (Last ("Vm.memory.size[total]")-last ("vm.memory.size[available]")
Percentage
Zabbix Modifying the template OS Linux template to make it more accurate to use RAM (used memory)