cluster-api icon indicating copy to clipboard operation
cluster-api copied to clipboard

How to keep v1.Node in cluster when deleting Machine?

Open k82cn opened this issue 3 years ago • 6 comments

User Story

As an operator, I would like to keep v1.Node in the cluster when deleting Machine; as I'd like to migrate cluster-api and infra to other cluster.

Detailed Description

I'd like to move cluster-api and infra to other cluster; so I'd like to keep v1.Node in the cluster, just remove cluster-api CRs.

Anything else you would like to add:

xref: https://metal3io.netlify.app/bmo/detached_annotation.html

/kind feature

k82cn avatar Oct 09 '22 08:10 k82cn

@k82cn: This issue is currently awaiting triage.

If CAPI contributors determines this is a relevant issue, they will accept it by applying the triage/accepted label and provide further guidance.

The triage/accepted label can be added by org members by writing /triage accepted in a comment.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

k8s-ci-robot avatar Oct 09 '22 08:10 k8s-ci-robot

Deleting the Node is part of the deletion workflow and I don't think it should be disassociated from it unless there's a strong rationale for it. For migration scenarios I'd suggest to explore spec.Pause, and may be open an issue to discuss best practices.

enxebre avatar Oct 10 '22 07:10 enxebre

I agree with @enxebre, this should not be implemented unless we clarify use cases/user stories around the idea of "detaching", which is something we do not support and, as far as I remember, was never discussed during office hours.

Please also note that in most of the infrastructure providers Machine deletion implies the removal of the underlying infrastructure, so keeping the node around does not really make sense.

fabriziopandini avatar Oct 10 '22 08:10 fabriziopandini

It sounds like the ask is to do something similar to clustectl move. Thus it can be probably solved with our current implementation accordingly.

sbueringer avatar Oct 10 '22 09:10 sbueringer

Please also note that in most of the infrastructure providers Machine deletion implies the removal of the underlying infrastructure, so keeping the node around does not really make sense.

We're using Metal3.BareMetalHost detached feature which will not remove the infra. So in my case, I removed BareMetalHost without de-provision (the kubelet keep running), but the v1.Node was deleted by Machine :(

It sounds like the ask is to do something similar to clustectl move. Thus it can be probably solved with our current implementation accordingly.

Any guidance or links for that?

k82cn avatar Oct 10 '22 10:10 k82cn

Here's the link:

https://cluster-api.sigs.k8s.io/clusterctl/commands/move.html

But might not make any sense depending on what exactly you want to do.

sbueringer avatar Oct 10 '22 10:10 sbueringer

/triage needs-information

vincepri avatar Oct 18 '22 20:10 vincepri

The Kubernetes project currently lacks enough contributors to adequately respond to all issues and PRs.

This bot triages issues and PRs according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Mark this issue or PR as fresh with /remove-lifecycle stale
  • Mark this issue or PR as rotten with /lifecycle rotten
  • Close this issue or PR with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle stale

k8s-triage-robot avatar Jan 16 '23 21:01 k8s-triage-robot

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues.

This bot triages un-triaged issues according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Mark this issue as fresh with /remove-lifecycle rotten
  • Close this issue with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle rotten

k8s-triage-robot avatar Feb 15 '23 22:02 k8s-triage-robot

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs.

This bot triages issues according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Reopen this issue with /reopen
  • Mark this issue as fresh with /remove-lifecycle rotten
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/close not-planned

k8s-triage-robot avatar Mar 17 '23 22:03 k8s-triage-robot

@k8s-triage-robot: Closing this issue, marking it as "Not Planned".

In response to this:

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs.

This bot triages issues according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Reopen this issue with /reopen
  • Mark this issue as fresh with /remove-lifecycle rotten
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/close not-planned

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

k8s-ci-robot avatar Mar 17 '23 22:03 k8s-ci-robot