I'm encountering the following error when trying to install a Kafka Cluster via the Strimzi Operator
Steps to reproduce:
1) install olm:
kubectl create -f https://raw.githubusercontent.com/operator-framework/operator-lifecycle-manager/master/deploy/upstream/quickstart/olm.yaml
2)install strimzi-cluster-operator:
kubectl create -f https://operatorhub.io/install/strimzi-cluster-operator.v0.11.1.yaml
3)install the kafka-cluster (see https://operatorhub.io/operator/strimzi-cluster-operator.v0.11.1# , under "Custom resource Definitions, look for Kafka)
kubectl create -f kafka-cluster.yaml
, where the contents of kafka-cluster.yaml are:
apiVersion: kafka.strimzi.io/v1alpha1
kind: Kafka
metadata:
name: my-cluster
spec:
kafka:
version: 2.1.0
replicas: 3
listeners:
plain: {}
tls: {}
config:
offsets.topic.replication.factor: 3
transaction.state.log.replication.factor: 3
transaction.state.log.min.isr: 2
storage:
type: ephemeral
zookeeper:
replicas: 3
storage:
type: ephemeral
entityOperator:
topicOperator: {}
userOperator: {}
step 3 fails with the following error:
error: unable to recognize "kafka-cluster.yaml": no matches for kind "Kafka" in version "kafka.strimzi.io/v1alpha1"
Any advice? Thanks.
Well it looks like I just had to wait several minutes before running the 3rd command, even though all relevant pods were in the running state after issuing the 2nd command. (I assume it took some time for the kafka image to download.) It works fine.
NAME READY STATUS RESTARTS AGE
my-cluster-entity-operator-66fbf6bc5d-wqc96 1/3 Running 0 119s
my-cluster-kafka-0 2/2 Running 0 2m46s
my-cluster-kafka-1 2/2 Running 0 2m46s
my-cluster-kafka-2 2/2 Running 0 2m46s
my-cluster-zookeeper-0 2/2 Running 0 3m31s
my-cluster-zookeeper-1 2/2 Running 0 3m31s
my-cluster-zookeeper-2 2/2 Running 0 3m31s