Apache的Mesos和Google的Kubernetes有什么区别

本文翻译自:What's the difference between Apache's Mesos and Google's Kubernetes

What exactly is the difference between Apache's Mesos and Google's Kubernetes? Apache的Mesos和Google的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 ? 你为什么要在Mesosphere上使用Kubernetes


#1楼

参考:https://stackoom.com/question/1o3F3/Apache的Mesos和Google的Kubernetes有什么区别


#2楼

Kubernetes is an open source project that brings 'Google style' cluster management capabilities to the world of virtual machines, or 'on the metal' scenarios. Kubernetes是一个开源项目,为虚拟机世界或“金属”场景带来“谷歌风格”集群管理功能。 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. 它适用于现代操作系统环境(如CoreOS或Red Hat Atomic),可提供为您管理的轻量级计算“节点”。 It is written in Golang and is lightweight, modular, portable and extensible. 它是用Golang编写的,具有轻量级,模块化,可移植性和可扩展性。 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. 我们(Kubernetes团队)正在与许多不同的技术公司(包括策划Mesos开源项目的Mesosphere)合作,将Kubernetes建立为与计算集群交互的标准方式。 The idea is to reproduce the patterns that we see people needing to build cluster applications based on our experience at Google. 我们的想法是根据我们在Google的经验,重现我们看到人们需要构建群集应用程序的模式。 Some of these concepts include: 其中一些概念包括:

  • pods — a way to group containers together pods - 将容器组合在一起的方法
  • 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. services - 一组执行常用功能的容器。

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. 因此,仅使用Kubernetes,您就会拥有一些简单,易于启动,可移植和可扩展的功能,可以将“群集”作为名词添加到您以最轻的方式管理的事物中。 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. 在这种情况下,群集就像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,在基本视觉方面存在相当多的重叠,但产品在其生命周期中处于完全不同的点并且具有不同的甜点。 Mesos is a distributed systems kernel that stitches together a lot of different machines into a logical computer. Mesos是一个分布式系统内核,它将许多不同的机器拼接成逻辑计算机。 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. 最棒的是,许多现代可扩展的数据处理应用程序在Mesos(Hadoop,Kafka,Spark)上运行良好,这很好,因为您可以在同一个基本资源池上运行它们,以及新的容器打包应用程序。 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. 它比Kubernetes项目更重,但由于像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. 现在真正有趣的是,Mesos目前正在适应添加大量Kubernetes概念并支持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). 因此,它将成为获取Kubernetes应用程序更多功能的门户(高可用性主,更高级的调度语义,扩展到大量节点的能力),如果您需要它们,并且非常适合运行生产工作负载(Kubernetes)仍处于阿尔法状态)。

When asked, I tend to say: 当被问到时,我倾向于说:

  1. Kubernetes is a great place to start if you are new to the clustering world; 如果您不熟悉聚类世界,Kubernetes是一个很好的起点; 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). 它提供了非常高的可移植性,因为它得到了许多不同提供商(Microsoft,IBM,Red Hat,CoreOs,MesoSphere,VMWare等)的支持。

  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. 如果您有现有的工作负载(Hadoop,Spark,Kafka等),Mesos会为您提供一个框架,让您可以将这些工作负载相互交错,并混合使用包括Kubernetes应用程序在内的一些新工具。

  3. Mesos gives you an escape valve if you need capabilities that are not yet implemented by the community in the Kubernetes framework. 如果您需要Kubernetes框架中社区尚未实现的功能,Mesos会为您提供一个逃生阀。


#3楼

Kubernetes and Mesos are a match made in heaven. Kubernetes和Mesos是天作之合。 Kubernetes enables the Pod (group of co-located containers) abstraction, along with Pod labels for service discovery, load-balancing, and replication control. Kubernetes支持Pod(一组共存容器)抽象,以及用于服务发现,负载平衡和复制控制的Pod标签。 Mesos provides the fine-grained resource allocations for pods across nodes in a cluster, and can make Kubernetes play nicely with other frameworks running on the same cluster resources. Mesos为群集中节点之间的pod提供了细粒度的资源分配,并且可以使Kubernetes与在相同群集资源上运行的其他框架很好地协作。

from readme of kubernetes-mesos 来自kubernetes-mesos的自述文件


#4楼

Mesos and Kubernetes can both be used to manage a cluster of machines and abstract away the hardware. Mesos和Kubernetes都可以用来管理一组机器并抽象出硬件。

Mesos, by design, doesn't provide you with a scheduler (to decide where and when to run processes and what to do if the process fails), you can use something like Marathon or Chronos, or write your own. 根据设计,Mesos不会为您提供调度程序(决定运行进程的位置和时间以及进程失败时该怎么做),您可以使用Marathon或Chronos之类的东西,或编写自己的程序。

