Cloud native distributed block storage for Kubernetes
I’m working on a cluster with some (~70) small projects on it and I’m still looking for the perfect storage solution. As the cloud provider charges per disk and I need a lof of (but very small) disks it’s not an option to use volumes provided by the cloud provider.
In my case I have a managed kubernetes cluster with dynamic nodes; that’s makes it a bit different if my cluster would die completely.
IO is not really important, most projects are very lightweight and nearly without traffic; but I have to ensure I can handle high-traffic-projects.
Longhorn.io looks like the perfect solution for all my needs – I can use different storage classes for my kubernetes notes and so I can schedule my workload onto specific nodes (see: Tip: Set Longhorn To Only Use Storage On A Specific Set Of Nodes). I’ll use it to move my storage from slow to fast nodes online. That’s real cloud 🙂
As a prerequisite I have to label my nodes first (you don’t have to):
and check what I’ve done:
Let’s take the longhorn.io yaml-file from https://github.com/longhorn/longhorn/blob/master/deploy/longhorn.yaml
Looks like Longhorn.io is perfect software as everything works for me out of the box 🙂
As we can see longhorn.io takes all the nodes’ storage but reserves enough space for the VM/OS. As a result I got a storageclass that I can use for my persistent volumes:
Note: You’ll maybe need a reverse proxy, loadbalancer or use kubectl proxy to get to your longhorn.io dashboard