DSpace Installation (dspace 6.0) Mukesh Pund Principal Scientist

Slides:



Advertisements
Similar presentations
Mukesh A Pund Scientist NISCAIR
Advertisements

Mukesh Pund Scientist, NISCAIR, New Delhi
Chapter Apache Installation on Linux. Acknowledgement The contribution made by Darrin Morison is acknowledged.
Object-Oriented Enterprise Application Development Tomcat 3.2 Configuration Last Updated: 03/30/2001.
Chapter Apache Installation in Linux- Mandrake. Acknowledgment The following information has been obtained directly from
70-290: MCSE Guide to Managing a Microsoft Windows Server 2003 Environment Chapter 12: Managing and Implementing Backups and Disaster Recovery.
National Workshop on Institutional Digital Repository (NDL) Project
Installing Tomcat on Windows  You may find the Tomcat install shield has some problems recognizing JSDK 1.4 beta installations.  You.
NDT Tools Tutorial: How-To setup your own NDT server Rich Carlson Summer 04 Joint Tech July 19, 2004.
Ch 8-3 Working with domains and Active Directory.
Installing DSpace on Window Bharat M. Chaudhari School of Petroleum Management, PANDIT DEENDAYAL PETROLEUM UNIVERSIRY, GANDHINAGAR
Using Opal to deploy a real scientific application as a Web service Sriram Krishnan
The DSpace Course Module – DSpace Installation. Module objectives  By the end of this module you will:  Understand the platforms DSpace can be hosted.
One to One instructions Installing and configuring samba on Ubuntu Linux to enable Linux to share files and documents with Windows XP.
Apache Tomcat Web Server SNU OOPSLA Lab. October 2005.
Eucalyptus Virtual Machines Running Maven, Tomcat, and Mysql.
Linux Operations and Administration
Developing Interfaces and Interactivity for DSpace with Manakin Part 2: Technical and Conceptual Overview of Dspace and Manakin Eric Luhrs Digital Initiatives.
Help session: Unix basics Keith 9/9/2011. Login in Unix lab  User name: ug0xx Password: ece321 (initial)  The password will not be displayed on the.
Guide to Linux Installation and Administration, 2e1 Chapter 8 Basic Administration Tasks.
70-290: MCSE Guide to Managing a Microsoft Windows Server 2003 Environment, Enhanced Chapter 12: Managing and Implementing Backups and Disaster Recovery.
Managing User Accounts. Module 2 – Creating and Managing Users ♦ Overview ► One should log into a Linux system with a valid user name and password granted.
FTP Server and FTP Commands By Nanda Ganesan, Ph.D. © Nanda Ganesan, All Rights Reserved.
Access Training Linux/Unix Power Broker Access Custom Schema Database Access Customer Training Date: 25-JAN-2005.
Using Opal to deploy a real scientific application as a Web service Sriram Krishnan, Ph.D.
Globus Toolkit Installation Report. What is Globus Toolkit? The Globus Toolkit is an open source software toolkit used for building Grid systems.
CODELABOR Shin Sang Jae Template Guide (codelabor-flex-lcds-template)
1 FreeBSD Installation AFNOG X Cairo, Egypt May 2009 Hervey Allen.
1 AHM -2-4 Sept 2003 e-Science Centre Running SRB Ananta Manandhar.
Apache, MySQL and PHP Installation and Configuration Chapter 2 MySQL Installation and Configuration.
Installing and Configuring Tomcat SSE. Downloading Tomcat l Download url: 4.0/release/v4.1.24/bin/
Surya Bahadur Kathayat Outline  Ramses  Installing Ramses  Ramses Perspective (Views and Editors)  Importing/Exporting Example.
1 FreeBSD Installation AFNOG Chix 2011 Blantyre, Malawi 31 st Oct - 4 th Nov 2011 Dorcas Muthoni and Evelyn Namara.
A Basic Introduction By Scott Phillips 2005/8/7. Agenda What is DSpace and what does it do? The DSpace Information Model Components & Features of DSpace.
FTP COMMANDS OBJECTIVES. General overview. Introduction to FTP server. Types of FTP users. FTP commands examples. FTP commands in action (example of use).
NJIT 1 Apache Tomcat (Version 6.0) THETOPPERSWAY.COM.
Tomcat Setup BCIS 3680 Enterprise Programming. One-Click Tomcat Setup 2  This semester we’ll try to set up Tomcat with a PowerShell script.  Preparation.
Settings MySQL Database and JDBC configuration Instructor: Sergey Goldman.
INTERNET APPLICATIONS CPIT405 Install a web server and analyze packets.
CACI Proprietary Information | Date 1 PD² SR13 Client Upgrade Name: Semarria Rosemond Title: Systems Analyst, Lead Date: December 8, 2011.
CACI Proprietary Information | Date 1 PD² v4.2 Increment 2 SR13 and FPDS Engine v3.5 Database Upgrade Name: Semarria Rosemond Title: Systems Analyst, Lead.
C Copyright © 2006, Oracle. All rights reserved. Oracle Secure Backup Additional Installation Topics.
CACI Proprietary Information | Date 1 Upgrading to webMethods Product Suite Name: Semarria Rosemond Title: Systems Analyst, Lead Date: December 8,
Using Linux Kaya Oğuz Room: 310.
1 Remote Installation Service Windows 2003 Server Prof. Abdul Hameed.
Fundamental of Databases
DSpace: Settings Mukesh Pund Principal Scientist CSIR-NISCAIR
CS1010: Intro Workshop.
Hyrax Configuration.
Hadoop Architecture Mr. Sriram
Getting started with CentOS Linux
Connect:Direct for UNIX v4.2.x Silent Installation
Install external command line softwares
Get Me Started! Setting up a development setup
CONTENT MANAGEMENT SYSTEM CSIR-NISCAIR, New Delhi
Dspace Statistics: Google Analytics, Solr
CONTENT MANAGEMENT SYSTEM CSIR-NISCAIR, New Delhi
The Linux Operating System
Introduction, Features & Technology
CompTIA Server+ Certification (Exam SK0-004)
INSTALLING AND SETTING UP APACHE2 IN A LINUX ENVIRONMENT
Apache Tomcat Web Server
University of Texas Rio Grande Valley Systems Administration CSCI 6175
Run Java file with Window cmd
Creating ODP regional node from scratch
Getting started with CentOS Linux
CPAN 260 Relational Database Design and SQL
Installing Tomcat.
How to install and manage exchange server 2010 OP Saklani.
Presentation transcript:

