error: x509: certificate has expired or is not yet valid
search cancel

error: x509: certificate has expired or is not yet valid

book

Article ID: 399864

calendar_today

Updated On:

Products

VMware Telco Cloud Automation

Issue/Introduction

kube-apiserver logs show error

Warning  FailedCreatePodSandbox kubelet  Failed to create pod sandbox: rpc error: code = Unknown desc = failed to setup network for sandbox "": plugin type="multus" name="multus-cni-network" failed (add): [whereabouts/whereabouts--pod-network]: error adding container to network "k8s-pod-network": error getting ClusterInformation: Get "https://kubernetes:443apis/crd.projectcalico.org/v1/clusterinformations/default": x509: certificate has expired or is not yet valid: current time is after

Environment

2.2

2.3

Cause

Certificates on one or more control plane nodes have expired.


Resolution

  1. SSH into each control plane node and run
    kubeadm certs check-expiration

  2. For each control plane node with expired certificates
    kubeadm certs renew all