What Are Amazon CloudWatch, Amazon CloudWatch Events, and Amazon CloudWatch Logs?
Amazon CloudWatch monitors your Amazon Web Services (AWS) resources and the applications you run on AWS in real-time. You can use CloudWatch to collect and track metrics, which are the variables you want to measure for your resources and applications. CloudWatch alarms send notifications or automatically make changes to the resources you are monitoring based on rules that you define. For example, you can monitor the CPU usage and disk reads and writes of your Amazon Elastic Compute Cloud (Amazon EC2) instances and then use this data to determine whether you should launch additional instances to handle increased load. You can also use this data to stop under-used instances to save money. In addition to monitoring the built-in metrics that come with AWS, you can monitor your own custom metrics. With CloudWatch, you gain system-wide visibility into resource utilization, application performance, and operational health.
You can use Amazon CloudWatch Events to deliver a timely stream of system events that describe changes in AWS resources to AWS Lambda functions, Amazon SNS topics, Amazon SQS queues, streams in Amazon Kinesis Streams, or built-in targets. Using simple rules that you can set up quickly, you can match events and route them to one or more target functions or streams. CloudWatch Events becomes aware of operational changes as they happen and takes action, sending messages to respond to the environment and activating functions, making changes, capturing state information, and taking corrective action. For more information, see Using CloudWatch Events.
You can use Amazon CloudWatch Logs to monitor, store, and access your log files from Amazon EC2 instances, AWS CloudTrail, or other sources. You can then retrieve the associated log data from CloudWatch Logs using the Amazon CloudWatch console, the CloudWatch Logs commands in the AWS CLI, the CloudWatch Logs API, or the CloudWatch Logs SDK. For more information about CloudWatch Logs see Monitoring Log Files.
The rest of this section introduces the key concepts and terms that will help you understand what you need to do to monitor your resources and applications.
The Getting Set Up with CloudWatch section walks you through the process of signing up for AWS and setting up the CloudWatch command-line interface (CLI). The Getting Started with CloudWatch section walks you through the process of publishing metrics, getting statistics, and setting alarms.