# Centralizing Logs Across Kubernetes, AWS and On-Prem Servers

> A beginner-friendly, step-by-step guide to centralizing logs from Kubernetes clusters, AWS services, and on-prem servers: which collector to run where, how to label logs consistently, how to secure the network path, and how to see EKS, GKE, and AKS in one view.

Source: https://openobserve.ai/blog/centralize-logs-kubernetes-aws-on-prem/
Published: 2026-11-30
Authors: Simran Kumari
Category: Engineering
Tags: OpenObserve, Logging, Kubernetes, AWS, OpenTelemetry, Infrastructure

---

**Centralizing logs across Kubernetes, AWS, and on-prem servers** means running the right collector in each environment, tagging every log with where it came from, and sending everything to one platform you can search in one place. The hard part isn't the agents; it's consistent labels, safe network paths, and access control.

## TL;DR

- Run one collector per environment: the OpenObserve Collector Helm chart in every Kubernetes cluster, Kinesis Data Firehose for AWS service logs, the OpenObserve Collector on Linux and Windows servers, and a syslog forwarder for network devices.
- Agree on one label scheme before you onboard anything, so a single query can filter by environment, cloud, region, cluster, service, and host.
- Send everything outbound over HTTPS with separate credentials per environment, and use a gateway collector where servers have no internet access.
- Give every Kubernetes cluster a unique `k8sCluster` name, and OpenObserve shows EKS, GKE, AKS, and on-prem clusters side by side in one Kubernetes view.
- OpenObserve is the platform we recommend for this, because it ingests from all of these sources and lets you search every environment with one SQL query.

## What is centralized logging?

Centralized logging is the practice of collecting logs from every place they're written (containers, servers, cloud services, firewalls, switches) and storing them in one searchable platform. Our [log management guide](/blog/what-is-log-management/) covers the full lifecycle, and the [log aggregation glossary entry](/glossary/what-is-log-aggregation/) explains the collection step on its own.

If you're new to this, a few terms come up throughout the guide:

| Term | What it means |
|---|---|
| **Collector** (or agent) | A small program that runs next to your workloads, reads their logs, and forwards them. Examples: the OpenTelemetry Collector, Fluent Bit, Vector. |
| **OTLP** | The [OpenTelemetry Protocol](/glossary/what-is-otlp/), a standard format for sending logs, metrics, and traces over HTTP or gRPC. |
| **Gateway collector** | A collector that receives logs from other collectors in the same network and forwards them, so only one machine needs internet access. |
| **Stream** | In OpenObserve, a named collection of logs of the same kind, similar to an index or table. |
| **Label** (or field) | A key-value pair attached to every log line, such as `environment=prod`, that lets you filter. |

### Why centralize logs from Kubernetes, AWS, and on-prem servers?

Picture a checkout failure. The frontend runs on EKS, the payment service runs on an on-prem VM in your data center, and the database sits behind an AWS Network Firewall. Without centralized logs, the on-call engineer opens three tools, learns three query languages, and lines up timestamps by hand. With centralized logs, one search for the order ID returns the failed request across all three environments, ordered by time.

Centralizing also gives you:

- **One retention and access policy** instead of one per tool, which matters for audits.
- **Cross-environment alerts,** such as "error rate above 5% in any region", written once.
- **Lower operating effort,** because you run and upgrade one log platform instead of several.

## What does a hybrid log architecture look like?

A hybrid log architecture has three layers. Each environment gets its own collection method, but they all meet at one destination.

1. **Collection:** an agent in each environment that reads logs where they're written.
2. **Transport:** an authenticated, encrypted path from each environment to the backend, sometimes through a gateway collector that buffers and batches.
3. **Storage and query:** one backend where every log is searchable with the same query language and labels.

