Fedora Account System
Red Hat Associate
Red Hat Customer
Description of problem: caBundles are stored on the mutatingWebhookConfiguration instance. Kubemacpool and kubernetes-nmstate components use kube-admission-webhook (https://github.com/qinqon/kube-admission-webhook) pod to rotate ca certs and append them to the appropriate mutatingWebhookConfiguration. After a large amount of rotations (~700+) then the caBundle appended to mutatingWebhookConfiguration cannot be applied due to etcd's APPLY side restirction (1.5Mb) This results with the kubemacpool/kubernetes pods to decline requests on ``` x509: certificate has expired or is not yet valid ``` on the kube-admission-webhook logs one can see that it fails to apply the caBundle: ``` failed rotating all certs: failed adding new CA cert to CA bundle at webhook: failed to update webhook CABundle: failed to update webhook CABundle: etcdserver: request is too large ``` Version-Release number of selected component (if applicable): How reproducible: Steps to Reproduce: 1. manually cause a lot of ca rotations on kubemacpool/kubernetes-nmstate. 2. 3. Actual results: VM cannot be created, due to "x509: certificate has expired or is not yet valid" Expected results: VM should be able to be created with no errors. Additional info:
https://github.com/qinqon/kube-admission-webhook/pull/54
KAW bump on KMP: https://github.com/k8snetworkplumbingwg/kubemacpool/pull/338
KAW bump in KNMSTATE: https://github.com/nmstate/kubernetes-nmstate/pull/851
*** Bug 2011636 has been marked as a duplicate of this bug. ***
change merged to CNV4.9 since http://cnv-version-explorer.apps.cnv.engineering.redhat.com/BundleDetails?ver=v4.9.0-260
Verified the following way: 1. I deleted the nmstate secret (in openshift-cnv namespace) infinitely every 5 seconds using a script. 2. I sampled the output of the nmstate mutatingwebhookconfiguration after several iterations. The output size kept growing, until it remained steady after ~100 iterations. On the point, I verified that the caBundle part in the continued to update. OCP 4.9.6 CNV 4.9.1 nmstate-handler v4.9.1-7 kubemacpool v4.9.1-3
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory (OpenShift Virtualization 4.9.1 Images), and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2021:5091