WEBVTT

00:04.200 --> 00:07.050
Hello and welcome to this lecture. In this lecture

00:07.050 --> 00:13.810
we will discuss about designing a kubernetes cluster. Before you head into designing a cluster.

00:13.820 --> 00:16.490
I must ask the following questions.

00:16.490 --> 00:18.740
What is the purpose of this cluster?

00:18.770 --> 00:25.100
Is it for learning or development or testing purpose or for hosting production grade applications.

00:25.100 --> 00:27.740
What is the cloud adoption at your organization?

00:27.740 --> 00:33.650
Do you prefer your platform to be managed by a cloud provider or a self hosted?

00:33.650 --> 00:37.100
What kind of workloads are you going to run on this cluster?

00:37.100 --> 00:40.400
How many applications are to be hosted on the Cluster?

00:40.490 --> 00:42.050
Few or many?

00:42.050 --> 00:48.590
What kind of applications are going to be hosted on the Cluster?  Web applications or big data or analytics?

00:49.310 --> 00:53.880
Depending on the kind of application the resource requirements may vary.

00:53.900 --> 00:57.500
What type of network traffic are these applications expecting?

00:57.500 --> 01:00.900
Continuous heavy traffic or burst?

01:00.910 --> 01:03.510
Well let's try and break down some of these.

01:03.890 --> 01:09.320
If you want to deploy a cluster for learning purposes then a solution based on minikube or a single

01:09.320 --> 01:17.120
node cluster deployed using kubeadm on local VMs or cloud providers like GCP or AWS should do.

01:17.120 --> 01:22.550
We have deployed such a cluster in the beginners course. To deploy a cluster for development and testing

01:22.550 --> 01:28.310
purposes, and multi node cluster with single master and multiple worker nodes would help.

01:28.310 --> 01:34.580
Again kubeadm is an appropriate tool. Or if on managed cloud environments, then quickly provision a

01:34.580 --> 01:44.630
cluster on GCP, AWS or AKS on Azure. Letâ€™s talk about

01:44.660 --> 01:49.020
production level clusters. For hosting production grade applications.

01:49.070 --> 01:54.540
a High Availability Multi node cluster with multiple master nodes is recommended.

01:54.860 --> 02:01.370
We look at more details about High Availability setup with multiple-master nodes later in this section.

02:01.370 --> 02:08.570
Again this can be setup with kubeadm or GCP  or using kops on AWS or other supported platforms.

02:08.810 --> 02:15.270
You can have upto 5000 nodes in the cluster, a total of 150k PODs in the cluster,

02:15.300 --> 02:21.770
300,000 containers in total and upto 100 PODs per node. Depending on the size of your

02:21.770 --> 02:22.430
cluster.

02:22.430 --> 02:28.850
the resource requirement for your nodes varies. CSPs like GCP and AWS automatically

02:28.850 --> 02:34.100
selects the right sized nodes for you based on the number of nodes in the cluster.

02:34.100 --> 02:39.680
This table shows the size of the instances and their resource specifications for a specific number of

02:39.680 --> 02:40.100
nodes.

02:40.730 --> 02:47.420
If you are deploying on prem nodes then you could probably start with these numbers as base. Cloud or

02:47.420 --> 02:48.080
Onprem?

02:48.140 --> 02:53.840
We have already discussed that all of these deployment options are available in any environment. For

02:53.840 --> 02:54.830
on-prem

02:54.830 --> 02:57.120
kubeadm is a very useful tool.

02:57.200 --> 03:02.780
Google Container engine makes provisioning kubernetes clusters on GCP very easy.

03:02.780 --> 03:08.990
It comes with one-click cluster upgrade features that makes it very easy to maintain the cluster. KOPS

03:09.050 --> 03:15.890
is a nice tool to deploy kubernetes cluster on AWS and the Azure Kubernetes Service or AKS

03:15.980 --> 03:23.400
helps in managing the hosted kubernetes environment on Azure. Depending on the workloads configured, your

03:23.400 --> 03:30.600
node and disk configurations will differ. For High Performance workloads rely on SSD Backed Storage. For

03:30.600 --> 03:32.680
multiple concurrent access

03:32.730 --> 03:38.410
consider network based storage. For shared access to volumes across multiple PODs,

03:38.490 --> 03:42.910
Consider persistent storage volumes that we discussed in the storage section.

03:43.050 --> 03:49.230
Consider defining different classes of storage and allocating the right class to the right applications.

03:49.320 --> 03:53.410
The Nodes forming a kubernetes cluster can be physical or virtual

03:53.460 --> 03:59.740
In our case we will be deploying virtual machines on VirtualBox environments has nodes of our cluster.

03:59.850 --> 04:05.100
You may chose to deploy on physical machines or virtual machines or cloud environments like GCP,

04:05.260 --> 04:09.140
AWS, Azure or any other platform of your choice.

04:09.180 --> 04:14.550
We will be building a cluster with three nodes one master and two worker nodes.

04:14.550 --> 04:19.860
Now We know that master nodes are for hosting control plane components like the kube-api server, etcd

04:19.860 --> 04:24.030
server and others, while worker nodes for hosting workloads.

04:24.030 --> 04:26.830
However this is not a strict requirement.

04:26.850 --> 04:32.580
The master nodes are also considered as nodes and can host workloads. As a best practice

04:32.580 --> 04:38.370
it is recommended to dedicate master nodes for control plane components only specially in a production

04:38.370 --> 04:39.660
environment.

04:39.660 --> 04:46.350
Deployment tools like kubeadm prevent workloads from being hosted on master nodes by adding a taint to

04:46.350 --> 04:47.850
the master node.

04:48.010 --> 04:52.160
You must use 64 bit Linux operating system for nodes.

04:52.240 --> 04:57.200
Another thing to note is that typically you have all the control plane components on the master nodes.

04:57.370 --> 05:03.460
However, in large clusters you may chose to separate the ETCD clusters from the master node to its

05:03.550 --> 05:05.380
own cluster nodes.

05:05.410 --> 05:09.100
We will discuss more about the different topologies for that in the upcoming lecture

05:09.130 --> 05:14.080
when we talk about high availability setup. Well those are some of the considerations for designing a

05:14.080 --> 05:15.360
kubernetes cluster.

05:15.370 --> 05:20.490
Refer to the links in the references section for more details and some interesting reads.

05:20.560 --> 05:22.040
Well that's it for this lecture.

05:22.180 --> 05:28.420
Before you go from our certification exam standpoint there's really nothing much you need to remember

05:28.420 --> 05:29.200
from this section.

05:29.200 --> 05:34.540
You don't have to memorize the numbers that we discussed as these are available in the documentation

05:34.540 --> 05:41.660
page well we'll get into more interesting topics in the upcoming lectures in this section where we will

05:41.660 --> 05:46.530
provision an actual cluster from scratch by ourselves.

05:46.940 --> 05:48.820
Well that's it for this lecture.

05:48.860 --> 05:50.000
I'll see you in the next election.

