posted by 쁘로그래머 2018. 6. 28. 18:55

# Question

I'm looking for some pros and cons of whether to go with Marathon and Chronos, Docker Swarm or Kubernetes when running Docker containers on DC/OS.

For example, when is it better to use Marathon/Chronos than Kubernetes and vice versa?

Right now I'm mostly into experimenting but hopefully we'll start using one of these services in production after the summer. This may disqualify Docker Swarm since I'm not sure if it'll be production ready by then.

What I like about Docker Swarm is that it's essentially just "Docker commands" and you don't have to learn something completely new. We're already using docker-compose and that will work out of the box with Docker Swarm (at least in theory) so that would be a big plus. My main concern with Docker Swarm is if it'll cover all use cases required to run a system in production.

# Answer

I'll try to break down the unique aspects of each container orchestration framework on Mesos.

Use Docker Swarm if:

Use Kubernetes-Mesos if:

  • You want to launch K8s Pods, which are groups of containers co-scheduled and co-located together, sharing resources.
  • You want to launch a service alongside one or more sidekick containers (e.g. log archiver, metrics monitor) that live next to the parent container.
  • You want to use the K8s label-based service-discovery, load-balancing, and replication control.
  • See http://kubernetesio.blogspot.com/2015/04/kubernetes-and-mesosphere-dcos.html

Use Marathon if:

  • You want to launch Docker or non-Docker long-running apps/services.
  • You want to use Mesos attributes for constraint-based scheduling.
  • You want to use Application Groups and Dependencies to launch, scale, or upgrade related services.
  • You want to use health checks to automatically restart unhealthy services or rollback unhealthy deployments/upgrades.
  • You want to integrate HAProxy or Consul for service discovery.
  • You want to launch and monitor apps through a web UI or REST API.
  • You want to use a framework built from the start with Mesos in mind.

Use Chronos if:

  • You want to launch Docker or non-Docker tasks that are expected to exit.
  • You want to schedule a task to run at a specific time/schedule (a la cron).
  • You want to schedule a DAG workflow of dependent tasks.
  • You want to launch and monitor jobs through a web UI or REST API.
  • You want to use a framework built from the start with Mesos in mind.


source: https://stackoverflow.com/questions/29198840/marathon-vs-kubernetes-vs-docker-swarm-on-dc-os-with-docker-containers/29815033#29815033

posted by 쁘로그래머 2018. 6. 28. 18:52

# Question

What exactly is the difference between Apache's Mesos and Google's Kubernetes? I understand both are server cluster management software. Can anyone elaborate where the main differences are - when would which framework be preferred?

Why would you want to use Kubernetes on top of Mesosphere?

# Answer

Kubernetes is an open source project that brings 'Google style' cluster management capabilities to the world of virtual machines, or 'on the metal' scenarios. It works very well with modern operating system environments (like CoreOS or Red Hat Atomic) that offer up lightweight computing 'nodes' that are managed for you. It is written in Golang and is lightweight, modular, portable and extensible. We (the Kubernetes team) are working with a number of different technology companies (including Mesosphere who curate the Mesos open source project) to establish Kubernetes as the standard way to interact with computing clusters. The idea is to reproduce the patterns that we see people needing to build cluster applications based on our experience at Google. Some of these concepts include:

  • pods — a way to group containers together
  • replication controllers — a way to handle the lifecycle of containers
  • labels — a way to find and query containers, and
  • services — a set of containers performing a common function.

So with Kubernetes alone you will have something that is simple, easy to get up-and-running, portable and extensible that adds 'cluster' as a noun to the things that you manage in the lightest weight manner possible. Run an application on a cluster, and stop worrying about an individual machine. In this case, cluster is a flexible resource just like a VM. It is a logical computing unit. Turn it up, use it, resize it, turn it down quickly and easily.

With Mesos, there is a fair amount of overlap in terms of the basic vision, but the products are at quite different points in their lifecycle and have different sweet spots. Mesos is a distributed systems kernel that stitches together a lot of different machines into a logical computer. It was born for a world where you own a lot of physical resources to create a big static computing cluster. The great thing about it is that lots of modern scalable data processing application run well on Mesos (Hadoop, Kafka, Spark) and it is nice because you can run them all on the same basic resource pool, along with your new age container packaged apps. It is somewhat more heavy weight than the Kubernetes project, but is getting easier and easier to manage thanks to the work of folks like Mesosphere.

Now what gets really interesting is that Mesos is currently being adapted to add a lot of the Kubernetes concepts and to support the Kubernetes API. So it will be a gateway to getting more capabilities for your Kubernetes app (high availability master, more advanced scheduling semantics, ability to scale to a very large number of nodes) if you need them, and is well suited to run production workloads (Kubernetes is still in an alpha state).

When asked, I tend to say:

  1. Kubernetes is a great place to start if you are new to the clustering world; it is the quickest, easiest and lightest way to kick the tires and start experimenting with cluster oriented development. It offers a very high level of portability since it is being supported by a lot of different providers (Microsoft, IBM, Red Hat, CoreOs, MesoSphere, VMWare, etc).

  2. If you have existing workloads (Hadoop, Spark, Kafka, etc), Mesos gives you a framework that let's you interleave those workloads with each other, and mix in a some of the new stuff including Kubernetes apps.

  3. Mesos gives you an escape valve if you need capabilities that are not yet implemented by the community in the Kubernetes framework.

source: https://stackoverflow.com/questions/26705201/whats-the-difference-between-apaches-mesos-and-googles-kubernetes/26789308#26789308