Bonita_v6 with Tomcat installation

Hi,
I'm trying to install bonita 6 bundle tomcat whith MySql .
I followed this tutorial http://documentation.bonitasoft.com/tomcat-bundle and i have an exception :

    javax.servlet.ServletException: org.bonitasoft.console.common.server.utils.DefaultTenantIdException: Can't retrieve default tenant id
    org.bonitasoft.console.common.server.sso.filter.InternalSSOFilter.doFilter(InternalSSOFilter.java:109)

<p>
	root cause<br />
	org.bonitasoft.console.common.server.utils.DefaultTenantIdException: Can't retrieve default tenant id<br />
	&nbsp;&nbsp; &nbsp;org.bonitasoft.console.common.server.utils.TenantsManagementUtils.getDefaultTenantId(TenantsManagementUtils.java:205)<br />
	&nbsp;&nbsp; &nbsp;org.bonitasoft.console.common.server.login.TenantIdAccessor.getDefaultTenantId(TenantIdAccessor.java:52)<br />
	&nbsp;&nbsp; &nbsp;org.bonitasoft.console.common.server.login.TenantIdAccessor.ensureTenantId(TenantIdAccessor.java:46)<br />
	&nbsp;&nbsp; &nbsp;org.bonitasoft.console.common.server.login.filter.AutoLoginRule.doAuthorize(AutoLoginRule.java:31)<br />
	&nbsp;&nbsp; &nbsp;org.bonitasoft.console.common.server.login.filter.AuthorizationFilter.isAuthorized(AuthorizationFilter.java:86)<br />
	&nbsp;&nbsp; &nbsp;org.bonitasoft.console.common.server.login.filter.AuthorizationFilter.doAuthorizationFiltering(AuthorizationFilter.java:68)<br />
	&nbsp;&nbsp; &nbsp;org.bonitasoft.console.common.server.login.filter.AuthorizationFilter.doFilter(AuthorizationFilter.java:58)<br />
	&nbsp;&nbsp; &nbsp;org.bonitasoft.console.common.server.sso.filter.InternalSSOFilter.doFilter(InternalSSOFilter.java:103)</p>

<p>
	root cause<br />
	org.bonitasoft.engine.platform.NodeNotStartedException: The current node has not been started yet. Method PlatformAPI.startNode() must be called previously.<br />
	&nbsp;&nbsp; &nbsp;org.bonitasoft.engine.api.impl.ServerAPIImpl.invokeAPI(ServerAPIImpl.java:213)<br />
	&nbsp;&nbsp; &nbsp;org.bonitasoft.engine.api.impl.ServerAPIImpl.invokeMethod(ServerAPIImpl.java:105)<br />
	&nbsp;&nbsp; &nbsp;org.bonitasoft.engine.api.impl.ClientInterceptor.invoke(ClientInterceptor.java:88)<br />
	&nbsp;&nbsp; &nbsp;com.sun.proxy.$Proxy0.login(Unknown Source)<br />
	&nbsp;&nbsp; &nbsp;org.bonitasoft.console.common.server.utils.TenantsManagementUtils.getDefaultTenantId(TenantsManagementUtils.java:200)<br />
	&nbsp;&nbsp; &nbsp;org.bonitasoft.console.common.server.login.TenantIdAccessor.getDefaultTenantId(TenantIdAccessor.java:52)<br />
	&nbsp;&nbsp; &nbsp;org.bonitasoft.console.common.server.login.TenantIdAccessor.ensureTenantId(TenantIdAccessor.java:46)<br />
	&nbsp;&nbsp; &nbsp;org.bonitasoft.console.common.server.login.filter.AutoLoginRule.doAuthorize(AutoLoginRule.java:31)<br />
	&nbsp;&nbsp; &nbsp;org.bonitasoft.console.common.server.login.filter.AuthorizationFilter.isAuthorized(AuthorizationFilter.java:86)<br />
	&nbsp;&nbsp; &nbsp;org.bonitasoft.console.common.server.login.filter.AuthorizationFilter.doAuthorizationFiltering(AuthorizationFilter.java:68)<br />
	&nbsp;&nbsp; &nbsp;org.bonitasoft.console.common.server.login.filter.AuthorizationFilter.doFilter(AuthorizationFilter.java:58)<br />
	&nbsp;&nbsp; &nbsp;org.bonitasoft.console.common.server.sso.filter.InternalSSOFilter.doFilter(InternalSSOFilter.java:103)</p>


