Bird
0
0

You want to automate installing software on an EC2 instance at launch using user data. Which of these is the best practice?

hard📝 Application Q15 of 15
AWS - EC2 Fundamentals
You want to automate installing software on an EC2 instance at launch using user data. Which of these is the best practice?
AManually SSH into the instance after launch to install software
BStore installation commands in instance metadata
CWrite a shell script in user data that installs software and runs on first boot
DUse user data only to store instance tags
Step-by-Step Solution
Solution:
  1. Step 1: Understand user data purpose

    User data is designed to run scripts automatically at instance launch to configure or install software.
  2. Step 2: Evaluate options

    Manual SSH is not automated, metadata is read-only info, and tags are not stored in user data.
  3. Final Answer:

    Write a shell script in user data that installs software and runs on first boot -> Option C
  4. Quick Check:

    User data automates setup scripts [OK]
Quick Trick: Use user data scripts to automate setup at launch [OK]
Common Mistakes:
MISTAKES
  • Trying to store commands in metadata
  • Ignoring automation benefits
  • Misusing user data for tags

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More AWS Quizzes