https://rancher.com/ logo
Title
o

orange-state-45356

11/21/2022, 8:10 PM
Hi Everyone, I'm working on longhorn and it is working well and maintainability from ui is very easy by defining tags, adding disks, backups and snapshots. But i did not find the anything for programatic use cases like maintaining longhorn features like adding disk and tags to differentiate the hdd and ssd pool. please help me to point out any CLI scripts/apis where i can reference to use it in my environment.
c

creamy-pencil-82913

11/21/2022, 9:51 PM
I am pretty sure it’s all just done via annotations on the Kubernetes objects. See https://github.com/longhorn/longhorn/blob/master/enhancements/20200319-default-disks-and-node-configuration.md
o

orange-state-45356

11/21/2022, 10:00 PM
This is not help my requirement. Does longhorn has self brain to check the node to find out new disk (lets say if we added new disk to existing node and we can not add new disk in longhorn every time like running CLI/API in fat clusters).
c

creamy-pencil-82913

11/21/2022, 10:22 PM
longhorn doesn’t use raw physical disks. If you add raw disk, you need to either format it, mount it to a path, and then configure LH to use that path, or add the new disk to an existing array/volume group/etc, and then expand the filesystem to make the additional space available to LH.
So you will always have to do something on the node itself when you add disks