All Apps and Add-ons

perfmon Accurate Memory Utilization Percentage

mspiewak
Explorer

We are starting to use the Splunk App for Infrastructure to ingest Windows metrics. One of the KPIs we want to measure is percentage of memory used on servers. It appears that is not an available perfmon counter. The only way it seems you would be able to calculate percentage of actual memory used is to get the total memory of the server somehow and then do a calculation like:
(totalMem - Available_MBytes)/totalMem * 100

How are others capturing total memory and calculating memory usage in a percentage?

dagarwal_splunk
Splunk Employee
Splunk Employee

I don't see any other easy way to get this metrics from perfmon..
Your approach looks fine to me to get the %Memory Usage..

0 Karma

mspiewak
Explorer

Thanks, ended up going with something like this:

| mstats avg(_value) as "mem_avail" WHERE "host"="server123" AND metric_name="Memory.Available_MBytes" AND "index"="em_metrics" span=1m by host
| join host [search index=windows host=server123 source=os
| eval totalMemMB = TotalPhysicalMemoryKB/1024]
| eval usedPct = (totalMemMB - mem_avail)/totalMemMB * 100
| timechart avg(usedPct) as "avgUsedPct" span=1m
0 Karma
.conf21 Now Fully Virtual!
Register for FREE Today!

We've made .conf21 totally virtual and totally FREE! Our completely online experience will run from 10/19 through 10/20 with some additional events, too!