The Azure troubleshooting workflow
-
Phase 0: Before you start
-
Phase 1: The foundation
-
Phase 2: Day-to-day operations
-
Phase 3: Enterprise architecture
-
Phase 4: Troubleshooting step by step
-
Phase 5: Final project and career
This lesson opens the Azure troubleshooting phase, and before any tool it teaches a habit. When something breaks, the first thing you ask is “what changed, and is it us or Azure?”, because most outages come from a change and Azure records nearly every change, as long as you know where to look.
Four places answer that question: Resource Health (is this resource healthy, and if not, why), the Activity log (who did what and when), Change Analysis in Resource Graph (which property changed, down to the value) and Service Health (whether Azure itself is having a problem).
In the lab you’ll stage a real incident on a web VM and then investigate it the way an on-call engineer would, using a small script you’ll keep for the rest of Phase 4. After that come the two traps that make people say “nothing changed” when something did.
| Time | You need | Cost | By the end you can |
|---|---|---|---|
| About 45 minutes | A free account, the CLI and PowerShell | Around 3 US cents: one small VM and a public IP for less than an hour | For any incident, find what changed, who changed it and whether Azure is to blame, in under five minutes |
What it is, in one line
Azure troubleshooting begins with one question, “what changed?”, and you answer it from Resource Health, the Activity log, Change Analysis and Service Health.
In Simple Words
The building’s visitor register
One morning a shop in a mall can’t open its shutter. Before calling a mechanic, the manager asks three things: is the whole mall closed today (Service Health), what does the shutter’s own panel say (Resource Health), and who came in last night according to the security register (Activity log)?
The register has an entry: “Electrician, 11:40 pm, worked on shutter wiring.” Now the manager knows where to start looking.
The register only shows who came into the building, though. If the shopkeeper’s own staff moved things around inside the shop, it has no idea, and that’s the same gap you have between Azure’s records and changes made inside your VM.
Engineer's View
The four places to look
- Resource Health: how Azure sees the health of one resource (Available, Unavailable, Degraded or Unknown), with a reason like “stopped by an authorized user” or a platform event.
- Activity log: control-plane operations (create, update, delete, start, stop, run command) with the time, caller and status, kept for 90 days. What happens inside a VM and data reads don’t show up here.
- Change Analysis: the resourcechanges table in Azure Resource Graph gives you before and after values at property level for changes in the last 14 days, and often who made them.
- Service Health: Azure incidents, planned maintenance and advisories for your subscriptions and regions. You can query these from Resource Graph as well.
- Time: Azure keeps times in UTC, so filters like
--start-timehave to be in UTC or your window ends up shifted by your time zone. - Inside the VM: for guest changes (a stopped service, a firewall rule, an edited config file) you need guest tools such as Run Command, journalctl, Event Viewer, or Change Tracking and Inventory.
How it works, step by step
This is the order an experienced engineer works through when the pager goes off:
- Scope: what’s broken, since when, and for whom? Note the time in UTC.
- Is it Azure? Look at Service Health for the region and service, and Resource Health for the resource.
- What changed? Read the Activity log for the resource group around that time, including the caller.
- What exactly changed? Pull up the property-level difference in Change Analysis.
- Fix and confirm: revert or correct the change, then test it the same way the user would.
If steps 2 to 4 turn up nothing, the change is most likely inside the guest or in a dependency (DNS, certificates, a partner API), so that’s where you look next.
Each lesson in Phase 4 follows this order and then goes deep into one type of failure.
Stage an incident and find what changed
Before you run any command, double-check it
Read every command twice before you press Enter. Check the target: the system or account, the IDs, the names and the sizes. These commands are for learning and were tested in our lab, not on your system. At work, run the read-only list commands first, follow your change process, make sure a backup exists, and ask a second person to check anything that changes or deletes data. You run them at your own risk.
1A small web VM to break
Create a VM running nginx with an NSG rule for HTTP (takes about 4 minutes):
az group create --name rg-saat-l59 --location centralindia --tags course=saatvedha-azure lesson=59 -o none
az vm create --resource-group rg-saat-l59 --name vm-web --image Canonical:ubuntu-24_04-lts:server:latest --size Standard_B1s --public-ip-sku Standard --nsg-rule NONE --admin-username azureuser --generate-ssh-keys --tags course=saatvedha-azure lesson=59 -o none
az network nsg rule create --resource-group rg-saat-l59 --nsg-name vm-webNSG --name allow-http --priority 100 --direction Inbound --access Allow --protocol Tcp --destination-port-ranges 80 -o none
az vm run-command invoke --resource-group rg-saat-l59 --name vm-web --command-id RunShellScript --scripts 'apt-get update -qq > /dev/null; DEBIAN_FRONTEND=noninteractive apt-get install -y -qq nginx > /dev/null; systemctl is-active nginx' --query "value[0].message" -o tsv
$ip = az vm show --resource-group rg-saat-l59 --name vm-web --show-details --query publicIps -o tsv
$vmId = az vm show --resource-group rg-saat-l59 --name vm-web --query id -o tsv
curl.exe -sI --max-time 5 http://$ip/ | Select-Object -First 1You should see:
HTTP/1.1 200 OK2Stage the incident
Make two changes, wait 5 minutes, and then imagine you’ve just been paged with “the website is down”:
az network nsg rule delete --resource-group rg-saat-l59 --nsg-name vm-webNSG --name allow-http
az vm deallocate --resource-group rg-saat-l59 --name vm-web3Is it Azure? Service Health and Resource Health
First check for active Azure incidents, then look at the VM’s own health:
az graph query -q "servicehealthresources | where type =~ 'Microsoft.ResourceHealth/events' | extend kind = tostring(properties.EventType), status = tostring(properties.Status), title = tostring(properties.Title) | where kind == 'ServiceIssue' and status == 'Active' | project title" --query "data[].title" -o tsv
az rest --method get --url "https://management.azure.com${vmId}/providers/Microsoft.ResourceHealth/availabilityStatuses/current?api-version=2020-05-01" --query "properties.{state:availabilityState, summary:summary, reason:reasonType}"You should see something like this (the first command prints nothing if Azure has no active incident):
{
"reason": "Customer Initiated",
"state": "Unavailable",
"summary": "This virtual machine is stopping and deallocating as requested by an authorized user or process."
}So Azure has no incident and the VM was stopped deliberately by someone with access. Two commands in, you already have most of the answer.
4Who did what: the Activity log
Save this as C:\azure-lab\Get-RecentChanges.ps1, since you’ll use it in every Phase 4 lesson:
param(
[Parameter(Mandatory)][string]$ResourceGroup,
[int]$Hours = 2
)
# SaatVedha Azure Lesson 59: who changed what in a resource group, newest first
$start = (Get-Date).AddHours(-$Hours).ToUniversalTime().ToString('yyyy-MM-ddTHH:mm:ssZ')
$events = az monitor activity-log list --resource-group $ResourceGroup --start-time $start --query "[?status.value=='Succeeded' && !contains(operationName.value, '/read')]" -o json | ConvertFrom-Json
if (-not $events) { "No changes in $ResourceGroup in the last $Hours hour(s)."; return }
$events |
Sort-Object { [datetime]$_.eventTimestamp } -Descending |
Select-Object @{ n = 'Time'; e = { ([datetime]$_.eventTimestamp).ToLocalTime().ToString('HH:mm:ss') } },
@{ n = 'Operation'; e = { $_.operationName.localizedValue } },
@{ n = 'Resource'; e = { ($_.resourceId -split '/')[-1] } },
@{ n = 'Who'; e = { $_.caller } } |
Format-Table -AutoSizeRun it:
C:\azure-lab\Get-RecentChanges.ps1 -ResourceGroup rg-saat-l59 -Hours 1You should see something like this (times are shown in local time and the caller will be your account):
Time Operation Resource Who
---- --------- -------- ---
10:42:40 Deallocate Virtual Machine vm-web priya@contoso.com
10:41:02 Delete Security Rule allow-http priya@contoso.com
10:36:15 Run Command on Virtual Machine vm-web priya@contoso.com
10:35:51 Create or Update Security Rule allow-http priya@contoso.com5Exactly what changed: Change Analysis
Query Resource Graph for property-level changes in the resource group:
az graph query -q "resourcechanges | extend ts = todatetime(properties.changeAttributes.timestamp), target = tostring(properties.targetResourceId), kind = tostring(properties.changeType), who = tostring(properties.changeAttributes.changedBy) | where target contains 'rg-saat-l59' | project ts, kind, who, target, changes = properties.changes | order by ts desc | take 5" --query "data[].{time:ts, kind:kind, who:who, resource:target}" -o tableYou should see something like this:
Time Kind Who Resource
---------------------------- ------ ----------------- -------------------------------------------------------------
2026-10-21T05:12:40.0000000Z Update priya@contoso.com /subscriptions/.../virtualMachines/vm-web
2026-10-21T05:11:02.0000000Z Delete priya@contoso.com /subscriptions/.../securityRules/allow-httpIf you add changes to the --query, you’ll see the before and after values of each property, like the VM’s power state. Then fix it:
az vm start --resource-group rg-saat-l59 --name vm-web
az network nsg rule create --resource-group rg-saat-l59 --nsg-name vm-webNSG --name allow-http --priority 100 --direction Inbound --access Allow --protocol Tcp --destination-port-ranges 80 -o none
$ip = az vm show --resource-group rg-saat-l59 --name vm-web --show-details --query publicIps -o tsv
curl.exe -sI --max-time 5 http://$ip/ | Select-Object -First 1The site replies HTTP/1.1 200 OK again.