DSpace Installation (dspace 6.0) Mukesh Pund Principal Scientist 02/19/13 02/19/13 02/19/13 02/19/13 DSpace Installation (dspace 6.0) Mukesh Pund Principal Scientist NISCAIR, New Delhi Dspace 1 1 1

Required Software Operating System: 02/19/13 02/19/13 02/19/13 02/19/13 Required Software Operating System: Linux: Redhat/Fedora, Suse,Mandrake, Debian etc. Unix: Solaris (Sun system)‏, HP-UX (Hewlett Packard)‏, AIX (IBM), Mac OS X Mail server (Sendmail/postfix) RDBMS (postgres/oracle) DSpace Java compiler (jdk) Java Servlet Container Maven Ant Java build tool, similar to make in the world of ‘C’ Complies java programs of dspace source code, generates war files 2 2 2

02/19/13 02/19/13 02/19/13 02/19/13 Role of RDBMS Database backend (postgres/oracle) of DSpace, stores information on: Communities Collection Members - passwords E-groups etc. 3 3 3

Step1: Linux Installation 02/19/13 02/19/13 02/19/13 02/19/13 Step1: Linux Installation Strongly advise to Load Linux fully unless you are a Linux Guru Make sure the following are installed Mail server Copy all the files provided on CD-ROM tar.gz files in /opt directory Or Download the following (or latest) files from Internet jdk-8u121-linux-i586.rpm (java compiler) Apache-ant-1.9.8-bin.tar.gz (ant) Postgresql-9.5.5-1-linux.run (RDBMS) Apache-tomcat-8.5.11.tar.gz (servlet container) Apache-maven-3.3.9-bin.tar.gz (maven) Dspace-source-6.0-src-release.zip (dspace software) 4 4 4

Step 2: Installation of Java 02/19/13 02/19/13 02/19/13 02/19/13 Step 2: Installation of Java Install  java1.8 or later First we have to give execute permission to java install package file before executing it. cd /opt [root@localhost opt]#chmod a+x jdk-8u121-linux-i586.rpm [root@localhost opt]#sudo rpm -ivh jdk-8u121-linux-i586.rpm #By default java is installed under /usr/java/ cd /usr/java/jdk1.8.0_121 alternatives --install /usr/bin/java java /usr/java/jdk1.8.0_121/bin/java 2 alternatives --config java 5 5 5

Step 5: PostgreSQL installation 02/19/13 02/19/13 02/19/13 02/19/13 Step 5: PostgreSQL installation You need to become Linux root user to install postgresql Use the following commands to install #cd /opt #chmod +x Postgresql-9.5.5-1-linux.run #./Postgresql-9.5.5-1-linux.run You will get the PostgreSQL GUI wizard. It will prompt for Database Superuser (postgres) password, Enter the password. It will prompt for the database port no. (By default it is 5432), Click on Next to proceed. At the end of installation it will prompt for the “Stack builder installation”, uncheck the “Stack Builder at exit” checkbox. Click on Finish 6 6 6

Tune PostgreSQL for DSpace 02/19/13 02/19/13 02/19/13 02/19/13 Tune PostgreSQL for DSpace Firstly we need to get into /opt/postgreSQL/9.5/data/ [root@localhost opt]# cd /opt/postgreSQL/9.5/data/ Now add the line “host dspace dspace 127.0.0.1/32 md5” in pg_hba.conf To achieve this please type following command [root@localhost data]$#vi pg_hba.conf #IPv4 Local Connections: host all all 127.0.0.1/32 md5 host dspace dspace 127.0.0.1/32 md5 Now restart the postgres service 7 7 7

Tune PostgreSQL for DSpace 02/19/13 02/19/13 02/19/13 02/19/13 Tune PostgreSQL for DSpace [root@localhost data]# service postgresql-9.5 restart Now , add the postgres to our Environment Variable (PATH), to execute the postgres commands. [root@localhost data]#gedit /etc/profile.d/java.sh And edit the PATH. PATH=/opt/PostgreSQL/9.5/bin:$JAVA_HOME/bin:$ANT_HOME/bi n:$MAVEN_HOME/bin:$PATH And save the file /etc/profile.d/java.sh Now give effect to the System Environment by [root@localhost data]$#source /etc/profile.d/java.sh 8 8 8

Step 4: Apache-ant installation 02/19/13 02/19/13 02/19/13 02/19/13 Step 4: Apache-ant installation Check Apache Ant is already installed or not using the command: #which ant You need to login as Linux root user If not installed type the following commands to install #cd /opt #tar -zxvf apache-ant-1.9.8-bin.tar (extract files) 9 9 9

Step 6: Installation of Apache Tomcat 02/19/13 02/19/13 02/19/13 02/19/13 Step 6: Installation of Apache Tomcat You have to become root user and type the following commands #cd /opt #tar -zxvf Apache-tomcat-8.5.11.tar.gz [extract files] 10 10 10

Step 6: Installation of Apache maven 02/19/13 02/19/13 02/19/13 02/19/13 Step 6: Installation of Apache maven You have to become root user and type the following commands #cd /opt #tar -zxvf Apache-maven-3.3.9-bin.tar.gz [extract files] 11 11 11

Set Envirnment Variable(PATH) 02/19/13 02/19/13 02/19/13 02/19/13 Set Envirnment Variable(PATH) Now write the following lines in /etc/profile.d/java.sh #gedit /etc/profile.d/java.sh ANT_HOME=/opt/apache-ant-1.9.8 CATALINA_HOME=/opt/apache-tomcat-8.5.11 MAVEN_HOME=/opt/apache-maven-3.3.9 PATH=/opt/PostgreSQL/9.5/bin:$JAVA_HOME/bin:$ANT_HOME/bin: $MAVEN_HOME/bin:$PATH export PATH JAVA_HOME ANT_HOME MAVEN_HOME export CLASSPATH=." Save the file and exit Type the following commands at command prompt #chmod +x /etc/profile.d/java.sh #source /etc/profile.d/java.sh 12 12 12

Verify all the software installations 02/19/13 02/19/13 02/19/13 02/19/13 Verify all the software installations [root@localhost profile.d]#echo $JAVA_HOME /usr/java/jdk1.8.0_121 [root@localhost profile.d]# echo $CATALINA_HOME /opt/apache-tomcat-8.5.11 [root@localhost profile.d]# ant -version Apache Ant(TM) version 1.9.8 complied on December 25 2016 [root@localhost profile.d]#mvn -version Apache Maven 3.3.9(r1232337; 2012-01-17 14:14:56+0530) Maven home: /opt/apache-maven-3.3.9 Java version: 1.8.0_121, vendor: Oracle Corporation Java home: usr/java/jdk1.8.0_121/jre Default locale: en_US, platform encoding: UTF-8 OS name: “Linux”, version::”2.6.32-279.el6.i686”, arch: “1386, family: “unix” 13 13 13

Contd. Now start the tomcat server by executing 02/19/13 02/19/13 02/19/13 02/19/13 Contd. Now start the tomcat server by executing [root@localhost profile.d]# cd $CATALINA_HOME/bin [root@localhost bin]# ./startup.sh Using CATALINA_BASE: /opt/apache-tomcat-8.5.11 Using CATALINA_HOME: /opt/apache-tomcat-8.5.11 Using CATALINA_TMPDIR: /opt/apache-tomcat-8.5.11./temp Using JRE_HOME: /usr/java/jdk1.8.0_121 Using CLASSPATH: /opt/apache-tomcat- 8.5.11/bin/bootstrap.jar:/opt/apache-tomcat-8.5.11/bin/tomcat- juli.jar [root@localhost bin]# 14 14 14

Contd. Now shutdown the tomcat server by executing 02/19/13 02/19/13 02/19/13 02/19/13 Contd. Now shutdown the tomcat server by executing [root@localhost profile.d]#cd $CATALINA_HOME/bin [root@localhost bin]# ./shutdown.sh Using CATALINA_BASE: /opt/apache-tomcat-7.0.35 Using CATALINA_HOME: /opt/apache-tomcat-7.0.35 Using CATALINA_TMPDIR: /opt/apache-tomcat-7.0.35./temp Using JRE_HOME: /usr/java/jdk1.8.0_121 Using CLASSPATH: /opt/apache-tomcat- 7.0.35/bin/bootstrap.jar:/opt/apache-tomcat-7.0.35/bin/tomcat- juli.jar 15 15 15

Step 7: Installation of Dspace Application 02/19/13 02/19/13 02/19/13 02/19/13 You have to login as Linux root user Create the DSpace Linux user by using the commands #groupadd dspace [create group] #useradd dspace –g dspace [ create dspace user] Now we will go to the /opt/PostgreSQL/9.5/data [root@localhost data]# cd /opt/PostgreSQL/9.5/data Now we will create “dspace” user for the database and a database named “dspace” owned by “dspace” user that we created in the step1, step just above [root@localhost data]$ createuser –U postgres –d –A –P dspace Enter password for new role: - Enter dspace Password (for simplicity keep it “dspace”) Enter it again:- Enter dspace Password(for simplicity keep it “dspace”) Shall the new role be allowed to create more new roles? (y/n) y Password: Enter the postgres password (superuser password) Now create a database name “dspace” [root@localhost data]$ createdb –U dspace –E UNICODE dspace Password: Enter the dspace password (if followed instructions at Step 3 then enter “dspace”). 16 16 16

Step 7: Installation of Dspace contd.. 02/19/13 02/19/13 02/19/13 02/19/13 Now it’s time to actually install the Dspace [root@localhost data]# cd / Now copy the Dspace package into the root /. [root@localhost /]# cp /opt/dspace-6.0-src-release.zip . Now run(unzip) the installation package of the Dspace [root@localhost /]# unzip dspace-6.0-src-release.zip Now we will create the new directory at root to contain the Dspace application files. [root@localhost /]#mkdir dspace Now we have to change the ownership of both the directories, from root to dspace user, as it is to be used by dspace user. [root@localhost /]#chown dspace.dspace /dspace –R (Note:- There is a space between /dspace and –R) [root@localhost /] chown dspace.dspace /dspace-6.0-src-release 17 17 17

Step 7: Installation of Dspace contd.. 02/19/13 02/19/13 02/19/13 02/19/13 Now login as dspace user. [root@localhost /]# su dspace [dspace@localhost /]# Now we have to configure the dspace configuration file. Reach to the folder containing the configuration file. [dspace@localhost /]# cd /dspace-6.0-src-release/dspace/config/   Now edit the dspace.cfg file [dspace@localhost config]# vi dspace.cfg db.name=postgres db.username=dspace db.password=whatever password you have given remove the { } and $ after inserting value in these fields). . 18 18 18

Step 7: Installation of Dspace contd.. 02/19/13 02/19/13 02/19/13 02/19/13 Now it’s time for the dspace compilation. Firstly we have to move to /dspace-6.0-src-release/dspace [dspace@localhost config]$ cd /dspace-6.0-src-release/dspace Now begin the compilation [dspace@localhost dspace]# mvn package (Note: - It might take several minutes to it get installed & internet connection should not get terminate). After installation is completed the BUILD SUCCESS message will be displayed. 19 19 19

02/19/13 02/19/13 02/19/13 02/19/13 Contd. Now we have go to the /dspace-6.0-src- release/dspace/target/dspace-installer [dspace@localhost dspace]$ cd / dspace-6.0-src- release/dspace/target/dspace-installer/ [dspace@localhost dspace-installer]$ Now we have to give ant fresh_install command. [dspace@localhost dspace-installer]$ ant fresh_install (Note: - It might take some time, so be patient). After installation is completed the BUILD SUCCESS message will be displayed. 20 20 20

Contd. Now we have to build the Administrator account for dspace 02/19/13 02/19/13 02/19/13 02/19/13 Contd. Now we have to build the Administrator account for dspace [dspace@localhost dspace-installer]#/dspace/bin/dspace create- administrator Creating an initial administrator account E-mail address:mukeshpun@gmail.com First name:- mukesh Last name:- pund WARNING: Password will not dispaly on-screen. Password: Again to confirm: Is the above data correct? (y or n): y [dspace@localhost dspace-installer]# 21 21 21

Now it’s time to tell tomcat server where dspace is 02/19/13 02/19/13 02/19/13 02/19/13 Go to root directory [dspace@localhost dspace-installer]$#cd / Login as root user [dspace@localhost /]# su [root@localhost /]# Now go to /opt/apache-tomcat-7.0.35/conf/Catalina/localhost/ [root@localhost /]#cd /opt/apache-tomcat- 7.0.35/conf/catalina/localhost/ [root@localhost localhost]#   22 22 22

02/19/13 02/19/13 02/19/13 02/19/13 Contd. Now create 3 files named jspui.xml, xmlui.xml, oai.xml one by one. JSPUI.XML [root@localhost localhost]# vi jspui.xml Add the following text into it. <Context path=“/jspui” docBase=“/dspace/webapps/jspui” debug=“0” reloadable= “true” cachingAllowed=“false” crosscontext=“true” /> Press <Esc> and press :wq then press Enter. XMLUI.XML [root@localhost localhost]# vi xmlui.xml 23 23 23

02/19/13 02/19/13 02/19/13 02/19/13 Contd. <Context path=“/xmlui” docBase=“/dspace/webapps/xmlui” debug=“0” reloadable= “true” cachingAllowed=“false” crosscontext=“true” /> Press <Esc> and press :wq then press Enter. JSPUI.XML [root@localhost localhost]# vi oai.xml Add the following text into it. <Context path=“/oai” docBase=“/dspace/webapps/oai” debug=“0” reloadable= “true” cachingAllowed=“false” crosscontext=“true” />   24 24 24

[root@localhost localhost] cd /opt 02/19/13 02/19/13 02/19/13 02/19/13 Now it’s time to permission of tomcat owner, so that tomcat can be executed by dspace user. [root@localhost localhost] cd /opt [root@localhost opt]$ chown dspace.dspace apache-tomcat-8.5.11/ -R   Now login as dspace, and start tomcat server. [root@localhost opt] su dspace [root@localhost opt] cd $CATALINA_HOME/bin [root@localhost bin] ./startup.sh 25 25 25

Installation of Dspace- Summary 02/19/13 02/19/13 02/19/13 02/19/13 Installation of Dspace- Summary Dspace is based on open source technlogy The installation process is some what complex for new users The following components should properly work : Postgresql server Jdbc driver for postgres server Apache tomcat Initially there may be few errors related to above components if not properly installed 26 26 26

