Kubernetes Fundamentals Flashcards
Kubernetes is often used as a ______, which means that it is spanned across multiple servers that work on different tasks and to distribute the load of a system.
Cluster
Name the two types of server nodes that make up a Kubernetes Cluster.
1) Control plane nodes
2) Worker nodes
What does the control plane node do?
Control plane nodes contain various components which manage the cluster and control various tasks, such as deployment, scheduling and self-healing.
What does the worker node do?
Applications run on the worker node. Their behavior is controlled by the control plane node.
Which services are typically hosted on the control plane node?
1) kube-apiserver
2) kube-scheduler
3) kube-controller-manager
4) etcd
5) cloud-controller-manager
Which services are typically hosted on the worker node?
1) container runtime
2) kubelet
3) kube-proxy
What is a Kubernetes namespace?
A Kubernetes namespace can be used to divide a cluster into multiple virtual clusters, which can be used for multi-tenancy when multiple teams share a cluster.
The ________ is the centerpiece of Kubernetes. All other components interact with it and this is where users would access the cluster.
kube-apiserver
________ is a database which holds the state of a cluster.
etcd
When a new workload should be scheduled, the __________ chooses a worker node that could fit, based on different properties like CPU and memory.
kube-scheduler
The _____________ contains different non-terminating control loops that manage the state of the cluster. For example, one of these control loops can make sure that a desired number of your application is available all the time.
kube-controller-manager
The _____________ can be used to interact with the API of cloud providers, to create external resources like load balancers, storage or security groups.
cloud-controller-manager
The _________ _________ is responsible for running the containers on the worker node. For a long time, Docker was the most popular choice, but is now replaced in favor of other runtimes like containerd.
container runtime
__________ is a small agent that runs on every worker node in the cluster. It talks to the api-server and the container runtime to handle the final stage of starting containers.
kubelet
_________ is a network proxy that handles inside and outside communication of your cluster. Instead of managing traffic flow on its own, it tries to rely on the networking capabilities of the underlying operating system if possible.
kube-proxy
What three tools can be used to create a test cluster?
- Minikube
- kind
- MicroK8s
Which installers can be used to setup a production-grade cluster on your own hardware or virtual machines?
- kubeadm
- kops
- kubespray
What are some commercial Kubernetes distributions?
- Rancher
- k3s
- OpenShift
- VMWare Tanzu
What Kubernetes services are offered by cloud providers?
- Amazon (EKS)
- Google (GKE)
- Microsoft (AKS)
- DigitalOcean (DOKS)
Before a request is processed by Kubernetes, what three stages does it have to go through?
- Authentication
- Authorization
- Admission Control
Kubernetes users are always _________ managed. ________ _______ can be used to authenticate technical users.
Externally, Service Accounts
_________ decides what the requester is allowed to do. In Kubernetes this can be done with __________.
Authorization, RBAC (Role-Based Access Control)
In the last step, _________ _________ can be used to modify or validate a request. Tools like the _______ _______ ______ can be used to manage _______ ________ externally.
Admission controllers, Open Policy Agent, admission control
In Kuberentes, what is a Pod?
Pods are the smallest compute unit and can be thought of as a wrapper around a container.
Which container runtimes are available with CRI?
- containerd
- CRI-O
- Docker
____________ is a lightweight and performant implementation to run containers. Arguably it is the most popular container runtime right now. It is used by all major cloud providers for the Kubernetes As A Service products.
containerd
___________ was created by Red Hat and with a similar code base closely related to podman and buildah.
CRI-O
The standard for a long time, but never really made for container orchestration. The usage of _______ as the runtime for Kubernetes has been deprecated and removed in Kubernetes 1.24. Kubernetes has a great blog article that answers all the questions on the matter.
Docker
What are the two most common tools that try to solve the security problem of Kubernetes sharing the kernel?
- gvisor
- Kata Containers
Made by Google, __________ provides an application kernel that sits between the containerized process and the host kernel.
gvisor
____________ _________ is a secure runtime that provides a lightweight virtual machine, but behaves like a container.
Kata Containers
What are the four different networking problems that Kubernetes aims to solve?
- Container-to-Container communications
- Pod-to-Pod communications
- Pod-to-Service communications
- External-to-Service communications
What are the three important requirements for implementing networking in Kubernetes?
- All pods can communicate with each other across nodes.
- All nodes can communicate with all pods.
- No Network Address Translation (NAT).
__________ can be solved by Pods.
Container-to-Container communications
_________ can be solved with an overlay network.
Pod-to-Pod communications
__________ and _________ is implemented by the kube-proxy and packet filter on the node.
Pod-to-Service and External-to-Service communications
Name three network vendors can you choose from to implement networking.
- Project Calico
- Weave
- Cilium
Most Kubernetes setups include a DNS server add-on called _________ , which can provide service discovery and name resolution inside the cluster.
core-dns
What are Network Policies?
Network Policies act as cluster internal firewalls. Network policies can be defined for a set of pods or namespaces.
Network Policies are implemented by the __________ plugin.
network
In Kubernetes, what is scheduling?
Scheduling is a sub-category of container orchestration and describes the process of automatically choosing the right (worker) node to run a containerized workload on.
In a Kubernetes cluster, the ___________ is the component that makes the scheduling decision, but is not responsible for starting the workload.
kube-scheduler
Regarding Pods, what is the default behavior of Kubernetes schedulers?
The default behavior is to schedule the Pod on the node with the least amount of Pods.