# AWS CloudWatch Logs

Log groups through a Firehose stream.

Logs Available

[Open the Connect card in Epok](https://app.epok.cloud/#/connect?source=aws) [Full setup guide](https://epok.cloud/docs/running-on-aws#firehose)

## What you get

Logs, arriving through Subscription filter and Amazon Data Firehose.

## Set it up

1. Create an ingest key in Epok: Settings, then API keys.
2. Download aws-logs.sh from the setup page, read it, and run it with your log groups (or --dry-run first to print every command).
3. The CloudFormation stack adds a subscription filter per log group, a Firehose stream to Epok and an S3 bucket for anything Firehose cannot deliver.
4. Run the data-arrived check from the setup page, then search for the log groups in Explore.

The commands and configuration for each step are on the [setup guide](https://epok.cloud/docs/running-on-aws#firehose).

## What was tested

- The published setup, run against a local copy of Epok's ingest stack: 1 run.
- End to end with real cloud resources, sending to a local Epok stack rather than the hosted service: 1 run.
- Code tests of the ingest route or the sender: 2 tests.
- No run against the hosted service is recorded yet.

## What you see in Epok

- Explore and Live tail: search, patterns and new errors.

## Troubleshooting

- No data: the stack's delivery-error log group shows Epok's answer. 401 or 403 means the key is wrong or lacks the ingest scope.
- A 413 means the Firehose buffer is too large: keep it at 4 MB or less.
- CloudWatch allows 2 subscription filters per log group; a third makes the stack fail.

## More in Cloud & Kubernetes

[Container logs](https://epok.cloud/integrations/k8s-container-logs) [Kubernetes events](https://epok.cloud/integrations/k8s-events) [Node, pod and cluster metrics](https://epok.cloud/integrations/k8s-metrics) [Traces from your pods](https://epok.cloud/integrations/k8s-traces) [EC2](https://epok.cloud/integrations/aws-ec2) [CloudWatch metrics](https://epok.cloud/integrations/aws-cloudwatch-metrics) [Lambda](https://epok.cloud/integrations/aws-lambda) [ECS on Fargate](https://epok.cloud/integrations/aws-ecs-fargate) [Compute Engine](https://epok.cloud/integrations/gcp-compute-engine) [Cloud Logging](https://epok.cloud/integrations/gcp-cloud-logging) [Cloud Run](https://epok.cloud/integrations/gcp-cloud-run)
