0

I am trying to install datastax cassandra (DSE) on Kubernetes on Ubuntu. But getting the below error in the pod logs.

Apache Cassandra: Unable to gossip with any seeds

Replicas: 2

Heap memory given: 8GB

Ram Given: 16GB

Server: AWS EC2

Disk: Local provision

Note: Minikube is not required for this process

Here's my cluster.yaml file

apiVersion: apps/v1
kind: StatefulSet
metadata:
  name: cassandra
  namespace: cassandra
  labels:
    app: cassandra
spec:
  serviceName: cassandra
  replicas: 2
  selector:
    matchLabels:
      app: cassandra
  template:
    metadata:
      labels:
        app: cassandra
    spec:
      terminationGracePeriodSeconds: 1800
      containers:
      - name: cassandra
        image: datastax/dse-server:6.7.7
        imagePullPolicy: Always
        ports:
        - containerPort: 7000
          name: intra-node
        - containerPort: 7001
          name: tls-intra-node
        - containerPort: 7199
          name: jmx
        - containerPort: 9042
          name: cql
        resources:
          limits:
            cpu: "8000m"
            memory: 16Gi
          requests:
            cpu: "8000m"
            memory: 16Gi
        securityContext:
          capabilities:
            add:
              - IPC_LOCK
        lifecycle:
          preStop:
            exec:
              command:
              - /bin/sh
              - -c
              - nodetool drain

        env:
          - name: MAX_HEAP_SIZE
            value: 8G
          - name: HEAP_NEWSIZE
            value: 8G
          - name: SEEDS
            value: "10.32.0.2,10.32.0.5,10.32.0.6"
          - name: CLUSTER_NAME
            value: "Demo Cluster"
          - name: DC
            value: "dc1"
          - name: RACK
            value: "rack1"
          - name: NUM_TOKENS
            value: "128"
          - name: DS_LICENSE
            value: "accept"
          - name: POD_IP
            valueFrom:
              fieldRef:
                fieldPath: status.podIP
        readinessProbe:
          exec:
            command:
            - /bin/bash
            - -c
            - "cp /ready_probe.sh /tmp/ready_probe.sh && chmod 777 /tmp/ready_probe.sh && /tmp/ready_probe.sh"
          initialDelaySeconds: 20
          timeoutSeconds: 5                
        volumeMounts:
        - name: cassandra-data
          mountPath: /var/lib/cassandra
          subPath: cassandra
        - name: cassandra-data
          mountPath: /var/lib/spark
          subPath: spark
        - name: cassandra-data
          mountPath: /var/lib/dsefs
          subPath: dsefs
        - name: cassandra-data
          mountPath: /var/log/cassandra
          subPath: log-cassandra
        - name: cassandra-data
          mountPath: /var/log/spark
          subPath: log-spark
        - name: cassandra-data
          mountPath: /config
          subPath: config
        - name: cassandra-data
          mountPath: /var/lib/opscenter
          subPath: opscenter
        - name: cassandra-data
          mountPath: /var/lib/datastax-studio
          subPath: datastax-studio
        - name: script
          mountPath: /ready_probe.sh
          subPath: ready.sh
      volumes:
      - name: script
        configMap:
          name: script
      affinity:
        nodeAffinity:
          requiredDuringSchedulingIgnoredDuringExecution:
            nodeSelectorTerms:
            - matchExpressions:
              - key: kubernetes.io/hostname
                operator: In
                values:
                - ubuntuserver          
  volumeClaimTemplates:
  - metadata:
      name: cassandra-data
    spec:
      accessModes: [ "ReadWriteOnce" ]
      storageClassName: local-storage
      resources:
        requests:
          storage: 128Gi

Can anyone please help me with that?

  • Does this help you: https://stackoverflow.com/questions/20690987/apache-cassandra-unable-to-gossip-with-any-seeds – acid_fuji Mar 25 '21 at 08:11
  • You've mentioned that minikube is not needed but does that mean you're running this on minikube? – acid_fuji Mar 25 '21 at 08:12

0 Answers0