Thanks to visit codestin.com
Credit goes to github.com

Skip to content

kube-controller-manager leader election triggers DetachVolume.Detach #104169

@henro001

Description

@henro001

What happened:

When kube-controller-manager process in terminated on a leader node, a new leader election starts. This will trigger DetachVolume.Detach for all persistent volumes in the cluster. In our case, we use Cinder CSI driver, the volumes are detached in cinder, but the volumeattachmens are not deleted/updated, so this requires manual intervention to clean up the statefulsets/volumeattachments.

What you expected to happen:

The volumes should not be detached.

How to reproduce it (as minimally and precisely as possible):

Terminate kube-controller-manager on the leader node.

kill -s SIGHUP $(pidof kube-controller-manager)

Anything else we need to know?:

Cinder CSI driver enabled.

Environment:

  • Kubernetes version: 1.19.9
  • Cloud provider or hardware configuration: Openstack Cinder
  • OS (e.g: cat /etc/os-release): Ubuntu 18.04.4 LTS (Bionic Beaver)"

Metadata

Metadata

Assignees

No one assigned

    Labels

    kind/bugCategorizes issue or PR as related to a bug.needs-triageIndicates an issue or PR lacks a `triage/foo` label and requires one.sig/storageCategorizes an issue or PR as relevant to SIG Storage.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions