Kubernates Flashcards
What is Kubernetes?
https://cloud.google.com/learn/what-is-kubernetes
https://kubernetes.io/docs/concepts/overview/
Question 1
https://www.interviewbit.com/kubernetes-interview-questions/
What is a Kuberantes container?
https://avinetworks.com/glossary/kubernetes-container/#:~:text=Kubernetes%20containers%20resemble%20virtual%20machines,to%20their%20relaxed%20isolation%20properties
What are K8s?
Kubernetes (sometimes shortened to K8s with the 8 standing for the number of letters between the “K” and the “s”) is an open source system to deploy, scale, and manage containerized applications anywhere.
What is orchestration when it comes to software and DevOps?
Orchestration refers to the integration of multiple services that allows them to automate processes or synchronize information in a timely fashion. Say, for example, you have six or seven microservices for an application to run. If you place them in separate containers, this would inevitably create obstacles for communication. Orchestration would help in such a situation by enabling all services in individual containers to work seamlessly to accomplish a single
Container orchestration is a process that involves managing and coordinating the deployment, scaling, and operation of multiple containers that run on a single server or across multiple servers. It automates container provisioning, networking, resource allocation, load balancing, availability, and lifecycle management tasks. Container orchestration tools, such as Kubernetes, Docker Swarm, and Apache Mesos, help ensure that containers work together seamlessly and efficiently to deliver the desired applications or services.
How are Kubernetes and Docker related?
https://aws.amazon.com/compare/the-difference-between-kubernetes-and-docker/
Question 3
https://www.turing.com/interview-questions/kubernetes
This is one of the most frequently asked Kubernetes interview questions, where the interviewer might as well ask you to share your experience working with any of them. Docker is an open-source platform used to handle software development. Its main benefit is that it packages the settings and dependencies that the software/application needs to run into a container, which allows for portability and several other advantages. Kubernetes allows for the manual linking and orchestration of several containers, running on multiple hosts that have been created using Docker.
What are the main differences between the Docker Swarm and Kubernetes?
https://www.freecodecamp.org/news/kubernetes-vs-docker-swarm-what-is-the-difference/
Intermediate Question 15
https://www.turing.com/interview-questions/kubernetes
What is the difference between deploying applications on hosts and containers?
Deploying Applications consist of an architecture that has an operating system. The operating system will have a kernel that holds various libraries installed on the operating system needed for an application.
Whereas container host refers to the system that runs the containerized processes. This kind is isolated from the other applications; therefore, the applications must have the necessary libraries. The binaries are separated from the rest of the system and cannot infringe any other application.
What are the features of Kubernetes?
https://kubernetes.io/
What are the main components of Kubernetes architecture?
https://kubernetes.io/docs/concepts/overview/components/
Question 15
https://www.turing.com/interview-questions/kubernetes
Explain the working of the master node in Kubernetes?
The master node dignifies the node that controls and manages the set of worker nodes. This kind resembles a cluster in Kubernetes. The nodes are responsible for the cluster management and the API used to configure and manage the resources within the collection. The master nodes of Kubernetes can run with Kubernetes itself, the asset of dedicated pods.
What is the role of Kube-apiserver?
https://kubernetes.io/docs/reference/command-line-tools-reference/kube-apiserver/#:~:text=The%20Kubernetes%20API%20server%20validates,which%20all%20other%20components%20interact.
Intermediate Question 39
https://www.turing.com/interview-questions/kubernetes
What is a node in Kubernetes?
A node is the smallest fundamental unit of computing hardware. It represents a single machine in a cluster, which could be a physical machine in a data center or a virtual machine from a cloud provider. Each machine can substitute any other machine in a Kubernetes cluster. The master in Kubernetes controls the nodes that have containers.
What does the node status contain?
https://kubernetes.io/docs/reference/node/node-status/
Intermediate Question 19
https://www.turing.com/interview-questions/kubernetes
What process runs on Kubernetes Master Node?
https://medium.com/featurepreneur/kubernetes-architecture-processes-run-on-master-node-c5869b89b931
The Kube-api server process runs on the master node and serves to scale the deployment of more instances.
The process that runs on the Kubernetes master node is the Kube-apiserver. This process is the access point for all the REST commands that control the cluster. It is the only Kubernetes control panel component with a user-accessible API and the sole master component you will interact with. It acts as a gateway to the cluster and supports life cycle orchestration.
What is a pod in Kubernetes?
https://kubernetes.io/docs/concepts/workloads/pods/
Intermediate Question 21
https://www.turing.com/interview-questions/kubernetes
In this Kubernetes interview question, try giving a thorough answer instead of a one-liner. Pods are high-level structures that wrap one or more containers. This is because containers are not run directly in Kubernetes. Containers in the same pod share a local network and the same resources, allowing them to easily communicate with other containers in the same pod as if they were on the same machine while at the same time maintaining a degree of isolation.
What is the job of the kube-scheduler?
https://kubernetes.io/docs/reference/command-line-tools-reference/kube-scheduler/#:~:text=The%20Kubernetes%20scheduler%20is%20a,Pod%20to%20a%20suitable%20Node.
What is a cluster of containers in Kubernetes?
A cluster of containers is a set of machine elements that are nodes. Clusters initiate specific routes so that the containers running on the nodes can communicate with each other. In Kubernetes, the container engine (not the server of the Kubernetes API) provides hosting for the API server.
What is the Google Container Engine?
The Google Container Engine is an open-source management platform tailor-made for Docker containers and clusters to provide support for the clusters that run in Google public cloud services.
Container Engine also makes application management easier. Your cluster is equipped with common capabilities, such as logging and container health checking, to give you insight into how your application is running. And, as your application’s needs change, resizing your cluster with more CPU or memory is easy.
https://www.techtarget.com/searchitoperations/definition/Google-Container-Engine-GKE#:~:text=Google%20Kubernetes%20Engine%20(GKE)%20is,orchestration%20platform%20developed%20by%20Google.
What are Daemon sets?
https://kubernetes.io/docs/concepts/workloads/controllers/daemonset/#:~:text=A%20DaemonSet%20defines%20Pods%20that,Pods%20are%20added%20to%20them.
The DaemonSets are pod sets that run on a host only one time on a host. And so, they are used attributes of host layers such as -network or network monitoring. DaemonSet enables you to run the Kubernetes pod on the cluster nodes that fulfill certain criteria or requirements. It ensures that some or all nodes run a copy of a pod. DaemonSets are used to deploy background services, run cluster storage, log collection, and deploy a node monitoring daemon on every node
What is ‘Heapster’ in Kubernetes?
https://logz.io/blog/kubernetes-monitoring/#:~:text=Heapster%20is%20a%20bridge%20between,node%20via%20the%20Kubernetes%20API.
https://kubernetes.io/blog/2015/05/resource-usage-monitoring-kubernetes/
A Heapster is a cluster-wide aggregator of data that runs on each node. It is a Kubernetes project that provides a robust monitoring solution for Kubernetes clusters. Heapster is flexible and modular, making it easy to use and customize for different needs. However, Heapster has been deprecated since Kubernetes version 1.11. Its functionality has been replaced by the Kubernetes Metrics Server, which provides a more efficient and scalable way to collect and expose resource utilization data from Kubernetes nodes and pods.
What is Minikube?
https://kubernetes.io/docs/tutorials/kubernetes-basics/create-cluster/cluster-intro/#:~:text=Minikube%20is%20a%20lightweight%20Kubernetes,%2C%20macOS%2C%20and%20Windows%20systems.
Minikube is a lightweight implementation of Kubernetes, which creates a VM on your local machine. It is a tool that sets the Kubernetes environment on your laptop or PC, and it addresses a different type of use case than most other distributions, such as Rancher, EKS, and OpenShift. It creates a lightweight, self-contained environment with all the necessary components for running Kubernetes, such as the API server, etcd, and kubelet. This allows developers to experiment with Kubernetes without the need for a full-scale production environment.
What is a Namespace in Kubernetes?
Namespaces are used for dividing cluster resources between multiple users. They are meant for environments where there are many users spread across projects or teams and provide a scope of resources.
https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/#:~:text=Namespaces%20are%20a%20way%20to,resources%20within%20the%20same%20namespace.
Name the initial namespaces from which Kubernetes starts?
Default
Kube – system
Kube – public
Intermediate Question 25
https://www.turing.com/interview-questions/kubernetes
What is the Kubernetes controller manager?
https://kubernetes.io/docs/reference/command-line-tools-reference/kube-controller-manager/#:~:text=The%20Kubernetes%20controller%20manager%20is,the%20state%20of%20the%20system.
What are the types of controller managers?
https://blog.knoldus.com/introduction-to-kube-controller-manager/
What is etcd?
https://etcd.io/
Kubernetes uses etcd as a distributed key-value store for all of its data, including metadata and configuration data, and allows nodes in Kubernetes clusters to read and write data. Although etcd was purposely built for CoreOS, it also works on a variety of operating systems (e.g., Linux, BSB, and OS X) because it is open-source. Etcd represents the state of a cluster at a specific moment in time and is a canonical hub for state management and cluster coordination of a Kubernetes cluster.
What are the different services within Kubernetes?
https://cloud.google.com/kubernetes-engine/docs/concepts/service#:~:text=Types%20of%20Kubernetes%20Services,-There%20are%20five&text=LoadBalancer%3A%20Clients%20send%20requests%20to,need%20a%20stable%20IP%20address.
Question 23
https://www.turing.com/interview-questions/kubernetes
What is ClusterIP?
https://sysdig.com/blog/kubernetes-services-clusterip-nodeport-loadbalancer/
Intermediate Question 26
https://www.turing.com/interview-questions/kubernetes
The ClusterIP is the default Kubernetes service that provides a service inside a cluster (with no external access) that other apps inside your cluster can access.
What is NodePort?
https://cloud.ibm.com/docs/containers?topic=containers-nodeport#:~:text=About%20NodePorts&text=The%20NodePort%20service%20serves%20as,incoming%20requests%20for%20the%20service.
Intermediate Question 27
https://www.turing.com/interview-questions/kubernetes
The NodePort service is the most fundamental way to get external traffic directly to your service. It opens a specific port on all Nodes and forwards any traffic sent to this port to the service.
What is the LoadBalancer in Kubernetes?
https://avinetworks.com/glossary/kubernetes-load-balancer/#:~:text=The%20load%20balancer%20tracks%20the,Kubernetes%20pods%20for%20the%20service.
Basic question 6
https://www.interviewbit.com/kubernetes-interview-questions/
What is the Ingress network, and how does it work?
https://kubernetes.io/docs/concepts/services-networking/ingress/#:~:text=Make%20your%20HTTP%20(or%20HTTPS,define%20via%20the%20Kubernetes%20API.
Questions 25 and 26
https://www.turing.com/interview-questions/kubernetes
An ingress is an object that allows users to access your Kubernetes services from outside the Kubernetes cluster. Users can configure the access by creating rules that define which inbound connections reach which services.
How does it work- This is an API object that provides the routing rules to manage the external users’ access to the services in the Kubernetes cluster through HTTPS/ HTTP. With this, users can easily set up the rules for routing traffic without creating a bunch of load balancers or exposing each service to the nodes.
What do you understand by Cloud controller manager?
https://kubernetes.io/docs/concepts/architecture/cloud-controller/#:~:text=The%20cloud%20controller%20manager%20runs,controllers%20in%20a%20single%20process.
What is Container resource monitoring?
https://aws.amazon.com/cloudwatch/container-monitoring/#:~:text=Container%20monitoring%20is%20the%20activity,ensure%20they%20are%20operating%20smoothly.
Question 29
https://www.turing.com/interview-questions/kubernetes
What is the difference between a replica set and a replication controller?
https://www.geeksforgeeks.org/kuberneters-difference-between-replicaset-and-replication-controller/
What is a headless service?
https://cloud.google.com/kubernetes-engine/docs/concepts/service#:~:text=A%20headless%20Service%20is%20a,of%20going%20through%20a%20proxy.
Intermediate Question 10
https://www.turing.com/interview-questions/kubernetes
What are federated clusters?
https://subscription.packtpub.com/book/cloud-and-networking/9781786461001/11/ch11lvl1sec71/understanding-cluster-federation#:~:text=Cluster%20federation%20is%20conceptually%20simple,unified%20view%20of%20the%20system.
Question 35
https://www.simplilearn.com/tutorials/kubernetes-tutorial/kubernetes-interview-questions
Intermediate Question 12
https://www.turing.com/interview-questions/kubernetes
What is Kubelet?or Which node in Kubernetes keeps track of resource utilization?
https://kubernetes.io/docs/reference/command-line-tools-reference/kubelet/
Question 19
https://www.turing.com/interview-questions/kubernetes
What is Kubectl?
https://kubernetes.io/docs/tasks/tools/#:~:text=kubectl,see%20the%20kubectl%20reference%20documentation.
Questions 12 and 13
https://www.turing.com/interview-questions/kubernetes
Give examples of recommended security measures for Kubernetes.
https://kubernetes.io/docs/tasks/administer-cluster/securing-a-cluster/
Basic question 7
https://www.interviewbit.com/kubernetes-interview-questions/
What is Kube-proxy?
https://medium.com/@seifeddinerajhi/kube-proxy-and-cni-the-hidden-components-of-kubernetes-networking-eb30000bf87a#:~:text=Kube%2DProxy%20serves%20as%20a,network%20rules%20within%20the%20node.
How can you get a static IP for a Kubernetes load balancer?
A static IP for the Kubernetes load balancer can be achieved by changing DNS records since the Kubernetes Master can assign a new static IP address.
https://stackoverflow.com/questions/32266053/how-to-specify-static-ip-address-for-kubernetes-load-balancer
https://cloud.google.com/kubernetes-engine/docs/tutorials/configuring-domain-name-static-ip#:~:text=Balancer%20with%20Ingress.-,Use%20a%20Service,per%20unused%20IP%20address%20pricing.
Intermediate Question 32
https://www.turing.com/interview-questions/kubernetes
How to do maintenance activity on the K8 node?
Basic question 1
https://www.interviewbit.com/kubernetes-interview-questions/
How do we control the resource usage of POD?
Basic question 2
https://www.interviewbit.com/kubernetes-interview-questions/
What are the various K8’s services running on nodes and describe the role of each service?
Basic question 3
https://www.interviewbit.com/kubernetes-interview-questions/
What is PDB (Pod Disruption Budget)?
Basic question 4
https://www.interviewbit.com/kubernetes-interview-questions/
What’s the init container and when it can be used?
https://kubernetes.io/docs/concepts/workloads/pods/init-containers/#:~:text=This%20page%20provides%20an%20overview,(which%20describes%20app%20containers).
Question 30
https://www.turing.com/interview-questions/kubernetes
How to monitor the Kubernetes cluster?
Basic question 8
https://www.interviewbit.com/kubernetes-interview-questions/
How to get the central logs from POD?
Basic question 9
https://www.interviewbit.com/kubernetes-interview-questions/
How to turn the service defined below in the spec into an external one?
Intermediate Question 1
https://www.interviewbit.com/kubernetes-interview-questions/
Complete the following configurationspec file to make it Ingress
Intermediate Question 2
https://www.interviewbit.com/kubernetes-interview-questions/