Skip to content

Instantly share code, notes, and snippets.

@yutannihilation
Last active January 7, 2020 08:56
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save yutannihilation/122c22222ad085865f63 to your computer and use it in GitHub Desktop.
Save yutannihilation/122c22222ad085865f63 to your computer and use it in GitHub Desktop.
Nomadについて調べたこと

Nomad

Intro

Nomadとは

  • cluster manager
  • task scheduler

Docker Support

Dockerをfirst-class workload typeにしている。

Operationally Simple

クライアントもサーバもひとつのバイナリ。外部リソースやストレージを必要としない。

分散マネジメントはSerfとかConsulによってつくられている

Multi-Datacenter and Multi-Region Aware

データセンタのグループを抽象化して「region」と捉えている。

region単位で行われるスケジューリングは、データセンタにまたがるスケジューリングを可能にする。

複数のregionは統合され、グローバルなジョブを登録することも可能。

Flexible Workloads

task driver(?)をサポートしているので、コンテナでも仮想マシンでも単独のアプリケーションでも動く。

LinuxでもWindowsでもBSDでもOSXでも。

Built for scale

耐障害性とか並列実行の最適化とか、いろいろいい感じにやってくれまっせ(超意訳)

Use Cases

Microservices Platform

However, they add an operational challenge of managing hundreds or thousands of services instead of a few large applications.

マイクロサービスってそんなものすごい量になるの…?

Hybrid Cloud Deployments

クラウドでもベアメタルでも。

E-Commerce

E-CommerceするにはいろいろあるけどNomadで大丈夫

Nomad vs. Other Software

AWS EC2

Nomadはオープンソースだし、Docker以外でもベアメタルでも使える。

Docker Swarm

Swarmはコンテナを抽象化している。Nomadはジョブを抽象化している。

Docker Swarmはデフォルトでは分散環境を想定していないし、可用性にも欠ける(active/standbyモデル)。

HTCondor

HTCondorはバッチのキューイングシステム。あんまり長期のサービスやバッチのワークロード用にデザインされていない。

Kuberetes

Kubernetes aims to provide all the features needed to run Docker based applications including cluster management, scheduling, service discovery, monitoring, secrets management and more.

Nomad only aims to provide cluster management and scheduling and is designed with the Unix philosophy of having a small scope while composing with tools like Consul for service discovery and Vault for secret management.

KuberetesはDockerに絞る代わりにサービスディスカバリからモニタリングまですべてを提供する。Nomadはクラスターマネジメントとスケジューリングしかしない。

Kubenetesはetcdに依存していたりと色々複雑。

Mesos with Aurora, Marathon

Mesosはリソースマネージャ。APIを通して、スケジューリングの仕組みを持つフレームワークと統合される。

Mesosは、スケジューリングをユーザ自身が考えなければならないことと、Zookeeperに調停とストレージの面で依存していることがつらみ。

Nomad is designed to be a global state, optimistically concurrent scheduler. Global state means schedulers get access to the entire state of the cluster when making decisions enabling richer constraints, job priorities, resource preemption, and faster placements.

あと、Nomadはregionという概念に分かれていることで、isolationとかscalabilityに優れている。

Terraform

Terraform is designed to support any type of resource including low-level components such as compute instances, storage, and networking, as well as high-level components such as DNS entries, SaaS features, etc. Terraform knows how to create, provision, and manage the lifecycle of these resources. Nomad runs on existing infrastructure and manages the lifecycle of applications running on that infrastructure.

Terraformはあらゆるリソースをサポートするように設計されていて、それをどう作ればいいか知っている。Nomadはすでにあるインフラの上で走る。

Terraformはoffline tool。Nomadは既にあるジョブを更新したり削除したりできる。

Hadoop YARN

YARNってHadoopだけですよね?

Getting Started

(まだみれてない)

Job Specification

Internals

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment