skip to Main Content

Is there anyway we can migrate Redis Cluster data that are running inside 2 different Kubernetes cluster? How we can communicate between Redis stateful pods which are running on two different Kubernetes Clusters?

We have two Redis Clusters which are running on two different Kubernetes Clusters X & Y. I want to transfer data from redis-X to redis-Y cluster. How we can establish connection between redis-X and redis-Y clusters so that we can migrate data?

Any help or hint is appreciated.

2

Answers


  1. There are two possible approaches to establish connection between clusters:

    1. Built-in solutions
    2. 3rd party solution

    Built-in solutions

    • NodePort – Exposes the service on each Node’s IP at a static port (the NodePort). A ClusterIP service, to which the NodePort service routes, is automatically created. You’ll be able to contact the NodePort service, from outside the cluster, by requesting <NodeIP>:<NodePort>
    • LoadBalancer – Exposes the Service externally using a cloud provider’s load balancer. NodePort and ClusterIP services, to which the external load balancer routes, are automatically created.
    • ingress (both 1st and 3rd party implementations) – more flexible then previous two, but only works with HTTP/HTTPS.

    Read more: Kubernets services, NGINX ingress

    3rd party solution

    Istio supports multi-cluster deployment model. However, if you don’t have service mesh deployed, doing so may be too much for single task use.


    Once you have connection established between clusters you can migrate Redis using MIGRATE command, or redis-migrate-tool proposed in comments.

    Login or Signup to reply.
  2. Here is a new approach using Skupper.

    https://github.com/bryonbaker/rhai-redis-demo

    It is a full step by step demo I wrote that shows a globally distributed real-time replicated cache from on-premises and across four kubernetes clusters. The Redis cache is replicated from on-premises to Sydney, London and and New York.

    No NodePorts, Submariner, or Istio Federation required. It all uses standard routes.

    The demo is based on OpenShift – but it will work with any flavour of xKS.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search