hostpath-provisioner icon indicating copy to clipboard operation
hostpath-provisioner copied to clipboard

The folders are not deleted if running on a multi-node cluster

Open realshuting opened this issue 6 years ago • 1 comments

I used this provisioner on a 3 nodes k8s cluster. I ran a daemonset with replica=3 on the cluster with the volumeclaimtemplates declared in the yaml file. Each time I deployed the application, it will create 3 PVCs and associated PVs across the node. When I delete the application(PVCs as well), I can see it will only cleanup the folder which is mounted to the same node where the "hostpath-provisioner" pod is scheduled. I checked the code which I expected is normal behavior: https://github.com/MaZderMind/hostpath-provisioner/blob/fe8ab311ab0cf51f97a81764dccc4bd5c8b15040/hostpath-provisioner.go#L133

However the folders created on the other two nodes are not been deleted. Is there a way to clean up all folders across the nodes when we delete the PVCs?

realshuting avatar Jan 31 '19 20:01 realshuting

Hi

I have no idea. I do not even run a Kubernetes productively anymore. This Reposirory and Code is #Unmaintained. You should not use it in production.

MaZderMind avatar Feb 01 '19 19:02 MaZderMind