# Reading data from redis server into logstash input

**URL:** <https://discuss.elastic.co/t/reading-data-from-redis-server-into-logstash-input/192673>\
**Category:** Logstash\
**Created:** [July 29, 2019, 10:30am UTC](https://discuss.elastic.co/t/reading-data-from-redis-server-into-logstash-input/192673 "2019-07-29T10:30:27Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Madhu\_Neal1](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/madhu_neal1/32/51135_2.png) [@Madhu\_Neal1](https://discuss.elastic.co/u/Madhu_Neal1)\
**Post date:** [July 29, 2019, 10:30am UTC](https://discuss.elastic.co/t/reading-data-from-redis-server-into-logstash-input/192673/1 "2019-07-29T10:30:27Z")

</div>

Team,

Greeting of the day!

I like know how to read values which are saved in redis-server under the key and I have an input setting like this:

input {  
redis {  
host =\> "127.0.0.1"  
# these settings should match the output of the agent  
data\_type =\> "list"  
key =\> "Mneal"  
codec =\> "json"  
}  
}  
output {  
elasticsearch {  
hosts =\> ["localhost:9200"]  
index =\> "neal-redis-devicestbl-%{+YYYY.MM.dd}"  
}  
stdout {  
codec =\> rubydebug  
}  
}

Next when I run logstash it gives me an error: [logstash.inputs.redis] Redis connection problem {:exception=\>#\<Redis::CommandError: ERR Error running script (call to some\_value): @user\_script:2: WRONGTYPE Operation against a key holding the wrong kind of value\>}

ELK stack version: 7.2

Note: redis keys are in hash value but I like to know how to pass hash value via logstash?

Redis Cli - output for your reference:  
127.0.0.1:6379\> keys \*

1. "Mneal"  
127.0.0.1:6379\> type Mneal  
hash  
127.0.0.1:6379\>

Can you guys please help me here!

Many Thanks,  
Madhu

---

<div class="post-metadata">

**Author:** ![Madhu\_Neal1](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/madhu_neal1/32/51135_2.png) [@Madhu\_Neal1](https://discuss.elastic.co/u/Madhu_Neal1)\
**Post date:** [July 29, 2019, 1:56pm UTC](https://discuss.elastic.co/t/reading-data-from-redis-server-into-logstash-input/192673/2 "2019-07-29T13:56:00Z")

</div>

@andrewkroh: Can you please help me on this thread. 🙂 !

---

<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:** [August 26, 2019, 1:56pm UTC](https://discuss.elastic.co/t/reading-data-from-redis-server-into-logstash-input/192673/3 "2019-08-26T13:56:00Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
