# Logstash and redis High Availability

**URL:** <https://discuss.elastic.co/t/logstash-and-redis-high-availability/42275>\
**Category:** Logstash\
**Created:** [February 19, 2016, 8:45pm UTC](https://discuss.elastic.co/t/logstash-and-redis-high-availability/42275 "2016-02-19T20:45:25Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Python\_Coder](https://avatars.discourse-cdn.com/v4/letter/p/aeb1de/32.png) [@Python\_Coder](https://discuss.elastic.co/u/Python_Coder)\
**Post date:** [February 19, 2016, 8:45pm UTC](https://discuss.elastic.co/t/logstash-and-redis-high-availability/42275/1 "2016-02-19T20:45:25Z")

</div>

I have currently 2 Redis instances in active active modes using Redhat cluster and i'm feeding them with log shippers,  
We have 2 other servers with Logstash installed by which events would be popped up from both redis servers and stored into ElasticSearch.

Is it possible to to tell Logstash1 to pop up events from Redis1 and if Redis1 isn't available pop up events from Redis2 and vice versa????

Thanks

---

<div class="post-metadata">

**Author:** ![Python\_Coder](https://avatars.discourse-cdn.com/v4/letter/p/aeb1de/32.png) [@Python\_Coder](https://discuss.elastic.co/u/Python_Coder)\
**Post date:** [February 20, 2016, 2:49pm UTC](https://discuss.elastic.co/t/logstash-and-redis-high-availability/42275/2 "2016-02-20T14:49:21Z")

</div>

hello

---

<div class="post-metadata">

**Author:** ![Drew\_Town](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/drew_town/32/44829_2.png) [@Drew\_Town](https://discuss.elastic.co/u/Drew_Town)\
**Post date:** [February 21, 2016, 3:50pm UTC](https://discuss.elastic.co/t/logstash-and-redis-high-availability/42275/3 "2016-02-21T15:50:09Z")

</div>

I don't believe you can do this in Logstash itself. You would need to setup something like HAProxy that can check for up/down states and send the request somewhere based on hostname. I think that should get you where you want to go.

---

<div class="post-metadata">

**Author:** ![Python\_Coder](https://avatars.discourse-cdn.com/v4/letter/p/aeb1de/32.png) [@Python\_Coder](https://discuss.elastic.co/u/Python_Coder)\
**Post date:** [February 21, 2016, 4:32pm UTC](https://discuss.elastic.co/t/logstash-and-redis-high-availability/42275/4 "2016-02-21T16:32:14Z")

</div>

Thanks, instead of HAproxy, i'm using pacemaker (redhat cluster), both redis are in active active and being monitored by pacemaker itself, however, the issue is, logstash1 is popping event from redis1 and logstash2 is popping event from redis2. i needed a directive by which i can tell logstash pop up event from redis1 and if not available pop up event from redis2.  
thanks man, much appreciated

---

<div class="post-metadata">

**Author:** ![Joe\_Lawson](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/joe_lawson/32/3390_2.png) [@Joe\_Lawson](https://discuss.elastic.co/u/Joe_Lawson)\
**Post date:** [February 21, 2016, 5:47pm UTC](https://discuss.elastic.co/t/logstash-and-redis-high-availability/42275/5 "2016-02-21T17:47:37Z")

</div>

Kafka is very well suited for a distributed highly available queue. Check  
it out if you haven't.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 6, 2017, 5:10am UTC](https://discuss.elastic.co/t/logstash-and-redis-high-availability/42275/6 "2017-07-06T05:10:24Z")

</div>


