skip to content
Alvin Lucillo

View logs of service

/ 1 min read

List the services first

systemctl list-units --type=service

  UNIT                               LOAD   ACTIVE SUB     DESCRIPTION
  containerd.service                 loaded active running containerd container runtime
  dbus.service                       loaded active running D-Bus System Message Bus
  kmod-static-nodes.service          loaded active exited  Create List of Static Device Nodes
  kubelet.service                    loaded active running kubelet: The Kubernetes Node Agent

Then use the service name with journalctl

journalctl -u kubelet.service

Nov 24 11:18:24 cluster1-controlplane kubelet[920]: E1124 11:18:24.403271     920 run.go:72] "command failed" err="failed to load kubelet config file, path: /var/lib/kubelet/confi>
Nov 24 11:18:34 cluster1-controlplane kubelet[1643]: E1124 11:18:34.588708    1643 run.go:72] "command failed" err="failed to load kubelet config file, path: /var/lib/kubelet/conf>
Nov 24 11:18:37 cluster1-controlplane kubelet[2255]: Flag --container-runtime-endpoint has been deprecated, This parameter should be set via the config file specified by the Kubel>
Nov 24 11:18:37 cluster1-controlplane kubelet[2255]: Flag --pod-i