How to solve IgniteException: Can not perform the operation because the cluster is inactive Exception

1. The Exception

When we use Apache ignite ,when we want to enable the native persistence feature of it, we would add the following configurations to the config file of apache ignite:

<property name="dataStorageConfiguration">
  <bean class="org.apache.ignite.configuration.DataStorageConfiguration">
    <property name="defaultDataRegionConfiguration">
		<bean class="org.apache.ignite.configuration.DataRegionConfiguration">
	  		<property name="persistenceEnabled" value="true"/>

However, when we start the test again, we get this exception :

Query execution failed

SQL Error [50000]: 

class org.apache.ignite.IgniteException: Can not perform the operation because the cluster is inactive. Note, that the cluster is considered inactive by default if Ignite Persistent Store is used to let all the nodes join the cluster. To activate the cluster call

2. Environments

  • JDK 1.8
  • Apache ignite 2.6

3. Solve the problem

You need to activate the ignite after enabling the persistence feature like this:

 [user@bnode3 apache-ignite-fabric-2.6.0-bin]$ bin/ --activate
Control utility [ver. 2.6.0#20180710-sha1:669feacc]
2018 Copyright(C) Apache Software Foundation
User: user
Cluster activated
[user@bnode3 apache-ignite-fabric-2.6.0-bin]$

Now the problem solved. Hope it helps for you.