mirror of
https://github.com/rancher/rancher-docs.git
synced 2026-09-25 04:28:15 +00:00
adding in Bill's answers to Denise's questions
This commit is contained in:
@@ -5,15 +5,42 @@ aliases:
|
||||
- /rancher/v2.x/en/tasks/logging/
|
||||
---
|
||||
|
||||
To record cluster or project events, Rancher can integrate with a variety of popular logging services that exist outside of your clusters. Configuring logging services:
|
||||
Rancher can integrate with a variety of popular logging services and tools that exist outside of your Kubernetes clusters.
|
||||
|
||||
- Alerts you to errors and warnings in your Kubernetes infrastructure in a live stream.
|
||||
- Allows you to view data reports using your logging service's tools and identify trends in your clusters or projects.
|
||||
Rancher supports the following services:
|
||||
|
||||
Rancher supports the following logging services:
|
||||
|
||||
- [Embedded Elasticsearch]({{< baseurl >}}/rancher/v2.x/en/tools/logging/embedded-elasticsearch)
|
||||
- [Elasticsearch]({{< baseurl >}}/rancher/v2.x/en/tools/logging/elasticsearch)
|
||||
- [Splunk]({{< baseurl >}}/rancher/v2.x/en/tools/logging/splunk)
|
||||
- [Kafka]({{< baseurl >}}/rancher/v2.x/en/tools/logging/kafka)
|
||||
- [Syslog]({{< baseurl >}}/rancher/v2.x/en/tools/logging/syslog)
|
||||
- [Syslog]({{< baseurl >}}/rancher/v2.x/en/tools/logging/syslog)
|
||||
|
||||
## Advantages
|
||||
|
||||
Setting up a logging service to collect logs from your cluster/project is helpful several ways:
|
||||
|
||||
- Logs errors and warnings in your Kubernetes infrastructure to a stream. The stream informs you of events like a container crashing, a pod eviction, or a node dying.
|
||||
- Allows you to capture and analyze the state of your cluster and look for trends in your environment using the log stream.
|
||||
- Helps you when troubleshooting or debugging.
|
||||
- Saves your logs to a safe location outside of your cluster, so that you can still access them even if your cluster encounters issues.
|
||||
|
||||
## Logging Scope
|
||||
|
||||
You can configure logging at either cluster or project level.
|
||||
|
||||
- If you're a [cluster owner or member]({{< baseurl >}}/rancher/v2.x/en/admin-settings/rbac/cluster-project-roles/#cluster-roles) who works in operations or security, configure cluster logging.
|
||||
- If you're a [project owner or member]({{< baseurl >}}/rancher/v2.x/en/admin-settings/rbac/cluster-project-roles/#project-roles) who works on an application, configure project logging.
|
||||
|
||||
>**Note:** You can only configure one logging service per cluster or project.
|
||||
|
||||
## Collected Logs
|
||||
|
||||
After you configure a logging service for a cluster or project, it collects logs from the following locations of your nodes:
|
||||
|
||||
- The `/var/log/containers` path for application-level logging.
|
||||
- The `/var/lib/rancher/rke/logs/` path for Kubernetes system components.
|
||||
|
||||
After collection, all logs are stored by your logging service. Log into your service to view them.
|
||||
|
||||
## Related Links
|
||||
|
||||
[Logging Architecture](https://kubernetes.io/docs/concepts/cluster-administration/logging/)
|
||||
@@ -3,7 +3,7 @@ title: Elasticsearch
|
||||
weight: 200
|
||||
---
|
||||
|
||||
If your organization uses [Elasticsearch](https://www.elastic.co/), either on premise or in the cloud, you can configure it to log events from your cluster. Afterwards, you can log into your Elasticsearch deployment to view logs for cluster or container events.
|
||||
If your organization uses [Elasticsearch](https://www.elastic.co/), either on premise or in the cloud, you can configure it to log Kubernetes events. Afterwards, you can log into your Elasticsearch deployment to view logs for cluster or container events.
|
||||
|
||||
## Configuring Elasticsearch Logging
|
||||
|
||||
@@ -13,11 +13,15 @@ You can configure Elasticsearch to log events at both the cluster and project le
|
||||
|
||||
1. Browse to the cluster or project that you want to log.
|
||||
{{% accordion id="cluster" label="To Configure Cluster Logging:" %}}
|
||||
If you're a [cluster owner or member]({{< baseurl >}}/rancher/v2.x/en/admin-settings/rbac/cluster-project-roles/#cluster-roles) who works in operations or security, configure cluster logging.
|
||||
|
||||
1. From the **Global** view, open the cluster that you want to configure logging for.
|
||||
|
||||
1. From the main menu, select **Tools > Logging**.
|
||||
{{% /accordion %}}
|
||||
{{% accordion id="project" label="To Configure Project Logging:" %}}
|
||||
If you're a [project owner or member]({{< baseurl >}}/rancher/v2.x/en/admin-settings/rbac/cluster-project-roles/#project-roles) who works on an application, configure project logging.
|
||||
|
||||
1. From the **Global** view, open the project that you want to configure logging for.
|
||||
|
||||
1. From the main menu, select **Resources > Logging**.
|
||||
|
||||
@@ -1,43 +0,0 @@
|
||||
---
|
||||
title: Embedded Elasticsearch
|
||||
weight: 100
|
||||
---
|
||||
|
||||
If your organization doesn't have any logging solutions, you can use Rancher's Embedded Elasticsearch option to log records from your cluster. This option sets up an instance of [Elasticsearch](https://www.elastic.co/) within your cluster, and then uses cluster resources to run it.
|
||||
|
||||
>**Notes:**
|
||||
>
|
||||
>- Embedded Elasticsearch is experimental at this time. Therefore, persistent storage for Embedded Elasticsearch is unavailable. We plan to offer full support in a Rancher release that's yet to be determined.
|
||||
>- Embedded Elasticsearch is only available for clusters and not projects.
|
||||
>- Setting up Embedded Elasticsearch requires a well provisioned node within the cluster. See the prerequisites below for more details.
|
||||
|
||||
## Configuring Embedded Elasticsearch Logging
|
||||
|
||||
>**Prerequisites:** Your cluster must meet the following hardware requirements:
|
||||
>
|
||||
>- At least 1 dedicated CPU (2 or more in total).
|
||||
>- At least 512 MB RAM.
|
||||
|
||||
1. From the **Global** view, open the cluster that you want to configure logging for.
|
||||
|
||||
1. From the main menu, select **Tools > Logging**.
|
||||
|
||||
1. Select **Embedded Elasticsearch**.
|
||||
|
||||
1. Complete the **Embedded Elasticsearch Configuration** form.
|
||||
|
||||
1. From **CPUs and Memory**, set the CPU and memory that Elasticsearch can access within your cluster for logging. CPU and memory must meet the prerequisites above.
|
||||
|
||||
1. Enter an [Index Pattern](https://www.elastic.co/guide/en/kibana/current/index-patterns.html).
|
||||
|
||||
1. Complete the **Additional Logging Configuration** form.
|
||||
|
||||
1. Use the **Add Field** button to add key value pairs that represent [custom log fields](http://docs.splunk.com/Documentation/AddOns/released/CiscoWSA/Configurew3clogfieldextractions) used to filter log events.
|
||||
|
||||
1. Enter a **Flush Interval**. This value determines how often the buffered logs are flushed.
|
||||
|
||||
1. Click **Save**.
|
||||
|
||||
**Result:** Rancher is now configured to send cluster and container events to Embedded Elasticsearch for logging.
|
||||
|
||||
You can view your logs by clicking the **Elasticsearch Endpoint** and **Kibana Endpoint** links available on the **Cluster Logging** page, which should be the page you're viewing now.
|
||||
@@ -3,21 +3,23 @@ title: Kafka
|
||||
weight: 400
|
||||
---
|
||||
|
||||
You can configure a [Kafka](https://kafka.apache.org/) to log events that occur in your Kubernetes cluster.
|
||||
You can configure a [Kafka](https://kafka.apache.org/) to log events that occur in your Kubernetes cluster at both the cluster and project level.
|
||||
|
||||
## Configuring Kafka Logging
|
||||
|
||||
You can configure Kafka to log events at both the cluster and project level.
|
||||
|
||||
>**Prerequisite:** You must have a Kafka server configured.
|
||||
|
||||
1. Browse to the cluster or project that you want to log.
|
||||
{{% accordion id="cluster" label="To Configure Cluster Logging:" %}}
|
||||
If you're a [cluster owner or member]({{< baseurl >}}/rancher/v2.x/en/admin-settings/rbac/cluster-project-roles/#cluster-roles) who works in operations or security, configure cluster logging.
|
||||
|
||||
1. From the **Global** view, open the cluster that you want to configure logging for.
|
||||
|
||||
1. From the main menu, select **Tools > Logging**.
|
||||
{{% /accordion %}}
|
||||
{{% accordion id="project" label="To Configure Project Logging:" %}}
|
||||
If you're a [project owner or member]({{< baseurl >}}/rancher/v2.x/en/admin-settings/rbac/cluster-project-roles/#project-roles) who works on an application, configure project logging.
|
||||
|
||||
1. From the **Global** view, open the project that you want to configure logging for.
|
||||
|
||||
1. From the main menu, select **Resources > Logging**.
|
||||
|
||||
@@ -20,11 +20,15 @@ You can configure Splunk to log events at both the cluster and project level.
|
||||
|
||||
1. Browse to the cluster or project that you want to log.
|
||||
{{% accordion id="cluster" label="To Configure Cluster Logging:" %}}
|
||||
If you're a [cluster owner or member]({{< baseurl >}}/rancher/v2.x/en/admin-settings/rbac/cluster-project-roles/#cluster-roles) who works in operations or security, configure cluster logging.
|
||||
|
||||
1. From the **Global** view, open the cluster that you want to configure logging for.
|
||||
|
||||
1. From the main menu, select **Tools > Logging**.
|
||||
{{% /accordion %}}
|
||||
{{% accordion id="project" label="To Configure Project Logging:" %}}
|
||||
If you're a [project owner or member]({{< baseurl >}}/rancher/v2.x/en/admin-settings/rbac/cluster-project-roles/#project-roles) who works on an application, configure project logging.
|
||||
|
||||
1. From the **Global** view, open the project that you want to configure logging for.
|
||||
|
||||
1. From the main menu, select **Resources > Logging**.
|
||||
|
||||
@@ -13,12 +13,15 @@ You can configure Syslog to log events at both the cluster level and the project
|
||||
|
||||
1. Browse to the cluster or project that you want to log.
|
||||
{{% accordion id="cluster" label="To Configure Cluster Logging:" %}}
|
||||
If you're a [cluster owner or member]({{< baseurl >}}/rancher/v2.x/en/admin-settings/rbac/cluster-project-roles/#cluster-roles) who works in operations or security, configure cluster logging.
|
||||
|
||||
1. From the **Global** view, open the cluster that you want to configure logging for.
|
||||
|
||||
1. From the main menu, select **Tools > Logging**.
|
||||
|
||||
{{% /accordion %}}
|
||||
{{% accordion id="project" label="To Configure Project Logging:" %}}
|
||||
If you're a [project owner or member]({{< baseurl >}}/rancher/v2.x/en/admin-settings/rbac/cluster-project-roles/#project-roles) who works on an application, configure project logging.
|
||||
|
||||
1. From the **Global** view, open the project that you want to configure logging for.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user