CloudWatch Flashcards
1
Q
CloudWatch EC2 Detailed Monitoring
A
- Metrics every 5 minutes
- Detailed monitoring every 1 minute
- EC2 memory usage is by default not pushed
- Must be pushed with a custom metric
2
Q
CloudWatch Custom Metrics
A
- use dimensions (attributes) to segment metrics
- instance.id
- environment.name
Metric Resolution:
- standard: 1 minute - High Resolution: up to 1 second (StorateResolution API Parameter) - Higher Cost
- Use API call PutMetricData
- use exponential back off in case of throttle errors
3
Q
CloudWatch Alarms
A
- trigger notifications for any metric
- can go to Auto Scaling, EC2 Actions, SNS notification
- various options (sampling, %, max,min)
4
Q
CloudWatch Alarms: States
A
- OK
- INSUFFICIENT_DATA
- ALARM
5
Q
CloudWatch Alarms: Period
A
- Length of time in seconds to evaluate a metric
- High Resolution custom metrics: can only choose 10 sec or 30 sec.
6
Q
CloudWatch Logs
A
- Can send logs using the SDK
- can collect from Beanstalk, EC2, VPC, API GW… etc.
- Logs can go to:
- batch exporter to S3 for archival
- stream to ElasticSearch cluster for further analytics
7
Q
CloudWatch Events
A
- schedule corn jobs
- event patterns: event rules to react to a service something
- codePipeline state changes
- trigger to lambda functions
- creates a small Jason document to give information of the change
8
Q
Amazon EventBridge
A
- EventBridge is the next evolution of CloudWatch Events
- Default Event Bus: generated by AWS services
- Partner Even Bus: receive events from other SaaS services or application
- Custom Even Bus: from your own applications
- cross account even buses can be access
- rules for event buses
9
Q
CloudWatch: Log Expiration Polices
A
By default, logs are key kept indefinitely and never expire.
- Retention between 1 day to ten years