Kubeinit / kubeinit

Ansible automation to have a KUBErnetes cluster INITialized as soon as possible...

Home Page:https://www.kubeinit.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

RFE: Support addition of non-os disks

raghavendra-talur opened this issue · comments

It would help storage developers a great deal if there was an option of adding non-os disks to the worker nodes. These disks can then be used by the local storage https://github.com/openshift/local-storage-operator to make them consumable by https://github.com/rook/rook or other storage operators.

I am familiar with the virsh/virt-install changes required to add the disks, if you could guide me on the the following two topics I will give it a try to implement this feature myself.

  • Field to add to the compute nodes section. I am thinking of
    ** extradisk_size=inGB
    ** extradisk_count=int

  • How to handle the validation of the required disk sizes per hypervisor.

Hello @raghavendra-talur !!

This should be relatively easy to implement, the steps should be:
1- Add the external volumes info in the inventory files, we could extend this information https://github.com/Kubeinit/kubeinit/blob/main/kubeinit/hosts/okd/inventory#L37-L44 to support an array of additional volumes.

Something like

...
root_device=/dev/vda
additional_volumes=[{size: 10G, device=/dev/vdb, mount=/mnt/foo},{size: 10G, device=/dev/vdc, mount=/mnt/foo2}]

Then here rely on the logic to create attach the volumes:

https://github.com/Kubeinit/kubeinit/blob/main/kubeinit/roles/kubeinit_libvirt/tasks/60_deploy_centos_guest.yml and https://github.com/Kubeinit/kubeinit/blob/main/kubeinit/roles/kubeinit_libvirt/tasks/60_deploy_coreos_guest.yml

So you can plug as many volumes as you need.

If you manage to implement it then Ill fix up the disk usage validation for sure.

Thanks!!!

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days

@raghavendra-talur any update on this? Do you require anything from us?

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days