Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Accessing ElastiCache from EKS Cluster

I have set up an EKS cluster and I am trying to connect application pod to ElastiCache endpoint. I put both in same VPC and configured in/out security groups for them. Unfortunately while trying to telnet from pod to cache endpoint, it says "xxx.yyy.zzz.amazonaws.com: Unknown host". Is it even possible to make such a connection?

like image 752
admly Avatar asked May 02 '26 19:05

admly


2 Answers

Yes, if the security groups allow connectivity then you can connect from EKS pods to Elasticache. However, be aware that the DNS name may not resolve for some time (up to around 15 minutes) after you launch the Elasticache instance/cluster.

like image 82
jbg Avatar answered May 05 '26 10:05

jbg


I found an answer in the issue from cortexproject(monitoring tool based on Grafana stack).

Solved it using "addresses" instead "host" with the address of my memcached. It worked.

PS: "addresses" option isn't documented in the official documentation.

It has to view like this:

memcached_client:
  addresses: memcached.host
like image 32
PRIHLOP Avatar answered May 05 '26 09:05

PRIHLOP