SUSE Support

Here When You Need Us

Logging integration doesn't work if Docker Root is not default /var/lib/docker

This document (000020113) is provided subject to the disclaimer at the end of this document.

Situation

Issue

As of the time of this writing, Rancher Logging is broken when the Docker root is configured to something other than /var/lib/docker.

This issue is tracked in GitHub issue #21112.

Pre-requisites

  • Rancher 2.x managed/imported cluster with logging enabled.
  • Docker root configured to something other than /var/lib/docker on the nodes (confirmed with docker info | grep Root).

Workaround

These steps will assume you have the Docker data root set to /other-docker-root. Change /other-docker-root to whatever your custom path is:

  1. Rancher UI -> Cluster -> System Project -> Workloads -> cattle-logging Namespace

  2. Find workload rancher-logging-fluentd-linux

  3. Edit YAML

  4. Edit volume dockerroot

  5. Change "Path on the Node" from /var/lib/docker to /other-docker-root

  6. Add volume (with the following details):

Volume Name: dockerrootcustom
Type: bind-mount
Path on the Node: /other-docker-root
Mount Point: /other-docker-root
  1. Click Save

At this point logging should be working with your non-default Docker root directory. You should be able to verify this on your logging target. Keep in mind it may take a few minutes for logs to show up there as fluentd is configured to clear its buffer every 60 seconds by default.

Disclaimer

This Support Knowledgebase provides a valuable tool for SUSE customers and parties interested in our products and solutions to acquire information, ideas and learn from one another. Materials are provided for informational, personal or non-commercial use within your organization and are presented "AS IS" WITHOUT WARRANTY OF ANY KIND.

  • Document ID:000020113
  • Creation Date: 06-May-2021
  • Modified Date:06-May-2021
    • SUSE Rancher

< Back to Support Search

For questions or concerns with the SUSE Knowledgebase please contact: tidfeedback[at]suse.com

SUSE Support Forums

Get your questions answered by experienced Sys Ops or interact with other SUSE community experts.

Support Resources

Learn how to get the most from the technical support you receive with your SUSE Subscription, Premium Support, Academic Program, or Partner Program.

Open an Incident

Open an incident with SUSE Technical Support, manage your subscriptions, download patches, or manage user access.