AWS OpsWorks Flashcards

1
Q

Opsworks comprises of 3 different products, what are they?

A

Ops works is in fact 3 separate products

  • OpsWorks stacks
  • Opsworks for Chef automation (not needed for the exam)
  • Opsworks for Puppet automation (not needed for the exam)
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What is a OpsWorks stack?

A

Opsworks is configuration management for some of the standard IaaS components in EWS. It is a higher level of abstraction over componets like EC2.

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

What is an OpsWorks layer?

A

A layer is a set of configurations that when applied will configure the required component in you deployment. Such as EC2 instance,

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

What is an RDS service layer?

A

This is a OpsWorks layer that can represent and existing RDS instance within OpsWorks. The RDS instance represented by the service layer is already created.

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

What layer types can you have in OpsWorks?

A
  • EC2 instance layer
  • ELB layer
  • ECS Cluster Layer
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What is an ECS Cluster service layer?

A

It is launching and maintaining containers in an existing ECS cluster.

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

What is OpsWorks auto healing?

A

This is when you have an agent on the instance and if this agent and Ops|Works loose comms, OpsWorks will stop and start you instance if it is a EBS backed instance or it will delete and create a new instance if it is a store-backed instance.

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

Can I use OpsWorks stacks with windows?

A

Yes, it is supported.

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

Is Opsworks a global or regional service?

A

It is a global service but it crates resource in a region, you have to select the region.

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

Can Opsworks stacks create and manage EC2 clusters?

A

No, ops works does not create EC2 clusters, if you already have an EC2 cluster then you can add it to the stack as an EC2 layer.

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

What are you doing when you add an EC2 cluster layer to you Opsworks stack?

A

You are adding a layer to the stack of the type EC2 and this will be an external EC2 cluster you have already created.

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

I wnat to have my stack instances recover in the event of failure, how cna I achieve this?

A

Ops work as a configuration item in the configuration for the layer that enables you to select auto-healing for the instance.

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

For auto-healing where is the configuration item?

A

It is in the layer settings.

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

Explain how auto-healing works in Opsworks stacks?

A

Each instance in an ops works stack layer has an agent if the agent does not talk with the Opsworks services for more then 5min the instance, the instance will be considered failed. Ops work will take action to start and stop the instance if the instance is EBS if the instance is a local store instance the instance will be replaced.

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

Can I add existing EC2 instances to my instances layer?

A

Yes, you can add the existing instance to your layer. It will also install the Opsworks stacks agent on the instance.

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

When I add an existing EC2 instance to a opsworks stack layer, what will opsworks do as part of this process?

A

Opsworks will install and agent on the EC2 instance so Opsworks stack can manage the instance.

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

Can I register on-prem instances with opsworks?

A

Yes, in the opsworks stack layer you select register instance, you will be given the option to install the agent on the on-prem VM.

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

What is the ops work agent used for?

A

It is used to manage the instance under control of opsworks.

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

When creating a stack what config parameters do you set up?

A
  • Stack name
  • Region
  • VPC
  • Subnet
  • Default OS
  • SSH Key
20
Q

What are the chef recipes life cycle events?

A
  • Setup: after a started instance has finished booting
  • Configure: occurs on all of the stack’s instances when one of the following occurs, instance enters or leaves the online state. You associate an Elastic IP address with an instance or disassociate one from an instance. You attach an Elastic Load Balancing load balancer to a layer, or detach one from a layer.
  • Deploy: This event occurs when you run a Deploy command,
  • Undeploy: This event occurs when you delete an app or run an Undeploy command to remove an app from a set of application server instances.
  • Shutdown: This event occurs after you direct AWS OpsWorks Stacks to shut an instance down but before the associated Amazon EC2 instance is actually terminated. AWS OpsWorks Stacks runs recipes to perform cleanup tasks such as shutting down services.
21
Q

I wnat to install software on my instances when they are created by Opsworks, how cna I do this?

A

I create a chef recipe, store it on git, s3 or HTTP server. I configure the stack to use this recipe repository. I create a layer for my instance and in the recipe section select to use the chef scrip under the Startup event.

22
Q

I want each instance in my Opsworks layer to make configuration changes to it running software when a new instance is added, how cna I do this?

A

Ensure the stack is configured to use one of the repositories used to store chef recipes (git, s3 and HTTP). In the layer under recipes and using the configure life cycle event select the chef recipe you wnat to use.

