Workbook on Digital Private Papers > Installing - DSpace

Installing - DSpace

Acquiring the software and documentation

We should have already installed:

Before you progress to the installation, we would advise that you acquire a copy of the DSpace Installation Instructions and read them thoroughly.

From the getting started with DSpace home page select the Sourceforge.net link:

http://www.dspace.org/resource/start.html

thumbs/dspace-02.jpg

Download the latest stable DSpace source code release:

http://sourceforge.net/projects/dspace/

thumbs/dspace-03.jpg

Select the latest DSpace source code release:

e.g. click on dspace1.3.2-source.tar.gz

thumbs/dspace-04.jpg

Open a terminal window and acquire root level privileges.

su
Password:

thumbs/dspace-00.jpg

Create the DSpace user and a group of the same name. Specify the uid (user id) and gid (group id) rather than allowing the system to default when running multiple systems. This user also needs to be a member of the tomcat group. So run:

# groupadd -g 106 dspace
# useradd -d /usr/local/src/dspace -c "dspace Administrative user" -G tomcat,users -g dspace -m -p \ dspace56 -u 106 -r -s /bin/bash dspace

thumbs/dspace-01.jpg

Change to the [dspace-source] directory and unpack the release from the downloaded file:

cd /usr/local/src/dspace
tar xzf /[dspace-source]/dspace1.3.2-source.tar.gz

thumbs/dspace-05.jpg

Copy the PostgreSQL JDBC drivers (.jar file) into [dspace-source]/lib

cd /dspace-1.3.2-source/lib

cp /usr/share/pgsql/postgresql-8.0-311*.jar .

thumbs/dspace-06.jpg

1. Set the DSpace OS user level password

2. Create the DSpace PostgreSQL user. You will be prompted to supply and confirm the password for DSpace PostgreSQL user followed by the password for the postgres administrator to authorise the create user command.:

Note the password for the DSpace PostgreSQL user isn't necessarily the same as the DSpace user's UNIX password:

createuser -h localhost -U postgres -d -A -P dspace

thumbs/dspace-07.jpg

Create a DSpace database, owned by the DSpace PostgreSQL user. You will be prompted to supply the password for DSpace PostgreSQL user to authorise the create database command:

createdb -h localhost -U dspace -E UNICODE dspace

thumbs/dspace-08.jpg

Edit [dspace-source]/config/dspace.cfg the DSpace configuration file:

cd config
kate dspace.cfg

thumbs/dspace-08a.jpg

In particular you'll need to set these properties:

dspace.url
dspace.hostname
dspace.name
db.password (the password you entered in the previous step)
mail.server
mail.from.address
feedback.recipient
mail.admin
alert.recipient (not essential but very useful!)

Note that if you change dspace.dir you'll also need to change other properties with values that start with /dspace, e.g. assetstore.dir, log.dir...

Line Parameter Value

12 dspace.dir
/usr/local/dspace

15 dspace.url
https://localhost:8080/dspace

17 dspace.hostname
[add hostname]

21 dspace.name
DSpace at Paradigm (Oxford University)

31config.template.log4j.properties
/usr/local/dspace/config/log4j.properties

32config.template.log4j-handle-plugin.properties
/usr/local/dspace/config/log4j-handle-plugin-properties

33config.template.oaicat.properties
/usr/local/dspace/config/oaicat.properties

50 db.password
[add password]

67mail.server
smtp.[add mailserver]

70mail.from
dspace-noreply@[add]

76mail.admin
dspace-help@[add]

85assetstore.dir
/usr/local/dspace/assetstore

156history.dir
/usr/local/dspace/history

159search.dir
/usr/local/dspace/search

165log.dir
/usr/local/dspace/log

168upload.temp.dir
/usr/local/dspace/upload

183report.dir
/usr/local/dspace/reports

192handle.dir
/usr/local/dspace/handle-server

201webui.cert.ca
/usr/local/dspace/etc/certificate-ca.pem

thumbs/dspace-09.jpg

Create the directory for the DSpace installation. As root, run mkdir [dspace] ; chown dspace [dspace]:

mkdir /usr/local/dspace
chown -R dspace:dspace /usr/local/dspace

thumbs/dspace-10.jpg

To make sure that the tomcat group members can write to the web application directory:

chmod 775 /srv/www/tomcat5/base/webapps
chgrp tomcat /srv/www/tomcat5/base/webapps

thumbs/dspace-14.jpg

Become the dspace UNIX user, change to the DSpace source directory:

su - dspace
cd /usr/local/src/dspace/*source

thumbs/dspace-11.jpg

Compile and install DSpace:

ant fresh_install

thumbs/dspace-12.jpg

If all has gone well you are presented with the summary screen and BUILD SUCCESSFUL:

thumbs/dspace-13.jpg

Copy the DSpace Web application archives ( .war files ) to the Tomcat web application directory:

cp build/*.war /srv/www/tomcat5/base/webapps

thumbs/dspace-15.jpg

Create an initial administrator account:

/usr/local/dspace/bin/create-administrator

thumbs/dspace-16.jpg

Complete the create administrator dialog:

thumbs/dspace-17.jpg

Exit back to the root user and start/restart tomcat:

/etc/init.d/tomcat5 restart

thumbs/dspace-18.jpg

Troubleshooting: If tomcat doesn't respond then verify that the firewall is permitting traffic to port 8080. Use Yast from SUSE Linux's the menu and navigate to the Firewall Configuration summary or revisit the Install Tomcat pages.

Start ->System->Controlcenter (yast2)-> Security -> Firewall

thumbs/dspace-19.jpg

Also check that Tomcat can write to its config directory. If need be, change the permissions:

chown tomcat /etc/tomcat5/base

Visit the base URL of the server e.g http://pserver11.paradigm.ac.uk:8080/dspace and you should see the DSpace home page:

http://pserver11.paradigm.ac.uk:8080/dspace

thumbs/dspace-20.jpg

The administration user created can now login as an ordinary user - You have a working but empty repository as it contains no communities or collections:

http://pserver11.paradigm.ac.uk:8080/dspace

thumbs/dspace-20a.jpg

In order to setup some communities and collections, you'll need to access the administration user interface by appending dspace-admin to the base URL of their server:

http://pserver11.paradigm.ac.uk:8080/dspace/dspace-admin

thumbs/dspace-20b.jpg

Supply the administration users email address and password in the DSpace login form:

thumbs/dspace-21.jpg

The administration User Interface is now at your service:

thumbs/dspace-22.jpg