Question

Difficulty: HardCreate and Configure Virtual Machines

Your company is deploying several Azure virtual machines (VMs) to support different application workloads. You need to configure various post-deployment configuration and monitoring tasks.

Match each administrative requirement to the correct Azure virtual machine feature or extension.

  • Execute a custom bash script from a private Azure storage blob on a Linux virtual machine during the provisioning phase.Custom Script Extension
  • Enforce a specific system configuration baseline on a Windows virtual machine and automatically correct any unauthorized configuration drift.Azure Automation State Configuration (DSC) extension
  • Run an administrative script on an active, running Windows virtual machine that does not have a public IP address or active network route from your workstation.Run Command
  • Automatically collect and forward guest-level operating system performance counters to a Log Analytics workspace.Azure Monitor agent

Answer

Execute a custom bash script during provisioning matches Custom Script Extension; Enforce a baseline and correct configuration drift matches Azure Automation State Configuration (DSC) extension; Run an administrative script without a public IP on an active VM matches Run Command; Collect and forward guest-level OS performance counters matches Azure Monitor agent.
The correct matches align with Microsoft Azure best practices: Custom Script Extension is used for bootstrapping/provisioning scripts; Azure Automation DSC ensures state compliance and remediates drift; Run Command executes scripts on running VMs via the local VM agent without public IP requirements; and the Azure Monitor agent handles guest-level performance data collection.

Step-by-Step Solution

1
Analyze the requirement for running a script during provisioning from a private blob.
Identify that the Custom Script Extension is designed specifically to download and execute scripts during VM deployment.
Other extensions either manage configuration state or monitor performance rather than executing one-time bootstrap scripts.
2
Analyze the requirement for maintaining configuration state and correcting drift.
Identify that PowerShell Desired State Configuration (DSC) via Azure Automation enforces a configuration baseline and automatically corrects deviations.
Custom Script Extension and Run Command only execute scripts once and do not monitor or remediate drift continuously.
3
Analyze the requirement for executing a script on a running VM without direct network access or a public IP.
Identify that Run Command utilizes the VM agent to run scripts securely from the Azure portal/CLI without direct network routes.
This bypasses NSG rules and public IP requirements, unlike SSH or RDP which require network access.
4
Analyze the requirement for gathering guest-level performance metrics.
Identify that the Azure Monitor agent is used to collect OS-level diagnostics and send them to Log Analytics.
The Azure Monitor agent is the standard mechanism for data collection at the OS level.

Key Concept

Selecting the appropriate extension or management feature to configure and manage Azure Virtual Machines post-deployment.
Estimated Time:2m 0s
Rate this question