<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Re: Configuring an external Zookeeper to work with NiFi stand alone mode in Support Questions</title>
    <link>https://community.cloudera.com/t5/Support-Questions/Configuring-an-external-Zookeeper-to-work-with-NiFi-stand/m-p/191496#M153577</link>
    <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/525/mclarke.html" nodeid="525"&gt;@Matt Clarke&lt;/A&gt; &lt;/P&gt;&lt;P&gt;Hello, just wanted to update that this did not work. I changed the state-provider for &lt;A href="http://nifi.state.management.provider.local/"&gt;nifi.state.management.provider.local&lt;/A&gt; to zk-provider in nifi.properties file. Then I updated the state-management.xml file with the ZK properties.&lt;/P&gt;&lt;P&gt;nifi.properties change is below:&lt;/P&gt;&lt;PRE&gt;# The ID of the local state provider
nifi.state.management.provider.local=zk-provider
# The ID of the cluster-wide state provider. This will be ignored if NiFi is not clustered but must be populated if running in a cluster.
nifi.state.management.provider.cluster=zk-provider
&lt;/PRE&gt;
&lt;PRE&gt;&amp;lt;local-provider&amp;gt;
        &amp;lt;id&amp;gt;local-provider&amp;lt;/id&amp;gt;
        &amp;lt;class&amp;gt;org.apache.nifi.controller.state.providers.local.WriteAheadLocalStateProvider&amp;lt;/class&amp;gt;
        &amp;lt;property name="Directory"&amp;gt;./state/local&amp;lt;/property&amp;gt;
        &amp;lt;property name="Always Sync"&amp;gt;false&amp;lt;/property&amp;gt;
        &amp;lt;property name="Partitions"&amp;gt;16&amp;lt;/property&amp;gt;
        &amp;lt;property name="Checkpoint Interval"&amp;gt;2 mins&amp;lt;/property&amp;gt;
 &amp;lt;/local-provider&amp;gt;

&amp;lt;cluster-provider&amp;gt;
        &amp;lt;id&amp;gt;zk-provider&amp;lt;/id&amp;gt;
        &amp;lt;class&amp;gt;org.apache.nifi.controller.state.providers.zookeeper.ZooKeeperStateProvider&amp;lt;/class&amp;gt;
        &amp;lt;property name="Connect String"&amp;gt;myhostname:myport&amp;lt;/property&amp;gt;
        &amp;lt;property name="Root Node"&amp;gt;/nifi&amp;lt;/property&amp;gt;
        &amp;lt;property name="Session Timeout"&amp;gt;10 seconds&amp;lt;/property&amp;gt;
        &amp;lt;property name="Access Control"&amp;gt;Open&amp;lt;/property&amp;gt;
&amp;lt;/cluster-provider&amp;gt;&lt;/PRE&gt;&lt;P&gt;I have the correct hostname and port for zk-provider above in state-management.xml, I just have removed the entries in the post.&lt;/P&gt;&lt;P&gt;Question: Should be changing the root node?&lt;/P&gt;&lt;P&gt;Here is the error I am getting:&lt;/P&gt;&lt;PRE&gt;Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'flowService': FactoryBean threw exception on object creation; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'flowController': FactoryBean threw exception on object creation; nested exception is java.lang.IllegalStateException: Cannot create Local State Provider because the 'nifi.state.management.provider.local' property in the NiFi Properties file is set to 'zk-provider', but this id is assigned to a cluster-provider entry in the State Management Configuration File (/etc/nifi/state-management.xml), rather than a local-provider entry

Caused by: java.lang.IllegalStateException: Cannot create Local State Provider because the 'nifi.state.management.provider.local' property in the NiFi Properties file is set to 'zk-provider', but this id is assigned to a cluster-provider entry in the State Management Configuration File (/etc/nifi/state-management.xml), rather than a local-provider entry
	at org.apache.nifi.controller.state.manager.StandardStateManagerProvider.createStateProvider(StandardStateManagerProvider.java:157)
	at org.apache.nifi.controller.state.manager.StandardStateManagerProvider.createLocalStateProvider(StandardStateManagerProvider.java:87)
	at org.apache.nifi.controller.state.manager.StandardStateManagerProvider.create(StandardStateManagerProvider.java:73)
	at org.apache.nifi.controller.FlowController.&amp;lt;init&amp;gt;(FlowController.java:507)
	at org.apache.nifi.controller.FlowController.createStandaloneInstance(FlowController.java:409)
	at org.apache.nifi.spring.FlowControllerFactoryBean.getObject(FlowControllerFactoryBean.java:77)
	at org.springframework.beans.factory.support.FactoryBeanRegistrySupport.doGetObjectFromFactoryBean(FactoryBeanRegistrySupport.java:168)
	... 45 common frames omitted
2018-07-19 15:26:03,674 INFO [Thread-1] org.apache.nifi.NiFi Initiating shutdown of Jetty web server...
2018-07-19 15:26:03,821 INFO [Thread-1] o.eclipse.jetty.server.AbstractConnector Stopped ServerConnector@1ffe7c42{HTTP/1.1,[http/1.1]}{hdf-lab-0:8080}
2018-07-19 15:26:03,822 INFO [Thread-1] org.eclipse.jetty.server.session Stopped scavenging
Received trapped signal, beginning shutdown...&lt;/PRE&gt;&lt;P&gt;Is there other property settings I should use?&lt;/P&gt;&lt;P&gt;I would like to make NiFi work with containers.&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;</description>
    <pubDate>Thu, 19 Jul 2018 22:39:02 GMT</pubDate>
    <dc:creator>prachisharma432</dc:creator>
    <dc:date>2018-07-19T22:39:02Z</dc:date>
  </channel>
</rss>

