2019-02-20 18:10:29 -05:00
---
2019-08-21 00:48:59 -04:00
id: high-availability
title: "High availability"
2019-02-20 18:10:29 -05:00
---
<!--
~ Licensed to the Apache Software Foundation (ASF) under one
~ or more contributor license agreements. See the NOTICE file
~ distributed with this work for additional information
~ regarding copyright ownership. The ASF licenses this file
~ to you under the Apache License, Version 2.0 (the
~ "License"); you may not use this file except in compliance
~ with the License. You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing,
~ software distributed under the License is distributed on an
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
~ KIND, either express or implied. See the License for the
~ specific language governing permissions and limitations
~ under the License.
-->
2019-04-19 18:52:26 -04:00
Apache ZooKeeper, metadata store, the coordinator, the overlord, and brokers are recommended to set up a high availability environment.
2019-02-20 18:10:29 -05:00
- For highly-available ZooKeeper, you will need a cluster of 3 or 5 ZooKeeper nodes.
We recommend either installing ZooKeeper on its own hardware, or running 3 or 5 Master servers (where overlords or coordinators are running)
2020-12-17 16:37:43 -05:00
and configuring ZooKeeper on them appropriately. See the [ZooKeeper admin guide ](https://zookeeper.apache.org/doc/current/zookeeperAdmin ) for more details.
2019-02-20 18:10:29 -05:00
- For highly-available metadata storage, we recommend MySQL or PostgreSQL with replication and failover enabled.
See [MySQL HA/Scalability Guide ](https://dev.mysql.com/doc/mysql-ha-scalability/en/ )
2020-12-17 16:37:43 -05:00
and [PostgreSQL's High Availability, Load Balancing, and Replication ](https://www.postgresql.org/docs/current/high-availability.html ) for MySQL and PostgreSQL, respectively.
2020-01-03 12:33:19 -05:00
- For highly-available Apache Druid Coordinators and Overlords, we recommend to run multiple servers.
2019-02-20 18:10:29 -05:00
If they are all configured to use the same ZooKeeper cluster and metadata storage,
then they will automatically failover between each other as necessary.
Only one will be active at a time, but inactive servers will redirect to the currently active server.
- Druid Brokers can be scaled out and all running servers will be active and queryable.
2019-08-21 00:48:59 -04:00
We recommend placing them behind a load balancer.