Kubernetes will do scheduling for you out of the box, and can be used as a scheduler for Mesos (please correct me if I'm wrong here!) which is where you can use them together. Kubernetes将为您安排开箱即用,并可用作Mesos的调度程序(如果我在这里错了,请纠正我!),这是您可以一起使用它们的地方。 Mesos can have multiple schedulers sharing the same cluster, so in theory you could run kubernetes and chronos together on the same hardware. Mesos可以有多个调度程序共享同一个集群,因此从理论上讲,您可以在同一个硬件上一起运行kubernetes和chronos。

Super simplistically: if you want control over how your containers are scheduled, go for Mesos, otherwise Kubernetes rocks. 超级简单化:如果你想控制容器的安排方式,那就选择Mesos,否则Kubernetes会摇滚。


#5楼

Both projects aim to make it easier to deploy & manage applications inside containers in your datacenter or cloud. 这两个项目旨在简化在数据中心或云中的容器内部署和管理应用程序的过程。

In order to deploy applications on top of Mesos, one can use Marathon or Kubernetes for Mesos. 为了在Mesos上部署应用程序,可以使用Marathon或Kubernetes for Mesos。

Marathon is a cluster-wide init and control system for running Linux services in cgroups and Docker containers. Marathon是一个集群范围的init和控制系统,用于在cgroups和Docker容器中运行Linux服务。 Marathon has a number of different canary deploy features and is a very mature project. Marathon具有许多不同的canary部署功能,是一个非常成熟的项目。

Marathon runs on top of Mesos, which is a highly scalable, battle tested and flexible resource manager. Marathon运行在Mesos之上,这是一个高度可扩展,经过实战考验且灵活的资源管理器。 Marathon is proven to scale and runs in many production environments. 事实证明,Marathon可以在许多生产环境中扩展和运行。

The Mesos and Mesosphere technology stack provides a cloud-like environment for running existing Linux workloads, but it also provides a native environment for building new distributed systems. Mesos和Mesosphere技术堆栈为运行现有Linux工作负载提供了类似云的环境,但它也为构建新的分布式系统提供了本机环境。

Mesos is a distributed systems kernel, with a full API for programming directly against the datacenter. Mesos是一个分布式系统内核,具有完整的API,可直接针对数据中心进行编程。 It abstracts underlying hardware (eg bare metal or VMs) away and just exposes the resources. 它抽象出底层硬件(例如裸机或虚拟机),只是暴露资源。 It contains primitives for writing distributed applications (eg Spark was originally a Mesos App, Chronos, etc.) such as Message Passing, Task Execution, etc. Thus, entirely new applications are made possible. 它包含用于编写分布式应用程序的原语(例如Spark最初是Mesos App,Chronos等),例如消息传递,任务执行等。因此,全新的应用程序成为可能。 Apache Spark is one example for a new (in Mesos jargon called) framework that was built originally for Mesos. Apache Spark是最初为Mesos构建的新(在Mesos术语中称为)框架的一个示例。 This enabled really fast development - the developers of Spark didn't have to worry about networking to distribute tasks amongst nodes as this is a core primitive in Mesos. 这实现了非常快速的开发--Spark的开发人员不必担心网络在节点之间分配任务,因为这是Mesos中的核心原语。

To my knowledge, Kubernetes is not used inside Google in production deployments today. 据我所知,今天在生产部署中,Kubernetes并未在Google内部使用。 For production, Google uses Omega/Borg, which is much more similar to the Mesos/Marathon model. 对于制作,谷歌使用Omega / Borg,它与Mesos / Marathon模型更相似。 However the great thing about using Mesos as the foundation is that both Kubernetes and Marathon can run on top of it. 然而,使用Mesos作为基础的好处是Kubernetes和Marathon都可以在它上面运行。

More resources about Marathon: 关于Marathon的更多资源:

https://mesosphere.github.io/marathon/ https://mesosphere.github.io/marathon/

Video: https://www.youtube.com/watch?v=hZNGST2vIds 视频: https//www.youtube.com/watch?v = hZNGST2vIds


#6楼

I like this short video here mesos learning material 我喜欢这个简短的视频,这里是mesos学习资料

with bare metal clusters, you would need to spawn stacks like HDFS, SPARK, MR etc... so if you launch tasks related to these using only bare metal cluster management, there will be a lot cold starting time. 对于裸机金属集群,您需要生成HDFS,SPARK,MR等堆栈...因此,如果仅使用裸机集群管理启动与这些相关的任务,则会有很多冷启动时间。

with mesos, you can install these services on top of the bare metals and you can avoid the bring up time of those base services. 使用mesos,您可以在裸机上安装这些服务,您可以避免这些基本服务的启动时间。 This is something mesos does well. 这是mesos做得很好的事情。 and can be utilised by kubernetes building on top of it. 并且可以被建在其上的kubernetes使用。

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值