Alternative to Kubernetes

Kubernetes, is a solution to manage containerized applications. But have we ever imagined what might be an alternative to Kubernetes ?

Below are few other solutions to manage as well, and these solutions are also popular:

1. Docker Swarm: Docker Swarm is native clustering for Docker. It turns a pool of Docker hosts into a single, virtual Docker host. Because, Docker swarm serves the standard Docker API, any tool that already communicates with a Docker daemon can use Swarm to transparently scale to multiple hosts. Few of the supported tools:

(a) Docker client
(b) Dokku
(c) Docker Compose
(d) Docker Machine
(e) Jenkins

Reference: Docker Swarm Overview

2. Apache Mesos: Apache Mesos is a great platform for fine grained resource sharing in the data center.

Reference: Apache Mesos Intro

3. Nomad: Nomad is a tool for managing a cluster of machines and running applications on them. Nomad abstracts away machines and the location of applications, and instead enable users to declare what they want to run and Nomad handles where they should run and how to run them.

Reference: Nomad Project

4. Marathon: Marathon is the framework that lets you orchestrate containers.

Reference: Marathon Intro

High Level Architecture of Kubernetes

Kubernetes Fundamentals

Kubernetes has six main components that need to be running to get a functioning cluster:
1. The API Server
2. The Scheduler
3. The controller manager
4. The kubelet
5. The proxy (alias kube proxy)
6. An etcd cluster

Each of these components can run as a standard Linux processes on your nodes, or they can run as Docker containers themselves.

kubearch
Image retrieved from @wattsteve Kubernetes training slide.

Components of Kubernetes cluster

Master Node: As seen from the above architectural diagram, the master node runs the API server, the scheduler, and the controller manager. The master node can also be configured in a multi-master highly available setup. The scheduler and controller elect a leader and the API servers can be fronted by a load balancer.

API Server: The API server exposes a REST interface to all of the Kubernetes resources and it is highly configurable.

Scheduler: The Scheduler main responsibility is to place the containers on the node in the cluster according to various policies, metrics, and resource requirements. It is also configurable via the command line flags.

Controller: The controller manager is responsible for reconciling the actual state of the the cluster with the desired state, as specified via the API. In effect, it is a control loop that performs actions based on the observed state of the cluster and the desired state. The main controller is also configurable.

Worker Nodes

All the worker nodes run the *kubelet* and *kube proxy*, as well as the Docker engine.

kubelet: The *kubelet* interacts with the underlying **Docker** engine also installed on all the nodes and makes sure that the containers that need to run are actually running.
kube-proxy: The kube-proxy is in charge of managing the network connectivity to the containers.

As an alternative to running a Docker Engine, you can also run Kubernetes with rkt, For more information on how to do this, you may refer to the documentaion: https://kubernetes.io/docs/getting-started-guides/rkt/

What is a Multicore Processor and Manycore Processor ?

Mutilcore Processor: A multi-core processor is a single computing component with two or more independent actual processing units (called “cores”), which are units that read and execute program instructions. The instructions are ordinary CPU instructions (such as add, move data, and branch), but the single processor can run multiple instructions on separate cores at the same time, increasing overall speed for programs amenable to parallel computing. Below is a sample diagram of the multicore architecture.

                                                 

Examples: AMD (A-Series,Athlon II,FX-Series,Phenom,Epyc); IBM(POWER 4, POWER 5, POWER 6), Intel (Core 2 Duo, Core i3, Core i5, Core i7)

Manycore ProcessorManycore processors are specialist multi-core processors designed for a high degree of parallel processing, containing a large number of simpler, independent processor cores (e.g. 10s, 100s, or 1,000s). Manycore processors are used extensively in embedded computers and high-performance computing.

Examples: Sunway TahiuLight (Chinese Supercomputer), GPU’s, Intel Xeon Phi, Tilera, Teraflops Research Chip, etc.

Difference between a CPU and GPU

Related image

A Central Processing Unit (CPU) is a general purpose processor – it can in principle do any computation, but not necessarily in an optimal fashion for any given computation. One can do graphics processing on a CPU – but it likely will not produce the result anywhere nearly as fast as a properly programmed GPU.

(CPU) MIMD: The MIMD architecture performs multiple actions simultaneously on numerous data pieces. One example is performing various mathematical calculations — such as addition and multiplication — simultaneously in order to solve a complex math problem with many separate components. MIMD computing may or may not be synchronized and is increasingly more common than SIMD computing.

A Graphical Processing Unit (GPU) is a special purpose processor, optimized for calculations commonly (and repeatedly) required for Computer Graphics, particularly SIMD operations.

(GPU) SIMD: The SIMD architecture performs a single, identical action simultaneously on multiple data pieces, including retrieving, calculating or storing information. One example is retrieving multiple files at the same time. Processors with local memory containing different data execute the same instruction in a synchronized fashion, with inter-processor communication for shift allocation.

Practical Differences: MIMD is frequently used for problems that break down algorithms into separate and independent parts, with each part assigned to a different processor for simultaneous solution; whereas, SIMD is typically used for problems requiring lots of computations with processors performing the same operation in parallel.