Orange-OpenSource / nifikop

The NiFiKop NiFi Kubernetes operator makes it easy to run Apache NiFi on Kubernetes. Apache NiFI is a free, open-source solution that support powerful and scalable directed graphs of data routing, transformation, and system mediation logic.
https://orange-opensource.github.io/nifikop/
Apache License 2.0
128 stars 34 forks source link

Help with "Unknown user with identity..." #120

Closed celsomarques closed 3 years ago

celsomarques commented 3 years ago

Type of question

Question/Help

Question

What did you do? I'm migrating my config to Terraform and now I'm facing some issue

What did you expect to see?

What did you see instead? Under which circumstances?

ERROR controller-runtime.manager.controller.nifiuser Reconciler error {"reconciler group": "nifi.orange.com", "reconciler kind": "NifiUser", "name": "nifi-controller.nifi-dev.mgt.cluster.local", "namespace": "nifi-dev", "error": "could not connect to nifi nodes: nifi-headless.nifi-dev.svc.cluster.local:8443: non 200 response from NiFi cluster"}
ERROR nifi_client Unknown user with identity 'CN=nifi-controller.nifi-dev.mgt.cluster.local'. Contact the system administrator. {"error": "Non 200 response from nifi node: 403 Forbidden", "errorVerbose": "Non 200 response from nifi node: 403 Forbidden

Environment

Client Version: version.Info{Major:"1", Minor:"20", GitVersion:"v1.20.7", GitCommit:"132a687512d7fb058d0f5890f07d4121b3f0a2e2", GitTreeState:"clean", BuildDate:"2021-05-12T12:40:09Z", GoVersion:"go1.15.12", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"20+", GitVersion:"v1.20.8-gke.900", GitCommit:"28ab8501be88ea42e897ca8514d7cd0b436253d9", GitTreeState:"clean", BuildDate:"2021-06-30T09:23:36Z", GoVersion:"go1.15.13b5", Compiler:"gc", Platform:"linux/amd64"}

Terraform v1.0.3 on linux_amd64

Additional context

kubectl get -n nifi-dev nifiusers

NAME                                                   AGE
nifi-0-node.nifi-headless.nifi-dev.svc.cluster.local   137m
nifi-1-node.nifi-headless.nifi-dev.svc.cluster.local   137m
nifi-controller.nifi-dev.mgt.cluster.local             137m

Nifi pods are connected to Zookeeper and certificates are ok either.

celsomarques commented 3 years ago

The error was caused by space after CN= nifi.security.identity.mapping.pattern.dn=CN=([^,]*)(?:, (?:O|OU)=.*)?