Skip to content
Advertisement

Nifi Migration Required for blank Sensitive Properties Key

I’m using nifi 1.14.0 in container where I’m experiencing this problem when I restart nifi.

Migration Required for blank Sensitive Properties Key

erro
2021-09-07 01:15:03,672 INFO [main] o.a.n.p.AbstractBootstrapPropertiesLoader Determined default application properties path to be '/opt/nifi/nifi-current/./conf/nifi.properties'

2021-09-07 01:15:03,684 INFO [main] o.a.nifi.properties.NiFiPropertiesLoader Loaded 202 properties from /opt/nifi/nifi-current/./conf/nifi.properties

2021-09-07 01:15:03,700 ERROR [main] o.a.nifi.properties.NiFiPropertiesLoader Flow Configuration [./conf/flow.xml.gz] Found: Migration Required for blank Sensitive Properties Key [nifi.sensitive.props.key]

2021-09-07 01:15:03,704 ERROR [main] org.apache.nifi.NiFi Failure to launch NiFi due to java.lang.IllegalArgumentException: There was an issue decrypting protected properties

java.lang.IllegalArgumentException: There was an issue decrypting protected properties

at org.apache.nifi.NiFi.initializeProperties(NiFi.java:346)

at org.apache.nifi.NiFi.convertArgumentsToValidatedNiFiProperties(NiFi.java:314)

at org.apache.nifi.NiFi.convertArgumentsToValidatedNiFiProperties(NiFi.java:310)

at org.apache.nifi.NiFi.main(NiFi.java:302)

Caused by: org.apache.nifi.properties.SensitivePropertyProtectionException: Sensitive Properties Key [nifi.sensitive.props.key] not found: See Admin Guide section [Updating the Sensitive Properties Key]


at org.apache.nifi.properties.NiFiPropertiesLoader.getDefaultProperties(NiFiPropertiesLoader.java:226)

at org.apache.nifi.properties.NiFiPropertiesLoader.get(NiFiPropertiesLoader.java:209)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

at java.lang.reflect.Method.invoke(Method.java:498)

at org.apache.nifi.NiFi.initializeProperties(NiFi.java:341)

and in my file nifi.properties

security properties 
nifi.sensitive.props.key=l5bGW7Miy5Vv5sGTr8tXqLyVfpOdTnY0
nifi.sensitive.props.key.protected=l5bGW7Miy5Vv5sGTr8tXqLyVfpOdTnY0
nifi.sensitive.props.algorithm=NIFI_PBKDF2_AES_GCM_256
nifi.sensitive.props.provider=BC
nifi.sensitive.props.additional.keys=

can someone help me?

Advertisement

Answer

all I found so far is this nifi issue here.

If you find a nice workaround or simple solution please let me know 🙂

Greetings Oliver

EDIT:

Just found this Issue. I applied the changes in my own start.sh and it worked.

if [ -n "${NIFI_SENSITIVE_PROPS_KEY}" ]; then
    prop_replace 'nifi.sensitive.props.key' "${NIFI_SENSITIVE_PROPS_KEY}"
fi
4 People found this is helpful
Advertisement