You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/storage/blobs/soft-delete-blob-enable.md
+12-6Lines changed: 12 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,7 @@ author: normesta
7
7
8
8
ms.service: storage
9
9
ms.topic: how-to
10
-
ms.date: 05/05/2022
10
+
ms.date: 07/21/2022
11
11
ms.author: normesta
12
12
ms.subservice: blobs
13
13
ms.custom: devx-track-azurepowershell
@@ -19,13 +19,15 @@ Blob soft delete protects an individual blob and its versions, snapshots, and me
19
19
20
20
Blob soft delete is part of a comprehensive data protection strategy for blob data. To learn more about Microsoft's recommendations for data protection, see [Data protection overview](data-protection-overview.md).
21
21
22
-
Blob soft delete is enabled by default for a new storage account. You can enable or disable soft delete for a storage account at any time by using the Azure portal, PowerShell, or Azure CLI.
23
-
24
22
## Enable blob soft delete
25
23
24
+
You can enable or disable soft delete for a storage account at any time by using the Azure portal, PowerShell, or Azure CLI.
25
+
26
26
### [Portal](#tab/azure-portal)
27
27
28
-
To enable blob soft delete for your storage account by using the Azure portal, follow these steps:
28
+
Blob soft delete is enabled by default when you create a new storage account with the Azure portal. The setting to enable or disable blob soft delete when you create a new storage account is on the **Data protection** tab. For more information about creating a storage account, see [Create a storage account](../common/storage-account-create.md).
29
+
30
+
To enable blob soft delete for an existing storage account by using the Azure portal, follow these steps:
29
31
30
32
1. In the [Azure portal](https://portal.azure.com/), navigate to your storage account.
31
33
1. Locate the **Data Protection** option under **Data management**.
@@ -37,7 +39,9 @@ To enable blob soft delete for your storage account by using the Azure portal, f
37
39
38
40
### [PowerShell](#tab/azure-powershell)
39
41
40
-
To enable blob soft delete with PowerShell, call the [Enable-AzStorageBlobDeleteRetentionPolicy](/powershell/module/az.storage/enable-azstorageblobdeleteretentionpolicy) command, specifying the retention period in days.
42
+
Blob soft delete is not enabled when you create a new storage account with PowerShell. You can enable blob soft delete after the new account has been created.
43
+
44
+
To enable blob soft delete for an existing storage account with PowerShell, call the [Enable-AzStorageBlobDeleteRetentionPolicy](/powershell/module/az.storage/enable-azstorageblobdeleteretentionpolicy) command, specifying the retention period in days.
41
45
42
46
The following example enables blob soft delete and sets the retention period to seven days. Remember to replace the placeholder values in brackets with your own values:
To enable blob soft delete with Azure CLI, call the [az storage account blob-service-properties update](/cli/azure/storage/account/blob-service-properties#az-storage-account-blob-service-properties-update) command, specifying the retention period in days.
65
+
Blob soft delete is not enabled when you create a new storage account with Azure CLI. You can enable blob soft delete after the new account has been created.
66
+
67
+
To enable blob soft delete for an existing storage account with Azure CLI, call the [az storage account blob-service-properties update](/cli/azure/storage/account/blob-service-properties#az-storage-account-blob-service-properties-update) command, specifying the retention period in days.
62
68
63
69
The following example enables blob soft delete and sets the retention period to seven days. Remember to replace the placeholder values in brackets with your own values:
0 commit comments