Google Kubernetes Engine - Redis Master to Slave replication does not happen

4/9/2018

I have set-up a cluster under Google Kubernetes Engine and tried the GuestBook Redis image (Java). Was able to put a key onto Redis Master, however failing to read the value from the Slave. Tried to read it from Master itself and found the respective key and its value, however read from Slave fails and the reason could be replication not happening.

Tried the approach provided under page https://cloud.google.com/kubernetes-engine/docs/tutorials/guestbook (tried using JAVA).

I suppose the redis-slave-controller.yaml has the necessary configuration to set the replication, but still it does not work. Could someone please help what could be missing here?

-- V Siva Reddy
google-cloud-platform
google-kubernetes-engine
java
redis

1 Answer

4/10/2018

I was using the latest redis4 image (launcher.gcr.io/google/redis4:latest) for both master and slave and it seemed to be causing the replication issue. Could not find the right image for slave for the latest version and hence

I replaced the below images and it is working correctly now.

Redis Master image: gcr.io/google_containers/redis:latest
Redis Slave image: gcr.io/google_containers/redis-slave:v2

-- V Siva Reddy
Source: StackOverflow