Lesson 1.1: Kubernetes Introduction
Kubernetes is an open source container orchestration platform for automating deployment, scaling, and management of containerized applications [1].
Kubernetes includes a powerful set of tools to control the life cycle of applications, e.g. parameterised redeployment in case of failures,state management,etc. Furthermore, Kubernetes incorporates an advanced scheduling system which can even specify different schedulers for each job.Kubernetes supports software defined infrastructures and resource disaggregation by leveraging container based deployment and particular drivers (e.g. Container Network Interface driver) based on standardised interfaces [2].
-
Pods: The smallest unit and the building block of applications in Kubernetes is called a pod. A pod is a group of one or more containers sharing the pod's IP address and its port space. In practice, microservices are containerized and deployed on a Kubernetes cluster as pods.
-
Controllers are the management entities that maintain the pods and are responsible for creating and maintaining the required number of pods based on their specifications. Controllers are watch loops that bring the current state of the cluster to the desired state.
- For Example: when a pod crashes, the pod’s controller will reschedule the pod. Kubernetes has different types of controllers, each addressing a specific purpose. For example, StatefulSet controllers manage stateful pods while Deployment controllers are usually used for managing stateless applications.
- Controllers delete and revive pods dynamically and cause the pods’ IP addresses to change often. Therefore, the pods’ IP addresses are not reliable. In Kubernetes, it is possible to assign customizable labels to pods and select them based on these labels.
- Kubernetes also defines an abstraction called Service, which selects pods as its endpoints list based on their labels. Services have static virtual IP addresses. All requests received at the IP address of the service are load balanced between the service endpoints in a random or round-robin manner
- Kubernetes abstracts the details of storage solutions by providing two API resources: the Persistent Volumes (PV) and Persistent Volume Claims (PVC). A PV is a piece of storage in the cluster whose lifecycle is independent of those of the pods using it. PVs can be provisioned dynamically or statically. A PVC, on the other hand, is a request for storage made by a pod. A PVC binds the pod to a PV that matches the PVC’s characteristics
References:
-
[1] N. Nguyen and T. Kim, "Toward Highly Scalable Load Balancing in Kubernetes Clusters," in IEEE Communications Magazine, vol. 58, no. 7, pp. 78-83, July 2020, doi: 10.1109/MCOM.001.1900660. URL: https://ieeexplore.ieee.org/stamp/stamp.jsp?tp=&arnumber=9161999&isnumber=9161976
-
[2] Zhou, N., Georgiou, Y., Pospieszny, M. et al. Container orchestration on HPC systems through Kubernetes. J Cloud Comp 10, 16 (2021). https://doi.org/10.1186/s13677-021-00231-z