大网数据广告活动
服务器运维问答

Available Memory SNMP MIB for post-2016 kernel/CentOS 7+?

· 52CE 我爱测

It looks like the "MemAvailReal" actually only reports free memory, not available memory. Is there a more recent version of this MIB or a different standard MIB which measures available memory? I tried this from a CentOS 7.3 syst…

问题原文

原帖链接 · dolthesis · CC BY-SA 4.0

It looks like the "MemAvailReal" actually only reports free memory, not available memory. Is there a more recent version of this MIB or a different standard MIB which measures available memory?

I tried this from a CentOS 7.3 system with the following packages, but pretty sure this is the same behavior in the most recent point releases as well.

  • net-snmp-5.7.2-24.el7_2.1.x86_64
  • net-snmp-utils-5.7.2-24.el7_2.1.x86_64
  • net-snmp-libs-5.7.2-24.el7_2.1.x86_64
  • net-snmp-agent-libs-5.7.2-24.el7_2.1.x86_64

Example of behavior:

[root@hostname ~]# free -m
total used free shared buff/cache available
Mem: 7823 232 4183 156 3407 7097
Swap: 2047 12 2035

There is ~7.0 GB of available memory, however...

[root@hostname ~]# snmpwalk -v 2c -c communitystring 127.0.0.1 memAvailReal
UCD-SNMP-MIB::memAvailReal.0 = INTEGER: 4294500 kB

The "memAvailReal" MIB seems to report the free memory.

已采纳解答

原帖链接 · Jacob · CC BY-SA 4.0

As per net-snmp-libs version: 5.7.2-43 memAvailReal now returns the available memory instead of the free memory. This package should be available in RHEL/CentOS 7.7

More information: https://access.redhat.com/errata/RHBA-2019:2239 https://bugzilla.redhat.com/show_bug.cgi?id=1250060

Update: This change was reverted: https://bugzilla.redhat.com/show_bug.cgi?id=1779609 & https://sourceforge.net/p/net-snmp/code/ci/ef6db67f708f6590fb9d2797022ca1d957c89073

摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。

资料来源与适用范围

资料来源
Server Fault
适用范围
以原帖系统、软件版本与发布日期为准(2019-03-04)
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY-SA 4.0

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。