Implement backup and recovery
📘Microsoft Certified: Azure Administrator Associate (AZ-104)
1. What is a Backup Policy in Azure?
A backup policy in Azure is a set of rules that tells Azure Backup:
- When to take backups (schedule)
- How long to keep backups (retention)
In other words, a backup policy defines how your data is protected over time. Without a policy, you would have to manually create backups, which is not practical for enterprise IT environments.
Example in IT:
If you have a virtual machine (VM) running a database, you want Azure to automatically back it up every day and keep these backups for 30 days. The backup policy defines exactly that schedule and retention period.
2. Key Components of a Backup Policy
When creating a backup policy in Azure, you need to understand these components:
a. Backup Schedule
The schedule determines when backups happen.
- Daily Backup: Back up once every day at a specified time.
- Weekly Backup: Back up on specific days of the week.
- Monthly Backup: Back up on specific days of the month.
Example:
You have a VM with critical applications. You may schedule:
- Daily backups at 10 PM
- Weekly full backups every Sunday at 11 PM
Tip: Daily backups are usually incremental (only changes are saved), and weekly or monthly backups are often full backups (everything is saved).
b. Retention Policy
The retention policy determines how long backups are kept before they are automatically deleted.
- Short-term retention: Keeps daily or weekly backups for a few days or weeks.
- Long-term retention: Keeps monthly or yearly backups for months or years.
Example:
- Daily backups: Keep for 30 days
- Weekly backups: Keep for 12 weeks
- Monthly backups: Keep for 12 months
This helps in situations where you need to restore your data from weeks or months ago.
c. Backup Type
Azure supports different types of backups depending on the resource:
- Azure Virtual Machines (VMs):
- Full VM backup, including OS and data disks
- Azure SQL Databases:
- Point-in-time backup for recovery
- Azure File Shares:
- File-level backup
- Azure Blobs:
- Object-level backup
For the exam, you must know that VMs, SQL Databases, and File Shares are the main Azure resources where backup policies are used.
d. Instant Restore vs. Long-Term Backup
- Instant Restore: Recover data quickly (short-term retention)
- Long-Term Backup: Keep data for months/years (long-term retention)
In IT environments, this allows companies to meet compliance requirements and quickly recover from issues.
3. Creating a Backup Policy in Azure Portal
Here’s how it works step by step:
- Go to Recovery Services Vault
- A Recovery Services vault is a storage location in Azure where all your backups are saved.
- Select “Backup Policies”
- You can create a new policy or modify an existing one.
- Define Schedule
- Choose Daily, Weekly, or Monthly backup schedules
- Set the time of day when backups run
- Set Retention Rules
- Define how long each backup should be kept for short-term and long-term
- Assign Policy to a Resource
- Apply the policy to VMs, SQL databases, or file shares
Once applied, Azure automatically takes backups according to this policy. No manual intervention is needed.
4. Backup Policy Best Practices for IT Environments
- Use Incremental Backups where possible
- Saves storage and costs
- Only backs up changes after the initial full backup
- Set Appropriate Retention
- Short-term retention for operational recovery (e.g., last 30 days)
- Long-term retention for compliance or audits (e.g., 1 year)
- Align Backup Schedules with Workload Usage
- For VMs with high activity, schedule backups during off-peak hours
- Test Restores Regularly
- A backup is only useful if you can restore it successfully
- Use Multiple Policies if Needed
- You can have different policies for critical VMs vs. less important VMs
5. AZ-104 Exam Focus Points
For the exam, make sure you understand:
- What a backup policy is and why it’s used
- The components of a backup policy:
- Schedule (daily, weekly, monthly)
- Retention (short-term and long-term)
- Backup type (VMs, SQL, Files)
- How to create and configure a policy in the Recovery Services Vault
- How to assign a policy to an Azure resource
- Best practices for backups in IT environments
- Difference between short-term and long-term retention
You don’t need to memorize all retention periods, but you must know that Azure allows different retention for daily, weekly, monthly, and yearly backups.
✅ Summary in One Line:
A backup policy in Azure defines when and how long data is backed up and ensures automated, reliable recovery for Azure resources like VMs, SQL databases, and file shares.
