Confluence - Configure Database

Hi,

 

I have a problem. I try configure Confluence, but I don't know what do in step "Configure Database".

I check options "java:comp/env/jdbc/DataSourceName" and "jdbc/DataSourceName". Still I can see this same error:

Setup Datasource Database Failed

The following error(s) occurred:

 
  • Could not lookup datasource successfully: com.atlassian.config.bootstrap.BootstrapException: Couldn't locate Datasource (java:comp/env/jdbc/) in the initial context. An object was bound to this name but whatever we found, it wasn't a Datasource:

Anyone can help me?

2 answers

0 votes

What database are you trying to connect to, and what connection settings are you giving to Confluence?

  • Did you restart after changing the server.xml file?
  • Can you show us the section of your server.xml file which describes the datasource, after hiding the passwords?

                      Yes, I did  restart server. I use postgresql. database.

                       server.xml :

                       <Resource name="jdbc/confluence" auth="Container" type="javax.sql.DataSource"
                        username="username"
                        password="password"
                        driverClassName="org.postgresql.Driver"
                        url="jdbc:postgresql://localhost:5432/database"
                        maxActive="20"
                        maxIdle="10"
                        validationQuery="select 1" />

 

                       I have file /atlassian/confluence/lib/postgresql-9.2-1004.jdbc4.jar on serer.

                       I add some text on end file /atlassian/confluence/confluence/WEB-INF/web.xml:

        <description>Connection Pool</description>

        <res-ref-name>jdbc/confluence</res-ref-name>

        <res-type>javax.sql.DataSource</res-type>

        <res-auth>Container</res-auth>

    </resource-ref>

 

 

 

 

Suggest an answer

Log in or Sign up to answer
Community showcase
Published Tuesday in Confluence

Introducing Praecipio Consulting, an Atlassian Solution Partner

Hey there Community!  My name is Vannya Vallejo, the Channel Communication Specialist at Atlassian and I want to help Atlassian users like you learn about our Solution Partners and how they c...

350 views 0 9
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you