-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Addressing Log Errors After Move to containerd
#56
Comments
OBSERVED
CAUSElog locations have moved (docker kept them in brooke@k8s-dev-node-1:~$ sudo ls -la /var/lib/docker/containers/
total 0
drwxr-xr-x 2 root root 6 Feb 18 21:01 .
drwx--x--- 3 root root 24 Feb 18 21:01 .. However, there are existing symlinks from These are the broken symlinks: brooke@k8s-dev-node-1:~$ find /var/log/pods -type l ! -exec test -e {} \; -print
/var/log/pods/kube-system_kube-proxy-wlwnx_688267e9-8631-436c-b45b-b4431534737f/kube-proxy/6.log
/var/log/pods/kube-system_kube-proxy-wlwnx_688267e9-8631-436c-b45b-b4431534737f/kube-proxy/7.log
/var/log/pods/kube-system_calico-node-6kfdj_ac07af65-25e7-4b53-933a-71dd5d409ee6/upgrade-ipam/7.log
/var/log/pods/kube-system_calico-node-6kfdj_ac07af65-25e7-4b53-933a-71dd5d409ee6/install-cni/0.log
/var/log/pods/kube-system_calico-node-6kfdj_ac07af65-25e7-4b53-933a-71dd5d409ee6/flexvol-driver/0.log
/var/log/pods/kube-system_calico-node-6kfdj_ac07af65-25e7-4b53-933a-71dd5d409ee6/calico-node/7.log
/var/log/pods/kube-system_calico-node-6kfdj_ac07af65-25e7-4b53-933a-71dd5d409ee6/calico-node/8.log
/var/log/pods/ceph-csi-rbd_ceph-csi-rbd-csi-cephfsplugin-t9qsf_687a526a-d9db-4c81-917b-4aefef82fc7f/driver-registrar/6.log
/var/log/pods/ceph-csi-rbd_ceph-csi-rbd-csi-cephfsplugin-t9qsf_687a526a-d9db-4c81-917b-4aefef82fc7f/driver-registrar/7.log
/var/log/pods/ceph-csi-rbd_ceph-csi-rbd-csi-cephfsplugin-t9qsf_687a526a-d9db-4c81-917b-4aefef82fc7f/csi-rbdplugin/6.log
/var/log/pods/ceph-csi-rbd_ceph-csi-rbd-csi-cephfsplugin-t9qsf_687a526a-d9db-4c81-917b-4aefef82fc7f/csi-rbdplugin/7.log
/var/log/pods/ceph-csi-rbd_ceph-csi-rbd-csi-cephfsplugin-t9qsf_687a526a-d9db-4c81-917b-4aefef82fc7f/liveness-prometheus/6.log
/var/log/pods/ceph-csi-rbd_ceph-csi-rbd-csi-cephfsplugin-t9qsf_687a526a-d9db-4c81-917b-4aefef82fc7f/liveness-prometheus/7.log
/var/log/pods/velero_node-agent-qxqsf_fd501ba9-6855-4084-97ac-acfc84b00c75/node-agent/6.log
/var/log/pods/velero_node-agent-qxqsf_fd501ba9-6855-4084-97ac-acfc84b00c75/node-agent/7.log
/var/log/pods/brooke_fluentbitbrooke-fluent-bit-8lx7d_0f80fda3-05ba-4991-b72d-b2d99a679402/fluent-bit/6.log
/var/log/pods/brooke_fluentbitbrooke-fluent-bit-8lx7d_0f80fda3-05ba-4991-b72d-b2d99a679402/fluent-bit/7.log
/var/log/pods/ceph-csi-cephfs_ceph-csi-cephfs-csi-cephfsplugin-zrk44_9e19da0d-8fc9-4d66-9208-870dab986568/driver-registrar/6.log
/var/log/pods/ceph-csi-cephfs_ceph-csi-cephfs-csi-cephfsplugin-zrk44_9e19da0d-8fc9-4d66-9208-870dab986568/driver-registrar/7.log
/var/log/pods/ceph-csi-cephfs_ceph-csi-cephfs-csi-cephfsplugin-zrk44_9e19da0d-8fc9-4d66-9208-870dab986568/csi-cephfsplugin/6.log
/var/log/pods/ceph-csi-cephfs_ceph-csi-cephfs-csi-cephfsplugin-zrk44_9e19da0d-8fc9-4d66-9208-870dab986568/csi-cephfsplugin/7.log
/var/log/pods/ceph-csi-cephfs_ceph-csi-cephfs-csi-cephfsplugin-zrk44_9e19da0d-8fc9-4d66-9208-870dab986568/liveness-prometheus/6.log
/var/log/pods/ceph-csi-cephfs_ceph-csi-cephfs-csi-cephfsplugin-zrk44_9e19da0d-8fc9-4d66-9208-870dab986568/liveness-prometheus/7.log SOLUTIONremove these broken links ## List them as a test
$ for link in $(find /var/log/pods -type l ! -exec test -e {} \; -print); do ls -la $link; done
## remove them
$ for link in $(find /var/log/pods -type l ! -exec test -e {} \; -print); do sudo rm $link; done |
OBSERVED
CAUSE(see this GH issue) kubelet is unable to remove the orphaned pod directory, because there's still a file in it; e.g.: brooke@k8s-dev-node-1:~$ sudo ls -la /var/lib/kubelet/pods/3e251619-7e5d-4b39-8f87-
ffdbc08364f1/volumes/kubernetes.io~csi/cephfs-metadig-pv
total 4
drwxr-x--- 2 root root 27 Apr 15 2024 .
drwxr-x--- 3 root root 31 Apr 12 2024 ..
-rw-r--r-- 1 root root 253 Feb 18 20:58 vol_data.json SOLUTIONIf you delete the orphaned while true; do \
sudo tail -n10 /var/log/syslog | \
grep kubelet | grep -Eo 'orphaned pod \\"([a-z0-9]+-?)*\\"' | \
awk '{ print $3 }' | tr -d '\\' | uniq | \
xargs -I % sh -c 'echo "deleting /var/lib/kubelet/pods/%"; sudo rm -rf /var/lib/kubelet/pods/%;'; \
sleep 2; \
done |
OBSERVED
SOLUTIONsudo chmod o+r /run/systemd/system/netplan-ovs-cleanup.service |
to do:
|
No description provided.
The text was updated successfully, but these errors were encountered: