Maintenance machine should not have HeartBeat alert.

%3CLINGO-SUB%20id%3D%22lingo-sub-2697949%22%20slang%3D%22en-US%22%3EMaintenance%20machine%20should%20not%20have%20HeartBeat%20alert.%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2697949%22%20slang%3D%22en-US%22%3E%3CP%3EHi%20All%2C%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI%20am%20working%20on%20query%20where%20it%20should%20show%20the%20Heart%20Beat%20alert%20for%20availability%26nbsp%3B%20VM%20and%20skip%20the%20maintenance%20VM.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EIs%20it%20possible%20to%20have%20Tags%20of%20the%20VM%20updated%20with%20Maintenance%20should%20not%20have%20Alert.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CDIV%3E%3CP%3E%3CSPAN%3EHeartbeat%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%3CSPAN%3E%7C%20where%20Computer%20contains%20%22VM%22%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%3CSPAN%3E%7C%20summarize%20LastHeartbeat%3Dmax(TimeGenerated)%20by%20Computer%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%3CSPAN%3E%7C%20where%20LastHeartbeat%20%26lt%3B%20ago(1m)%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CSPAN%3EThankyou!%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%3CSPAN%3ERegards%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%3CSPAN%3EMenaka%3C%2FSPAN%3E%3C%2FP%3E%3C%2FDIV%3E%3C%2FLINGO-BODY%3E
New Contributor

Hi All,

 

I am working on query where it should show the Heart Beat alert for availability  VM and skip the maintenance VM.

 

Is it possible to have Tags of the VM updated with Maintenance should not have Alert.

 

Heartbeat

| where Computer contains "VM"

| summarize LastHeartbeat=max(TimeGenerated) by Computer

| where LastHeartbeat < ago(1m)

 

Thankyou!

Regards

Menaka

1 Reply
Hi,
TAGS are not in Log Analytics. But you could build a custom solution to set up computer groups based on tags, then use the computer groups to control alerts.

But you can also use Action Rules to suppress alerts during maintenance.
https://docs.microsoft.com/en-us/azure/azure-monitor/alerts/alerts-action-rules?tabs=portal

Talking about availability, there might be better ways for you to measure availability then heart beat. For example if the server is providing a web service you can measure avability based on the web service instead.