ERROR Cannot bind datasource 'jdbc/nxactivities' in JNDI NamingException: Context is read only
I am running Nuxeo 5.5 Tomcat Distribution on PostgreSQL 9.1 with Social Collaboration enabled. On startup, I receive the following error.
ERROR [org.nuxeo.runtime.datasource.DataSourceComponent] Cannot bind datasource 'jdbc/nxactivities' in JNDI javax.naming.NamingException: Context is read only
at org.apache.naming.NamingContext.checkWritable(NamingContext.java:903)
at org.apache.naming.NamingContext.bind(NamingContext.java:831)
at org.apache.naming.NamingContext.bind(NamingContext.java:171)
at org.apache.naming.NamingContext.bind(NamingContext.java:187)
at org.nuxeo.runtime.datasource.DataSourceComponent.addDataSource(DataSourceComponent.java:119)
at org.nuxeo.runtime.datasource.DataSourceComponent.registerContribution(DataSourceComponent.java:81)
at org.nuxeo.runtime.model.DefaultComponent.registerExtension(DefaultComponent.java:39)
...
Later in the log during startup, I naturally receive the following error:
ERROR [org.hibernate.connection.DatasourceConnectionProvider] Could not find datasource: java:comp/env/jdbc/nxactivities javax.naming.NameNotFoundException: Name nxactivities is not bound in this Context
...
Any thoughts? Should I create a JIRA for this issue?
Hi again,
I think I managed to bypass the problem.
I commented the datasource in “nuxeo/WEB-INF/activity-datasource-config.xml” and declared it in my tomcat nuxeo.xml like this :
< ResourceLink global="jdbc/nuxeo" name="jdbc/nxactivities" type="javax.sql.DataSource"/>
Now I don't see any errors on startup or when I upload a file for instance.
I wanted to test the collaboration tab, but I got this error :
18:12:46,953 ERROR [OpenSocialAdapter] Unable to get gadget spec for publicsocialworkspaces org.apache.shindig.gadgets.GadgetException: Unable to retrieve spec for https://MyIp:8083/nuxeo/site/gadgets/publicsocialworkspaces/publicsocialworkspaces.xml. HTTP error 500
But I guess it's another issue ?
Hi, I have the same problem.
At startup :
ERROR [DataSourceComponent] Cannot bind datasource 'jdbc/nxactivities' in JNDI javax.naming.NamingException: Le Contexte est en lecture seule at org.apache.naming.NamingContext.checkWritable(NamingContext.java:903) at org.apache.naming.NamingContext.bind(NamingContext.java:831)
When I upload a file :
ERROR [DatasourceConnectionProvider] Could not find datasource: java:comp/env/jdbc/nxactivities javax.naming.NameNotFoundException: Le Nom nxactivities n'est pas lié à ce Contexte at org.apache.naming.NamingContext.lookup(NamingContext.java:770) at org.apache.naming.NamingContext.lookup(NamingContext.java:140)
Here is my server config :
OS: Linux (Ubuntu 11.10)
JDK: java-6-sun-1.6.0.31
Database: PostgreSQL 9.1
I bundled “nuxeo-cap-5.5-tomcat” in a static WAR and put it in my own Tomcat V6.0.35
I'm on https on port 8083, and use ldaps authentification.
FYI, the bundled version don't display the error when I launch it with nuxectl console. (nuxeoctl start don't work because I get this error but I guess it's another issue…)
Here is my nuxeo.conf
nuxeo.log.dir=/var/nuxeo-home/log nuxeo.pid.dir=/var/nuxeo-home/log nuxeo.data.dir=/var/nuxeo-home/data nuxeo.tmp.dir=/var/nuxeo-home/tmp nuxeo.web.dir=/var/nuxeo-home/web nuxeo.runtime.home=/var/nuxeo-home nuxeo.force.generation=false nuxeo.wizard.done=true nuxeo.templates=postgresql,dam,collaboration,https nuxeo.bind.address={myIP} nuxeo.server.emptySessionPath=false nuxeo.server.ajp.port=8009 nuxeo.server.https.port=8083 nuxeo.server.https.keystoreFile=/etc/tomcat/public.pfx nuxeo.server.https.keystorePass={myPass} nuxeo.server.tomcat-admin.port=8006 nuxeo.url=https://localhost:8083/nuxeo nuxeo.loopback.url=https://{MYIP}:8083/nuxeo opensocial.gadgets.port=8083 server.status.key={aKey} nuxeo.updatecenter.disabled=true nuxeo.db.name=nuxeodb nuxeo.db.user=nuxeodb nuxeo.db.password={myPass} mail.smtp.host=smtp.{myhost} mail.smtp.auth=true mail.smtp.username=postmaster%{myhost} mail.smtp.password={myPass}
I also changed nuxeo default config, data, tmp, web, log dir and also runtime home as explained here
Like ron said, any toughts on that? Thanks in advance.
I've tried myself with the nuxeo 5.5 HF06 distribution, and all worked fine.
bin/nuxeo.conf
?