✅ Checkpoint: You found both changes, who made them and when, ruled Azure out and brought the site back.
Break It, Then Fix It
Leave the VM running, since both breaks use it.
1Break it: “nothing changed” because of the time zone
A colleague in India checks the Activity log starting from 10:30, typing the time as it shows on their own clock:
az monitor activity-log list --resource-group rg-saat-l59 --start-time 2026-10-21T10:30:00 --query "[?status.value=='Succeeded'].operationName.localizedValue" -o tsvNothing comes back at all.
Azure took 10:30 as UTC, which is 16:00 in India and hasn’t happened yet. So the colleague decides “no changes” and goes off looking in the wrong place.
To fix it, convert the local time to UTC first (or use the script, which handles that for you):
$start = (Get-Date '2026-10-21 10:30').ToUniversalTime().ToString('yyyy-MM-ddTHH:mm:ssZ')
$start
az monitor activity-log list --resource-group rg-saat-l59 --start-time $start --query "[?status.value=='Succeeded'].operationName.localizedValue" -o tsvYou should see something like this:
2026-10-21T05:00:00Z
Create or Update Security Rule
Start Virtual Machine
...Put in your own date and time. In tickets, always write incident times in UTC and only convert to local when you’re talking to people.
2Break it: a change Azure didn’t record
Someone signs in to the VM and stops nginx. Simulate that, then investigate the usual way:
az vm run-command invoke --resource-group rg-saat-l59 --name vm-web --command-id RunShellScript --scripts 'systemctl stop nginx' -o none
curl.exe -sI --max-time 5 http://$ip/ | Select-Object -First 1
az rest --method get --url "https://management.azure.com${vmId}/providers/Microsoft.ResourceHealth/availabilityStatuses/current?api-version=2020-05-01" --query "properties.{state:availabilityState, summary:summary, reason:reasonType}"
C:\azure-lab\Get-RecentChanges.ps1 -ResourceGroup rg-saat-l59 -Hours 1You should see something like this:
curl: (7) Failed to connect to 20.x.x.x port 80 after 21 ms: Could not connect to server
{
"reason": null,
"state": "Available",
"summary": "There aren't any known Azure platform problems affecting this virtual machine."
}
Time Operation Resource Who
---- --------- -------- ---
10:58:12 Run Command on Virtual Machine vm-web priya@contoso.com
...The VM is healthy and no Azure resource has changed. The only clue is a Run Command entry, which tells you that someone ran something inside but not what. “Connection refused” helps too, because it means the packet reached the VM, so the NSG is fine and nothing is listening.
To fix it, look inside the guest, find what was stopped and start it again:
az vm run-command invoke --resource-group rg-saat-l59 --name vm-web --command-id RunShellScript --scripts 'journalctl -u nginx --since -30min --no-pager | tail -3; systemctl start nginx; systemctl is-active nginx' --query "value[0].message" -o tsv
curl.exe -sI --max-time 5 http://$ip/ | Select-Object -First 1The journal shows nginx being stopped, the service is active again and the site returns 200.

