Longhorn PVC redistribution volumes on all nodes Longhorn PVC redistribution volumes on all nodes kubernetes kubernetes

Longhorn PVC redistribution volumes on all nodes


I think it’s better for you to just create a new replica. Instead of deleting your pv/pvc.Click on the longhorn volume that you want to move around to a different node (using longhorn dashboard, in volume menu).

In the context menu there should be option to Update Replicas Count if your volume is attached.

Increase the replica so longhorn create more replica in the healthy node. Wait for it to finish rebuilding. Let’s say previously you have 2 replicas, now you have 3 (one new replica in the healthy node). Reduce the replica count again to 2. Then delete your replica in the node you want to cordon.

So this way:

  • No need to delete your PV/PVC then reattach
  • Zero downtime

Also, longhorn has reached version 1 by now. It’s a good idea to upgrade.