Azure Backup failures
-
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
“Azure Backup failed” alerts tend to arrive at night, and the job error is a code like UserErrorGuestAgentStatusUnavailable or UserErrorRequestDisallowedByPolicy. Each code points at one part of the backup chain, whether that’s the VM agent, the snapshot, the network, a policy or the restore target.
Back in Lesson 35 you set up VM backup and restored files and a whole VM. This time we look at what happens when it goes wrong: how to read a failed job, which layer each error belongs to, and how to fix it without waiting for the next night’s run.
In the lab you’ll protect a VM and run a backup, then break the VM agent and a restore and fix both using the job errors.
| Time | You need | Cost | By the end you can |
|---|---|---|---|
| About 90 minutes (mostly waiting for jobs) | A free account and the CLI | About 10 US cents: a small VM, its backup storage and a storage account for a couple of hours | Read Azure Backup job errors, fix VM agent and snapshot problems, and avoid common restore failures |
What it is, in one line
You decode an Azure Backup failure from the job’s error code, which points to the agent, the snapshot, a policy, the network or the restore target.
In Simple Words
The photographer at a school
Picture a school photographer who comes every evening to take a photo of each classroom. He needs the class monitor to open the door and say “ready”, and if the monitor has already gone home, he waits a while, gives up and writes “monitor not available” in his diary. Next morning the principal reads the diary, and she doesn’t blame the camera, she asks why the monitor left early. Here the photographer is Azure Backup, the monitor is the VM agent and the diary is the job error.
Engineer's View
The Azure VM backup chain
- VM agent: the Azure guest agent (walinuxagent on Linux, WindowsAzureGuestAgent on Windows) has to be running and able to talk to the platform, because Backup installs its extension through it.
- Backup extension and snapshot: the extension coordinates an application-consistent or file-system-consistent snapshot, and then the platform takes the disk snapshots (this is the snapshot phase).
- Restore points: the snapshots are kept as instant restore points in a restore point collection, inside a resource group with a name like AzureBackupRG_centralindia_1, and later copied to the vault (the transfer phase).
- Common job errors: UserErrorGuestAgentStatusUnavailable (agent not responding), UserErrorRequestDisallowedByPolicy (a policy blocks the snapshot or its resource group), UserErrorVmNotInDesirableState (VM in a Failed state), ExtensionFailedSnapshotLimitReachedError (too many snapshots on a disk).
- Restore targets: to restore disks you need a staging storage account in the same region as the vault, and to restore a VM you need a valid size, network and resource group.
- Where to look: az backup job list and job show, the Backup jobs blade in the vault, and Backup reports or diagnostics in Log Analytics.
How it works, step by step
Here’s what goes on during a scheduled VM backup:
- The vault starts a job and, through the VM agent, asks the VM’s backup extension to get ready.
- On Linux the extension freezes the file systems for a moment (or runs pre and post scripts for apps), and on Windows VSS makes the snapshot application-consistent.
- The platform snapshots every disk and stores the result as a restore point in the restore point collection.
- The snapshot phase of the job completes, and from now on instant restore is possible.
- The data is then transferred to the vault for long-term retention, and the job completes.
If step 1 can’t reach the agent, the job fails before any snapshot is taken. If step 3 can’t create the restore point collection or its resource group, you get a policy or permission error instead.
| Error code | Layer | First check |
|---|---|---|
| UserErrorGuestAgentStatusUnavailable | VM agent | Agent status in the instance view; restart the agent |
| UserErrorRequestDisallowedByPolicy | Azure Policy | Policies on the VM and the restore point resource group |
| UserErrorVmNotInDesirableState | VM state | VM provisioning state; fix Failed state |
| ExtensionFailedSnapshotLimitReachedError | Snapshots | Other tools snapshotting the same disks (Lesson 68) |
| Restore: vault and storage account in different regions | Restore target | Use a staging account in the vault’s region |
Protect a VM and read its backup jobs
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 VM and a vault
Create a small VM and a Recovery Services vault. Soft delete is turned off on this lab vault only, so that clean-up happens straight away:
az group create --name rg-saat-l69 --location centralindia --tags course=saatvedha-azure lesson=69 -o none
az vm create --resource-group rg-saat-l69 --name vm-bk --image Canonical:ubuntu-24_04-lts:server:latest --size Standard_B1s --public-ip-address '""' --nsg-rule NONE --admin-username azureuser --generate-ssh-keys --tags course=saatvedha-azure lesson=69 -o none
az backup vault create --resource-group rg-saat-l69 --name rsv-l69 --location centralindia -o none
az backup vault backup-properties set --resource-group rg-saat-l69 --name rsv-l69 --soft-delete-feature-state Disable -o noneIn production, leave soft delete on (Lesson 35 explains why). Here we turn it off only to make clean-up quicker.
2Protect the VM and run a backup
Turn on protection with the default policy and start a backup now:
az backup protection enable-for-vm --resource-group rg-saat-l69 --vault-name rsv-l69 --vm vm-bk --policy-name DefaultPolicy -o none
$until = (Get-Date).AddDays(30).ToString('dd-MM-yyyy')
az backup protection backup-now --resource-group rg-saat-l69 --vault-name rsv-l69 --container-name vm-bk --item-name vm-bk --backup-management-type AzureIaasVM --retain-until $until -o none
az backup job list --resource-group rg-saat-l69 --vault-name rsv-l69 --query "[0:3].{operation:properties.operation, status:properties.status, start:properties.startTime, error:properties.errorDetails[0].errorCode}" -o tableAfter 15 to 30 minutes you should see something like this:
Operation Status Start Error
---------------- ---------- -------------------------------- -------
Backup Completed 2026-10-21T08:12:40.123456+00:00
ConfigureBackup Completed 2026-10-21T08:10:02.654321+00:00Completed means that at least the snapshot phase has finished and a recovery point exists.


