1 h 30 (S9.1 : 15 min · S9.2 : 35 min · S9.3 : 40 min)
modules 6 (Azure Files, File Sync, Lyon server) and 7 (web01, web02, data disk)
web01 backup started at 09:00 by lancer-sauvegarde.sh, share partage-lyon synchronized, Lyon server started
15 min
Data protection = Redundancy (failure) + Backup (error, attack) + Recovery (disaster)| Threat | Redundancy (LRS, ZRS, GRS) | Backup |
|---|---|---|
| Loss of a disk, of a datacenter | Yes | Not needed |
| Accidental deletion or overwrite | No: replicated | Yes |
| Ransomware (files encrypted) | No: replicated | Yes, if the vault is protected |
| Failed application update | No | Yes (rollback) |
starveostNNdata)RPO = Maximum acceptable data loss (backup frequency)RTO = Maximum acceptable downtime (restore speed)| Arvéo workload | RPO | RTO | Retention |
|---|---|---|---|
Customer portal (web01, web02) |
24 h | 4 h | 30 d + 12 wk |
Share partage-lyon |
24 h | 1 h (file) | 30 d |
Lyon accounting exports (F:\Compta) |
24 h | 1 d | 30 d |
Azure Backup = Recovery Services vault | Backup vault + Policies| Vault | Protected workloads |
|---|---|
| Recovery Services | Azure VMs, Azure Files, SQL / SAP HANA in a VM, MARS agent, MABS / DPM |
| Recovery Services | Azure Site Recovery (VM replication) |
| Backup vault | Blobs, managed disks, AKS, Azure Database for PostgreSQL |
francecentral)rsv-stNN-arveo in rg-stNN-shared, a single one for VMs, share and Lyon server[TO VERIFY] in the current Azure Backup support matrixVault storage = LRS | ZRS | GRS (default) (+ Cross Region Restore)francesouth)Q="[0].properties.{Storage:storageModelType, CRR:crossRegionRestoreFlag}"
az backup vault backup-properties show -g rg-st07-shared -n rsv-st07-arveo \
--query "$Q" -o tablevault created, then an item protected before setting redundancy = GRS imposed
Vault security = Soft delete + Immutability + MUA + PIN + RBACvault owners ≠ administrators of the protected VMs
Policy = Schedule (frequency, time) + Retention (GFS) + Snapshot retention| Criterion (Azure VMs) | Standard | Enhanced |
|---|---|---|
| Frequency | Once a day | Every 4 to 24 h |
| Snapshots kept | 1 to 5 days | 1 to 30 days |
| Trusted Launch VMs | Not supported | Required |
| Premium SSD v2, Ultra disks | No | Yes |
web01 and web02: Ubuntu 24.04 Trusted Launch images (M7) → Enhanced policypol-vm-arveo: once a day at 22:00, 7 d of snapshots, 30 days, 12 Sundays[TO VERIFY] in the "Enhanced policy for Azure VMs" documentationRecovery point = Snapshot (snapshot tier) → Transfer (vault tier)flowchart LR P[pol-vm-arveo<br/>22:00] --> EXT[Extension<br/>VMSnapshotLinux] EXT --> SNAP[Disk snapshots<br/>snapshot tier, 7 d] SNAP --> V[rsv-st07-arveo<br/>vault tier, 30 d]
lancer-sauvegarde.sh: LRS vault, policy, web01 protection and backupQP="{Type:properties.policyType, Snapshots:properties.instantRpRetentionRangeInDays}"
az backup policy show -g rg-st07-shared -v rsv-st07-arveo -n pol-vm-arveo \
--query "$QP" -o table
QJ="[].{Item:properties.entityFriendlyName, Operation:properties.operation"
az backup job list -g rg-st07-shared -v rsv-st07-arveo -o table \
--query "$QJ, Status:properties.status}"Expected output (status depends on progress):
Type Snapshots
------ -----------
V2 7
Item Operation Status
------------- --------------- ----------
vm-st07-web01 Backup InProgress
vm-st07-web01 ConfigureBackup CompletedLab 09.1: inspect the vault, protect web02, start the MARS agent (5 min)
35 min
Method = Workload type + Location (Azure | on-premises)| Workload | Method | Arvéo |
|---|---|---|
| Azure VM (all disks) | VM backup (extension) | web01, web02 |
| Azure Files share | Share snapshots managed by the vault | partage-lyon |
| Files and folders of a Windows server | MARS agent | F:\Compta (Lyon) |
| Full on-premises server, Hyper-V, SQL | MABS or DPM | Out of scope |
| Blobs | Operational or vaulted backup (Backup vault) | pod (bonus) |
Azure Files backup = Share snapshot (in the account) + Schedule + Retention[TO VERIFY] availabilityAzureBackupProtectionLock lock set on the account: account deletion blockedsnapshot tier only = account deleted or compromised, backups lost
az backup policy create -g rg-st07-shared -v rsv-st07-arveo -n pol-files-arveo \
--backup-management-type AzureStorage --workload-type AzureFileShare \
--policy @scripts/labs/module-09/pol-files-arveo.json -o none
az backup protection enable-for-azurefileshare -g rg-st07-shared -v rsv-st07-arveo \
--policy-name pol-files-arveo --storage-account starveost07files2610 \
--azure-file-share partage-lyon -o none
az backup protection backup-now -g rg-st07-shared -v rsv-st07-arveo \
--container-name "$CONT" --item-name "$ITEM" --backup-management-type AzureStorage \
--retain-until "$(date -d '+30 days' +%d-%m-%Y)" -o none$CONT, $ITEM: internal names read with az backup item list (see lab 09.2)az backup restore restore-azurefiles -g rg-st07-shared -v rsv-st07-arveo \
--container-name "$CONT" --item-name "$ITEM" --rp-name "$RP" \
--restore-mode OriginalLocation --resolve-conflict Overwrite \
--source-file-type File --source-file-path Exploitation/tournee-03.csv -o none--resolve-conflict: Overwrite (replace) or Skip (keep the existing file)AlternateLocation: another account or share (--target-storage-account, --target-file-share)[TO VERIFY]restore to another share first to check, then copy
MARS = Agent + Vault credentials + Passphrase + Local policyflowchart LR FS[vm-st07-lyon-fs<br/>F:\Compta] --> AG[MARS agent<br/>local cache] AG -->|HTTPS 443<br/>natgw-lyon| V[rsv-st07-arveo<br/>France Central]
.VaultCredentials file, valid 10 days, used ONCE for registrationMSOnlineBackup PowerShell), not in the vaultMARS backup = Up to 3 a day + GFS retention + NTFS / ReFS volumes[TO VERIFY])| Operation | Requirement |
|---|---|
| Registration | Vault credentials + passphrase |
| Restore to another server | Vault credentials + ORIGINAL passphrase |
| Retention reduction, stop with deletion | Security PIN (portal, 5 min) |
MSOnlineBackup PowerShell module installed with the agent (run as administrator)$p = New-OBPolicy
Add-OBFileSpec -Policy $p -FileSpec (New-OBFileSpec -FileSpec @('F:\Compta'))
Set-OBSchedule -Policy $p -Schedule (New-OBSchedule -DaysOfWeek Monday,Tuesday,
Wednesday,Thursday,Friday -TimesOfDay 21:00)
$r = New-OBRetentionPolicy -RetentionDays 30
Set-OBRetentionPolicy -Policy $p -RetentionPolicy $r
Set-OBPolicy -Policy $p -Confirm:$false
Get-OBPolicy | Start-OBBackupExpected output (end):
The backup operation completed successfully.Synchronized share → Back up the Azure share (cloud endpoint)partage-lyon → Azure Files backupF:\Compta, local application) → MARS agentBefore (Lyon): weekly LTO tape of the whole server, 2-day restore
After (Azure): share by snapshots (1 min) + F:\Compta by MARS, file restore in minutes
40 min
VM restore = Recovery point + Restore type + Target| Option | Result | Arvéo case |
|---|---|---|
| Create a VM | New VM, new NIC | Disaster, test clone |
| Restore disks | Managed disks, no VM | Recover data, custom VM |
| Replace existing | VM disks replaced, same NIC and IP | Rollback after an update |
| File recovery | Point mounted by script (iSCSI, 3260) | A few files |
| Cross Region Restore | One of the options in the paired region | Loss of France Central (GRS + CRR) |
Restore time = Point tier + Disk size| Tier | Where | Restore | Available |
|---|---|---|---|
| Snapshot | Restore point collection (AzureBackupRG_<region>_1) |
Minutes | As soon as the snapshot ends |
| Vault | Vault storage (LRS, ZRS, GRS) | Longer (copy from the vault) | After the transfer |
| Snapshot and vault | Both | The service uses the snapshot | After the transfer |
TIER="join(',', properties.recoveryPointTierDetails[].type)"
az backup recoverypoint list -g rg-st07-shared -v rsv-st07-arveo \
--container-name "$CONT" --item-name "$ITEM" --backup-management-type AzureIaasVM \
--query "[].{Name:name, Date:properties.recoveryPointTime, Tier:$TIER}" -o tableInstantRP (snapshot), HardenedRP (vault); durations [TO VERIFY]web01 data recovered without touching the VMaz backup restore restore-disks -g rg-st07-shared -v rsv-st07-arveo \
--container-name "$CONT" --item-name "$ITEM" --rp-name "$RP" \
--storage-account "$DIAG_SA" --target-resource-group rg-st07-app \
--diskslist 0 -o none
az backup job list -g rg-st07-shared -v rsv-st07-arveo --operation Restore \
--query "[0].{Operation:properties.operation, Status:properties.status}" -o tableExpected output:
Operation Status
----------- ----------
Restore InProgress--diskslist 0: LUN 0 data disk (the OS disk is restored too [TO VERIFY])Replace existing = VM stopped + Disks replaced by those of the point + Start[TO VERIFY] current behaviorweb02 alone (M7 HA)Before (Lyon): reinstall + tape restore (1 to 2 days)
After (Azure): back to the previous day's 22:00 point (15 to 30 min [TO VERIFY])
Site Recovery = Replication (RPO in minutes) + Recovery plan + Failoverflowchart LR W[vm-st07-web01<br/>France Central] -->|continuous replication| C[Cache + disks<br/>France South] C -->|failover| R[Recovery VM<br/>DR vnet] RP[Recovery plan<br/>order + scripts] -.-> R
Backup = Go back in time · Site Recovery = Fail over elsewhere| Criterion | Azure Backup | Azure Site Recovery |
|---|---|---|
| Threat covered | Error, deletion, ransomware | Loss of a region, a site |
| RPO | Hours (4 to 24 h) | Minutes (continuous replication) |
| RTO | Hours | Minutes to 1 h |
| Retention | Days to years | Recovery points over 15 days max [TO VERIFY] |
web01 require an Enhanced policy?AzureBackupRG_francecentral_1starveost<NN>files<SES> fail after protection?partage-lyon is synchronized with tiering. What should be backed up?F:\Partages\Commun with the MARS agentF: with a manual snapshotweb01's private IP and membership in pool bp-web?