DEV Community

Multi AZ Kubernetes with kops in AWS regions with only 2 AZ

Peter Gundel on March 30, 2017

At the moment we are setting up Kubernetes at store2be. We are a company from Germany and most of our business is taking place in Germany. Therefor...
Collapse
 
yevgeniyo profile image
Yevgeniy Ovsyannikov

This should be fixed!

kops create cluster --zones=us-east-1c --master-count=3 k8s.example.com will create 3 masters all in us-east-1c

You can also:

kops create cluster --zones=us-east-1b,us-east-1c --master-zones=us-east-1b,us-east-1c --master-count=3, it will round-robin around the master zones, so it will so pick b,c,b

Collapse
 
jbialy profile image
Janusz Bialy

In terms of high availability and in order to maintain proper quorum for the cluster, an odd number of master nodes should be used!

github.com/kubernetes/kops/blob/ma...

Collapse
 
peterfication profile image
Peter Gundel

This is true and this article doesn't state otherwise. It's just about getting a kind of high availability if you only have two AZ available.

Collapse
 
fii profile image
fii

How is storage shared between the AZs ? is does your storage span all AZs ?

Collapse
 
peterfication profile image
Peter Gundel

We don't use storage yet, because we only have containers that only need databases/S3 so far. But as far as I know this is not possible in AWS because EBSs can only be attached to EC2 instances in the same AZ.