I tried :
    Stop the Tomcat server
    Edit the properties file in BONITA_HOME/bonita/client/platform/conf/platform-tenant-config.properties
    Set the parameter platform.create to true
    Delete the parameter platform.tenant.default.id

but nothing work , i have the same message ...
Any ideas ?

 

 

The documentation is not complete regarding setenv.sh - you need to include the DB_OPTS variable in CATALINA_OPTS:

open /usr/share/tomcat7/bin/setenv.sh and change the line starting with 'CATALINA_OPTS= ’ to this:

CATALINA_OPTS=“${CATALINA_OPTS} ${BONITA_HOME} ${BTM_OPTS} ${DB_OPTS} -Dfile.encoding=UTF-8 -Xshare:auto -Xms1024m -Xmx1024m -XX:MaxPermSize=256m -XX:+HeapDumpOnOutOfMemoryError”

Of course yo need to make sure you have defined DB_OPTS before CATALINA_OPTS

did you started the bundle with the default h2 database, before setting mysql ?

Thanks for your answer but i tried with a new  installation of tomcat and the result is the same

 

Hi,

In yourTOMCAT_HOME/bonita/server do you have a folder for MySQL?

No  , just the folder "tenants" and "platform".

I managed one time to access the portal
mysql table were created but now I have this exception

nobody for help me ?

 

i tried with the new bundle 6.2 and it work !

 

Hi!

How have you sucessed? I have  tried to configure bonitaBPM Community 6.1.1 and 6.2 for using Mysql but i have never sucessed. I tried with Ms Sqlserver but i receive the same error:

Etat HTTP 500 - org.bonitasoft.engine.platform. NodeNotStartedException: The current node has not been started yet. Method PlatformAPI.startNode() must be called previously.

Explain me how have you done, please. I have readen the tutorial "how to configure bonita for your SGBD

I got these similar errors in studio log while trying to publish organization. 

org.eclipse.core.commands.ExecutionException: 
    at org.bonitasoft.studio.actors.ui.handler.InstallOrganizationHandler.execute(InstallOrganizationHandler.java:116)
    at org.eclipse.ui.internal.handlers.HandlerProxy.execute(HandlerProxy.java:293)
    at org.eclipse.core.commands.Command.executeWithChecks(Command.java:476)
    at org.bonitasoft.studio.actors.ui.wizard.SynchronizeOrganizationWizard$1.run(SynchronizeOrganizationWizard.java:121)
    at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:121)
Caused by: org.bonitasoft.engine.platform.NodeNotStartedException: The current node has not been started yet. Method PlatformAPI.startNode() must be called previously.

i don't know  really why the tomcat 6.2 work now and not the 6.1.
With the version 6.2 i managed to access the portal and i had an error with mysql
i changed the file my.cnf , my-small.cnf , my-medium.cnf and my-large.cnf (largest packet) and  it work
i hope that can help you

Thank you, but tell me please. What do you imply by "i changed the file my.cnf , my-small.cnf , my-medium.cnf and my-large.cnf (largest packet) "

Have you removed this files or modified the content? and in wich repository are they?

 


Hi , koffiange67

try this ,

go to the folder "usr/share/mysql/"  //(with linux)
edit "my-large.cnf"
find the line "max_allowed_packet= ___"
increase the value
the same for my-medium.cnf ang my-small.cnf

Hi,

I am getting a same kind of error when I run my tomcat.
For the first time when i started my tomcat(with oracle11g as db) using startup.bat file, it started without any error and displayed me the bonita login page, then i shut it down.
When I started my tomcat for the second time, it starts without any error. But when i try to load bonita ‘http://localhost:8080/bonita’, it is giving me error “Node not started. Method ‘org.bonitasoft.engine.api.LoginAPI.login’ cannot be ca
lled until node has been started (PlatformAPI.startNode())”.

Also, I deleted server/tenant forder that was created when i run tomcat using h2.
When I run tomcat using oracle database for the first time, this folder appeared again and i deleted it. But after second run this is not appearing. Check if there is any link between above asked problem.

Please let me know how to resolve it.