2020/01/27 17:12:12 [emerg] 105#105: duplicate location "/healthz" in /tmp/nginx-cfg568474076:487
nginx: [emerg] duplicate location "/healthz" in /tmp/nginx-cfg568474076:487
nginx: configuration file /tmp/nginx-cfg568474076 test failed
It happens when you have an ingress object conflicting with "/healthz" path.
Solution
Make sure to not have an ingress object overlapping "/healthz".
Pod sandbox changed, it will be killed and re-created
Cause
This error happens when deploying a pod. It is caused most liked because of Docker processes crashed or is unstable on the node due IO peak.
Solution
The solution is to reboot the node.
References
failed to watch file "/var/log/pods/6438eb52-202a-11ea-8dce-e279cb2777e2/my-app/0.log": no space left on device
Symptom
When you run.
kubectl -n my-ns logs -f my-app-659858b967-5hmtz
The command outputs a few lines of log and then breaks.
Cause
The obvious reason is the node's HD is full. Although this error can be caused by other reasons.
This error (ENOSPC) comes from the inotify_add_watch syscall, and actually has multiple meanings (the message comes from golang). Most likely the problem is from exceeding the maximum number of watches, not filling the disk. This can be increased with the fs.inotify.max_user_watches sysctl.
Solution
Increase max_user_watches.
cat /proc/sys/fs/inotify/max_user_watches # default is 8192
sysctl fs.inotify.max_user_watches=1048576 # increase to 1048576
If you do not have SSH connection to the node, apply the following manifest (not recommended for production environments).