[Dspace-tech] Error : ant fresh_install

13 views
Skip to first unread message

SANDEEP BHAVSAR

unread,
Aug 25, 2015, 1:10:26 PM8/25/15
to dspac...@lists.sourceforge.net
Respected All

Please help me in solving this error !!


dspace@sbhavsar-server:~/
dspace-1.5.2-src-release/dspace/target/dspace-1.5.2-build.dir$ ant fresh_install
Buildfile: build.xml

init_installation:

init_configs:

setup_database:
     [java] 2009-10-27 15:51:16,778 INFO  org.dspace.core.ConfigurationManager @ Loading system provided config property (-Ddspace.configuration): config/dspace.cfg
     [java] 2009-10-27 15:51:16,814 INFO  org.dspace.core.ConfigurationManager @ Using default log4j provided log configuration,if uninitended, check your dspace.cfg for (log.init.config)
     [java] 2009-10-27 15:51:16,815 INFO  org.dspace.storage.rdbms.InitializeDatabase @ Initializing Database
     [java] 2009-10-27 15:51:17,368 FATAL org.dspace.storage.rdbms.InitializeDatabase @ Caught exception:
     [java] org.postgresql.util.PSQLException: FATAL: password authentication failed for user "dspace"
     [java]     at org.postgresql.core.v3.ConnectionFactoryImpl.doAuthentication(ConnectionFactoryImpl.java:275)
     [java]     at org.postgresql.core.v3.ConnectionFactoryImpl.openConnectionImpl(ConnectionFactoryImpl.java:94)
     [java]     at org.postgresql.core.ConnectionFactory.openConnection(ConnectionFactory.java:65)
     [java]     at org.postgresql.jdbc2.AbstractJdbc2Connection.<init>(AbstractJdbc2Connection.java:116)
     [java]     at org.postgresql.jdbc3.AbstractJdbc3Connection.<init>(AbstractJdbc3Connection.java:30)
     [java]     at org.postgresql.jdbc3.Jdbc3Connection.<init>(Jdbc3Connection.java:24)
     [java]     at org.postgresql.Driver.makeConnection(Driver.java:369)
     [java]     at org.postgresql.Driver.connect(Driver.java:245)
     [java]     at java.sql.DriverManager.getConnection(DriverManager.java:582)
     [java]     at java.sql.DriverManager.getConnection(DriverManager.java:185)
     [java]     at org.apache.commons.dbcp.DriverManagerConnectionFactory.createConnection(DriverManagerConnectionFactory.java:65)
     [java]     at org.apache.commons.dbcp.PoolableConnectionFactory.makeObject(PoolableConnectionFactory.java:294)
     [java]     at org.apache.commons.pool.impl.GenericObjectPool.borrowObject(GenericObjectPool.java:974)
     [java]     at org.apache.commons.dbcp.PoolingDriver.connect(PoolingDriver.java:176)
     [java]     at java.sql.DriverManager.getConnection(DriverManager.java:582)
     [java]     at java.sql.DriverManager.getConnection(DriverManager.java:207)
     [java]     at org.dspace.storage.rdbms.DatabaseManager.getConnection(DatabaseManager.java:550)
     [java]     at org.dspace.storage.rdbms.DatabaseManager.loadSql(DatabaseManager.java:923)
     [java]     at org.dspace.storage.rdbms.InitializeDatabase.main(InitializeDatabase.java:100)

BUILD FAILED
/home/dspace/dspace-1.5.2-src-release/dspace/target/dspace-1.5.2-build.dir/build.xml:585: Java returned: 1


--
Thanks and Regards

Sandeep Bhavsar
Librarian
Dr.V.N.Bedekar Institute of Management Studies
Thane(W) 400601
MUMBAI. INDIA
@@@@@@@@@@@@@@@@@@@@@@@@@@
email    : sandeep...@gmail.com
Mob     : 9987049099
elibrary :http://www.vpmthane.org/im/elib/main.htm
@@@@@@@@@@@@@@@@@@@@@@@@@@

Claudia Jürgen

unread,
Aug 25, 2015, 1:10:27 PM8/25/15
to SANDEEP BHAVSAR, dspac...@lists.sourceforge.net
Hello Sandeep,

check your dspace configuration and make sure you got the database
settings (database name, database user, database user password) right,
they are in the following section of dspace.cfg:

##### Database settings #####

# Database name ("oracle", or "postgres")
db.name = ${default.db.name}
#db.name = postgres
#db.name = oracle

# URL for connecting to database
db.url = ${default.db.url}
#db.url = jdbc:postgresql://localhost:5432/dspace

