https://rancher.com/ logo
#fleet
Title
p

powerful-farmer-23811

10/11/2022, 6:53 PM
Hello everyone, I am getting the following error on my fleet-agents after upgrading from 2.5.16 to 2.6.8.
Failed to register agent: looking up secret cattle-fleet-local-system/fleet-agent-bootstrap: Unauthorized
I have done some research and found when I run this
kubectl auth can-i get secret --as=system:serviceaccount:cattle-fleet-system:fleet-agent -n cattle-fleet-system
I get "no" and instead of "yes" Running this does show I have the secrets in place kubectl get secret -n cattle-fleet-system NAME TYPE DATA AGE c-9rmhj kubernetes.io/tls 2 43h default-token-x24mk kubernetes.io/service-account-token 3 43h fleet-controller-bootstrap-token-2lfsx kubernetes.io/service-account-token 3 43h fleet-controller-token-9gdts kubernetes.io/service-account-token 3 43h gitjob-token-r5jmr kubernetes.io/service-account-token 3 43h sh.helm.release.v1.fleet-crd.v1 helm.sh/release.v1 1 43h sh.helm.release.v1.fleet-crd.v2 helm.sh/release.v1 1 40h sh.helm.release.v1.fleet.v1 helm.sh/release.v1 1 43h sh.helm.release.v1.fleet.v2 helm.sh/release.v1 1 43h sh.helm.release.v1.fleet.v3 helm.sh/release.v1 1 40h sh.helm.release.v1.fleet.v4 helm.sh/release.v1 1 40h stv-aggregation Opaque 3 43h Any help would be great appreciated
Also get this on the other clusters fleet-agents
Failed to register agent: looking up secret cattle-fleet-system/fleet-agent-bootstrap: looking up secret cattle-fleet-system/fleet-agent-bootstrap: secrets \"fleet-agent-bootstrap\" not found
for the cattle-fleet-local-system i get this
kubectl auth can-i get secret --as=system:serviceaccount:cattle-fleet-local-system:fleet-agent -n cattle-fleet-local-system
yes
kubectl get secret --as=system:serviceaccount:cattle-fleet-local-system:fleet-agent -n cattle-fleet-local-system
NAME TYPE DATA AGE c-9rmhj kubernetes.io/tls 2 43h default-token-sdrxm kubernetes.io/service-account-token 3 43h fleet-agent-bootstrap Opaque 5 43h fleet-agent-token-9pqb8 kubernetes.io/service-account-token 3 43h
I have now removed the old fleet-system from 2.5.8 and did a upgrade on the new cattle-fleet-system and it has now removed all my gitrepos, that's not an issue. I can create them and see if it fixes the issue
That did the trick.
👍 1
h

hundreds-state-15112

11/02/2022, 3:41 PM
@powerful-farmer-23811 Hello I believe I’m having the same issue. Can you please clarify some of the steps you took. Did you remove the old fleet-system from 2.6.8? And could you share the specifics steps of how you did the upgrade?
Or @quick-sandwich-76600 if you understand what was done
q

quick-sandwich-76600

11/02/2022, 7:01 PM
Hi @hundreds-state-15112 . There are no internal references to this nor I've found comments on any of the GitHub issues. If found this one that can be similar but not related to a migration: https://github.com/rancher/rancher/issues/36117
h

hundreds-state-15112

11/02/2022, 7:05 PM
I am mostly having the “not found” issue vs “unauthorized”. Here is a link to my thread if you care to take a peek. I’m about to give up at this point because I’ve spent way too much time on this.
q

quick-sandwich-76600

11/02/2022, 10:32 PM
@hundreds-state-15112 unfortunately, there's not a clear match to what you are experiencing in the searches I've done internally. I saw your other messages and the links you shared to other issue reports... but I think they may not be related to your problem. I've personally done several migrations 2.5 > 2.6 using helm, but they just worked, so I never paid attention to what was happening behind the scenes. Can you open a support ticket? My support colleagues may better track the process you followed and identify the root cause faster.
h

hundreds-state-15112

11/08/2022, 7:26 PM
I ran into this same problem when migrating clusters, but I can still do helm operations after rebooting the entire cluster. So it seems like while it’s complaining, it’s still working?
711 Views