CloudWatch Agent

Overview

The unified CloudWatch agent collects metrics, logs, and traces from Amazon EC2 instances, on-premises servers, and applications to provide centralized observability. It helps monitor system health across different environments and supports both cloud and hybrid infrastructures.

Key Features:

  1. System-Level Metrics:

    • Collects in-guest and system metrics from EC2 instances (across OS types) and on-premises servers.

    • Monitors both AWS-managed and non-AWS servers in hybrid environments.

  2. Custom Metrics Support:

    • Retrieves custom metrics using StatsD and collectd protocols.

    • StatsD supports Linux and Windows; collectd is Linux-only.

  3. Log Collection:

    • Gathers logs from EC2 and on-premises servers running Linux or Windows.

    • Logs are processed and stored in Amazon CloudWatch Logs.

  4. Traces Collection:

    • Supports collecting traces from OpenTelemetry and AWS X-Ray SDKs to streamline trace collection without separate daemons.

  5. Metrics & Logs Management:

    • Collected metrics are stored under the CWAgent namespace (customizable).

    • Logs are encrypted, archived, and billed as custom metrics.

  6. Application Signals:

    • Newer versions support CloudWatch Application Signals to enhance observability.

  7. Open-Source and Customization:

    • The agent is open-source under the MIT license and hosted on GitHub.

    • Users can build and customize the agent.

Supported Operating Systems:

  • x86-64 Architecture: Amazon Linux, Ubuntu, RHEL, CentOS, Debian, SUSE, Oracle Linux, AlmaLinux, Rocky Linux, Windows Server, Windows 10, macOS (Sonoma, Ventura, Monterey).

  • ARM64 Architecture: Amazon Linux, Ubuntu, RHEL, CentOS, Debian, SUSE, macOS (Sonoma, Ventura, Monterey).

Installation Process Overview:

  1. Set Up IAM Roles/Users: Create roles or users to allow the agent to collect data and integrate with AWS Systems Manager (SSM).

  2. Download the Agent: Use the command line or integrate with SSM for installation.

  3. Configure the Agent: Modify the CloudWatch agent configuration file to specify the metrics and logs to collect.

  4. Install and Start the Agent:

    • Attach the IAM role to EC2 instances.

    • For on-premises servers, use an IAM profile with user credentials.

Last updated