Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
1.4k views
in Technique[技术] by (71.8m points)

docker - Kubernetes Liveness Probe Logging

We're using Kubernetes 1.1.3 with its default fluentd-elasticsearch logging.

We also use LivenessProbes on our containers to make sure they operate as expected.

Our problem is that lines we send out to the STDOUT from the LivenessProbe does not appear to reach Elastic Search.

Is there a way to make fluentd ship LivenessProbes output like it does to regular containers in a pod?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

The output from the probe is swallowed by the Kubelet component on the node, which is responsible for running the probes (source code, if you're interested). If a probe fails, its output will be recorded as an event associated with the pod, which should be accessible through the API.

The output of successful probes isn't recorded anywhere unless your Kubelet has a log level of at least --v=4, in which case it'll be in the Kubelet's logs.

Feel free to file a feature request in a Github issue if you have ideas of what you'd like to be done with the output :)


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...