raindrop
raindrop

Reputation: 523

KQL query for Time chart

I have used this query, but I cannot get the time chart to show the trend of the CPU. appears to be only showing the current cpu. my objective is to show the trend from each computer(host)

 Telemetry_system
 | where hostname_s contains "computer-A"
 | where TimeGenerated > ago(5m)
 | summarize
  by
 hostname,
 callBackUrl,
 cpu_d
 | summarize Aggregatedcpu= avg(cpu_d) by hostname, callBackUrl
 | render timechart

Upvotes: 1

Views: 759

Answers (1)

Yoni L.
Yoni L.

Reputation: 25955

If I understand your intention correctly, try this:

Telemetry_system
| where hostname_s contains "computer-A"
| where TimeGenerated > ago(5m)
| summarize Aggregatedcpu = avg(cpu_d) by strcat(hostname, "_", callBackUrl), bin(TimeGenerated, 1s)
| render timechart

Upvotes: 1

Related Questions