3Clean up
Delete the lab resource group, but hang on to Get-RecentChanges.ps1:
az group delete --name rg-saat-l59 --yes✅ Checkpoint: You dodged the UTC trap and followed a guest-level change from a Run Command entry to the service logs.
This happened at work
The certificate nobody changed
It was a Monday morning at an e-commerce company, and from exactly 05:30 IST some customers couldn’t complete orders. The on-call team opened the Activity log and found nothing in the last 24 hours, Service Health showed no incidents, and so they spent the next two hours staring at the network.
In the end the change wasn’t in Azure at all. A TLS certificate on the application gateway’s backend servers had expired at 00:00 UTC, which is 05:30 IST, so nobody had changed anything and time had done it for them. Some customers were riding on cached sessions, which is why it didn’t look like a full outage at first.
What they changed: the on-call checklist got a fourth question after “what changed?”, which is “what expired or ran out?” (certificates, secrets, credits, quotas). Key Vault certificates now raise expiry alerts 30 days ahead, and every incident timeline is written in UTC, which would have made that 00:00 pattern jump out straight away.
Common mistakes and troubleshooting
| Mistake | What you see | What to do |
|---|---|---|
| Local time passed as UTC | Empty Activity log | Convert to UTC using ToUniversalTime(). |
| Looking too soon | Recent change missing | Give the logs a few minutes to show up. |
| Assuming the Activity log sees inside VMs | “Nothing changed” | Check the guest logs, Run Command entries and Change Tracking. |
| Skipping Resource Health | Hours chasing a platform event | Check Service Health and Resource Health first. |
| Filtering only failed operations | Missing the successful change that broke things | Look at successful writes and deletes too. |
| Forgetting things that expire | No change found anywhere | Look at certificates, secrets, credits and quotas. |
Interview questions
Click a question to open it. Each one is phrased the way an interviewer would ask it, and underneath you’ll find why they ask it and one way you could answer in your own words.
Fresher level
1. What is the Activity log?
Why they ask this: The basic concept.
How you might answer: It’s the record of control-plane operations on Azure resources, so who did what and when, with the status and caller. It’s kept for 90 days.
2. Resource Health vs Service Health?
Why they ask this: Basic vocabulary.
How you might answer: Resource Health tells you about one of your own resources, while Service Health covers Azure-wide incidents, maintenance and advisories that hit your regions and services.
3. Where do you start when something breaks?
Why they ask this: They want a method.
How you might answer: I’d pin down the scope and when it started, check Service and Resource Health, and then look for what changed in the Activity log and Change Analysis.
2–5 years experience
4. The Activity log shows nothing, but the app broke. What next?
Why they ask this: A real troubleshooting path.
How you might answer: First I’d check the time window is in UTC and widen it. Then I’d look for guest changes, expired certificates or secrets, dependencies like DNS and partner services, and any Run Command entries.
5. How do you find exactly which property changed?
Why they ask this: A tool question.
How you might answer: Change Analysis, either through the resourcechanges table in Resource Graph or the Change Analysis view. It shows you the before and after values.
6. How do you keep Activity logs longer than 90 days?
Why they ask this: Operations practice.
How you might answer: Set up a diagnostic setting to send them to a Log Analytics workspace or a storage account, and then query them with KQL.
Senior level
7. How would you design incident response for 30 subscriptions?
Why they ask this: They want scale.
How you might answer: I’d send Activity logs from every subscription to one central workspace, set Service Health alerts per region and Resource Health alerts on critical resources, keep saved KQL for “what changed” and a runbook per symptom, and write all timelines in UTC.
8. How do you prevent change-caused outages?
Why they ask this: Prevention thinking.
How you might answer: Infrastructure as code with reviews and what-if, deployment rings, resource locks on the critical items, Azure Policy, and alerts on sensitive operations like NSG or route changes.
9. How do you separate a platform issue from your own?
Why they ask this: Senior judgement.
How you might answer: I’d line up Resource Health reasons, Service Health events and any regional pattern, test from more than one place, and compare against resources the change didn’t touch. A platform issue usually hits lots of resources at the same time.
Quick quiz
Q1. Which shows who stopped a VM?
- Service Health
- The Activity log
- Azure Advisor
- Cost Management
Show answer
B — Control-plane operations and callers are there.
Q2. A start time of 10:30 typed in IST returns nothing. Why?
- Logs deleted
- Azure reads it as UTC
- No permission
- Wrong region
Show answer
B — Times must be UTC.
Q3. Which shows the before and after value of a property?
- Resource Health
- Change Analysis (resourcechanges)
- Advisor
- Service Health
Show answer
B — It records property-level changes.
Q4. Resource Health says Available, nothing in the Activity log. Likely?
- Azure outage
- A change inside the guest
- Deleted VM
- Expired subscription
Show answer
B — Guest changes aren’t in Azure logs.
Q5. First question when paged?
- Which VM size?
- What changed, and is it Azure?
- How much does it cost?
- Who is on leave?
Show answer
B — Most incidents follow a change.
Quick recap
You now have a first five minutes you can repeat for any Azure incident, plus a script that speeds it up.
- Before you touch anything, ask what changed and whether it’s Azure.
- Service Health and Resource Health tell you whether the platform is involved.
- The Activity log gives you the operation and the caller.
- Change Analysis shows the property that changed.
- Work in UTC, and remember Azure logs don’t see guest changes.
Next lesson
Lesson 60: Azure VM won’t boot: Boot diagnostics and Serial Console → You rescue VMs that won’t boot, using boot diagnostics and the Serial Console for a broken /etc/fstab and other classic faults.
Further reading: Azure troubleshooting
Want to go deeper into Azure troubleshooting? See Microsoft’s Azure Monitor activity log and Get resource changes with Resource Graph. You can also see the full plan for this course on the Azure Cloud Administration course page.
