容器壞了棵癣,重啟一個(gè)容器,原來(lái)的容器內(nèi)的日志不丟失夺衍。但是狈谊,pod壞了,日志就丟失了沟沙。
As described in the logging overview, this command fetches log entries from the container log file. If the container is killed and then restarted by Kubernetes, you can still access logs from the previous container. However, if the pod is evicted from the node, log files are lost.
https://kubernetes.io/docs/tasks/debug-application-cluster/logging-stackdriver/