Skip to content

Push containers' logs to journald instead of json-file driver #3645

Open
@3Hren

Description

@3Hren

Hi!

During playing with SONiC we encountered an issue when all disk's space was consumed by docker containers' logs. I saw the #563 and seems it must prevent such behavior, but seems like it's not. For example swss container still pushes its logs to the bind mount/var/log/swss:/var/log/swss:rw.

There are 2 questions:

  1. Isn't it better to configure default docker log driver to something like journald, which is system-wide and can be externally configured to collect as much logs as switch admins want?
  2. Maybe it will be more general to route swss logs to the log driver (via stdout or other stuff) to apply the common logs-rotation-logic?

I can send a PR if you like.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions