Install DSpace 6.3 on Ubuntu 20.04 LTS

dspace 6.3
System Requirement

Hardware (Minimum)                                              


100 GB Hard Drive

i3  Processor

Software (To be installed to Run Dspace)

1. Java Development Kit-8 (JDK-8)

2. Apache Maven (Build Automation Tool )

3. Apache Ant (Pure Java Build Tool) 

4. PostgreSQL (Database) 

4. DSpace 6.3 Software

6. Apache Tomcat ( Server) 

Open the terminal (Press crtl+alt+t) and login as a root user

sudo su ( Hit Enter and enter Password)

Apply the below commands one by one to update and upgrade Ubuntu OS

sudo apt-get update

sudo apt-get upgrade

git installation

Executive the following commands one by one

apt-get install git

add-apt-repository ppa:git-core/ppa

apt update; apt install git

Install Complete Java Development kit-8

 sudo apt install openjdk-8-jdk

(If you have already installed another version of jdk then choose jdk-8 as default by applying the below command)

sudo update-alternatives --config java

Install Maven

sudo apt install maven

Install Apache ant

sudo apt install ant

PostgreSQL Installation Process

Apply the following commands:-

sudo sh -c 'echo "deb $(lsb_release -cs)-pgdg main" > /etc/apt/sources.list.d/pgdg.list'

wget --quiet -O - | sudo apt-key add -

sudo apt-get update

apt-get install postgresql-14

Create a database, user, and password 

sudo su postgres

createuser –U postgres –d –A –P dspace

(Enter the Password for a new role as “dspace”, if asked to create a new role allowed to create more roles then answer ‘y’)

Now Exit from Postgres


Open the PostgreSQL  file and add the following line in the file

sudo gedit /etc/postgresql/14/main/pg_hba.conf 

(Find the line "local is for unix domain socket connection only" and paste the following line under this line) 

local                all               dspace                         md5

Save and close

Restart PostgreSQL

/etc/init.d/postgresql restart

Create a DSpace User 

sudo useradd –m dspace

sudo passwd dspace

(Enter the Password e.g. dspace)

Apply the below commands to create a folder named “dspace”. And change the permission

sudo mkdir /dspace

sudo chown dspace /dspace

Create the Postgres database named dspace 

sudo su dspace

createdb –U dspace –E UNICODE dspace


Install pgcrypto extension

sudo su postgres

psql --username=postgres dspace -c "CREATE EXTENSION pgcrypto;"

Restart PostgreSQL

/etc/init.d/postgresql restart

Create a folder named “build” and change the permission

sudo mkdir /build

sudo chmod -R 777 /build

Download the Dspace6.3 version in the build folder

 cd /build


Extract the downloaded DSpace file

sudo tar xzvf dspace-6.3-src-release.tar.gz

Run the following command to open the file

sudo gedit /build/dspace-6.3-src-release/dspace-api/pom.xml

Find the below lines in the file and delete these lines  or comment carefully by following tags:

  <!--                  -->















Save and close

Install DSpace

Execute the following commands

cd /build/dspace-6.3-src-release

sudo mvn -U package

Install ant fresh

cd dspace/target/dspace-installer

sudo ant fresh_install 

Now exit


Download Apache tomcat

Apply below two commands to download the tomcat server in ‘opt’ directory

cd /opt

sudo wget

Extract the tar.gz file

sudo tar xzvf apache-tomcat-9.0.65.tar.gz

Rename the apache-tomcat-9.0.65 folder to tomcat.

sudo mv apache-tomcat-9.0.65 tomcat

Open the file /etc/profile.

sudo gedit /etc/profile   

Copy and paste this script in the last (Bottom) of file.

export JAVA_HOME=/usr/lib/jvm/java-8-openjdk-amd64

export CATALINA_HOME=/opt/tomcat

Save and close

Appy the command to Copy dspace webapps to opt tomcat webapps.

sudo cp -r /dspace/webapps/* /opt/tomcat/webapps    

Add the following scripts to make Tomcat automatically executable.

sudo gedit /etc/init.d/tomcat

Enter the following script in the blank file



# Provides:        tomcat8

# Required-Start:  $network

# Required-Stop:   $network

# Default-Start:   2 3 4 5

# Default-Stop:    0 1 6

# Short-Description: Start/Stop Tomcat server



start() {

 sh /opt/tomcat/bin/


stop() {

 sh /opt/tomcat/bin/

case $1 in

  start|stop) $1;;

  restart) stop; start;;

  *) echo "Run as $0 <start|stop|restart>"; exit 1;;


Save and close

Change the permission to make executable

sudo chmod +x /etc/init.d/tomcat

sudo update-rc.d tomcat defaults 

Restart the Tomcat and PostgreSQL

sudo service tomcat restart

sudo /etc/init.d/postgresql restart

sudo /etc/init.d/tomcat restart

Create a DSpace account for the Administrator (E-Person).

sudo /dspace/bin/dspace create-administrator

Provide  your Email ID, First Name, Last Name, and Password

Now open the dspace in the Browser

For JSPUI interface :-     http://localhost:8080/jspui

For XMLUI Interface:-   http://localhost:8080/xmlui


No comments

Powered by Blogger.