Forum Discussion
Arslan11
Apr 30, 2020Brass Contributor
Report on selected servers for a week on the memory usage
I would like a help with a Kusto query which I have almost completed but I am struggling in the last part. Kusto query Perf | where ObjectName == "Memory" and CounterName == "% Committed Bytes...
CliveWatson
May 01, 2020Former Employee
I see now, so change to this:
Perf
| where TimeGenerated > startofday(ago(5d))
| where ObjectName == "Memory" and CounterName == "% Committed Bytes In Use"
| where Computer startswith "retail"
| extend Used_Percent_Memory = 100- CounterValue
| summarize Used_Percent_Memory = max(CounterValue)by bin(TimeGenerated,1d) , Computer, ObjectName
| where Used_Percent_Memory < 90 and Used_Percent_Memory > 70
We take 5 days of data, then use a BIN in the summarise line to group the results per day
| where TimeGenerated > startofday(ago(5d))
and
| summarize Used_Percent_Memory = max(CounterValue)by bin(TimeGenerated,1d) , Computer, ObjectName
| TimeGenerated | Computer | ObjectName | Used_Percent_Memory |
|---|---|---|---|
| 2020-05-01T00:00:00Z | retail | Memory | 83.4487609863281 |
| 2020-04-28T00:00:00Z | retail | Memory | 83.6081695556641 |
| 2020-04-30T00:00:00Z | retail | Memory | 83.2831649780273 |
| 2020-04-26T00:00:00Z | retail | Memory | 83.5125961303711 |
| 2020-04-29T00:00:00Z | retail | Memory | 82.2031326293945 |
| 2020-04-27T00:00:00Z | retail | Memory | 81.8324279785156 |
e.g.
Arslan11
May 01, 2020Brass Contributor
CliveWatsonThanks, you are a star
, if I have any more Kusto querys, I will let you know, thanks again