Kubernetes metadata not showing up for init-Containers

(Ryan Schneider) #1

In Kubernetes you Init Containers can be specified for a Deployment. Unfortunately it appears that the kubernetes metadata fields are not showing up for logs from an init-container in a pod. The logs from the main app container (in this case Nginx) are being populated fine. See the following screenshot for an example. The sleep and terminating log messages were from an init container.

Is there something I'm missing from a configuration perspective? Since the one container works but the other doesn't I think it might be an oversight or a particular way the metadata is gathered?

Any guidance appreciated. This is using v6.0.0-alpha2. Below is a Deployment that could be used to reproduce:

apiVersion: apps/v1beta1
kind: Deployment
  name: nginx
  replicas: 3
        app: nginx
      - name: nginx
        image: nginx:1.13.1
        - containerPort: 80
      - name: slowness
        image: busybox
        command: ['sh', '-c', 'echo "Sleeping 10 sceonds..." && sleep 10'] 

(Carlos PĂ©rez Aradros) #2

This looks like a bug to me, thank you for reporting it! would you mind to open a new issue in github? https://github.com/elastic/beats/issues/new

I guess we will just need to index initContainers along with common containers :slight_smile:

(Ryan Schneider) #3

Sure thing, here we go - https://github.com/elastic/beats/issues/4825

Thanks a lot!

(system) #4

This topic was automatically closed after 21 days. New replies are no longer allowed.