Issue
Having provisioned a Managed controller/Team controller via CasC, in the following restart of this controller, it is not able to complete the provisioning process and it shows the following error in the Manage Page of the Managed controller/Team controller item:
Secret with name "[example-bundle-link] in namespace: [example-namespace] not found!
In the Operation Center logs this error is exposed like:
WARNING c.c.o.server.model.ManagedMaster#setStoppingErrorState: Stopping request of <controllerName> failed java.lang.IllegalArgumentException: Secret with name [<secretName>] in namespace: [<namespace>] not found! at io.fabric8.kubernetes.client.dsl.base.BaseOperation.waitUntilCondition(BaseOperation.java:1092) at io.fabric8.kubernetes.client.handlers.SecretHandler.waitUntilCondition(SecretHandler.java:93) at io.fabric8.kubernetes.client.handlers.SecretHandler.waitUntilCondition(SecretHandler.java:39) at io.fabric8.kubernetes.client.dsl.internal.NamespaceVisitFromServerGetWatchDeleteRecreateWaitApplicableImpl.waitUntilCondition(NamespaceVisitFromServerGetWatchDeleteRecreateWaitApplicableImpl.java:254) at io.fabric8.kubernetes.client.dsl.internal.NamespaceVisitFromServerGetWatchDeleteRecreateWaitApplicableImpl.waitUntilCondition(NamespaceVisitFromServerGetWatchDeleteRecreateWaitApplicableImpl.java:59) at com.cloudbees.masterprovisioning.kubernetes.cmd.KubernetesCommand.waitForDeletion(KubernetesCommand.java:119) at com.cloudbees.masterprovisioning.kubernetes.cmd.AbstractDeleteKubernetesCommand.executeInternal(AbstractDeleteKubernetesCommand.java:62) at com.cloudbees.masterprovisioning.kubernetes.cmd.KubernetesCommand.execute(KubernetesCommand.java:111) at com.cloudbees.masterprovisioning.kubernetes.KubernetesMasterProvisioning$DescriptorImpl.lambda$null$14(KubernetesMasterProvisioning.java:1256) at java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1384) at java.util.stream.ReferencePipeline$Head.forEach(ReferencePipeline.java:647) at com.cloudbees.masterprovisioning.kubernetes.KubernetesMasterProvisioning$DescriptorImpl.lambda$stop$15(KubernetesMasterProvisioning.java:1256)
Resolution
This is a known issue with the core and the fix is available since 2.249.2.x (October 2020 release)
Workaround
In the "Manage" page of the Managed controller item:
-
Click on "Acknowledge the error"
-
Then on "Free Snapshot"
-
And finally "Start" the master
This article is part of our Knowledge Base and is provided for guidance-based purposes only. The solutions or workarounds described here are not officially supported by CloudBees and may not be applicable in all environments. Use at your own discretion, and test changes in a safe environment before applying them to production systems.