# JDBC Driver
db.driver = ${default.db.driver}
#db.driver = org.postgresql.Driver

# Database username and password
db.username = ${default.db.username}
db.password = ${default.db.password}
#db.username = dspace
#db.password = dspace

Hope that helps

Claudia Jürgen




SANDEEP BHAVSAR schrieb:
> ------------------------------------------------------------------------
>
> ------------------------------------------------------------------------------
> Come build with us! The BlackBerry(R) Developer Conference in SF, CA
> is the only developer event you need to attend this year. Jumpstart your
> developing skills, take BlackBerry mobile applications to market and stay
> ahead of the curve. Join us from November 9 - 12, 2009. Register now!
> http://p.sf.net/sfu/devconference
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> DSpace-tech mailing list
> DSpac...@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/dspace-tech
Claudia_Juergen.vcf

SANDEEP BHAVSAR

unread,
Aug 25, 2015, 1:10:29 PM8/25/15
to Claudia...@ub.tu-dortmund.de, dspac...@lists.sourceforge.net
Respected Claudia Juergen

Please have  a look at my Database Settings


##### Database settings #####
# Database name ("oracle", or "postgres")
db.name = postgres

#db.name = postgres
#db.name = oracle
# URL for connecting to database

db.url = jdbc:postgresql://localhost:5432/dspace

#db.url = jdbc:postgresql://localhost:5432/dspace
# JDBC Driver
db.driver = org.postgresql.Driver

#db.driver = org.postgresql.Driver
# Database username and password
db.username = dspace
db.password = dspace

#db.username = dspace
#db.password = dspace

I tried with your settings also but facing the same error.

Thanks and Regards

2009/10/28 Claudia Jürgen <Claudia...@ub.tu-dortmund.de>

Claudia Jürgen

unread,
Aug 25, 2015, 1:10:30 PM8/25/15
to SANDEEP BHAVSAR, dspac...@lists.sourceforge.net
Hello Sandeep,

this depends on what you have done during Step 3 of the installation,
see section 3.2.3 of the manual:
________________________________________

3. Database Setup

Postgres:

a. A PostgreSQL 8.1-404 jdbc3 driver is configure as part of the default
DSpace build. You no longer need to
copy any postgres jars to get postgres installed.

b. Create a dspace database, owned by the dspace PostgreSQL user:

createuser -U postgres -d -A -P dspace
^
the db user

createdb -U dspace -E UNICODE dspace
^
the database name

Enter a password for the DSpace database. (This isn't the same as the
dspace user's UNIX password.)
__________________________________________


So how did you name the user under which the db was created?

How did you name the database?

What password did you enter?

You should use these values in the dspace.cfg
Claudia_Juergen.vcf

SANDEEP BHAVSAR

unread,
Aug 25, 2015, 1:10:31 PM8/25/15
to dspac...@lists.sourceforge.net


On Wed, Oct 28, 2009 at 4:01 PM, SANDEEP BHAVSAR <sandeep...@gmail.com> wrote:
I think i use the same password ( same as the dspace user's UNIX password).
But what is the solution now . Please Help !!!!
--
Thanks and Regards

Sandeep Bhavsar
Librarian
Dr.V.N.Bedekar Institute of Management Studies
Thane(W) 400601
MUMBAI. INDIA
@@@@@@@@@@@@@@@@@@@@@@@@@@
email    : sandeep...@gmail.com
Mob     : 9987049099
elibrary :http://www.vpmthane.org/im/elib/main.htm
@@@@@@@@@@@@@@@@@@@@@@@@@@

Mark H. Wood

unread,
Aug 25, 2015, 1:10:34 PM8/25/15
to dspac...@lists.sourceforge.net
On Wed, Oct 28, 2009 at 03:02:55PM +0530, SANDEEP BHAVSAR wrote:
> dspace@sbhavsar-server:~/
> dspace-1.5.2-src-release/dspace/target/dspace-1.5.2-build.dir$ ant
> fresh_install
> Buildfile: build.xml
>
> init_installation:
>
> init_configs:
>
> setup_database:
> [java] 2009-10-27 15:51:16,778 INFO
> org.dspace.core.ConfigurationManager @ Loading system provided config
> property (-Ddspace.configuration): config/dspace.cfg
> [java] 2009-10-27 15:51:16,814 INFO
> org.dspace.core.ConfigurationManager @ Using default log4j provided log
> configuration,if uninitended, check your dspace.cfg for (log.init.config)
> [java] 2009-10-27 15:51:16,815 INFO
> org.dspace.storage.rdbms.InitializeDatabase @ Initializing Database
> [java] 2009-10-27 15:51:17,368 FATAL
> org.dspace.storage.rdbms.InitializeDatabase @ Caught exception:
> [java] org.postgresql.util.PSQLException: FATAL: password
> authentication failed for user "dspace"

"Password authentication failed." The (username, password) pair that
DSpace presented when connecting to the database was not valid. In
dspace.cfg the db.username should be the user you created with
'createuser', and db.password should be the password you gave to that
username.

If you are using PostgreSQL, you also need to ensure that that
database user is permitted access to the DSpace database. That is
specified in pg_hba.conf. You would get a different error message if
this has not been done, when you do present a valid username and
password.

--
Mark H. Wood, Lead System Programmer mw...@IUPUI.Edu
Friends don't let friends publish revisable-form documents.

Patrick Etienne

unread,
Aug 25, 2015, 1:10:38 PM8/25/15
to dspace-tech
Fellow DSpace Techs -

I'm attempting to get the embargo patch working against a fresh installation of dspace 1.5.2 per the instructions available at the following URL: 

Despite my best efforts, I am not able to set this up successfully. After installing and looking at the results the symptoms are as follows:
1) Visual - I see inline bullet points but no text associated with them.
2) XHTML - yields the code listed below for each community/collection:

