CloudGuild · Blog · Cheat sheets · Lessons · Certifications
AZ-104 Exam Question Walkthrough: Ensuring Software Installation on VMs
Discover the best approach for ensuring software installation on Azure VMs in the AZ-104 exam. We break down a key question.
You may face tricky decisions in the AZ-104 exam. This question tests your understanding of VM management in Azure. Candidates often stumble on the efficiency of different methods.
The question
You have a VM running Windows Server in Azure that requires a specific software package for your application. You need to ensure that the software is installed every time the VM is created. What is the best way to achieve this?
- A. Use a Custom Script Extension
- B. Create a VM image with the software installed
- C. Install the software manually after creation
- D. Use Azure Automation to install the software
Think before you scroll
Consider the efficiency and automation of each option. The goal is to have the software installed automatically every time the VM is created. Weigh the options based on deployment speed and reliability.
The answer
The correct option is B: Create a VM image with the software installed. This method guarantees that the software is pre-installed on every VM deployment, making it the most efficient choice.
Why the other options lose
- A. Use a Custom Script Extension: This option requires running a script each time a VM is deployed. While it can install software, the process is less efficient than having a pre-configured image.
- C. Install the software manually after creation: This method is impractical for automated deployments. It introduces human error and delays, making it unsuitable for environments that require consistency.
- D. Use Azure Automation to install the software: Although Azure Automation can manage installations, it still requires setup and execution every time. This adds complexity and potential for failure compared to a pre-built image.
The concept behind it
Creating a VM image with necessary software installed is a best practice in Azure. It ensures that all VMs are deployed with the same configuration, minimizing the risk of errors and improving deployment speed. This principle applies to other resources as well, where predefined configurations can save time and maintain consistency.
Exam trap to remember
Always opt for pre-configured images for software installations on VMs. It’s the most efficient and reliable method for automated deployments.