Hello,
I've got an issue with the the ECK operator on Openshift when I'm trying to deploy an elasticsearch, when I deploy the elasticsearch object, I've got the following errors on the operator logs:
{"level":"info","@timestamp":"2020-02-10T15:23:21.824Z","logger":"elasticsearch-controller","message":"Ending reconciliation run","ver":"1.0.0-6881438d","iteration":16,"namespace":"mosaic-elk","name":"elasticsearch-sample","took":0.843814306}
{"level":"error","@timestamp":"2020-02-10T15:23:21.824Z","logger":"controller-runtime.controller","message":"Reconciler error","ver":"1.0.0-6881438d","controller":"elasticsearch-controller","request":"mosaic-elk/elasticsearch-sample","error":"the server could not find the requested resource (put elasticsearches.elasticsearch.k8s.elastic.co elasticsearch-sample)","errorCauses":[{"error":"the server could not find the requested resource (put elasticsearches.elasticsearch.k8s.elastic.co elasticsearch-sample)"}],"stacktrace":"github.com/go-logr/zapr.(*zapLogger).Error\n\t/go/pkg/mod/github.com/go-logr/zapr@v0.1.0/zapr.go:128\nsigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).reconcileHandler\n\t/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.4.0/pkg/internal/controller/controller.go:258\nsigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).processNextWorkItem\n\t/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.4.0/pkg/internal/controller/controller.go:232\nsigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).worker\n\t/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.4.0/pkg/internal/controller/controller.go:211\nk8s.io/apimachinery/pkg/util/wait.JitterUntil.func1\n\t/go/pkg/mod/k8s.io/apimachinery@v0.0.0-20191028221656-72ed19daf4bb/pkg/util/wait/wait.go:152\nk8s.io/apimachinery/pkg/util/wait.JitterUntil\n\t/go/pkg/mod/k8s.io/apimachinery@v0.0.0-20191028221656-72ed19daf4bb/pkg/util/wait/wait.go:153\nk8s.io/apimachinery/pkg/util/wait.Until\n\t/go/pkg/mod/k8s.io/apimachinery@v0.0.0-20191028221656-72ed19daf4bb/pkg/util/wait/wait.go:88"}
{"level":"debug","@timestamp":"2020-02-10T15:23:21.824Z","logger":"controller-runtime.manager.events","message":"Warning","ver":"1.0.0-6881438d","object":{"kind":"Elasticsearch","namespace":"mosaic-elk","name":"elasticsearch-sample","uid":"20adeb99-4c19-11ea-a947-fa163e7e2bbc","apiVersion":"elasticsearch.k8s.elastic.co/v1","resourceVersion":"7997994"},"reason":"ReconciliationError","message":"Reconciliation error: the server could not find the requested resource (put elasticsearches.elasticsearch.k8s.elastic.co elasticsearch-sample)"}
Despite having this error, an elasticsearch pod start:
$ oc get pods
NAME READY STATUS RESTARTS AGE
elastic-operator-0 1/1 Running 0 33m
elasticsearch-sample-es-default-0 1/1 Running 0 32m
$ oc get elasticsearch
NAME AGE
elasticsearch-sample 32m
I haven't been able to find any issue on github or subject on this forum discussing this error.
Here's the file I'm using for deploying elasticsearch:
apiVersion: elasticsearch.k8s.elastic.co/v1
kind: Elasticsearch
metadata:
name: elasticsearch-sample
spec:
baseImage: registry/elasticsearch
tag: v7.5.1
version: 7.5.1
nodeSets:
- name: default
count: 1
config:
node.master: true
node.data: true
node.store.allow_mmap: false
podTemplate:
metadata:
labels:
foo: bar
spec:
containers:
- name: elasticsearch
image: registry/elasticsearch:v7.5.1
resources:
requests:
memory: 1Gi
cpu: 1
limits:
memory: 2Gi
cpu: 1
volumeClaimTemplates:
- metadata:
name: elasticsearch-data
spec:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 1Gi
storageClassName: storage
Anyone ever encountered this issue ?
Thanks.