Components of Kubernetes Flashcards

1
Q

What is a pod?

A

A pod is the basic unit inside Kubernetes cluster.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What is a pod responsible for?

A

Running containers. It also controls the execution of that container.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What makes a pod die

A

When all the containers in the pod die

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Does a pod provide a way to set environment variables, mount storage, and feed other information into a container.

A

Yes.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What are the same resources all containers with a pod share

A

IP, storage, and RAM

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What is a Node?

A

A collection of pods. It is a physical or virtual machine

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

How many types of nodes are there? Specify them

A
  1. Master node and worker node.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

How many pods a worker node can hold?

A

1 or more pods

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

How many components are there in the worker node

A

3.
Kubelet process.
A Container Runtime Engine.
Kube-proxy.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Can you configure a master node to be a worker node?

A

Yes. But it’s not recommended for production purposes.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What does a Container Runtime do?

A

Run and manage a container’s life cycle

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What is a Kubelet process?

A

A process that runs on all worker nodes in the cluster

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What does a Kubelet process do?

A
  • Takes instructions from the control plane to manage the state of the node.
  • Collects performance and health information of the pods and their containers, and share that with the control plane to make scheduling decisions
  • Connects to the run time engine using the Container Runtime Interface (CRI)
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What is a Kube proxy?

A

An implementation of a network proxy that’s present on every node.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

What is a Kube proxy responsible for?

A
  • Routing traffic to the appropriate pod based on the incoming IP address
  • Exposes the node externally
  • Prevents IP conflicts on the pods
  • Responsible for port mappings.
  • Load balancer for the services running on the node.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What does a master node do?

A

Managing the other worker nodes and scheduling workloads on them (including deploying, starting up or destroying objects on worker nodes in order to meet the desired state).

If a service running on any pod of a worker node goes down, the master communicates with all the worker nodes in the cluster on how to re-route the traffic based on new container alignments.

Provides the control plane

17
Q

How can adminds access the Kubernetes master node to manage the Kubernetes cluster?

A
  1. kubectl (command-line interface)

2. Dashboard UI (web-based user interface)

18
Q

What are the four components of the master node?

A
  1. API server
  2. etcd
  3. Scheduler
  4. Controller Manager
19
Q

What are these 4 components also known as?

A

Kubernetes Control Plane

20
Q

What is the key management component of the entire cluster?

A

API Server.

21
Q

What is an API server?

A

The main access point to the cluster.

22
Q

What is the API server responsible for?

A

Provides both internal and external interfaces.

Updates the etcd with the changes in the cluster and it invokes the Scheduler and kubelet process when a new pod is created.

Responsible for the authentication and authorization

23
Q

What is a etcd

A

Persistent and distributed key-value store that contains the state and configuration data for the entire cluster.

24
Q

Where can etcd be configured?

A

On the master node or externally.

25
Q

Why does a node need etcd

A

Because it needs to learn how to maintain configuration of its running containers.

26
Q

How many ways are there to run a etcd

A

2 ways.
Distributed Database: multi-master nodes cluster
Standalone Database: single-master node cluster

27
Q

How to prevent conflicts between master nodes in a distributed database?

A

Implements logs.

28
Q

What is a Scheduler responsible for?

A
  • Assigning newly created and unscheduled pods to nodes.
  • ## The scheduler must know the resource requirements, resource availability, and other user-provided constraints to maximize proper resource utilization
29
Q

What does a Controller Manager do?

A
  • Supervises different controllers that drive actual cluster state toward the desired cluster state.
  • Communicates with the API server to create, update, and delete the resources it manages (pods, service endpoints, etc.).
  • Watches the state of the cluster through the API server and makes the necessary changes to move the cluster from current state* present in the etcd to the desired state defined in the configuration file*.
30
Q

Which of the following best describes a Kubernetes node?

a) A component of the API server used to schedule workloads
b) The smallest entity in Kubernetes, for a single container plus dependencies
c) A machine used to run Kubernetes workloads.
d) A group of machines used to run the Kubernetes API server

A

C