Support Questions
Find answers, ask questions, and share your expertise

docker container do not recover after nifi restart

docker container do not recover after nifi restart

New Contributor

Hi all, i'm running nifi on a docker container with TLS certificates

docker run --name nifi \ -v /Users/rogerio/certs:/opt/certs \ -p 8443:8443 \ -e AUTH=tls \ -e KEYSTORE_PATH=/opt/certs/server_keystore.jks \ -e KEYSTORE_TYPE=JKS \ -e KEYSTORE_PASSWORD=XXXXXX \ -e TRUSTSTORE_PATH=/opt/certs/server_truststore.jks \ -e TRUSTSTORE_PASSWORD=XXXXXX \ -e TRUSTSTORE_TYPE=JKS \ -e INITIAL_ADMIN_IDENTITY='CN=admin, OU=NIFI' -d \ apache/nifi:latest

I'm having the AccessDeniedExceptionMapper identity[OU=NIFI, CN=admin], groups[] does not have permission to access the requested resource. Unknown user with identity 'OU=NIFI, CN=admin'. Returning Forbidden response.

nifi@68a184386aa5:/opt/nifi/nifi-current/conf$ cat authoriz* | grep admin

<property name="Initial User Identity 1">admin</property>

<property name="Initial Admin Identity">admin</property>

<property name="Initial Admin Identity">admin</property>

nifi@68a184386aa5:/opt/nifi/nifi-current/conf$ cat users.xml

<?xml version="1.0" encoding="UTF-8" standalone="yes"?> <tenants> <groups/> <users> <user identifier="21232f29-7a57-35a7-8389-4a0e4a801fc3" identity="admin"/> </users> </tenants>

I scouted the internet and found a lot of material about this issue. The problem is that when I make the changes and restart nifi, it does not save the changes

nifi@68a184386aa5:/opt/nifi/nifi-current/bin$ ./nifi.sh restart

Java home: /docker-java-home/jre NiFi home: /opt/nifi/nifi-current Bootstrap Config File: /opt/nifi/nifi-current/conf/bootstrap.conf 2019-01-20 19:33:58,009 INFO [main] org.apache.nifi.bootstrap.Command Apache NiFi has accepted the Shutdown Command and is shutting down now 2019-01-20 19:33:58,091 INFO [main] org.apache.nifi.bootstrap.Command Waiting for Apache NiFi to finish shutting down... 2019-01-20 19:34:00,069 INFO [main] org.apache.nifi.bootstrap.Command Waiting for Apache NiFi to finish shutting down... 2019-01-20 19:34:02,078 INFO [main] org.apache.nifi.bootstrap.Command Waiting for Apache NiFi to finish shutting down...

➜ certs docker exec -it nifi bash Error response from daemon: Container 68a184386aa51b70bfae41b4f8bf138649d1f30ff8af25c89499cd199fb7e81a is not running

Actually, even the container is deleted.

Any ideia? Thanks

Rogerio