The add_kubernetes_metadata function of filebeat cannot collect .out file logs and match the metdata information of k8s pod #42318
Labels
needs_team
Indicates that the issue/PR needs a Team:* label
In the k8s environment, we need to collect the contents of files in the emptydir, and we want the output information to include the metadata information of the pod.
I can reproduce this with the following config:
/var/lib/kubelet/pods//volumes/kubernetes.io~empty-dir/ray-log/session_/logs/ contains log files ending with .out and .log, such as a.out and b.log. Only log files ending with .log can match the metdata of the pod.
We see in the code that only .log files can extract pod_uid. Is it possible to remove this restriction?
https://github.com/elastic/beats/blob/main/filebeat/processor/add_kubernetes_metadata/matchers.go
The text was updated successfully, but these errors were encountered: