CloudWatch, CloudTrail, AWS Config Flashcards
In CloudWatch, __________ is a variable to monitor (CPUUtilization, NetworkIn…)
Metric
In CloudWatch, __________ is an attribute of a metric (instance id, environment, etc…).
Dimension
Up to ______ dimensions per metric
30
Metrics have __________
timestamps
Can you define CloudWatch Log expiration policies?
YES
(never expire, 1 day to 10 years…)
CloudWatch Logs can send logs to:
- Amazon S3 (exports)
- Kinesis Data Streams
- Kinesis Data Firehose
- AWS Lambda
- OpenSearch
Are CloudWatch logs encrypted by default?
YES
For CloudWatch logs, can you setup KMS-based encryption with your own keys
YEs
- SDK, CloudWatch Logs Agent, CloudWatch Unified Agent
- Elastic Beanstalk: collection of logs from application
- ECS: collection from containers
- AWS Lambda: collection from function logs
- VPC Flow Logs:VPC specific logs
- API Gateway
- CloudTrail based on filter
- Route53: Log DNS queries
CloudWatch Logs - Sources
How long can log data take to become available for export?
12 hours
- Search and analyze log data stored in CloudWatch Logs
- Example: find a specific IP inside a log, count occurrences of “ERROR” in your logs…
- Provides a purpose-built query language
- Automatically discovers fields from AWS services and JSON log
events - Fetch desired event fields, filter based on conditions, calculate
aggregate statistics, sort events, limit number of events… - Can save queries and add them to CloudWatch Dashboards
- Automatically discovers fields from AWS services and JSON log
- Can query multiple Log Groups in different AWS accounts
- It’s a query engine, not a real-time engine
CloudWatch Logs Insights
CloudWatch Logs S3 export is ________ near-real time or real-time
NOT
- Get a real-time log events from CloudWatch Logs for processing and analysis
CloudWatch Logs Subscriptions
Where can CloudWatch Logs Subscriptions Send to?
Kinesis Data Streams
Kinesis Data Firehose
Lambda
filter which CloudWatch logs are events delivered to your destination
Subscription Filter
Metrics exists only in the_________ in which they are created.
region
Metrics ___________ be deleted, but they automatically expire after __________ if no new data is published to them.
cannot
15 months
Each metric data point must be marked with a ________
timestamp
The timestamp for a metric can be up to ________ in the past and up to _________ into the future.
two weeks
two hours
If you do not provide a timestamp, CloudWatch creates a timestamp for you based on ______________
the time the data point was received
By ___________, several services provide _______ metrics for resources. You can also enable _______________, or _____________
default
free
detailed monitoring
publish your own application metrics.
Enables you to query multiple CloudWatch metrics and use math expressions to create new time series based on these metrics.
Metric math
For EC2 metric: CloudWatch does not collect ____________ and ____________ metrics right from the get go. You need to install ___________ in your instances first to retrieve these metrics.
memory utilization
disk space usage
CloudWatch Agent
a name/value pair that uniquely identifies a metric.
Dimensions
a custom metric can be classified as standard or high
Resolution
2 types of CloudWatch Resolutions
Standard Resolution
High Resolution
- Data with a granularity of one minute.
- Default metrics produced by AWS services.
Standard Resolution
- Data with a granularity of one second.
- Provides more insight into your application’s sub-minute activity.
High Resolution
metric data aggregations over specified periods of time.
Statistics
A ________ is the length of time associated with a specific CloudWatch statistic. The default value is ________ seconds.
period
60
Each statistic has a ____________.
unit of measure
Metric data points that specify a unit of measure are aggregated _______.
separately
You can specify a unit when you create a custom metric. If you do not specify a unit, CloudWatch uses __________ as the unit.
None
CloudWatch aggregates statistics according to ________ that you specify when retrieving statistics.
the period length
For large datasets, you can insert a pre-aggregated dataset called a ___________.
statistic set
6 CloudWatch Statics
Minimum
Maximum
Sum
Average
SampleCount
pNN.NN
The lowest value observed during the specified period. You can use this value to determine low volumes of activity for your application.
Minimum
The highest value observed during the specified period. You can use this value to determine high volumes of activity for your application.
Maximum
All values submitted for the matching metric added together. Useful for determining the total volume of a metric.
Sum
The value of Sum / SampleCount during the specified period. By comparing this statistic with the Minimum and Maximum, you can determine the full scope of a metric and how close the average use is to the Minimum and Maximum. This comparison helps you to know when to increase or decrease your resources as needed.
Average
The count (number) of data points used for the statistical calculation.
SampleCount
The value of the specified percentile. You can specify any percentile, using up to two decimal places (for example, p95.45). Percentile statistics are not available for metrics that include any negative values.
pNN.NN
indicates the relative standing of a value in a dataset. They help you get a better understanding of the distribution of your metric data.
Percentiles
watches a single metric over a specified time period, and performs one or more specified actions, based on the value of the metric relative to a threshold over time.
Alarms