AWS EC2 Interview Questions and Answers

This post covers possible EC2 interview questions and answers. We will start with easy and end with solving complex answers an EC2 user should understand and apply while managing EC2 service/resources. After reading these questions, you will understand EC2 service more deeply and can solve complex problems by applying appropriate resources/actions.

Question: Which of the following instance types available under EC2?

  1. General purpose
  2. Compute optimized
  3. Memory optimized
  4. Storage optimized
  5. All of the above

Answer: 5

Question: Which of the following instance purchasing options available under EC2?

  1. On-demand instances
  2. Spot Instances
  3. Scheduled reserved instances
  4. Dedicated Instances
  5. All of the above

Answer: 5

Question: Is it possible to use AWS EC2 service for free?

  1. Yes
  2. No

Answer: 1

Question: Is there any limit for sending emails from EC2 instances?

  1. Yes
  2. No

Answer: 1

Question: In which storage type data persists when system terminates?

  1. Local instance store
  2. EBS
  3. Snapshot
  4. EFS

Answer: 2

Question: Which file system AWS provides to use with EC2 instances?

  1. XFS
  2. JFS
  3. EFS
  4. ext2

Answer: 3

Question: It is normal to have multiple instances or volumes for different reasons. It would be great if we can recognize these instances or volumes with easy to understand names or codes that other users follow. How can we assign a names or codes to EC2 resources that can be used to recognize particular resources?

  1. Using Events
  2. Creating EC2 Tags
  3. Creating System manager shared resources
  4. Using System manager services

Answer: 2

Question: Can we launch any number of desired instances from the EC2 console?

  1. Yes – There is no limit, and you can launch any number of instances anytime
  2. No – AWS limits the maximum number of instances for AWS accounts. Limits are visible under EC2 console Limits section

Answer – 2

Question: Which type of AMI can be used while launching an EC2 instance?

  1. Own AMIs
  2. AMIs from AWS Marketplace
  3. AMIs from Community
  4. All of the above

Answer: 4

Question: Which of the following options are available under instance configuration while launching an instance?

  1. The user can configure the number of instances to launch
  2. The user can request for Spot instances to reduce cost by applying a maximum price
  3. Auto-assign public IP
  4. Root volume size can be lesser then snapshot size
  5. All of the above

Answer: 1,2,3

Question: Which attributes can be used to uniquely recognize an instance?

  1. Instance ID
  2. VPC ID
  3. Private IPs
  4. Public IPs
  5. All of the above

Answer: 1,3,4

Question: Which of the following statements are true about EC2 Key/Pair?

  1. It is compulsory to attach a key pair while launching an instance
  2. Tags can be created using key pairs
  3. User can connect to newly created instance by using key pair
  4. Key pair can be used to start EC2 instances
  5. All of the above

Answer: 1, 3

Question: AWS Users can bid spot instances with lower costs to save prices compared to On-demand instances. Select following statements those are true about spot instances.

  1. AWS provides spare compute capacity to users by placing bids for Spot Instances
  2. Spot instance hourly rate can’t cost more than the same type of on-demand instance
  3. Spot instances can have allocation strategy of lowest price in multiple availability zones
  4. Number of spot instances balanced in various availability zones
  5. All of the above

Answer: 1, 3, 4

Question: Which of the following statements are correct about Reserved Instances?

  1. Hourly rate of reserved instances can’t cost more than the same type of on-demand instance
  2. There are multiple options with no upfront to All upfront payment of instance types
  3. We can run a reserved instance for an unlimited period of time
  4. There is no limit to purchase reserved instances

Answer: 1, 2

Question: Which of the following statements are correct about AMIs?

  1. The user can create private AMIs those are not visible to any other AWS account
  2. Users can create an AMI that is accessible publicly
  3. The user can share a private AMI with another AWS account
  4. A new AMI can be created by using manifest path or by selecting an already running instance
  5. All of the above

Answer: 5

Question: Can we delete Root Volume that is used by an already running instance?

  1. Yes
  2. No

Answer: 2

Question: Can snapshot be taken of an already in use Volume?

  1. Yes
  2. No

Answer: 1

Question: Select correct statements about Snapshots.

  1. Users can create a copy of snapshots
  2. Volumes can be created by using snapshots
  3. Images can be created by using snapshots
  4. All of the above

Answer: 4

Question: Snapshots can be private, public or can be shared with the limited number of AWS accounts.

  1. Yes
  2. No

Answer: 1

Question: Inbound and outbound ports can be controlled by applying security groups to instances?

  1. Yes
  2. No

Answer: 1

Question: Can we assign more than one security group to an instance?

  1. Yes
  2. No

Answer: 1

Question: Which of the following are valid values for source/destination while adding a rule?

  1. Single IP address
  2. Range of IP addresses
  3. Single domain/subdomain name
  4. Open to world
  5. All of the above

Answer: 1, 2, 4

Question: There are situations where a specific service can use multiple dynamic ports. Using a dynamic range of ports is very common to services like VOIP calls. What is the best way to open range of ports from 16000 to 16050 in security group?

  1. 16000, 16001, 16002 … 16050
  2. From 16000 to 16050
  3. 16000 – 16050
  4. None of the above

Answer: 3

Question: Which of the following are true about Elastic IPs?

  1. Elastic IPs available until the user releases them
  2. The Elastic IP provides a private IP address with it
  3. Elastic IPs can be attached to instances and available after the instance terminates
  4. All of the above

Answer: 4

Question: AWS provides a feature to scale instances on demand. Which of the following is used to launch/terminate instances whenever computing power needs changes?

  1. Load Balancers
  2. Auto-scaling
  3. Launch configurations
  4. Placement groups

Answer: 2

Question: Which EC2 feature can be used to transfer request to another available instance in case of working instance is overloaded or capacity reached a certain level?

  1. Load Balancer
  2. Auto-scaling
  3. Launch configuration
  4. Placement groups

Answer: 1

Thanks for reading all questions. I hope these will help you to understand some useful concepts to apply under EC2.

Comment, if you have any possible EC2 interview questions that you thought can be included.

Leave a Reply

Your email address will not be published. Required fields are marked *