kubectl – Couldn’t get current server API group list: the server has asked for the client to provide credentials

When I try to run kubectl commands connected to my k3s, I get the following error,

E0414 02:26:05.976507 3027896 memcache.go:265] "Unhandled Error" err="couldn't get current server API group list: the server has asked for the client to provide credentials"
E0414 02:26:05.987676 3027896 memcache.go:265] "Unhandled Error" err="couldn't get current server API group list: the server has asked for the client to provide credentials"
error: You must be logged in to the server (the server has asked for the client to provide credentials)

I even get this error from the server (when I am on the metal). Running sudo journalctl -u k3s -r on the server, I see

Unable to authenticate the request” err=”[x509: certificate has expired or is not yet valid: current time 2026-04-14T02:19:52-05:00 is after 2026-04-14T03:11:28Z, verifying certificate SN=redacted, SKID=, AKID=long_hex failed: x509: certificate has expired or is not yet valid: current time 2026-04-14T02:19:52-05:00 is after 2026-04-14T03:11:28Z]”

Follow by this error sprinkled around,

on=”” type=”Warning” reason=”CertificateExpirationWarning” message=”Node certificates require attention – restart k3s on this node to trigger automatic rotation: kube-proxy/client-kube-proxy.crt: certificate CN=system:kube-proxy expired at 2026-04-14T03:11:28Z, k3s-controller/client-k3s-controller.crt: certificate CN=system:k3s-controller expired at 2026-04-14T03:11:28Z”

Read more here: Source link