<div class="not-prose my-8" style="overflow-x:auto">
<svg viewBox="0 0 960 440" xmlns="http://www.w3.org/2000/svg" role="img" aria-labelledby="hybT hybD" style="width:100%;min-width:680px;height:auto;font-family:Inter,system-ui,sans-serif">
<title id="hybT">Hybrid log architecture for Kubernetes, AWS, and on-prem servers</title>
<desc id="hybD">Three environments on the left each send logs to OpenObserve on the right. Kubernetes clusters on EKS, GKE, AKS, or on-prem run the OpenObserve Collector Helm chart and send OTLP over HTTPS. AWS services such as CloudWatch Logs, VPC Flow Logs, WAF, and Network Firewall send logs through Kinesis Data Firehose to an HTTP endpoint. On-prem Linux and Windows servers run the OpenObserve Collector, and network devices send syslog to a forwarder such as syslog-ng; both can go through a gateway collector that is the only machine with internet access. In OpenObserve, every log carries the same labels and can be searched, charted, alerted on, and viewed per cluster in the Kubernetes explorer.</desc>
<defs><marker id="hybA" viewBox="0 0 10 10" refX="9" refY="5" markerWidth="7" markerHeight="7" orient="auto"><path d="M0,0 L10,5 L0,10 z" fill="#4b5563"/></marker></defs>
<g font-size="13" fill="#1f2937">
<rect x="10" y="10" width="560" height="120" rx="12" fill="#eff6ff" stroke="#3b82f6"/>
<text x="26" y="34" font-size="15" font-weight="700" fill="#1d4ed8">Kubernetes clusters</text>
<text x="26" y="56">EKS · GKE · AKS · on-prem</text>
<rect x="300" y="44" width="250" height="64" rx="8" fill="#ffffff" stroke="#3b82f6"/>
<text x="425" y="70" text-anchor="middle" font-weight="600">OpenObserve Collector</text>
<text x="425" y="90" text-anchor="middle">Helm chart, k8sCluster=&lt;name&gt;</text>
<line x1="200" y1="76" x2="296" y2="76" stroke="#4b5563" stroke-width="2" marker-end="url(#hybA)"/>
<text x="26" y="100" fill="#4b5563">container logs, events,</text>
<text x="26" y="118" fill="#4b5563">metrics, traces</text>

<rect x="10" y="150" width="560" height="120" rx="12" fill="#fff7ed" stroke="#f97316"/>
<text x="26" y="174" font-size="15" font-weight="700" fill="#c2410c">AWS</text>
<text x="26" y="196">CloudWatch Logs (subscription filter)</text>
<text x="26" y="216">VPC Flow Logs · WAF · Network Firewall</text>
<text x="26" y="236">EC2 and EKS: use the collector</text>
<rect x="300" y="184" width="250" height="64" rx="8" fill="#ffffff" stroke="#f97316"/>
<text x="425" y="210" text-anchor="middle" font-weight="600">Kinesis Data Firehose</text>
<text x="425" y="230" text-anchor="middle">HTTP endpoint destination</text>
<line x1="270" y1="216" x2="296" y2="216" stroke="#4b5563" stroke-width="2" marker-end="url(#hybA)"/>

<rect x="10" y="290" width="560" height="140" rx="12" fill="#f0fdf4" stroke="#16a34a"/>
<text x="26" y="314" font-size="15" font-weight="700" fill="#15803d">On-prem data center</text>
<text x="26" y="338">Linux and Windows servers</text>
<text x="26" y="356" fill="#4b5563">OpenObserve Collector</text>
<text x="26" y="384">Firewalls, switches, appliances</text>
<text x="26" y="402" fill="#4b5563">syslog → syslog-ng / Fluent Bit / Vector</text>
<rect x="300" y="328" width="250" height="64" rx="8" fill="#ffffff" stroke="#16a34a"/>
<text x="425" y="354" text-anchor="middle" font-weight="600">Gateway collector</text>
<text x="425" y="374" text-anchor="middle">optional, the only box with egress</text>
<line x1="250" y1="352" x2="296" y2="352" stroke="#4b5563" stroke-width="2" marker-end="url(#hybA)"/>
<line x1="290" y1="396" x2="300" y2="380" stroke="#4b5563" stroke-width="2" marker-end="url(#hybA)"/>
</g>
<g font-size="12" fill="#4b5563" font-weight="600">
<line x1="550" y1="76" x2="700" y2="190" stroke="#4b5563" stroke-width="2" marker-end="url(#hybA)"/>
<line x1="550" y1="216" x2="700" y2="216" stroke="#4b5563" stroke-width="2" marker-end="url(#hybA)"/>
<line x1="550" y1="360" x2="700" y2="244" stroke="#4b5563" stroke-width="2" marker-end="url(#hybA)"/>
<text x="585" y="120">OTLP / HTTPS</text>
<text x="590" y="208">HTTPS</text>
<text x="585" y="320">OTLP / HTTPS</text>
</g>
<g font-size="13" fill="#1f2937">
<rect x="704" y="120" width="246" height="200" rx="14" fill="#ede9fe" stroke="#7c3aed" stroke-width="2"/>
<text x="827" y="150" text-anchor="middle" font-size="16" font-weight="700" fill="#5b21b6">OpenObserve</text>
<text x="827" y="172" text-anchor="middle">one organization, one label scheme</text>
<text x="724" y="204">• SQL search across all environments</text>
<text x="724" y="228">• Dashboards per environment</text>
<text x="724" y="252">• Alerts written once</text>
<text x="724" y="276">• Kubernetes explorer: every cluster</text>
<text x="724" y="300">• Retention and RBAC per stream</text>
</g>
</svg>
</div>

