AZ-104 Question 38
Single answerYou manage an Azure resource group that hosts a critical Storage Account. The business requires that this Storage Account not be accidentally deleted, but administrators should still be able to upload and modify data within it. Which measure should you implement?
- A
Apply a ReadOnly lock at the resource group level containing the Storage Account
- B
Apply a CanNotDelete lock at the resource group level containing the Storage Account
- C
Apply a ReadOnly lock at the Storage Account resource level
- D
Apply a CanNotDelete lock at the Storage Account resource level
Show answer and explanation
Correct answer: D
Explanation
Using a CanNotDelete lock at the resource level is the best approach because it protects the resource from accidental deletion while allowing normal data operations.
- A. Incorrect.
ReadOnly lock prevents modifications to the resource, including data changes. This blocks necessary updates.
- B. Incorrect.
Applying a CanNotDelete lock at the resource group level also locks all resources in that group from being deleted, which may be acceptable but is broader in scope than required.
- C. Incorrect.
ReadOnly lock at the resource level prevents changes to that specific resource's configuration and data, which goes against the business requirement to upload and modify data.
- D. Correct.
CanNotDelete lock at the resource level ensures that the resource cannot be deleted while allowing modifications to data.