ASCDeviceEvents 表的查询

Azure Sphere 设备身份验证和证明失败

上周 Azure Sphere 设备身份验证和证明失败的列表,按时间排序。

ASCDeviceEvents
| where OperationName == "DeviceCertificateEvent" and
        Properties.EventType == "DeviceAttestationFailure" or Properties.EventType == "DeviceCertificateEvent" and
        ResultType == "Failure" // Filter by time by adding " | where TimeGenerated > ago(7d) " for last 7 days of data or using time picker in the UI
| project TimeGenerated, DeviceId, Properties, ResultDescription, Location
| sort by TimeGenerated desc
| limit 100

Azure Sphere 设备事件时间线

Azure Sphere 设备在上周生成的所有事件的排序时间线,用于监视和排查任何意外故障。

ASCDeviceEvents
| where OperationName == "DeviceCertificateEvent" or Properties.DeviceTelemetryEventCategory == "AppCrash" // Remove/Add filters to see all/specific events. Filter data by Device by adding " | where DeviceId == "Your Device ID" " 
| project TimeGenerated, OperationName, ResultType, ResultDescription, Properties, Location
| sort by TimeGenerated desc
| limit 100

Azure Sphere 设备检测信号事件时间图

Azure Sphere 设备上周启动的所有证书生成事件的时间图,用于持续监视设备运行状况并查看趋势。

let Interval = timespan(1d); // Interval for the Chart 
ASCDeviceEvents
| where OperationName == "DeviceCertificateEvent" and 
        Properties.EventType == "DeviceCertificatesGenerate" and 
        ResultType == "Success"
| summarize Device_Heartbeat_Events=count() by bin(TimeGenerated, Interval)
| render timechart

Azure Sphere 设备未更新到最新的 OS

上周尚未更新到最新 OS 版本的 Azure Sphere 设备列表。

ASCDeviceEvents
| where OperationName == "DeviceUpdateEvent" and  
        todouble(Properties.InstalledOSVersion) != todouble(Properties.TargetedOSVersion) // Filter by time by adding " | where TimeGenerated > ago(7d) " for last 7 days of data or using time picker in the UI
| summarize by DeviceId
| limit 100

Azure Sphere 设备遥测事件摘要

汇总 Azure Sphere 设备在过去一周内生成的每个事件类别的份额的饼图,用于监视设备的总体运行状况。

ASCDeviceEvents
| where OperationName == "DeviceTelemetryEvent" // Filter by time by adding " | where TimeGenerated > ago(7d) " for last 7 days of data or using time picker in the UI
| summarize count() by tostring(Properties.DeviceTelemetryEventCategory)
| render piechart