Hi @henriq_c ,
You search is a bit confusing. You're using a join to try and calculate percentused, when you can just use the first value to calculate it:
| eval percentused = round((100 - Value), 4)
So your search should look like:
index=xxxx eventtype="perfmon_windows" object="LogicalDisk" counter="% Free Space" host=cccc instance="C:"
| eval percentused = round((100 - Value), 4)
| timechart span=1m percentused by instance
If that's not what you're looking for, perhaps you could explain what you are trying to do more clearly.
Updated answer:
index=xxxx eventtype="perfmon_windows" object="LogicalDisk" (counter="% Free Space" host=cccc instance="C:") OR (counter="Free Megabytes" host=cccc instance="C:")
| eval percentfree = case( counter=="% Free Space", round(Value, 4) )
| eval gbfree = case( counter=="Free Megabytes", round(Value / 1000, 2) )
| stats latest(percentfree) as percentfree latest(gbfree) as gbfree by host instance
| eval gbused = round( ( gbfree / percentfree * 100 ), 2) - gbfree
| timechart span=1m gbused by instance
... View more