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
Get Updates on the Splunk Community!

Splunk APM: New Product Features + Community Office Hours Recap!

Howdy Splunk Community! Over the past few months, we’ve had a lot going on in the world of Splunk Application ...

Index This | Forward, I’m heavy; backward, I’m not. What am I?

April 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with another ...

A Guide To Cloud Migration Success

As enterprises’ rapid expansion to the cloud continues, IT leaders are continuously looking for ways to focus ...