Question

Difficulty: MediumAzure Resources, Resource Groups, Subscriptions, and Management Groups

A development team is deploying a testing environment that consists of an Azure Virtual Machine and an Azure SQL Database. The team needs to manage the lifecycle of these resources together, including deleting them simultaneously at the end of the test. The Virtual Machine must be deployed in the North Europe region to be close to developers, while the SQL Database must be deployed in the West Europe region for compliance.

Which of the following resource group configurations should the team use?

  1. A
    Create a parent resource group in North Europe for the Virtual Machine, and create a nested child resource group for the SQL Database.
  2. B
    Deploy the Virtual Machine and the SQL Database to separate resource groups, because resources must reside in a resource group located in the same region as the resource.
  3. Deploy both resources to a single resource group, regardless of the location of the resource group itself.Answer
  4. D
    Deploy both resources to a single resource group, which will automatically force the SQL Database to be deployed in the same region as the Virtual Machine.

Answer

Deploy both resources to a single resource group, regardless of the location of the resource group itself.
Deploying both resources to a single resource group is the correct approach. Azure resource groups are logical containers designed to group resources that share the same lifecycle. Resources within a resource group do not need to be in the same Azure region as each other or the resource group itself. Therefore, a Virtual Machine in North Europe and a SQL Database in West Europe can reside in the same resource group, allowing them to be deleted together when the group is deleted.

Step-by-Step Solution

1
Identify the organization and lifecycle requirement.
The Virtual Machine and SQL Database must be managed and deleted together as a single lifecycle unit.
Grouping resources that share a lifecycle into a single resource group is a recommended best practice in Azure.
2
Analyze regional constraints and resource group capabilities.
Resources inside a single resource group can be located in different regions (North Europe and West Europe). The resource group's location only determines where its metadata is stored.
This allows resources in different geographical locations to be managed together under a single lifecycle.
3
Evaluate the architectural constraints of resource groups.
Azure does not support nesting resource groups, so they cannot be organized hierarchically inside one another.
This rules out any nested resource group solutions.

Key Concept

Azure resource groups serve as logical containers for resources, allowing items in different regions to be grouped together for lifecycle management without nesting.
Rate this question