3Check the recovery point
List recovery points for the VM:
az backup recoverypoint list --resource-group rg-saat-l69 --vault-name rsv-l69 --container-name vm-bk --item-name vm-bk --backup-management-type AzureIaasVM --query "[].{name:name, time:properties.recoveryPointTime, type:properties.recoveryPointType}" -o tableYou should see one recovery point, of a type such as AppConsistent or FileSystemConsistent.
✅ Checkpoint: vm-bk is protected, one backup job completed, and a recovery point is listed.
Break It, Then Fix It
Keep the vault and the VM, you’ll use them for both breaks.
1Break it: the VM agent stops
Say a hardening script stops the Azure guest agent. Stop it with a 20-second delay so this Run Command can still report back:
az vm run-command invoke --resource-group rg-saat-l69 --name vm-bk --command-id RunShellScript --scripts 'systemd-run --on-active=20 systemctl stop walinuxagent; echo scheduled' --query "value[0].message" -o tsv
Start-Sleep -Seconds 120
az vm get-instance-view --resource-group rg-saat-l69 --name vm-bk --query "instanceView.vmAgent.statuses[0].displayStatus" -o tsv
$until = (Get-Date).AddDays(30).ToString('dd-MM-yyyy')
az backup protection backup-now --resource-group rg-saat-l69 --vault-name rsv-l69 --container-name vm-bk --item-name vm-bk --backup-management-type AzureIaasVM --retain-until $until -o noneThe agent now shows Not Ready. Wait for the job to finish (it can take 30 minutes or more before it gives up), then have a look:
az backup job list --resource-group rg-saat-l69 --vault-name rsv-l69 --query "[0:3].{operation:properties.operation, status:properties.status, start:properties.startTime, error:properties.errorDetails[0].errorCode}" -o tableYou should see something like this:
Operation Status Start Error
----------- --------- -------------------------------- -------------------------------------
Backup Failed 2026-10-21T08:58:11.123456+00:00 UserErrorGuestAgentStatusUnavailableThe vault couldn’t reach the agent, so it never took a snapshot. If you read the full message with az backup job show, it says the VM agent is unable to communicate with Azure Backup, and there’s nothing wrong with the vault or the policy.
For any failed job, you can read the full error and the recommended action by taking its name from the list and showing its error details:
$job = az backup job list --resource-group rg-saat-l69 --vault-name rsv-l69 --status Failed --query "[0].name" -o tsv
az backup job show --resource-group rg-saat-l69 --vault-name rsv-l69 --name $job --query "properties.errorDetails[0].{code:errorCode, message:errorString, fix:recommendations[0]}" -o jsonTo fix it, start the agent again. Run Command itself needs the agent, so restart the VM instead (or start the service from the Serial Console, Lesson 60), and then back up again:
az vm restart --resource-group rg-saat-l69 --name vm-bk -o none
az vm get-instance-view --resource-group rg-saat-l69 --name vm-bk --query "instanceView.vmAgent.statuses[0].displayStatus" -o tsv
$until = (Get-Date).AddDays(30).ToString('dd-MM-yyyy')
az backup protection backup-now --resource-group rg-saat-l69 --vault-name rsv-l69 --container-name vm-bk --item-name vm-bk --backup-management-type AzureIaasVM --retain-until $until -o noneThe agent is back to Ready and the new backup job completes.
2Break it: a restore to the wrong region
Now someone restores the disks using a storage account they already had in South India:
$sfx = Get-Random -Minimum 10000 -Maximum 99999
az storage account create --resource-group rg-saat-l69 --name stl69s$sfx --location southindia --sku Standard_LRS -o none
$rp = az backup recoverypoint list --resource-group rg-saat-l69 --vault-name rsv-l69 --container-name vm-bk --item-name vm-bk --backup-management-type AzureIaasVM --query "[0].name" -o tsv
az backup restore restore-disks --resource-group rg-saat-l69 --vault-name rsv-l69 --container-name vm-bk --item-name vm-bk --rp-name $rp --storage-account stl69s$sfx --target-resource-group rg-saat-l69The restore gets rejected with an error saying the vault and the storage account are in different regions, roughly like this:
The Recovery Services vault and target storage account are in two different regions.The staging account holds the VM configuration and, for some restores, the disk data while the restore is running, so it has to be in the vault’s region.
To fix it, create a staging account in Central India, restore again and check the job:
az storage account create --resource-group rg-saat-l69 --name stl69c$sfx --location centralindia --sku Standard_LRS -o none
az backup restore restore-disks --resource-group rg-saat-l69 --vault-name rsv-l69 --container-name vm-bk --item-name vm-bk --rp-name $rp --storage-account stl69c$sfx --target-resource-group rg-saat-l69 -o none
az backup job list --resource-group rg-saat-l69 --vault-name rsv-l69 --query "[0:3].{operation:properties.operation, status:properties.status, start:properties.startTime, error:properties.errorDetails[0].errorCode}" -o tableAfter a while you should see the Restore job as Completed, with new managed disks in rg-saat-l69.

