While reading an interesting blog post about kata containers, the following sentence caught my attention:

Unlike virtual machines, which can take a minute or two to start and waste a fair amount of hardware resources on isolation, Kata containers aim to start just as fast and consume resources just as efficiently as other containers.

This rang a bell because when Hardware virtualization was getting popularized by vSphere and other solutions, one of the advantages frequently mentioned was that usage of physical servers wastes resources and by running multiple VMs on a single host, you will utilize it more, thus reducing such wastage.

It is interesting to see that almost same reason is now being given for switching to containers from VMs themselves. To me, this highlights the fact that we (as in software field) are making constant progress towards having better utilization of servers as well as having a very flexible and powerful way of building and deploying apps (using VMs and Containers).

Going back to the main point of the blog, the concept of kata containers sounds very intriguing. I heard about them before but haven’t spent much time exploring. But I am curious now to see how I can take advantage of the fact that each kata container runs in a dedicated kernel (unlike Docker and other container runtimes). Specifically, I want to know if they allow containerizing ZFS. Since ZFS is implemented as a combination of a kernel module and userland utilities, it is not possible to containerize it using Docker. For example, a pool created in one Docker container will make it visible in other containers as well. But with kata containers running a dedicated kernel, it may be possible to fully containerize ZFS.

Just to be clear, this is just a theory and I haven’t tested the hypothesis. I do hope to spend some time understanding and exploring kata containers though.