IAM, AWS CLI, EC2 Fundamentals Flashcards

IAM, AWS CLI, EC2 Fundamentals

1
Q

What is the terminal command to list all iam users?

A

aws iam list-users

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What policy should be enabled to see the list of iam users in aws console?

A

IAMReadOnlyAccess

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

How does the ec2 instance grant permission to allow for viewing list of iam users in the terminal?

A

The IAM role linked to the ec2 instance has a policy of IAMReadOnlyAccess

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What happens if the IAMReadOnlyAccess policy is not enabled on the role attached to the ec2 instance?

A

The command to view all users will fail

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is the proper definition of an IAM Role?

A

An IAM entity that defines a set of permissions for making requests to AWS services, and will be used by an AWS service

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Which of the following is an IAM Security tool?
a) IAM Credentials Report
b) IAM Root Account Manager
c) IAM Services Report
d) IAM Security Advisor

A

IAM Credentials Report

IAM Credentials report lists all your AWS Account’s IAM Users and the status of their various credentials.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Which answer is INCORRECT regarding IAM users?
a) IAM Users can belong to multiple User Groups
b) IAM users don’t have to belong to a user group
c) IAM policies can be attached directly to IAM users
d) IAM users access AWS services using root account credentials,

A

d)

IAM Users access AWS services using their own credentials (username & password or Access Keys).

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Which of the following is an IAM best practice?
a) create several, IAM users for one physical person
b) don’t use the root user account
c) share your AWS account credentials with your colleagues, so she, or he can perform a task for you
d) don’t enable MFA for easier access

A

b)
Use the root account only to create your first IAM User and a few account/service management tasks. For everyday tasks, use an IAM User.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What are IAM Policies?
a) set up policies that defines how AWS accounts interact with each other
b) JSON documents that define a set up permissions for making requests to AWS services and can be used by IAM users user groups and IAM roles
c) set of policies that defines the password for IAM users
d) A set of policies is defined by AWS that show how customers interact with AWS

A

b)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Which principle should you apply regarding IAM Permissions?

A

Grant least privilege

Don’t give more permissions than the user needs.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What should you do to increase your root account security?

A

Enable MFA

When you enable MFA, this adds another layer of security. Even if your password is stolen, lost, or hacked your account is not compromised.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

IAM User Groups can contain IAM Users and other User Groups. True or False?

A

False

IAM User Groups can contain only IAM Users.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

An IAM policy consists of one or more statements. A statement in an IAM Policy does not consists which of the following,

a) Effect

b) Principal

c) Version

d) Action

e) Resource

A

c) Version

A statement in an IAM Policy consists of Sid, Effect, Principal, Action, Resource, and Condition. Version is part of the IAM Policy itself, not the statement.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Which EC2 Purchasing Option can provide you the biggest discount, but it is not suitable for critical jobs or databases?

A

Spot Instances are good for short workloads and this is the cheapest EC2 Purchasing Option. But, they are less reliable because you can lose your EC2 instance.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

What should you use to control traffic in and out of EC2 instances?

A

Security Groups

Security Groups operate at the EC2 instance level and can control traffic.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

How long can you reserve an EC2 Reserved Instance?

A

1 or 3 years

EC2 Reserved Instances can be reserved for 1 or 3 years only.

17
Q

You would like to deploy a High-Performance Computing (HPC) application on EC2 instances. Which EC2 instance type should you choose?

a) Storage Optimized

b) Compute Optimized

c) Memory Optimized

d) General Purpose

A

b)

Compute Optimized EC2 instances are great for compute-intensive workloads requiring high-performance processors (e.g., batch processing, media transcoding, high-performance computing, scientific modeling & machine learning, and dedicated gaming servers).

18
Q

Which EC2 Purchasing Option should you use for an application you plan to run on a server continuously for 1 year?

a) Reserved Instances

b) Spot Instances

c) On-Demand Instances

A

a)

Reserved Instances are good for long workloads. You can reserve EC2 instances for 1 or 3 years.

19
Q

You are preparing to launch an application that will be hosted on a set of EC2 instances. This application needs some software installation and some OS packages need to be updated during the first launch. What is the best way to achieve this when you launch the EC2 instances?

a) Connect to each EC2 instance using SSH then install the required software and update your OS packages manually

b) write a bash script that installs the required Software and updates to your OS then contact AWS support and provide them with the script. They will then run it on your EC2 instance at launch.

c) write a bash script that installs the required software and updates to your OS then use the script in EC2 User Data when your launch EC2 instances

A

c)

EC2 User Data is used to bootstrap your EC2 instances using a bash script. This script can contain commands such as installing software/packages, download files from the Internet, or anything you want.

20
Q

Which EC2 Instance Type should you choose for a critical application that uses an in-memory database?

a) Storage Optimized

b) Compute Optimized

c) Memory Optimized

d) General Purpose

A

c)

Memory Optimized EC2 instances are great for workloads requiring large data sets in memory.

21
Q

You have an e-commerce application with an OLTP database hosted on-premises. This application has popularity which results in its database has thousands of requests per second. You want to migrate the database to an EC2 instance. Which EC2 Instance Type should you choose to handle this high-frequency OLTP database?

a) Storage Optimized

b) Compute Optimized

c) Memory Optimized

d) General Purpose

A

a)

Storage Optimized EC2 instances are great for workloads requiring high, sequential read/write access to large data sets on local storage.

22
Q

Security Groups can be attached to only one EC2 instance. True or False ?

A

Security Groups can be attached to multiple EC2 instances within the same AWS Region/VPC.

23
Q

You’re planning to migrate on-premises applications to AWS. Your company has strict compliance requirements that require your applications to run on dedicated servers. You also need to use your own server-bound software license to reduce costs. Which EC2 Purchasing Option is suitable for you?

a) Convertible Reserved Instances

b) Dedicated Hosts

c) Spot Instances

A

b)

Dedicated Hosts are good for companies with strong compliance needs or for software that have complicated licensing models. This is the most expensive EC2 Purchasing Option available.

24
Q

You would like to deploy a database technology on an EC2 instance and the vendor license bills you based on the physical cores and underlying network socket visibility. Which EC2 Purchasing Option allows you to get visibility into them?

a) Spot Instances

b) On-Demand

c) Dedicated Hosts

d) Reserved Instances

A

c)