Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cluster getting re-imported after removal from Rancher #589

Closed
cpinjani opened this issue Jul 4, 2024 · 1 comment · Fixed by #597
Closed

Cluster getting re-imported after removal from Rancher #589

cpinjani opened this issue Jul 4, 2024 · 1 comment · Fixed by #597
Assignees
Labels
kind/bug Something isn't working
Milestone

Comments

@cpinjani
Copy link

cpinjani commented Jul 4, 2024

What steps did you take and what happened?

  • Install turtles and UI extension
  • Import CAPI cluster, v3 cluster gets created in Rancher. Wait for it to be Active
  • Remove the imported cluster from Rancher, it gets re-imported.
    Not always reproducible though.
cluster.mp4

Is there a race condition to annotate cluster as imported and its removal.
Cluster description after getting re-imported:

Name:         cluster1
Namespace:    default
Labels:       app.kubernetes.io/managed-by=Helm
              objectset.rio.cattle.io/hash=d8a48a02f9251fc48f93df5bf362b6004500d2a9
Annotations:  imported: true
              meta.helm.sh/release-name: clusters-clusters
              meta.helm.sh/release-namespace: default
              objectset.rio.cattle.io/id: default-clusters-clusters-cattle-fleet-local-system
API Version:  cluster.x-k8s.io/v1beta1
Kind:         Cluster
Metadata:
  Creation Timestamp:  2024-07-03T12:27:13Z
  Finalizers:
    cluster.cluster.x-k8s.io
  Generation:        2
  Resource Version:  156174
  UID:               6ed57ce2-c6dc-4933-b243-5fb30d57f4d7
Spec:
  Cluster Network:
    Pods:
      Cidr Blocks:
        10.1.0.0/16
    Service Domain:  cluster.local
    Services:
      Cidr Blocks:
        10.10.0.0/16
  Control Plane Endpoint:
    Host:  172.19.0.2
    Port:  6443
  Control Plane Ref:
    API Version:  controlplane.cluster.x-k8s.io/v1beta1
    Kind:         RKE2ControlPlane
    Name:         cluster1-control-plane
    Namespace:    default
  Infrastructure Ref:
    API Version:  infrastructure.cluster.x-k8s.io/v1beta1
    Kind:         DockerCluster
    Name:         cluster1
    Namespace:    default
Status:
  Conditions:
    Last Transition Time:  2024-07-03T12:30:51Z
    Status:                True
    Type:                  Ready
    Last Transition Time:  2024-07-03T12:29:58Z
    Status:                True
    Type:                  ControlPlaneInitialized
    Last Transition Time:  2024-07-03T12:30:51Z
    Status:                True
    Type:                  ControlPlaneReady
    Last Transition Time:  2024-07-03T12:27:59Z
    Status:                True
    Type:                  InfrastructureReady
  Control Plane Ready:     true
  Infrastructure Ready:    true
  Observed Generation:     2
  Phase:                   Provisioned
Events:
  Type    Reason               Age                 From                Message
  ----    ------               ----                ----                -------
  Normal  Provisioning         31m (x2 over 31m)   cluster-controller  Cluster cluster1 is Provisioning
  Normal  InfrastructureReady  30m (x12 over 30m)  cluster-controller  Cluster cluster1 InfrastructureReady is now true
  Normal  Provisioned          30m (x11 over 30m)  cluster-controller  Cluster cluster1 is Provisioned

What did you expect to happen?

Cluster should not be re-imported after removal.

How to reproduce it?

Steps mention above

Rancher Turtles version

v0.9.0

Anything else you would like to add?

Behavior is mostly seen with v3 cluster, not v1.

Label(s) to be applied

/kind bug

@cpinjani cpinjani added the kind/bug Something isn't working label Jul 4, 2024
@cpinjani cpinjani added this to the July release milestone Jul 4, 2024
@furkatgofurov7
Copy link
Contributor

I have spent time in reproducing this but with no luck. After removing the imported cluster, it was always gone and was never re-imported (as it is supposed to be doing), although the issue mentions it is not always reproducible, so I maybe had a luck in each try 🙂

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Something isn't working
3 participants