<!-- External Metadata URL: cocoon://metadata/handle/{community number}/{collection number}/mets.xml?sections=dmdSec,fileSec&fileGrpTypes=THUMBNAIL-->
<li class="ds-artifact-item {even/odd}" />

3) JSPUI - shows up as expected with all communities / collections listed.

It feels as though the xmlui portion of the patch is not being applied properly. This is just a guess, but an educated one in that the jspui works fine after the fresh install with the patch and sql schema patch applied, whereas the xmlui does not. However, patching the code does yield a several results as far as files patched which have "xmlui" as a directory in the patched files' paths.

To make this even stranger an issue, I would swear that the first time I tried doing a fresh install with the embargo patch, that it did actually work. I say this because I was able to navigate to an embargo tab using the administration user.

As another significant note, I also tried installing a fresh instance, replacing the database with an instance of a production dspace (1.5.2) database (vast amounts of data), then amending the database schema for that database instance with the code included in the embargo patch. The same results occurred. The JSPUI showed the content as expected, but the xhtml code was full of empty <li/> elements, one for each of the communities/collections that should have been display but were not from the xmlui.

Any tips, hints, or suggestions on this issue would greatly be appreciated!

 - Patrick E.

---
Patrick K. Étienne
Systems Analyst
Library and Information Center
Georgia Institute of Technology

"Mediocre Writers BorrowGreat Writers Steal" - T.S. Eliot

Sean Carte

unread,
Aug 25, 2015, 1:10:48 PM8/25/15
to Patrick Etienne, dspace-tech
2009/10/28 Patrick Etienne <patrick...@library.gatech.edu>:
> Fellow DSpace Techs -
> I'm attempting to get the embargo patch working against a fresh installation
> of dspace 1.5.2 per the instructions available at the following URL:
> http://wiki.dspace.org/index.php/User:Emetsger:Embargo:Downloads_here
> Despite my best efforts, I am not able to set this up successfully. After
> installing and looking at the results the symptoms are as follows:
> 1) Visual - I see inline bullet points but no text associated with them.
> 2) XHTML - yields the code listed below for each community/collection:
> <!-- External Metadata URL: cocoon://metadata/handle/{community
> number}/{collection
> number}/mets.xml?sections=dmdSec,fileSec&fileGrpTypes=THUMBNAIL-->
> <li class="ds-artifact-item {even/odd}" />

Do you mean that you cannot browse by item? If so the following may be
of use to you:

2009/7/2 Halliday, James Leonard <jhal...@indiana.edu>
>
> > I have a similar problem, but no newly defined field: I can't browse
> > by author or subject, as I get a java.lang.NullPointerException very
> > similar (or so it seems to me) to Lyn's error. (I've included the
> > cocoon and java stacktraces below.)
>
> The same thing happened to me when I was implementing Embargoes (Author and Subject browse stopped working), and here is the problem that I uncovered; hopefully the same fix will work for you. (Note: I have only worked with the 1.5.1 patch, but presumably the same fix will work for you.) I don't think it's related to patching an existing database vs. using a fresh one, because the error happens even on a fresh database, once you add data that includes subject or author information.
>
> Your patch file is not patching the DSpace code correctly. Check the dspace-api/src/main/java/org/dspace/browse/BrowseEngine.java class and the patch file. It looks like the patch file is patching the BrowseByValue method, instead of patching the BrowseByItem method, which it should be patching. The two methods look very similar, so the patch is getting confused. Double-check that class against the patch file manually, and make sure the appropriate changes are being made. Once I did that, all of my browsing problems were fixed.
>
> Another note: this bug is hard to find because the stack trace is coming from the wrong place. There is a bug in the core DSpace class org.dspace.app.xmlui.aspect.artifactbrowser.ConfigurableBrowse.java, in the getValidity() method that is causing a null pointer exception when the validity should be null (the last line for logging should include a null pointer check).
>
> Jim Halliday

