Kubernetes log collection

8/17/2017

I read a lot about kubernetes logging but can not decide which one is better. My problem is that I would like to collect my container logs which are going to stdout. My idea is to add /var/run/docker.sock to logspout (https://github.com/gliderlabs/logspout) as volume and then logspout forward the logs to logstash. I would like to hear what is your preference maybe you have much better idea on these topic.

-- doktoric
containers
kubernetes
logging

1 Answer

8/19/2017

You can use EFK(Elasticsearch fluentd Kibana) addon from k8s community https://github.com/kubernetes/kops/tree/master/addons/logging-elasticsearch

It automatically collects all the stdout logs and we can see it on the kibana dashboard accessible at the k8s api URL.

After creating this addon use kubectl cluster-info for the Kibana URL.

-- slashRahul
Source: StackOverflow