ksmd: add general_profit metric (#3778)
Expose /sys/kernel/mm/ksm/general_profit as node_ksmd_general_profit_bytes. This file (available since Linux 6.4, EL9) reports the net memory saved by KSM after subtracting the overhead of rmap_item tracking structures. Also gracefully skip any missing sysfs files instead of failing the entire collector, since general_profit and potentially other files may not exist on older kernels. Assisted-by: claude-4.6-opus Signed-off-by: Michal Skrivanek <michal.skrivanek@redhat.com>
M
michalskrivanek committed
1771767c6295668bf903c975981a623bd4c71f29
Parent: 128f5bf
Committed by GitHub <noreply@github.com>
on 8/5/2026, 6:08:44 AM