Skip to main content
Version: 3.10

Multitenant Logging

Get acquainted with the multitenant logging components.

Logging Components​

To configure the multitenant logging, it is necessary to deploy the following components:

In Grafana, every tenant represents an organization, i.e. it is necessary to create an organization for every namespace in the cluster. To get more details regarding the architecture of the Logging Operator, review the Diagram below.

Logging operator scheme

note

It is necessary to deploy Loki with the auth_enabled: true flag with the aim to ensure that the logs are separated for each tenant. For the authentication, Loki requires the HTTP header X-Scope-OrgID.

Review Project Logs in Grafana​

To find the project logs, navigate to Grafana and follow the steps below:

note

Grafana is a common service for different customers where each customer works in its own separated Grafana Organization and doesn't have any access to another project.

  1. Choose the organization by clicking the Current Organization drop-down list. If a user is assigned to several organizations, switch easily by using the Switch button:

    Current organization

  2. Navigate to the left-side menu and click the Explore button to see the Log Browser:

    Grafana explore

  3. Click the Log Browser button to see the labels that can be used to filter logs (e.g., hostname, namespace, application name, pod, etc.):

    note

    Enable the correct data source, select the relevant logging data from the top left-side corner, and pay attention that the data source name always follows the project_name-logging pattern.

    Log browser

  4. Filter out logs by clicking the Show logs button or write the query and click the Run query button.

  5. Review the results with the quantity of logs per time, see the example below:

    Logs example

    • Expand the logs to get detailed information about the object entry:

      Expand logs

    • Use the following buttons to include or remove the labels from the query:

      Addition button

    • See the ad-hoc statistics for a particular label:

      Ad-hoc stat example