The patched dspace-api/src/main/java/org/dspace/browse/BrowseEngine.java has the
embargo stuff in the browseByValue method from line 536 (of the
patched file). I copied those lines (536-566) to a similar spot in
the preceding browseByItem method (line 366) and commented them out in
the browseByValue method.

Sean
--
Sean Carte
esAL Library Systems Manager
+27 72 898 8775
+27 31 373 2490
fax: 0866741254
http://esal.dut.ac.za/

SANDEEP BHAVSAR

unread,
Aug 25, 2015, 1:11:02 PM8/25/15
to dspac...@lists.sourceforge.net
Respected All

AS per your suggestions I have changed the database password in dspace.cfg and that works for me. Now if you notice the error is not showing this line.

  [java] org.postgresql.util.
PSQLException: FATAL: password
authentication failed for user "dspace"



dspace@sbhavsar-server:~/
dspace-1.5.2-src-release/dspace/target/dspace-1.5.2-build.dir$ ant fresh_install
Buildfile: build.xml

init_installation:

init_configs:

setup_database:
     [java] 2009-11-01 09:48:46,229 INFO  org.dspace.core.ConfigurationManager @ Loading system provided config property (-Ddspace.configuration): config/dspace.cfg
     [java] 2009-11-01 09:48:46,238 INFO  org.dspace.core.ConfigurationManager @ Using default log4j provided log configuration,if uninitended, check your dspace.cfg for (log.init.config)
     [java] 2009-11-01 09:48:46,238 INFO  org.dspace.storage.rdbms.InitializeDatabase @ Initializing Database
     [java] 2009-11-01 09:48:46,314 FATAL org.dspace.storage.rdbms.InitializeDatabase @ Caught exception:
     [java] java.sql.SQLException: The url cannot be null
     [java]     at java.sql.DriverManager.getConnection(DriverManager.java:554)

     [java]     at java.sql.DriverManager.getConnection(DriverManager.java:185)
     [java]     at org.apache.commons.dbcp.DriverManagerConnectionFactory.createConnection(DriverManagerConnectionFactory.java:65)
     [java]     at org.apache.commons.dbcp.PoolableConnectionFactory.makeObject(PoolableConnectionFactory.java:294)
     [java]     at org.apache.commons.pool.impl.GenericObjectPool.borrowObject(GenericObjectPool.java:974)
     [java]     at org.apache.commons.dbcp.PoolingDriver.connect(PoolingDriver.java:176)
     [java]     at java.sql.DriverManager.getConnection(DriverManager.java:582)
     [java]     at java.sql.DriverManager.getConnection(DriverManager.java:207)
     [java]     at org.dspace.storage.rdbms.DatabaseManager.getConnection(DatabaseManager.java:550)
     [java]     at org.dspace.storage.rdbms.DatabaseManager.loadSql(DatabaseManager.java:923)
     [java]     at org.dspace.storage.rdbms.InitializeDatabase.main(InitializeDatabase.java:100)

BUILD FAILED
/home/dspace/dspace-1.5.2-src-release/dspace/target/dspace-1.5.2-build.dir/build.xml:585: Java returned: 1

Total time: 1 second

Simulataneously I am installing Dspace on Centos 5.3 (existing error is on Ubuntu 8.04) and getting the same error.

Thornton, Susan M. (LARC-B702)[RAYTHEON TECHNICAL SERVICES COMPANY]

unread,
Aug 25, 2015, 1:11:04 PM8/25/15
to SANDEEP BHAVSAR, dspac...@lists.sourceforge.net

You are now getting this error:

[java] java.sql.SQLException: The url cannot be null

 

Check your dspace.cfg configuration parameter for “db.url”.  It looks like yours is null.  Here is what we have ours set to:

db.url = jdbc:postgresql://127.0.0.1:5432/dspace

 

Hope this helps,

Sue Walker-Thornton

 


Reply all
Reply to author
Forward
0 new messages