hobby-kube / guide

Kubernetes clusters for the hobbyist.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Unable to resize persistent volume with rook

faejr opened this issue · comments

commented

I was playing around with this and noticed that you can't dynamically resize a rook-block volume. Perhaps this is at least worth mentioning in the guide, or to find a way to do so?

error: persistentvolumeclaims "storage" could not be patched: persistentvolumeclaims "storage" is forbidden: only dynamically provisioned pvc can be resized and the storageclass that provisions the pvc must support resize
commented

I decided to play around with this and completely uninstalled rook and then installed it again. But now it seems that the rook-ceph-mon pod is no longer getting started by the operator. Any idea?

Hey there.

Could it be that your storage device is already formatted and rook is unable to claim it?

P.S. Even though you seem to have deleted your comment regarding allowVolumeExpansion, I added it to the manifest. Thanks for the hint.

commented

Thanks for the reply!
That's actually a good thought, I didn't think to recreate the storage device.

The reason I delete my comment about allowVolumeExpansion was that it wasn't working even after adding that. But what I found is that you also should add the following parameter to the storage class to allow it to expand.

csi.storage.k8s.io/controller-expand-secret-name: rook-csi-rbd-provisioner
csi.storage.k8s.io/controller-expand-secret-namespace: rook

However I wasn't able to properly try it out since I haven't gotten rook to work again. I'll try your suggestion and get back

oh, I see. this only works with the flex driver. I just pushed the changes to use the parameters you mentioned.

commented

Seems like rook still doesn't want to work after recreating the storage device. I guess it may have left some other stray files on the systems.

commented

After researching and recreating my whole cluster to get rook working it appears that expanding a volume still doesn't work. Unfortunate

Warning  ExternalExpanding      17s    volume_expand Ignoring the PVC: didn't find a plugin capable of expanding the volume; waiting for an external controller to process this PVC.