02/19/13 02/19/13 02/19/13 02/19/13 Cron jobs To perform certain task periodically we may use cron jobs by typing following command: # crontab -e # Send out subscription e-mails at 01:00 every day 0 1 * * * /dspace/bin/sub-daily # Run the media filter at 02:00 every day 0 2 * * * /dspace/bin/filter-media # Generate full-text index at 2.15 am for (lucene based search engine, not required in Dspace 4.x and 5.x) 15 2 * * * /dspace/bin/index-all # build discovery index at 2.15 am (default index) 15 2 * * * /dspace/bin/ dspace index-discovery # build discovery index optimize at 3.15 am 15 3 * * * /dspace/bin/index-discovery -o # Clean up the database nightly at 2.40am 40 2 * * * vacuumdb --analyze dspace > /dev/null 2>&1" > /var/spool/cron/dspace * Minute 0-59 Hour 0-23 (0 = midnight) Day 1-31 Month 1-12 Weekday 0-6 (0 = Sunday)‏ 27 27 27

02/19/13 02/19/13 02/19/13 02/19/13 Cron jobs ….. To perform certain task periodically we may use cron jobs by typing following command: # Cleanup Web Spiders from DSpace Statistics Solr at 4.15 am 15 4 * * * /dspace/bin/dspace stats-util -i # Re-Optimize DSpace Statistics Solr Index at 4.15 am 15 4 * * * /dspace/bin/dspace stats-util -o # This ensures each year has its own Solr index, which improves performance. (yearly) 15 3 1 1 * /dspace/bin/dspace stats-util -s # This ensures the system administrator is notified whether any checksums were found to be different at 05:00 every Sunday 0 5 * * 0 /dspace/bin/dspace checker-emailer For more details Dspace cron-job settings: https://wiki.duraspace.org/display/DSDOC5x/Scheduled+Tasks+via+Cron 28 28 28

Starting apache tomcat on boot 02/19/13 02/19/13 02/19/13 02/19/13 Starting apache tomcat on boot To make your repository start at the boot time adds the following to /etc/rc.d/rc.local su –l dspace –c ‘/dspace/apache-tomcat- 8.5.11/bin/startup.sh 29 29 29

02/19/13 02/19/13 02/19/13 02/19/13 Trouble shooting.. Check your environment variable by giving the following commands echo $PATH echo $JAVA_HOME See whether java’s bin directory is in your PATH JAVA_HOME is pointing to Java directory Change your /dspace/.bash_profile 30 30 30

Trouble shooting: while fresh_install 02/19/13 02/19/13 02/19/13 02/19/13 Trouble shooting: while fresh_install Mostly you get database related errors, the cause could be You did not copy jdbc drivers in dspace-source/lib directory Or changes in the postgresql .conf file were not made at all, or done improperly 31 31 31

Trouble shooting: Once you launch DSpace 02/19/13 02/19/13 02/19/13 02/19/13 Trouble shooting: Once you launch DSpace If you do not see dspace on the screen Tomcat was not launched Or the port (8080) was already in use You started tomcat second time Solution Kill tomcat if you have started second time (using ps –a | grep java or killall java Change to another port in tomcat/config/server.xml Check $TOMCAT-HOME/logs/catalina.out For specific problem identification 32 32 32

Troubleshooting: Internal System Error 02/19/13 02/19/13 02/19/13 02/19/13 Troubleshooting: Internal System Error Most common error message To generic and is not specific The reasons could be many Check /dspace/log/dspace.log file, which may provide the specific problem 33 33 33

Trouble-shooting: Fails to sendmal 02/19/13 02/19/13 02/19/13 02/19/13 Trouble-shooting: Fails to sendmal Mail configuration is wrong You did not make mail server entry in /dspace/conf/dspace.cfg file DNS problem You do not have FQDN (Fully Qualified Domain Name) for you system It should hostname.domainname Ex: localhost.localdomain (not just localhost)‏ nsdl.niscair.res.in ( not jst nsdl)‏ 34 34 34

LOG FILES $TOMCAT_HOME/logs/catalina.out /dspace/log/dspace.log 02/19/13 02/19/13 02/19/13 02/19/13 LOG FILES $TOMCAT_HOME/logs/catalina.out /dspace/log/dspace.log 35 35 35

02/19/13 02/19/13 02/19/13 02/19/13 Thanks 36 36 36