3Clean up
Stop protection and delete the backup data, and then delete the group (soft delete is off on this vault):
az backup protection disable --resource-group rg-saat-l69 --vault-name rsv-l69 --container-name vm-bk --item-name vm-bk --backup-management-type AzureIaasVM --delete-backup-data true --yes -o none
az group delete --name rg-saat-l69 --yes
az group list --query "[?starts_with(name, 'AzureBackupRG')].name" -o tsvThe last command lists Azure Backup’s restore point groups. If other VMs are protected, leave them alone, because they hold instant restore snapshots.
✅ Checkpoint: You fixed a backup that failed because of the VM agent and a restore that failed because of the staging account region.
This happened at work
The policy that broke every backup on the first of the month
A university rolled out an Azure Policy that denied any resource group without a cost-centre tag. They’d tested it on new projects and it worked well. Then on the 1st of the month, every VM backup in a new region failed with UserErrorRequestDisallowedByPolicy, and nobody saw it until the morning report.
It took a bit of digging. The first time Azure Backup protected VMs in that region, it needed to create its restore point resource group, AzureBackupRG_southindia_1. That group had no cost-centre tag, the policy denied it, and so every job died at the snapshot step.
What they changed: for system-created groups the tag policy now uses Modify on resource groups instead of Deny. Azure Backup’s restore point groups are created in advance with the right tags in each region before go-live, and backup failures now alert the on-call engineer within an hour rather than showing up in the morning report.
Common mistakes and troubleshooting
| Mistake | What you see | What to do |
|---|---|---|
| VM agent stopped or outdated | UserErrorGuestAgentStatusUnavailable | Restart or update the agent; check its outbound access. |
| Tag Deny policy on resource groups | UserErrorRequestDisallowedByPolicy | Use Modify or pre-create the backup resource group. |
| Staging account in another region | Restore rejected | Use a storage account in the vault’s region. |
| VM in a Failed state | UserErrorVmNotInDesirableState | Fix the VM state, then retry the backup. |
| Another tool snapshotting the same disks | Snapshot limit errors | One backup product per disk (Lesson 68). |
| Waiting for the morning report | Failures unnoticed for hours | Alert on failed backup jobs. |
Interview questions
Click a question to open it. Each one is phrased the way an interviewer would ask it, and under it you’ll find why they ask and one way you could answer in your own words.
Fresher level
1. What does the VM agent have to do with backup?
Why they ask this: The basic concept.
How you might answer: Azure Backup installs and runs its extension through the VM agent, so if the agent is down, backup can’t coordinate the snapshot.
2. What is a recovery point?
Why they ask this: Basic vocabulary.
How you might answer: It’s a point-in-time copy of the VM’s disks from one backup, and you use it to restore files, disks or the whole VM.
3. Where do you see why a backup failed?
Why they ask this: Tool knowledge.
How you might answer: In the vault’s backup jobs, or with az backup job list and job show, which give you the error code and the message.
2–5 years experience
4. Backups fail with UserErrorGuestAgentStatusUnavailable. What do you check?
Why they ask this: A real troubleshooting path.
How you might answer: I’d check the agent status in the instance view, whether the agent service is running, its version, outbound access to Azure endpoints, proxy settings and disk space. Then I’d restart the agent or the VM and run the backup again.
5. Why might a policy break backups?
Why they ask this: A subtle cause.
How you might answer: Backup creates restore point collections and sometimes a resource group too. A Deny policy on tags, locations or resource types can block that, and you get UserErrorRequestDisallowedByPolicy.
6. Restore disks fails. What do you check?
Why they ask this: Restore skills.
How you might answer: The staging account’s region and type, permissions on the target group, quotas, whether the VM size is available, and whether the recovery point still exists.
Senior level
7. How would you monitor backup health for 500 VMs?
Why they ask this: They want operations design.
How you might answer: I’d use Backup center and Backup reports, send diagnostics to Log Analytics, alert on failed jobs and missed backups, and review protected versus unprotected VMs every week.
8. How do you make policies and backup work together?
Why they ask this: Governance thinking.
How you might answer: We tested every policy against backup operations, used Modify for tags on system groups, created the backup resource groups in advance with a naming convention, and exempted them where we had to.
9. How often should you test restores?
Why they ask this: Resilience.
How you might answer: Regularly, and for every critical workload. I’d restore files monthly and full VMs quarterly, measure how long the restore takes, and record the results.
Quick quiz
Q1. UserErrorGuestAgentStatusUnavailable points to?
- The vault
- The VM agent
- The storage account
- DNS
Show answer
B — The agent didn’t respond.
Q2. How do you fix an agent problem when Run Command doesn’t work?
- Delete the vault
- Restart the VM or use the Serial Console
- Change the policy
- Resize the disk
Show answer
B — Run Command needs the agent.
Q3. Staging storage account for restore must be?
- Premium
- In the same region as the vault
- Public
- In another subscription
Show answer
B — Different regions are rejected.
Q4. A tag Deny policy causes which backup error?
- UserErrorVmNotInDesirableState
- UserErrorRequestDisallowedByPolicy
- ResourceNotFound
- Conflict
Show answer
B — The policy blocks backup resources.
Q5. Where does Azure Backup keep instant restore snapshots?
- In the VM
- In a restore point collection resource group
- In Key Vault
- In the NSG
Show answer
B — For example AzureBackupRG_centralindia_1.
Quick recap
By now you can take a failed backup job from its error code to a fix, and you know the restore mistakes that waste time in a real incident.
- Every failed job has an error code; start there.
- Agent problems stop backup before any snapshot.
- Policies can block backup’s own resources.
- Restore staging accounts must match the vault’s region.
- Alert on failures and test restores regularly.
Next lesson
Lesson 70: Azure Monitor Agent not sending data → Next you’ll find out why Azure Monitor Agent stops sending data, looking at the heartbeat, data collection rules and the network.
Further reading: Azure Backup failed
Want to go deeper into Azure Backup failed? See Microsoft’s Troubleshoot backup errors with Azure virtual machines and Troubleshoot agent and extension issues. You can also see the full plan for this course on the Azure Cloud Administration course page.
