I've seen similar problems before, but wasn't sure whether I'd fully documented one particular issue, related to DB permissions.
So I'm boot-strapping my BPM database, post installation: -
/opt/ibm/WebSphereProfiles/Dmgr01/bin/bootstrapProcessServerData.sh -clusterName AppCluster
which returns: -
Bootstraping data into cluster AppCluster
WASX7357I: By request, this scripting client is not connected to any server process. Certain configuration and application operations will be available in local mode.
java.lang.Exception: java.lang.reflect.InvocationTargetException
…
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'handlersMap': Cannot create inner bean 'com.lombardisoftware.server.ejb.persistence.PSDefaultHandler#35a5e1c7' of type [com.lombardisoftware.server.ejb.persistence.PSDefaultHandler] while setting bean property 'sourceMap' with key [TypedStringValue: value [Task], target type [null]]; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'com.lombardisoftware.server.ejb.persistence.PSDefaultHandler#35a5e1c7' defined in class path resource [registry.persistence.xml]: Cannot resolve reference to bean 'dao.task' while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dao.task' defined in class path resource [registry.persistence.xml]: Instantiation of bean failed; nested exception is java.lang.ExceptionInInitializerError
…
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'message.routingCache' defined in class path resource [registry.xml]: Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationException: Could not instantiate bean class [com.lombardisoftware.bpd.runtime.engine.message.DefaultMessageRoutingCache]: Constructor threw exception; nested exception is org.springframework.jdbc.BadSqlGrammarException: PreparedStatementCallback; bad SQL grammar [select propvalue from lsw_system where propkey=?]; nested exception is com.ibm.db2.jcc.am.SqlSyntaxErrorException: DB2 SQL Error: SQLCODE=-551, SQLSTATE=42501, SQLERRMC=DB2USER1;SELECT;DB2USER1.LSW_SYSTEM, DRIVER=4.11.69
…
The DB messages lead one straight to root cause.
which returns: -
Bootstraping data into cluster AppCluster
WASX7357I: By request, this scripting client is not connected to any server process. Certain configuration and application operations will be available in local mode.
java.lang.Exception: java.lang.reflect.InvocationTargetException
…
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'handlersMap': Cannot create inner bean 'com.lombardisoftware.server.ejb.persistence.PSDefaultHandler#35a5e1c7' of type [com.lombardisoftware.server.ejb.persistence.PSDefaultHandler] while setting bean property 'sourceMap' with key [TypedStringValue: value [Task], target type [null]]; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'com.lombardisoftware.server.ejb.persistence.PSDefaultHandler#35a5e1c7' defined in class path resource [registry.persistence.xml]: Cannot resolve reference to bean 'dao.task' while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dao.task' defined in class path resource [registry.persistence.xml]: Instantiation of bean failed; nested exception is java.lang.ExceptionInInitializerError
…
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'message.routingCache' defined in class path resource [registry.xml]: Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationException: Could not instantiate bean class [com.lombardisoftware.bpd.runtime.engine.message.DefaultMessageRoutingCache]: Constructor threw exception; nested exception is org.springframework.jdbc.BadSqlGrammarException: PreparedStatementCallback; bad SQL grammar [select propvalue from lsw_system where propkey=?]; nested exception is com.ibm.db2.jcc.am.SqlSyntaxErrorException: DB2 SQL Error: SQLCODE=-551, SQLSTATE=42501, SQLERRMC=DB2USER1;SELECT;DB2USER1.LSW_SYSTEM, DRIVER=4.11.69
…
The DB messages lead one straight to root cause.
I'm using a different user - DB2USER1 - to connect from WAS to DB2, rather than the DB2 instance - DB2INST1 - which I'd normally use in lazybones fashion.
Whilst the DB2 instance has ALL rights to the database, this user does NOT.
Solution, give DB2USER1 the appropriate permissions - I chose DBADM - to the BPMDB database: -
db2 connect to BPMDB
db2 grant dbadm on database to user db2user1
db2 terminate
Sorted :-)
db2 connect to BPMDB
db2 grant dbadm on database to user db2user1
db2 terminate
Sorted :-)
Now my bootstrapping works as one would hope ....