### Which log collector should you run in each environment?

Here's which collector fits each source when the destination is OpenObserve. If you already run Fluent Bit, Vector, or another agent, you can keep it; our [telemetry agents comparison](/blog/best-telemetry-agents/) covers the trade-offs.

| Source | Collector | How it reaches OpenObserve |
|---|---|---|
| Kubernetes (EKS, GKE, AKS, on-prem) | OpenObserve Collector Helm chart, based on the OpenTelemetry Collector | OTLP over HTTPS |
| CloudWatch Logs | Subscription filter to Kinesis Data Firehose | Firehose HTTP endpoint |
| VPC Flow Logs, AWS WAF, AWS Network Firewall | Kinesis Data Firehose | Firehose HTTP endpoint |
| EC2 and on-prem Linux servers | OpenObserve Collector for Linux | OTLP over HTTPS |
| Windows servers | OpenObserve Collector for Windows | OTLP over HTTPS |
| Network devices and appliances (syslog) | syslog-ng / AxoSyslog, OTel Collector, Fluent Bit, or Vector | HTTP or OTLP |
| Existing Fluent Bit, Fluentd, Vector, Filebeat, or Splunk forwarders | Keep them | HTTP outputs or the Splunk HEC endpoint |

Every option is in the [log ingestion docs](https://openobserve.ai/docs/ingestion/logs/).

## How to centralize logs across Kubernetes, AWS, and on-prem: step by step

The steps below take you from zero to one searchable view of every environment. Do them in order: deciding on labels first saves you from renaming fields across hundreds of machines later.

### Step 1: Plan a consistent log labeling scheme

Collecting logs is the easy part. Making them searchable together depends on every environment using the same field names. Agree on these before onboarding the first environment:

| Field | Example values | Set where |
|---|---|---|
| `environment` | `prod`, `staging` | Collector configuration |
| `cloud_provider` | `aws`, `gcp`, `azure`, `on_prem` | Collector configuration |
| `region` | `us-east-1`, `europe-west1`, `dc-frankfurt` | Collector configuration |
| `k8s_cluster` | `prod-us-east-1` | Helm `k8sCluster` value |
| `service_name` | `checkout` | Application or OpenTelemetry resource attributes |
| `host_name` | `web-1` | Collected automatically |

In any OpenTelemetry Collector, the `resource` processor adds these fields to every log it forwards. Add it to the collector's `processors` and to its logs pipeline:

```yaml
processors:
  resource/labels:
    attributes:
      - key: environment
        value: prod
        action: upsert
      - key: cloud_provider
        value: on_prem
        action: upsert
      - key: region
        value: dc-frankfurt
        action: upsert
```

If older agents already send different names (`env` instead of `environment`, for example), use OpenObserve pipelines to rename them into the shared scheme at ingestion.

### Step 2: Collect Kubernetes logs from EKS, GKE, AKS, and on-prem clusters

Install the OpenObserve Collector in every cluster, whether it runs on EKS, GKE, AKS, or your own hardware. The Helm chart sends container logs, Kubernetes events, metrics, and auto-instrumented traces:

```bash
kubectl create ns openobserve-collector

helm --namespace openobserve-collector \
  install o2c openobserve/openobserve-collector \
  --set k8sCluster=prod-us-east-1 \
  --set exporters."otlphttp/openobserve".endpoint=<O2_ENDPOINT>/api/<O2_ORG> \
  --set exporters."otlphttp/openobserve".headers.Authorization="Basic <BASE64_AUTH>" \
  --set exporters."otlphttp/openobserve_k8s_events".endpoint=<O2_ENDPOINT>/api/<O2_ORG> \
  --set exporters."otlphttp/openobserve_k8s_events".headers.Authorization="Basic <BASE64_AUTH>"
```

The `k8sCluster` value is what makes multi-cluster monitoring work: the chart adds it to every log and event as the `k8s_cluster` field. Give every cluster a unique, descriptive name, such as `prod-us-east-1` or `prod-gke-europe-west1`. The **Data Sources** page in OpenObserve generates this command with your endpoint and credentials filled in.

The [Kubernetes integration docs](https://openobserve.ai/docs/integration/system/k8s/) cover each step. For platform-specific walkthroughs, see our [AKS setup guide](/blog/monitor-azure-kubernetes-aks-openobserve-setup/) and [on-prem Kubernetes monitoring guide](/blog/on-premise-kubernetes-monitoring/).

### Step 3: Send AWS logs from CloudWatch, VPC Flow Logs, and WAF

AWS services write logs in different places, so use the shortest path for each:

- **CloudWatch Logs:** add a subscription filter that sends each log group to a Kinesis Data Firehose stream with OpenObserve's HTTP endpoint as its destination. **Data > Data sources > Custom > Logs > Kinesis Firehose** shows the endpoint and access key. Our [CloudWatch to Firehose tutorial](/blog/how-to-send-aws-cloudwatch-logs-to-kinesis-firehose/) shows every console step.
- **VPC Flow Logs, AWS WAF, and AWS Network Firewall:** deliver these to Firehose directly, so they skip CloudWatch Logs ingestion entirely. See [how to monitor AWS WAF logs](/blog/how-to-monitor-aws-waf-logs/) for a worked example.
- **EC2 instances:** run the OpenObserve Collector for Linux on the instance, the same as on-prem servers; see our guide to [monitoring EC2 logs and metrics with OpenTelemetry](/blog/monitor-aws-ec2-logs-metrics-opentelemetry/).
- **EKS:** treat it like any other Kubernetes cluster with the Helm chart from Step 2.

### Step 4: Collect logs from on-prem Linux and Windows servers

- **Linux servers:** the OpenObserve Collector collects system logs (syslog and journald) and host metrics such as CPU, memory, disk, and network. If you're unsure which Linux log source to read, [journald vs syslog](/blog/journald-vs-syslog/) explains the difference.
- **Windows servers:** the OpenObserve Collector for Windows collects Windows event logs and metrics.

Both installers are in **Data Sources**, with your endpoint and credentials already filled in. See the [Linux](https://openobserve.ai/docs/integration/system/linux/) and [Windows](https://openobserve.ai/docs/integration/system/windows/) integration docs.

### Step 5: Forward syslog from network devices and appliances

Firewalls, switches, and storage appliances usually only speak syslog. OpenObserve doesn't run its own syslog server (it was removed in v0.16.0), so run a receiver next to the devices and point them at it:

- **syslog-ng or AxoSyslog** with its built-in OpenObserve destination. Our [syslog-ng log forwarding guide](/blog/syslog-ng-log-forwarding/) shows a working configuration.
- **The OpenTelemetry Collector's** `syslog` receiver.
- **Fluent Bit's** `syslog` input or **Vector's** `syslog` source.

Run the receiver on a machine in the same network as the devices, so syslog (which is often unencrypted) never crosses the internet.

### Step 6: Verify logs arrived and search across every environment

Open **Logs** in OpenObserve, pick a stream, and set the time range to the last 15 minutes. You should see recent lines from each source. To confirm every environment is reporting, count logs by your labels with SQL:

```sql
SELECT environment, cloud_provider, k8s_cluster, COUNT(*) AS log_lines
FROM "default"
GROUP BY environment, cloud_provider, k8s_cluster
ORDER BY log_lines DESC
```

Replace `default` with your stream's name. A missing row means that environment isn't sending yet, or is sending with different field names. Once every row is there, the same filter works for incidents, for example `WHERE k8s_cluster = 'prod-us-east-1' AND body LIKE '%timeout%'`.

![OpenObserve Logs explorer running a SQL query on Kubernetes logs, with Kubernetes fields such as cluster name and deployment name in the sidebar and log patterns grouped by frequency](/assets/platform/logs/powerful-search.png)

## How to secure log collection across hybrid environments

Centralizing logs means opening paths out of every environment and putting many teams' data in one place. Plan the network path and the access model before you onboard.

### Network paths: egress over HTTPS and gateway collectors

- **Egress over HTTPS only.** Every collector sends to one HTTPS endpoint, so on-prem firewalls need one outbound rule per site, not inbound access.
- **Gateway collectors for restricted networks.** Where servers can't reach the internet, run an OpenTelemetry Collector gateway in each site that receives from local agents and forwards to OpenObserve, so only the gateway needs egress.

### Credentials, redaction, and data residency

- **Separate credentials per environment,** so you can rotate or revoke one site without touching the others.
- **Redact before or at ingestion.** Mask passwords, tokens, and personal data in the collector or with OpenObserve's sensitive data redaction, before logs from many teams land in one place.
- **Data residency.** If some logs must stay in a region, use a regional OpenObserve Cloud deployment such as EU-Central 1 (Frankfurt), or self-host in that region.
- **Access per team.** Use RBAC on streams, or separate organizations for teams and tenants that must not see each other's logs.

## How to monitor EKS, GKE, and AKS clusters in one place

Once every cluster sends data with its own `k8sCluster` name, OpenObserve's **Infra › Kubernetes** explorer shows them together:

- A **clusters strip** with one tile per cluster and a health dot: **Healthy**, **Warning**, **Critical**, or **Not reporting**.
- **Search resources** (Ctrl+K or Cmd+K) across pods, workloads, nodes, and clusters.
- A **cluster overview** with node and pod readiness, warnings, capacity against requests and limits, and a **Needs attention** list with a **Logs** button for each failing pod.
- An **offline clusters** notice when a cluster stops reporting, with a link to the collector setup guide.

![OpenObserve Infra Kubernetes cluster overview showing the clusters strip, node and pod readiness, cluster capacity, a Needs attention list of failing pods with Logs buttons, and an open incident](/assets/blog/centralize-logs-kubernetes-aws-on-prem/image1.png)

The explorer is read-only, so it never changes your clusters. See the [Kubernetes Explorer docs](https://openobserve.ai/docs/user-guide/data-exploration/kubernetes/).

## Common challenges when centralizing logs (and how to fix them)

Most hybrid logging projects hit the same few problems. Here's how to spot and fix each one.

### Why is a cluster or server missing from my logs?

Check the collector's own logs first (`kubectl logs` in the `openobserve-collector` namespace, or the service logs on a server). The usual causes are a wrong endpoint or organization in the URL, an expired or mistyped credential, or a firewall blocking outbound HTTPS. For Kubernetes, the explorer's **Not reporting** state and offline clusters notice tell you which cluster stopped.

### Why can't I filter all environments with one query?

The fields don't match. One environment sends `env`, another sends `environment`, and a third sends nothing. Go back to Step 1, add the `resource` processor to every collector, and rename legacy fields with a pipeline.

### How do I keep log volume and cost under control?

Drop what you'll never search before it leaves the environment: debug logs from noisy services, health-check lines, and duplicate events. Our guide to [filtering logs at the source in the OTel Collector](/blog/filter-logs-at-source-in-otel-collector/) shows how, and [logging best practices](/blog/logging-best-practices/) covers what to log in the first place.

## Why centralize logs in OpenObserve?

OpenObserve is an open-source (AGPL-3.0) observability platform that accepts logs from every environment above, through OpenTelemetry, Firehose, syslog forwarders, and existing agents, and stores them as compressed Parquet on object storage with ingest-based pricing. Organizations, RBAC, and SSO keep each team's logs separate where they need to be.

- **Telemetry:** logs, metrics, and traces with a service graph and service catalog, plus continuous profiles.
- **Frontend monitoring:** real user monitoring (RUM), session replay, and error tracking.
- **Synthetic monitoring:** scheduled browser and protocol checks.
- **AI:** AI Assistant, SRE Agent for AI root cause analysis, an MCP server, LLM observability and evaluations, anomaly detection, log patterns, and insights.
- **Alerting and reliability:** scheduled, real-time, composite, and anomaly alerts, incident management, and SLOs with error budgets and burn rates.
- **Dashboards and reports:** real-time dashboards and scheduled PDF, PNG, or CSV reports.
- **Data processing:** pipelines, VRL functions, enrichment tables, and metrics downsampling.
- **Storage and cost:** Parquet on object storage, Bring Your Own Bucket on Cloud, extended retention, and ingest-based pricing with unlimited users.
- **Security and governance:** SSO, RBAC, multi-tenancy, sensitive data redaction, audit trail, cipher keys, and federated search.
- **Compliance:** SOC 2 Type II, ISO 27001, and GDPR via the EU-Central 1 (Frankfurt) region.
- **Open standards:** OpenTelemetry-native ingestion, PromQL and SQL querying, and open source under AGPL-3.0.

## Get started with OpenObserve

- Sign up for [OpenObserve Cloud](https://cloud.openobserve.ai) with a 14-day free trial and connect your first cluster from **Data Sources**.
- Prefer to self-host? Follow the [OpenObserve quickstart](https://openobserve.ai/docs/getting-started/).
- Already running Fluent Bit? See how to [send Kubernetes logs with Fluent Bit](/blog/how-to-send-kubernetes-logs-using-fluent-bit/).
- Comparing platforms first? Read our roundup of [log management tools](/blog/log-management-tools/).

## Frequently Asked Questions

### What is centralized logging?

Centralized logging means sending logs from every server, container, cloud service, and network device to one platform instead of leaving them where they were written. It gives you one place to search during an incident, one set of retention and access rules, and one query language across every environment.

### How do I collect logs from Kubernetes, AWS, and on-prem servers into one place?

Run the right collector in each environment and send everything to one backend over HTTPS. In OpenObserve, that means the OpenObserve Collector Helm chart in each Kubernetes cluster, Kinesis Data Firehose for CloudWatch Logs and other AWS service logs, the OpenObserve Collector on Linux and Windows servers, and syslog-ng, the OpenTelemetry Collector, Fluent Bit, or Vector for network devices that speak syslog.

### How do I monitor EKS, GKE, and AKS clusters in one place?

Install the same collector in every cluster with a unique cluster name, and send all of them to one OpenObserve organization. The OpenObserve Collector Helm chart takes a k8sCluster value that adds a k8s_cluster field to every log, metric, and event, and Infra › Kubernetes shows one tile per cluster with its health, plus cross-cluster search for pods, workloads, and nodes.

### Does OpenObserve have a built-in syslog server?

No. The built-in syslog server was removed in OpenObserve v0.16.0. Run a syslog receiver next to your devices, such as syslog-ng or AxoSyslog with its OpenObserve destination, the OpenTelemetry Collector syslog receiver, Fluent Bit, or Vector, and forward the logs to OpenObserve over HTTP or OTLP.

### How should I label logs from different environments?

Agree on a small set of fields before you onboard anything: environment, cloud provider, region, cluster, service, and host. Set them in each collector's configuration so every log line carries them, and use the same names everywhere so one query filters across all environments.

### Should I keep logs from each environment in separate streams?

Keep one stream per log type, not per environment, and separate environments with fields. Use separate streams when retention or access differs, for example a 365-day audit stream with restricted access. In OpenObserve you can also split teams or tenants into organizations, each with its own streams, users, and roles.

### Do on-prem servers need inbound firewall rules to send logs to a cloud platform?

No. Collectors push logs out over HTTPS, so each site needs one outbound rule to the log platform's endpoint and no inbound access. If servers can't reach the internet at all, run a gateway collector in the site that receives from local agents and is the only machine with egress.
