Triage and Remediation
Remediation
Using Console
Using Console
To remediate the misconfiguration of not having Geo-Redundant Backups enabled in Azure, follow these step-by-step instructions:
- Log in to the Azure portal at https://portal.azure.com/.
- Navigate to the resource group that contains the storage account you want to remediate.
- Select the storage account from the list of resources.
- In the left-hand menu, click on “Backup”.
- In the “Backup” menu, click on “Backup policy”.
- Click on “Edit”.
- In the “Policy details” section, select “Geo-redundant” from the “Replication” drop-down menu.
- Click on “Save”.
Using CLI
Using CLI
To remediate the misconfiguration of not having Geo-Redundant Backups enabled in Azure using Azure CLI, you can follow these steps:
- Open the Azure CLI command prompt or terminal.
-
Login to your Azure account using the command:
-
Once you are logged in, set the target subscription using the command:
-
Next, enable Geo-Redundant Backups for the desired resource group using the command:
Here, replace
<resource_group_name>
with the name of the resource group where the backup vault is located and<vault_name>
with the name of the backup vault. -
Verify the backup properties using the command:
This command will display the backup properties for the specified backup vault.
-
Once you have verified that Geo-Redundant Backups have been enabled, you can exit the Azure CLI using the command:
Using Python
Using Python
To remediate the misconfiguration of not having Geo-Redundant Backups enabled in Azure using Python, you can use the Azure SDK for Python. Here are the step-by-step instructions:
- Install the Azure SDK for Python using pip:
- Import the necessary modules:
- Set up the authentication credentials using a service principal:
- Instantiate the
RecoveryServicesBackupClient
using the authentication credentials:
- Get the list of protection intents:
- Check if Geo-Redundant Backups are enabled for each protection intent:
- Save the changes by calling
create_or_update
on each protection intent that had Geo-Redundant Backups enabled.