Skip to main content

Dspace 1.7 on Ubuntu 10.10 made Easy

4 replies [Last post]
Seun Ojedeji
Offline
Last seen: 1 year 28 weeks ago
Joined: 01/11/2011

One of the limiting factors to the adoption of DSpace by the community has historically been the the difficulty in installing DSpace and all of its prerequisites. This goal of this guide is to provide a simplistic path that will get a user up-and-running as quickly as possible.With Ubuntu 10.10 we will be using taskel to install the periquisites. By following the steps bellow, you will have dsapce running on your ubuntu 10.10: -    Install the server stack of Tomcat (web server) and PostgreSQL (database) by running the following commands:

sudo apt-get install tasksel
sudo tasksel

  • Select the following packages to install while leaving others

    [*] LAMP server
    [*] PostgreSQL database
    [*] Tomcat Java server

-   Install the Compile / Build tools by running

sudo apt-get install ant maven2

-   Create the database user (dspace) by running the following

sudo su postgres
createuser -U postgres -d -A -P dspace
exit

NB: you will be asked to chose a password, you are adviced to set it as dspace, else not the password you choserun

sudo nano /etc/postgresql/8.4/main/pg_hba.conf
# Add this line to the configuration: local all dspace md5

To now look as bellow:Database administrative login by UNIX socketslocal   all         postgres                          identlocal all dspace md5Restart postgresql

sudo service postgresql restart

Create the dspace database

createdb -U dspace -E UNICODE dspace

Configure Tomcat to know about the DSpace webapps.

sudo nano /etc/tomcat6/server.xml
# Insert the following chunk of text just above the closing </Host>

<!-- Define a new context path for all DSpace web apps -->
<Context path="/xmlui" docBase="/dspace/webapps/xmlui" allowLinking="true"/>
<Context path="/sword" docBase="/dspace/webapps/sword" allowLinking="true"/>
<Context path="/oai" docBase="/dspace/webapps/oai" allowLinking="true"/>
<Context path="/jspui" docBase="/dspace/webapps/jspui" allowLinking="true"/>
<Context path="/lni" docBase="/dspace/webapps/lni" allowLinking="true"/>
<Context path="/solr" docBase="/dspace/webapps/solr" allowLinking="true"/>

Create the [dspace] directory.The [dspace] directory is where the running dspace code will reside.

sudo mkdir /dspace

Download the Source Release

wget http://sourceforge.net/projects/dspace/files/DSpace%20Stable/1.7.0/dspace-1.7.0-src-release.tar.bz2
tar -xvjf dspace-1.7.0-src-release.tar.bz2

Compile and Build DSpace: Before we do this, we need we need to ensure java-6-openjdk is installed properly by running:
root@test-VirtualBox:~# whereis java-6-openjdk
java-6-openjdk: /etc/java-6-openjdk
If you get the output as above then you can proceed to the next step, if not, run "sudo apt-get install java-6-openjdk" install java-6-openjdk

Now run the following:

cd dspace-1.7.0-src-release
mvn -U package
cd dspace/target/dspace-1.7.0-build.dir

sudo ant fresh_install

 Fix Tomcat permissions, and restart the Tomcat serverThis guide follows the convention where the tomcat user will own all of the files in [dspace], so we have to change the owner of the files to tomcat6. Restarting tomcat will deploy the dspace webapps that are now ready to be viewed.

sudo chown tomcat6:tomcat6 /dspace -R
sudo /etc/init.d/tomcat6 restart
Create a usersudo dspace/bin/dspace create-administratorNow test: http://localhost:8080/jspui/ OR http://yoururl:8080/jspui/ OR http://ip address:8080/jspui/Login with your newly created account.COME BACK IF YOUHAVE PROBLEM!