Bird
0
0

Which AWS CLI command lists all EC2 instances in your account?

easy📝 Conceptual Q2 of 15
AWS - CLI
Which AWS CLI command lists all EC2 instances in your account?
Aaws iam list-users
Baws s3 ls
Caws lambda list-functions
Daws ec2 describe-instances
Step-by-Step Solution
Solution:
  1. Step 1: Identify command for EC2 instances

    The command to list EC2 instances is under the EC2 service and uses 'describe-instances'.
  2. Step 2: Eliminate unrelated commands

    Options B, C, and D relate to S3, Lambda, and IAM services, not EC2 instances.
  3. Final Answer:

    aws ec2 describe-instances -> Option D
  4. Quick Check:

    List EC2 instances = aws ec2 describe-instances [OK]
Quick Trick: EC2 instance info uses 'describe-instances' command [OK]
Common Mistakes:
MISTAKES
  • Using S3 commands for EC2
  • Confusing Lambda functions with EC2
  • Using IAM commands for instances

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More AWS Quizzes