Collect server not working on Ubuntu (this is a multi-user environment)

  • Asked
  • Active
  • Viewed 2084 times
0

I have been trying for couple of weeks now but could not get a Collect server working on Ubuntu (this is a multi-user environment). I installed a latest Sqlite and postgresql driver but still the same. Can anyone help me with this issue.

Note: I'm using latest version of Collect server. I tried on both Tomcat 9 and 10 but still the same.

0

Accepted answer

Dear user,
First of all you should have contacted us early...!
Tomcat 10 for sure doesn't work with Collect because of some libraries used by Collect (e.g. Spring framework) that are still not compatible with Tomcat 10.
If you are installing Collect in a multi user environment, it would be preferable to use PostgreSQL and not SQLite as DBMS.
Do you have any errors in the log files when you start up Tomcat?
We will contact you to your private email address to better understand your problems.
Many thanks,
Open Foris Team

Thanks. Which version of tomcat would you prefer best for collect deployment.

simiti simiti

Please use the latest version of Tomcat 9 (9.0.60) until we make Collect work with Tomcat 10 too. Many thanks.

Stefano (OF) Stefano (OF) ♦♦

Some of the error message.

Caused by: javax.naming.NameNotFoundException: Name [jdbc/collectDs] is not bound in this Context. Unable to find [jdbc]. at org.apache.naming.NamingContext.lookup(NamingContext.java:824) ~[catalina.jar:8.5.77] at org.apache.naming.NamingContext.lookup(NamingContext.java:171) ~[catalina.jar:8.5.77] at org.apache.naming.SelectorContext.lookup(SelectorContext.java:161) ~[catalina.jar:8.5.77]

simiti simiti

org.springframework.web.context.ContextLoader - Context initialization failed org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'liquibase' defined in class path resource [org/openforis/collect/application-context-core.xml]:

simiti simiti

there is a problem with the configuration of the database... have you defined the file collect.xml inside tomcat/conf/Catalina/localhost? Is the configuration correct? Do you have any other errors related to the DB?

Stefano (OF) Stefano (OF) ♦♦

Here is my collect.xml <?xml version="1.0" encoding="UTF-8"?> <context path="/collect" reloadable="false">
<resource name="jdbc/collectDs" auth="Container" type="javax.sql.DataSource" factory="org.apache.commons.dbcp.BasicDataSourceFactory" driverclassname="org.postgresql.Driver" url="jdbc:&lt;a href=" postgresql:="" localhost:5432="" collect""="">postgresql://localhost:5432/collect" username="collect" password="collect123" initialSize="5" maxActive="20" maxIdle="5"> </resource> </context>

simiti simiti

I've gone through this link couple of times but still no luck. Just out of curiosity. what java version is preferred. I'm using version 11.

simiti simiti

The structure of your XML file seems to be broken.
The content of the file should be something like this:

<?xml version="1.0" encoding="UTF-8"?> <Context path="/collect" reloadable="false"> <Resource name="jdbc/collectDs" auth="Container" type="javax.sql.DataSource" factory="org.apache.commons.dbcp.BasicDataSourceFactory" driverClassName="org.postgresql.Driver" url="jdbc:postgresql://localhost:5432/collect" username="collect" password="REPLACE_THIS_WITH_YOUR_PASSWORD" initialSize="5" maxActive="20" maxIdle="5"> </Resource> </Context>

Stefano (OF) Stefano (OF) ♦♦

I didn't put the entire script because the number of character is more than what is allowed in this comment box.

simiti simiti

Here is the error when try to manually start the collect from tomcat. FAIL - Application at context path [/collect] could not be started

simiti simiti

We have contacted you to your private email, please answer that email, many thanks.

Stefano (OF) Stefano (OF) ♦♦
showing 5 of 12 show 7 more comments
0

Accepted answer

Thanks. Issue now resolved by adding to tomcat/lib these files. 1. commons-pool-1.6.jar 2. commons-dbcp-1.4.jar

All good now and thanks Openforis support.

Your answer

Markdown text. Shortcuts: Ctrl+B bold, Ctrl+I italic, Ctrl+K link, Ctrl+E code, Ctrl+Shift+V paste as plain text. Tab indents list items and code; press Escape, then Tab, to leave the text box.

Insert an image

Say what the image shows, for people who can't see it.

Keyboard shortcuts

Anywhere

?
Show this list
/
Search
g h
Go to the home page
g q
Go to the questions
g t
Go to the tags
g u
Go to the users
a
Ask a question

Lists of questions

j k
Next or previous question
Enter
Open the question

Question pages

j k
Next or previous post

Shortcuts never apply while you type in a text field. Members can turn them off in their preferences.