AZ-104 Monitor and Maintain Azure Resources Practice Question
This AZ-104 practice question tests your understanding of monitor and maintain azure resources. This is a configuration task: choose the command set that satisfies every stated requirement. Small differences — like 'secret' vs 'password' or 'transport input ssh' vs 'all' — change whether the answer is correct. After answering, compare your reasoning against the explanation and wrong-answer breakdown below. Once you have made your selection, read the full explanation to reinforce the concept and understand why each distractor is designed to mislead on exam day.
Exhibit
Activity log export
-------------------
Category: Administrative
Destination: law-ops
KQL draft
---------
AzureActivity
| where OperationNameValue == "Microsoft.Resources/subscriptions/resourcegroups/delete"
| where Caller != "auto-remediate@contoso.com"
Requirement
-----------
Alert on resource group deletion events except when Caller is the automation account
Based on the exhibit, a subscription activity log is already being sent to Log Analytics. The operations team wants an alert that fires when any resource group is deleted, but it should ignore deletions performed by a known automation account. Which approach should the administrator use?
Activity log export
-------------------
Category: Administrative
Destination: law-ops
KQL draft
---------
AzureActivity
| where OperationNameValue == "Microsoft.Resources/subscriptions/resourcegroups/delete"
| where Caller != "auto-remediate@contoso.com"
Requirement
-----------
Alert on resource group deletion events except when Caller is the automation account
A
Create a metric alert on CPU percentage for the subscription.
Why wrong: CPU metrics do not describe administrative deletions. The requirement is based on activity logs, not platform performance.
B
Create a log alert using the AzureActivity table and filter out the automation caller.
The deletion event is captured in the AzureActivity table, and the alert should evaluate a KQL query that excludes the known automation account. That provides precise log-based alerting for administrative operations.
C
Enable a diagnostic setting on the resource group object.
Why wrong: Resource groups do not use diagnostic settings in the same way as platform resources. The event already exists in the activity log export.
D
Apply an Azure Policy deny assignment to all deletions.
Why wrong: Policy can restrict resource creation or configuration, but it does not analyze historical log entries or create alerts from them.
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
Create a log alert using the AzureActivity table and filter out the automation caller.
Option B is correct because the AzureActivity table in Log Analytics captures all control-plane operations, including resource group deletions. By creating a log alert query that filters on OperationNameValue='MICROSOFT.RESOURCES/SUBSCRIPTIONS/RESOURCEGROUPS/DELETE' and excludes Caller where it matches the automation account's service principal or object ID, the alert triggers only for non-automation deletions. This approach leverages the existing activity log stream to Log Analytics without additional configuration.
Key principle: Answer the scenario, not the keyword: identify the specific constraint before choosing the most familiar-sounding option.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
✗
Create a metric alert on CPU percentage for the subscription.
Why it's wrong here
CPU metrics do not describe administrative deletions. The requirement is based on activity logs, not platform performance.
✓
Create a log alert using the AzureActivity table and filter out the automation caller.
Why this is correct
The deletion event is captured in the AzureActivity table, and the alert should evaluate a KQL query that excludes the known automation account. That provides precise log-based alerting for administrative operations.
Related concept
Read the scenario before looking for a memorised answer.
✗
Enable a diagnostic setting on the resource group object.
Why it's wrong here
Resource groups do not use diagnostic settings in the same way as platform resources. The event already exists in the activity log export.
✗
Apply an Azure Policy deny assignment to all deletions.
Why it's wrong here
Policy can restrict resource creation or configuration, but it does not analyze historical log entries or create alerts from them.
Common exam traps
Common exam trap: answer the scenario, not the keyword
The trap here is that candidates may think a diagnostic setting on the resource group is needed to capture deletion events, but the activity log is already streaming at the subscription level and includes all resource group operations, making the additional setting redundant and incorrect.
Detailed technical explanation
How to think about this question
Under the hood, the AzureActivity table is populated by the Azure Resource Manager control plane, which logs every PUT, POST, or DELETE operation with a unique OperationNameValue and the Caller property (e.g., user UPN, service principal ID). A log alert query such as 'AzureActivity | where OperationNameValue == "MICROSOFT.RESOURCES/SUBSCRIPTIONS/RESOURCEGROUPS/DELETE" | where Caller != "<automation-sp-object-id>"' evaluates every new log entry against the condition. This is cost-effective because it reuses the existing diagnostic streaming and avoids creating separate alert rules per resource group.
KKey Concepts to Remember
Read the scenario before looking for a memorised answer.
Find the constraint that changes the correct option.
Eliminate answers that are true in general but not in this case.
TExam Day Tips
→Watch for words such as best, first, most likely and least administrative effort.
→Review why wrong options are wrong, not only why the correct option is correct.
Key takeaway
Answer the scenario, not the keyword: identify the specific constraint before choosing the most familiar-sounding option.
Real-world example
How this comes up in practice
A media company stores terabytes of video archives that are accessed once a year for audit purposes. Moving these objects to a cold storage tier (Azure Archive, S3 Glacier, or Google Nearline) costs a fraction of hot storage. Questions like this test whether you understand storage tiers, access frequency tradeoffs, and retrieval latency requirements.
Related glossary terms
Concepts from this question explained
These glossary pages explain the core terms tested in this AZ-104 question in full detail.
Monitor and Maintain Azure Resources — This question tests Monitor and Maintain Azure Resources — Read the scenario before looking for a memorised answer..
What is the correct answer to this question?
The correct answer is: Create a log alert using the AzureActivity table and filter out the automation caller. — Option B is correct because the AzureActivity table in Log Analytics captures all control-plane operations, including resource group deletions. By creating a log alert query that filters on OperationNameValue='MICROSOFT.RESOURCES/SUBSCRIPTIONS/RESOURCEGROUPS/DELETE' and excludes Caller where it matches the automation account's service principal or object ID, the alert triggers only for non-automation deletions. This approach leverages the existing activity log stream to Log Analytics without additional configuration.
What should I do if I get this AZ-104 question wrong?
Identify which exam domain this question belongs to, review the core concept, then practise similar questions from the same domain.
What is the key concept behind this question?
Read the scenario before looking for a memorised answer.
About these practice questions
Courseiva creates original exam-style practice questions with explanations and wrong-answer analysis. It does not publish real exam questions, exam dumps, or protected exam content. Learn why practice questions differ from exam dumps →
Share a tip, memory trick, or ask about the reasoning behind this question. Do not post real exam questions, leaked content, braindumps, or copyrighted exam material. Comments are moderated and may be removed without notice.
This AZ-104 practice question is part of Courseiva's free Microsoft certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the AZ-104 exam.
Question Discussion
Share a tip, memory trick, or ask about the reasoning behind this question. Do not post real exam questions, leaked content, braindumps, or copyrighted exam material. Comments are moderated and may be removed without notice.
Sign in to join the discussion.