Skip to content
Discussion options

You must be logged in to vote

The easiest way to make this reliable is to split the namespace at the Tail input, because Kubernetes container log filenames already contain the namespace.

Your current rewrite_tag approach only works if the Kubernetes filter has already added kubernetes.namespace_name and the rule is actually matching. Since the staging-logstash-* index is not created at all, first assume the rule is not producing any staging.* records.

A simpler shape is two Tail inputs with different tags and different DB files:

[INPUT]
    Name              tail
    Tag               staging.*
    Path              /var/log/containers/*_stl-staging_*.log
    Parser            docker
    DB                /var/log/flb…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@patrick-stephens
Comment options

Answer selected by patrick-stephens
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants