Hi, I recently found my k3s cluster keep restartin...
# k3s
a
Hi, I recently found my k3s cluster keep restarting
Copy code
❯ sudo systemctl status k3s
[sudo] password for fawenyo:
● k3s.service - Lightweight Kubernetes
     Loaded: loaded (/etc/systemd/system/k3s.service; enabled; preset: enabled)
    Drop-In: /etc/systemd/system/k3s.service.d
             └─override.conf
     Active: active (running) since Thu 2026-06-04 18:05:24 CST; 1min 54s ago
       Docs: <https://k3s.io>
    Process: 28439 ExecStartPre=/sbin/modprobe br_netfilter (code=exited, status=0/SUCCESS)
    Process: 28441 ExecStartPre=/sbin/modprobe overlay (code=exited, status=0/SUCCESS)
   Main PID: 28442 (k3s-server)
      Tasks: 363
     Memory: 1.9G (peak: 2.1G)
        CPU: 42.192s
     CGroup: /system.slice/k3s.service
Here are my config files
Copy code
❯ cat /etc/systemd/system/k3s.service;
[Unit]
Description=Lightweight Kubernetes
Documentation=<https://k3s.io>
Wants=network-online.target
After=network-online.target

[Install]
WantedBy=multi-user.target

[Service]
Type=notify
EnvironmentFile=-/etc/default/%N
EnvironmentFile=-/etc/sysconfig/%N
EnvironmentFile=-/etc/systemd/system/k3s.service.env
KillMode=process
Delegate=yes
User=root
# Having non-zero Limit*s causes performance problems due to accounting overhead
# in the kernel. We recommend using cgroups to do container-local accounting.
LimitNOFILE=1048576
LimitNPROC=infinity
LimitCORE=infinity
TasksMax=infinity
TimeoutStartSec=0
Restart=always
RestartSec=5s
ExecStartPre=-/sbin/modprobe br_netfilter
ExecStartPre=-/sbin/modprobe overlay
ExecStart=/usr/local/bin/k3s \
    server \
        '--disable' \
        'traefik,servicelb' \
        '--node-label' \
        'site=home' \
        '--tls-san' \
        '220.135.107.102,192.168.31.183,10.43.0.1' \
        '--flannel-backend=vxlan' \
❯ cat /etc/systemd/system/k3s.service.d/override.conf
[Service]
ExecStart=
ExecStart=/usr/local/bin/k3s server --config /etc/rancher/k3s/config.yaml
TimeoutStartSec=300
Environment="GODEBUG=tlsmlkem=0"
❯ cat /etc/rancher/k3s/config.yaml
disable:
  - traefik
  - servicelb
node-label:
  - site=home
tls-san:
  - 220.135.107.102
  - 192.168.31.183
  - 10.43.0.1
kube-controller-manager-arg:
  - "bind-address=0.0.0.0"
kube-scheduler-arg:
  - "bind-address=0.0.0.0"
etcd-expose-metrics: true
kubelet-arg:
  - "image-gc-high-threshold=85"
  - "image-gc-low-threshold=80"
  - "eviction-hard=imagefs.available<10%,nodefs.available<10%"
  - "resolv-conf=/etc/rancher/k3s/resolv.conf"
  - "serialize-image-pulls=false"
  - "registry-burst=10"
  - "registry-qps=5"
  - "housekeeping-interval=30s"
kube-apiserver-arg:
  - "event-ttl=1h"
  - "etcd-readycheck-timeout=30s"
etcd-arg:
  - "quota-backend-bytes=2147483648"
  - "auto-compaction-retention=1h"
  - "auto-compaction-mode=periodic"
  - "heartbeat-interval=500"
  - "election-timeout=5000"
and the error logs: https://pastebin.com/0s2rbfdV Any suggestion how to solve this? Thanks!
Issue solved. It seems to be related to my hardware
c
Why are you explicitly setting the config file path to the default value? Why do you have flags on both the main systemd unit and on the dropin? Why are you duplicating flags in both the config file and the flags? This seems like it'd be frustrating to manage.
You have a bunch of component args also set to the defaults