23
Q

If I wnat my instances in a layer to have public IP, how can I do this?

A

Select the enable public IP in the layer settings

24
Q

If I wnat my instances in a layer to have elastic IP, how can I do this?

A

Select the enable elastic IP in the layer settings

25
Q

I need additional EBS volumes on my layer instances, how cna I do this?

A

When creating the layer, set the EBS configuration, here you can select EBS volumes to be added to each new instances.

26
Q

How cna I capture logs form my layer instances?

A

Opsworks layer as configuration to enable layer instances to send there OS logs to cloudwatch logs.

27
Q

I am configuring layer instances logs to send logs to cloudwatch, what else do I need to configure?

A

Check tthet I understand thet AWSOpsWorksCloudWatchLogs policy will be added to the aws-opsworks-ec2-role

28
Q

What are the different instances types you can create in a layer in Opsworks?

A
  • 24/7 instances (normal on-demand Ec2 instance)

- Time-based: You select the start and stop time, li

29
Q

When would I use 24/7 (normal on-demand instances0?

A
  • Baseload
  • Time-based instances: If the load is known to occur during periods of the day, week, month
  • Load based instances:
    When you do not know what the load will be.
30
Q

If I wnat to install apps on my layer servers, how can I do this?

A

Opsworks has the concept of apps, you create an app, the app is a set of information like a pointer to a GIT, S3 where your app lives. You also can configure environment variables to be passed. To deploy this app you use ops work deploy, this is the deploy will take the app as a parameter. Deploy will enable you to select your instances.

31
Q

What are the 3 layer types in a stack?

A
  • Instance layer
  • RDS layer
  • EC2 Layer
32
Q

With the setup, the event gets executed on all instances?

A

No, Just on the instance thet is after booting

33
Q

What is a cookbook?

A

A Chef cookbook is comprised of recipes that a nodes desired state. Recipes are written in Ruby and contain information about everything that needs to be run, changed, or created on a node.

34
Q

What is an Opsworks recipe?

A

A recipe is a Ruby application that defines a system’s configuration. In Opsworks these recipes are invoked on each node through the agent during the life cycle events.

35
Q

What programing or templating language are recipes wrote in?

A

They are written in Ruby

36
Q

When setting up a stack, how can you create a VPC and Subnets for the stack?

A

You can not create the VPC or subnets as part of Opsworks stack, this is done externally and then defined in the stack configuration for the stack to use. The stack will ten use this VPC and Subnet when deploying EC2 instances.

37
Q

List the Opsworks life cycle events?

A
  • Startup
  • Configure
  • Deploy
  • Undeploy
  • Shutdown
38
Q

Is the Opsworks configure life cycle event executed only on a single instance?

A

No, it is executed on all nodes/instances in the Opsworks stack layer. This happens as a node is joining the nodes in the layer or leaving the layer or if the EIP is associated or disassociated and gives an opportunity for other nodes to understand a new node has come into the layer and if needed makes adjustments.

39
Q

What is the Opsworks Startup life cycle event used for?

A

Startup event fires just after bootup and is often used to install service and packages the application may require, like apache, PHP, etc.

40
Q

Where can I store Chef recipes for use in the layers?

A
  • GIT
  • HTTP
  • S3
41
Q

When would we use the deploy and undeploy Opsworks life cycle events?

A

When we are installing or uninstalling an application.

42
Q

I wnat to install and application to all my nodes in a layer?

A

You use the Apps feature to create an application, and then you create a deployment in Deployments and then you can use the deploy to deploy the application.

43
Q

What is the Apps feature used for in Opsworks?

A

It is used to create an app configuration, part of this configuration is a property thet points to where the source for the App is located, like GIT.

44
Q

Can I use OpsWorks to create an RDS and ECS instances?

A

No, not to create but you can create externally with tooling like CloudFormation and then link them to an OpsWorks works layer.

45
Q

What is the AWS OpsWorks Stacks Agent CLI?

A

The agent that AWS OpsWorks Stacks installs on every instance exposes a command line interface (CLI),
- Access log files for Chef runs.

  • Access AWS OpsWorks Stacks commands.
  • Manually run Chef recipes.
  • View instance reports.
  • View agent reports.
  • View a limited set of stack configuration and deployment attributes.