charts icon indicating copy to clipboard operation
charts copied to clipboard

k8 pods are not created in redis-cluster helm chart

Open abhishekGupta2205 opened this issue 3 years ago • 15 comments

Name and Version

bitnami/redis-cluster , 7.6.4

What steps will reproduce the bug?

installing helm chart

Are you using any custom parameters or values?

cluster.externalAcess.enbled=true

What is the expected behavior?

pods should be created

What do you see instead?

no pods are created and external ip also remains pending

Additional information

No response

abhishekGupta2205 avatar Jul 11 '22 05:07 abhishekGupta2205

Hi,

If the external IP is pending, then it seems to me that there kubernetes cluster is missing the proper external IP configuration. Which cluster are you using?

javsalgar avatar Jul 11 '22 10:07 javsalgar

minikube

abhishekGupta2205 avatar Jul 11 '22 13:07 abhishekGupta2205

Hi,

In this case, you need to enable addons like metallb in order to have external IPs. This link should help you https://faun.pub/metallb-configuration-in-minikube-to-enable-kubernetes-service-of-type-loadbalancer-9559739787df

javsalgar avatar Jul 13 '22 09:07 javsalgar

hi, i tried your suggestion and it is working fine . nodes are connecting to each other. But now dump.rdb file is not craeted in /bitnami/redis/data directory Screenshot from 2022-07-14 17-09-53

abhishekGupta2205 avatar Jul 14 '22 11:07 abhishekGupta2205

if i remove cluster.externalAccess.enabled =true then dump.rdb file is created

abhishekGupta2205 avatar Jul 14 '22 11:07 abhishekGupta2205

also many masters are not allotted any slots . Screenshot from 2022-07-14 17-48-04

abhishekGupta2205 avatar Jul 14 '22 12:07 abhishekGupta2205

i am only able to understand that the cluster is not created properly . can you tell the reason

abhishekGupta2205 avatar Jul 14 '22 12:07 abhishekGupta2205

Steps i did -

  1. install helm chart using externalacess.enabled =true parameter
  2. when i go inside the pod and execute redis-cli , i shows only one nodes. so i sent cluster meet command to connect to other nodes.
  3. when i tried using redis-cli to set the keys it show clusterdown hashslot not served. to solve it , i used (redis-cli --cluster fix) command to solve it
  4. now probelems which i am facing is that all the nodes are now masters and some nodes have no slot allocated and dump.rdb file is not created

abhishekGupta2205 avatar Jul 15 '22 06:07 abhishekGupta2205

Screenshot from 2022-07-15 12-32-03

abhishekGupta2205 avatar Jul 15 '22 07:07 abhishekGupta2205

Hi @abhishekgupta2205

When externalacess.enabled =true you need to perform some additional steps to set the external IPs. These steps are exposed in the notes after installing the helm chart. Example:

$ helm install redis-cluster bitnami/redis-cluster --version 7.6.4  --set cluster.externalAccess.enabled=true
NAME: redis-cluster
LAST DEPLOYED: Fri Jul 15 10:14:14 2022
NAMESPACE: default
STATUS: deployed
REVISION: 1
TEST SUITE: None
NOTES:
CHART NAME: redis-cluster
CHART VERSION: 7.6.4
APP VERSION: 6.2.7** Please be patient while the chart is being deployed **


To get your password run:
    export REDIS_PASSWORD=$(kubectl get secret --namespace "default" redis-cluster -o jsonpath="{.data.redis-password}" | base64 -d)

To connect to your Redis® server from outside the cluster check the following information:

  NOTE: It may take a few minutes for the LoadBalancer IP to be available.
        Watch the status with: 'kubectl get svc --namespace default -w redis-cluster'

    You will have a different external IP for each Redis® node. Get the external ip from `-external` suffixed services: `kubectl get svc`.
    Redis® port: 6379
    Once the LoadBalancerIPs are ready, you need to provide them and perform a Helm Upgrade:

    helm upgrade --namespace default redis-cluster --set "cluster.externalAccess.enabled=true,cluster.externalAccess.service.type=LoadBalancer,cluster.externalAccess.service.loadBalancerIP[0]=load-balancerip-0,cluster.externalAccess.service.loadBalancerIP[1]=load-balancerip-1,cluster.externalAccess.service.loadBalancerIP[2]=load-balancerip-2,cluster.externalAccess.service.loadBalancerIP[3]=load-balancerip-3,cluster.externalAccess.service.loadBalancerIP[4]=load-balancerip-4,cluster.externalAccess.service.loadBalancerIP[5]=load-balancerip-5" bitnami/redis-cluster
    Where loadbalancer-ip-i are the LoadBalancerIPs provided by the cluster.

fmulero avatar Jul 15 '22 08:07 fmulero

hi @fmulero i tried connecting to individual redis nodes through redis-cli by using external ip and nodeport provided , but could not connect to it. But i am able to connect through redis-cluster svc. is there any error or am i missing something. Screenshot from 2022-07-21 11-18-59

abhishekGupta2205 avatar Jul 21 '22 05:07 abhishekGupta2205

sir, external ip is also not created in kubernetes cluster. is there any alternate like metallb addon in minikube that i can use on kubernetes cluster so that external ip is created there also

abhishekGupta2205 avatar Jul 21 '22 12:07 abhishekGupta2205

Also can you suggest some other way to do the same functioning as cluster.externalaccess.enabled parameter is performing.

abhishekGupta2205 avatar Jul 21 '22 12:07 abhishekGupta2205

means without load balancer

abhishekGupta2205 avatar Jul 21 '22 12:07 abhishekGupta2205

This Issue has been automatically marked as "stale" because it has not had recent activity (for 15 days). It will be closed if no further activity occurs. Thanks for the feedback.

github-actions[bot] avatar Aug 06 '22 01:08 github-actions[bot]

Due to the lack of activity in the last 5 days since it was marked as "stale", we proceed to close this Issue. Do not hesitate to reopen it later if necessary.

github-actions[bot] avatar Aug 11 '22 01:08 github-actions[bot]