Notes to self: How do you know if a Redis cache is contactable?

I stood up a new Elasticache Redis cluster today for a colleague, and he was having trouble connecting. Often in AWS this means there’s a screwed up security group, but after checking the groups, he was still unable to connect.

So I logged into the staging server in question, raised my fingers to the keyboard and…

Realised I had no idea how to talk to Redis.

Luckily, the google is only a moment away.

First, installing telnet

The telnet client is not available by default, and I don’t install it at provision time. So from the PowerShell prompt, which is all I have available in Windows Core, I need to install it with Install-WindowsFeature.

Now, OK, so how do I connect to Redis?

Then what?

Best bet: issue the MONITOR command. This will give you a nice test of what’s going on in the cluster, and convince the developer standing at your left shoulder that yes, their web server can indeed talk to Redis.

Easy.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">