Getting ready

There are some brief ideas you should understand about building a multiple-master system:

  • Add a load balancer server in front of the masters. The load balancer will become the new endpoint accessed by nodes and clients.
  • Every master runs its own API server.
  • Only one scheduler and one controller manager are eligible to work in the system, which can avoid conflicting directions from different daemons while managing containers. To achieve this setup, we enable the --leader-elect flag in the scheduler and controller manager. Only the one getting the lease can take duties.

In this recipe, we are going to build a two-master system via kubeadm, which has similar methods while scaling more masters. Users may also use other tools to build up HA Kubernetes clusters. Our target is to illustrate the general concepts.

Before starting, in addition to master nodes, you should prepare other necessary components in the systems:

  • Two Linux hosts, which will be set up as master nodes later. These machines should be configured as kubeadm masters. Please refer to the Setting up Kubernetes clusters on Linux by kubeadm recipe in Chapter 1Building Your Own Kubernetes Cluster. You should finish the Package installation and System configuring prerequisites parts on both hosts.
  • A LoadBalancer for masters. It would be much easier if you worked on the public cloud, that's said ELB of AWS and Load balancing of GCE.
  • An etcd cluster. Please check the Clustering etcd recipe in this chapter.
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.117.99.71