Installing DSpace on CentOS 5

Section of an image of a display of scientific photography by Thomas Smillie

Installing DSpace is a reatively long and involved process due to the requirement to build the software using Maven and Ant. The installation is additionally complicated if you want to proxy DSpace through Apache, which will be probably the case if you wish to run any other web software on the server and don’t want to have to enter port numbers to access DSpace. This article will step through the installation process on CentOS 5.5 although some elements with be relevant to other linux distributions and Unix-like OSes.

This article is heavily indebted to Clive Gould’s description of the process using DSpace 1.5.2 and CentOS 5.3 though I’ve altered and expanded on a number of elements.

Note that this article does not cover installation and configuration of the Handle server. We hope to deal with this in a future post.

Prerequisites

DSpace has the following software prerequisites for all platforms:

  • Java JDK v5 or later
  • Apache Maven 2.0.8 or later
  • Apache Ant 1.7 or later
  • PostgreSQL database (Oracle is also an option)
  • Jakarta Tomcat (other servlet engines are also an option)
  • Perl 5

Installing on CentOS 5.5

Normally we would assume that you have disabled the root login and created a separate user with sudo permission. However, this is not the standard approach on CentOS machines and complicates the installation process. Therefore the following instructions should be carried out as the root user unless stated. We recommend disabling the root account following the installation.

Installing Prerequisites

Create user

DSpace and Tomcat will need to run as the same user so create that user now:

useradd –m dspace
passwd dspace

Java JDK

Because of apparent licensing issues it is not possible to install recent Java versions using yum and standard CentOS package repositories. Therefore it is necessary to manually download an RPM for Java install. This has implication for other required software that cannot be installed using yum due to Java dependencies.

Download the Java JDK Linux RPM version. The current version at time of writing is jdk-6u20-linux-i586-rpm.bin.

Give execute permission to all users on the downloaded file and run it:

chmod a+x jdk-6u20-linux-i586-rpm.bin
./jdk-6u20-linux-i586-rpm.bin

Edit the system profile (/etc/profile) and create an environment variable for the location of the java installation by adding the following line:

export JAVA_HOME=/usr/java/default

Apache Maven

Download Apache Maven binary distribution.  The latest version at the time of writing is 2.2.1.

Unpack the package to /user/local/ and create a symbolic link to the new folder called maven. The actual name of the directory created after unpacking the Maven distribution will be dependent on the version that you downloaded.

ln –s apache-maven-2.2.1 maven

Next you will need to create an environment variable for the location of Maven. Add the following lines to /etc/profile to set the Maven home directory environment variable and add Maven binaries to the system path:

export M2_HOME=/usr/local/maven
export PATH=${PATH}:${M2_HOME}/bin

Log out and back in so that the profile changes are picked up and test the installation by confirming the Maven version:

mvn –version

HTTP Proxy

If you need to run maven through a HTTP proxy you will be required to configure this in the central settings.xml file. This should live under the Maven installation directory:

cd $M2_HOME/conf/

Uncomment the proxies section and add your details as illustrated in the highlighted section below:

<settings xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/xsd/settings-1.0.0.xsd">
  <proxies>
    <proxy>
      <active>true</active>
      <protocol>http</protocol>
      <host>your.proxy.com</host>
      <port>8080</port
      <username>proxyuser</username>
      <password>somepassword</password>
      <nonProxyHosts>localhost</nonProxyHosts>
    </proxy>
  </proxies>
</settings>

The username and password settings are only required if your proxy server requires authentication.

You can test the Maven installation and network connectivity by running:

mvn clean

This will give the message BUILD ERROR because it requires a pom.xml file but the output will indicate whether maven is able to download packages from its repositories.

Apache Ant

Download the Ant binary distribution. The latest version at the time of writing is 1.82. Unpack it to /usr/local/ and create a symbolic link to the new folder called ant. The actual name of the directory created after unpacking the Ant distribution will be dependent on the version that you downloaded.

ln –s apache-ant-1.8.1 ant

Next you need to create an environment variable for the location of Ant. Add the following to /etc/profile:

export ANT_HOME=/user/local/ant
export PATH=${PATH}:${ANT_HOME}/bin

Log out and back in so that the profile changes are picked up and test the installation by confirming the Ant version:

ant –version

HTTP Proxy

Part of the DSpace installation needs to download files from the web. If you are accessing the internet through a proxy you may need to tell Ant the proxy details. Edit /etc/profileand add the following lines, filling in the details of your HTTP proxy:

export ANT_OPTS="-Dhttp.proxyHost=<proxy address> -Dhttp.proxyPort=<proxy port>"

Note that the proxy address should contain only the domain name (or IP address) and not include ‘http://’.

PostgreSQL database

Out of the box DSpace will run on two database servers, PostgreSQL and Oracle. While Oracle Express edition is free (other editions can be quite expensive) for this exercise we will use the open source PostgreSQL.

These instructions assume version 8.0+ of PostgreSQL. Installation packages are available for CentOS and in testing this procedure yum installed version 8.1.21. To install run:

yum install postgresql postgresql-server

Update: if you are installing DSpace 1.7 then PostgreSQL 8.2 or greater is required. We’d recommend the current 8.4 version. To install this use:
yum install postgresql84 postgresql84-server

You will want to set the database to start on system boot, and to start the server immediately:

chkconfig --level 234 postgresql on
service postgresql start

As per the DSpace installation instructions a couple of changes are needed to the PostgreSQL configuration. Edit the file /var/lib/pgsql/data/postgresql.conf and uncomment the line starting:

listen_addresses = 'localhost'

And in the file /var/lib/pgsql/data/pg_hba.conf add the line below. Note that this should be the first configuration entry in the list, i.e. before the line that says # “local” is for Unix domain socket connections only:

host dspace dspace 127.0.0.1 255.255.255.255 md5

Restart PostgreSQL to pick up the changes.

service postgresql restart

Apache Tomcat

DSpace will run on other servlet engines but for the purposes of this document we will use Apache Tomcat.

Download the Tomcat distribution. The latest stable version at the time of writing is 6.0.26. Unpack it to /usr/local/ and create a symbolic link to the new folder called tomcat. The actual name of the directory created after unpacking the Tomcat distribution will be dependent on the version that you downloaded.

ln –s apache-tomcat-6.0.26 tomcat

The DSpace documentation mentions setting the TOMCAT_USER environment variable so that Tomcat will run as the dspace user. This is not necessary because we will be creating a startup script for Tomcat that will ensure that it runs as the correct user. Do however make sure that the tomcat directory is owned by the dspace user:

cd /usr/local
chown –R dspace:dspace apache-tomcat-6.0.26

Set some Java options to ensure that Tomcat is compatible with DSpace. Edit /etc/profile and add the following line:

export JAVA_OPTS="-Xmx512M -Xms64M -Dfile.encoding=UTF-8"

Log out and back in for these changes to be picked up.

Also tell the Tomcat connector to support UTF-8 encoding in URIs. Edit /usr/local/tomcat/conf/server.xml and make the highlighted changes to this section:

<Connector port="8080" protocol="HTTP/1.1"
connectionTimeout="20000"
redirectPort="8443"
URIEncoding="UTF-8" />

And start Tomcat to check if it starts up OK:

cd /usr/local/tomcat/bin
./startup.sh

If everything is fine shutdown Tomcat:

./shutdown.sh

Perl

Perl should already be installed on your CentOS server installation.

Install DSpace

DSpace can be downloaded from Sourceforge. For this example we will be using the default release rather than the source release. Copy the distribution file to your chosen installation directory (e.g. /usr/local/) and unpack it.

This will create a directory called dspace-<version>-release where <version> is the number of the DSpace version you downloaded. Following the convention of the DSpace manual we will refer to this directory as [dspace-source] in the remainder of this document.

Configure PostgreSQL

The PostgreSQL database will need to be configured for use by DSpace. First create the user in the DBMS. You will only be able to do this as the postgres user:

su – postgres
createuser -U postgres -d -A -P dspace

Next, log in as the dspace user and create a database.  Log out (back to the root account) if still logged in as the postgres user:

exit

Then log in as dspace and create the database:

su – dspace
createdb -U dspace -E UNICODE dspace
exit

Configure DSpace

Edit the DSpace configuration file [dspace-source]/dspace/config/dspace.cfg and set the following values appropriate to your installation.

dspace.dir = /usr/local/dspace
dspace.hostname = dspace.mydomain.com
dspace.baseUrl = http://dspace.mydomain.com
dspace.url = ${dspace.baseUrl}/jspui
dspace.name = My DSpace Repository
db.username = dspace
db.password = XXXX
mail.server=smtp.mydomain.com
mail.from.address = dspace-noreply@mydomain.com
feedback.recipient = dspace-help@mydomain.com
mail.admin = dspace-help@mydomain.com
default.language = en_GB

Next create the DSpace installation directory. This should be the directory specified in the dspace.dir configuration option above and should be owned by the dspace user. Assuming a dspace directory of /user/local/dspace:

cd /usr/local
mkdir dspace
chown dspace:dspace dspace

Again, following the convention of the DSpace manual we will refer to this installation directory as [dspace].

Build and install DSpace

Run the Maven package for DSpace as the dspace user:

su – dspace
cd [dspace-source]/dspace
mvn package

This may download a large number of additional packages in order to generate the DSpace installation.

Next, run the Ant build (still logged in as the dspace user):

cd [dspace-source]/dspace/target/dspace-<version>-build.dir
ant fresh_install

Configure Tomcat to use DSpace webapps

The DSpace installation instructions describe either copying the DSpace webapps into the default Tomcat webapps folder or pointing Tomcat to the DSpace webapps by changing the appBase setting for localhost. We do not recommend either of these approaches – the latter would remove access to all the default Tomcat webapps, which may not be what you want. Instead follow the instructions from the Windows installation section to set Contexts for paths relevant to DSpace.

Edit the file /usr/local/tomcat/conf/server.xml and add the following lines, substituting the actual paths to your installation directories:

<!-- DEFINE A CONTEXT PATH FOR DSpace JSP User Interface  -->
<Context path="/jspui" docBase="[dspace]/webapps/jspui" debug="0"
reloadable="true" cachingAllowed="false"
allowLinking="true"/>

<!-- DEFINE A CONTEXT PATH FOR DSpace OAI User Interface  -->
<Context path="/oai" docBase="[dspace]/webapps/oai" debug="0"
reloadable="true" cachingAllowed="false"
allowLinking="true"/>

Before starting Tomcat, create the DSpace administration user. Still logged in as the dspace user run this command:

cd [dspace]/bin
./create-administrator

Update: for DSpace 1.7 use:
cd [dspace]/bin
./dspace create-administrator

And then restart Tomcat:

cd /usr/local/tomcat/bin
./shutdown.sh
./startup.sh

You can test the installation using lynx (or another browser if you have a GUI capable CentOS installation).

lynx http://localhost:8080/jspui

Additional Configuration Options

Proxy DSpace/Tomcat through Apache

We don’t want to have to type the port number in the URL in order to access our repository so the next step is to set up proxying through Apache to Tomcat using mod_jk.

Make sure you are logged in as root. Download the version of mod_jk relevant to your operating system and version of Apache from the Binary Releases section of the Apache connectors page. This will probably be /linux/jk-1.2.28/i586/mod_jk-1.2.28-httpd-2.2.X.so. Rename this file to mod_jk.so and copy it to the directory /usr/lib/httpd/modules/.

Create a file called /etc/httpd/conf/workers.properties with the following contents:

worker.list=worker1
worker.worker1.port=8009
worker.default.host=localhost
worker.default.type=ajp13
worker.default.lbfactor=1

Next, create a file called /etc/httpd/conf.d/jk.conf containing:

#
# Mod_jk2 allows the Apache Web server to connect to application
# servers using the AJP protocol. This allows web applications to
# be integrated seamlessly into your Apache server's URI space and
# utilize Apache features such as SSL processing.
#
LoadModule jk_module modules/mod_jk.so
#
# mod_jk is configured in /etc/httpd/conf/workers.properties
#
# Where to find workers.properties
JkWorkersFile    /etc/httpd/conf/workers.properties
# Where to put jk logs
JkLogFile    /var/log/httpd/mod_jk.log
# Set the jk log level [debug/error/info]
JkLogLevel    info
# Select the log format
JkLogStampFormat    "[%a %b %d %H:%M:%S %Y] "
# JkOptions indicate to send SSL KEY SIZE,
JkOptions    +ForwardKeySize +ForwardURICompat -ForwardDirectories
# JkRequestLogFormat set the request format
JkRequestLogFormat    "%w %V %T"
#
JkMount    /jspui worker1
#
JkMount    /jspui/* worker1
#
JkMount    /oai worker1
#
JkMount    /oai/* worker1

(Adapted from Clive Gould – http://dspacebromley.blogspot.com/)

Restart Apache:

service httpd restart

The repository should now be available at the domain name specified in the section Configure DSpace (with the addition of /jspui to the URL).

Configure Tomcat to start on boot

Configuring Tomcat to start when the system boots is a two stage process. First, log in as root and create a script file in the directory /etc/init.d/ called tomcat. Give it the following contents, changing any paths where relevant:

#!/bin/bash
# chkconfig: 234 20 80
# description: Tomcat Server basic start/shutdown script
# processname: tomcat
TOMCAT_HOME=/usr/local/tomcat
START_TOMCAT=${TOMCAT_HOME}/bin/startup.sh
STOP_TOMCAT=${TOMCAT_HOME}/bin/shutdown.sh
start() {
  echo -n "Starting tomcat: "
  su - dspace ${START_TOMCAT}
  echo "done."
}
stop() {
  echo -n "Shutting down tomcat: "
  su - dspace ${STOP_TOMCAT}
  echo "done."
}
case "$1" in
start)
  start
;;
stop)
  stop
;;
restart)
  stop
  sleep 10
  start
;;
*)
  echo "Usage: $0 {start|stop|restart}"
esac
exit 0

(Source http://cloudservers.rackspacecloud.com/index.php/CentOS_-_Tomcat_6, modified)

Test that this script works to start and stop Tomcat (this assumes that Tomcat is not currently running):

service tomcat start
service tomcat stop

Second, add the script to chkconfig and set it to run at appropriate system runlevels:

chkconfig --add tomcat
chkconfig --level 234 tomcat on

You can check whether this has worked by listing the chkconfig options for Tomcat:

chkconfig --list tomcat

Cron jobs

A number of cron jobs are required in order to carry out scheduled tasks such as sending subscription emails, generating thumbnail images of media and generating statistics. First create a set of cron jobs as the dspace user. From a root login:

su – dspace
crontab –e

Enter the following lines, substituting your DSpace installation path:

# 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
# Run the checksum checker at 03:00
0 3 * * *  [dspace]/bin/checker -lp
# Mail the results to the sysadmin at 04:00
0 4 * * *  [dspace]/bin/dsrun org.dspace.checker.DailyReportEmailer -c
# Run stat analysis
0 1 * * * [dspace]/bin/stat-general
0 1 * * * [dspace]/bin/stat-monthly
0 2 * * * [dspace]/bin/stat-report-general
0 2 * * * [dspace]/bin/stat-report-monthly

Log out and then back in as the postgres user and create another crontab to clean the database regularly:

exit
su – postgres
crontab –e

Add these lines (for example):

# Clean up the database nightly at 4.20am
20 4 * * * vacuumdb --analyze dspace > /dev/null 2>&1

Finished

This should complete the DSpace installation and you should be able to access the repository on your desired URL without the need to enter a port number.

About these ads

About Rob Ingram
Rob Ingram is the Technical Officer for the Repositories Support Project offering technical advice and support to UK repository networks.

17 Responses to Installing DSpace on CentOS 5

  1. I followed your steps till i got to mvn package where i start having problems. it gave some errors such as

    [WARNING] Not copying webapp webResources [/usr/local/dspace-1.7.0-release/dspace/modules/xmlui/src/main/webapp]: webapp directory [/usr/local/dspace-1.7.0-release/dspace/modules/xmlui/target/xmlui-1.7.0] does not exist!
    [INFO] Copying webapp webResources [/usr/local/dspace-1.7.0-release/dspace/modules/xmlui/src/main/webapp] to [/usr/local/dspace-1.7.0-release/dspace/modules/xmlui/target/xmlui-1.7.0]
    [INFO] Copying webapp resources [/usr/local/dspace-1.7.0-release/dspace/modules/xmlui/src/main/webapp]
    [INFO] ————————————————————————
    [ERROR] BUILD ERROR
    [INFO] ————————————————————————
    [INFO] Failed to copy file for artifact [org.dspace:dspace-discovery-xmlui-api:jar:1.7.0:compile]

    Embedded error: /usr/local/dspace-1.7.0-release/dspace/modules/xmlui/target/xmlui-1.7.0/WEB-INF/lib/dspace-discovery-xmlui-api-1.7.0.jar (No such file or directory)

    I realised those directories are non existent. How can i solve this?
    Thanks in advance.

    • Rob Ingram says:

      Hi,

      I would have thought that it would create any necessary directories. Did you run this as the ‘dspace’ user, and does this user have write permissions on /usr/local/dspace-1.7.0-release/?

      I haven’t tried a 1.7 install yet. It might be worth having a look on the DSpace General and Technical mailing lists to see if anybody else has experienced similar problems.

      Rob.

    • Gleise says:

      Try Maven 2.2.1 instead of Maven 3 and change the owner of the directory / usr/local/dspace-1.7.0-release for dspace. This worked for me.

  2. I got the dspace build to work perfectly – thanks mostly to your howto here (thanks a bunch). I’m trying to install dspace through apache per your optional “Proxy DSpace/Tomcat through Apache” above. I have http://localhost:8080/jspui working perfectly, but http://dspace.mydomain.com doesn’t work at all. Note that I have NameVirtualHosts on apache with a lot of websites (for example, I have wiki.mydomain.com, where I have the php app mediawiki installed successfully). Is it necessary to create a vhost in apache somehow so that dspace.mydomain.com works?

  3. Jeff says:

    This is a very helpful DSpace install guide for CentOS Rob! I’m trying to understand the defining of the JAVA_OPTS variable. I’m working on a few things that are new to me here.

    I noticed JAVA_OPTS is set in [dspace]/bin/dspace script already out-of-the-box (dspace v1.6.2):

    #Allow user to specify java options through JAVA_OPTS variable
    if [ “$JAVA_OPTS” = “” ]; then
    #Default Java to use 256MB of memory
    JAVA_OPTS=-Xmx256m
    fi

    # Now invoke Java
    java $JAVA_OPTS -classpath $FULLPATH org.dspace.app.launcher.ScriptLauncher “$@”

    Yet, I see that the installation instructions in the DSpace manual state:

    You need to ensure that Tomcat has a) enough memory to run DSpace and b) uses UTF-8 as its default file encoding for international character support. So ensure in your startup scripts (etc) that the following environment variable is set:

    JAVA_OPTS=”-Xmx512M -Xms64M -Dfile.encoding=UTF-8″

    And I see you have detailed this above as well, in /etc/profile. By setting it in /etc/profile does this set JAVA_OPTS globally? That was my understanding. So what is the value of JAVA_OPTS if it is set in /etc/profile with memory and file encoding specifications, and then also set in the ‘dspace’ script with potentially different memory specifications? My assumption is that one setting is for Tomcat (/etc/profile) and the other is for DSpace (which overrides the /etc/profile setting if/when ‘dspace’ script is run???).

    Just wanting to understand the JAVA_OPTS setting a little better.

    Thank you!

    • Rob Ingram says:

      Hi Jeff,

      I’m glad you found the guide useful.

      Yes, the setting in /etc/profile would be global (for anything that observes the environment variable).

      You’ll notice that the dspace script first checks if JAVA_OPTS is empty and only sets its default value of 256MB if it is. This should mean that the settings in /etc/profile should apply for dspace.

      I hope that helps.

      Rob.

  4. Deji says:

    I ve d same error while installing dspace-1.7.0-release with Apache Maven 2.2.1 installed. t
    his is d error

    [INFO] Scanning for projects…
    [INFO] Reactor build order:
    [INFO] DSpace Addon Modules
    [INFO] DSpace XML-UI (Manakin) :: Web Application
    [INFO] DSpace LNI :: Web Application
    [INFO] DSpace OAI :: Web Application
    [INFO] DSpace JSP-UI :: Web Application
    [INFO] DSpace SWORD :: Web Application
    [INFO] DSpace SOLR :: Web Application
    [INFO] DSpace Assembly and Configuration
    [INFO] ————————————————————————
    [INFO] Building DSpace Addon Modules
    [INFO] task-segment: [package]
    [INFO] ————————————————————————
    [INFO] [enforcer:enforce {execution: enforce-maven}]
    [INFO] [site:attach-descriptor {execution: default-attach-descriptor}]
    [INFO] ————————————————————————
    [INFO] Building DSpace XML-UI (Manakin) :: Web Application
    [INFO] task-segment: [package]
    [INFO] ————————————————————————
    [INFO] [enforcer:enforce {execution: enforce-maven}]
    [INFO] [resources:resources {execution: default-resources}]
    [INFO] Using ‘UTF-8′ encoding to copy filtered resources.
    [INFO] skip non existing resourceDirectory /usr/local/dspace-1.7.0-release/dspace/modules/xmlui/src/main/resources
    [INFO] [compiler:compile {execution: default-compile}]
    [INFO] No sources to compile
    [INFO] [resources:testResources {execution: default-testResources}]
    [INFO] Using ‘UTF-8′ encoding to copy filtered resources.
    [INFO] skip non existing resourceDirectory /usr/local/dspace-1.7.0-release/dspace/modules/xmlui/src/test/resources
    [INFO] [compiler:testCompile {execution: default-testCompile}]
    [INFO] Not compiling test sources
    [INFO] [surefire:test {execution: default-test}]
    [INFO] Tests are skipped.
    [INFO] [war:war {execution: default-war}]
    [INFO] Packaging webapp
    [INFO] Assembling webapp [xmlui] in [/usr/local/dspace-1.7.0-release/dspace/modules/xmlui/target/xmlui-1.7.0]
    [INFO] Processing war project
    [WARNING] Not copying webapp webResources [/usr/local/dspace-1.7.0-release/dspace/modules/xmlui/src/main/webapp]: webapp directory [/usr/local/dspace-1.7.0-release/dspace/modules/xmlui/target/xmlui-1.7.0] does not exist!
    [INFO] Copying webapp webResources [/usr/local/dspace-1.7.0-release/dspace/modules/xmlui/src/main/webapp] to [/usr/local/dspace-1.7.0-release/dspace/modules/xmlui/target/xmlui-1.7.0]
    [INFO] Copying webapp resources [/usr/local/dspace-1.7.0-release/dspace/modules/xmlui/src/main/webapp]
    [INFO] ————————————————————————
    [ERROR] BUILD ERROR
    [INFO] ————————————————————————
    [INFO] Failed to copy file for artifact [org.dspace:dspace-discovery-xmlui-api:jar:1.7.0:compile]

    Embedded error: /usr/local/dspace-1.7.0-release/dspace/modules/xmlui/target/xmlui-1.7.0/WEB-INF/lib/dspace-discovery-xmlui-api-1.7.0.jar (No such file or directory)
    [INFO] ————————————————————————
    [INFO] For more information, run Maven with the -e switch
    [INFO] ————————————————————————
    [INFO] Total time: 15 seconds
    [INFO] Finished at: Wed Apr 06 14:32:25 EDT 2011
    [INFO] Final Memory: 34M/82M
    [INFO] ————————————————————————

    When i checked for this directory [/usr/local/dspace-1.7.0-release/dspace/modules/xmlui/target/xmlui-1.7.0] , it does not exist at all and i cant proceed without. pls i ll highly appreciated ur experience to solve this problem of mine. Thanks

    Deji

    • Rob Ingram says:

      Hi Deji,

      My first thought would be to check the ownership of the /usr/local/dspace-1.7.0-release/ folder. Make sure that this and the dspace installation directory are owned by the dspace user. Log in as root and run:

      cd /usr/local
      chown -R dspace:dspace dspace-1.7.0-release
      chown -R dspace:dspace dspace

      And then make sure that you are logged in as the dspace user when you run mvn package.

      If this doesn’t work I see that you have posted the question to the DSpace tech list. I’m sure that somebody there will be able to help.

      Rob.

  5. Madhawa says:

    Dear Rob

    Does this applies to CentOS 5.5 64bit?

  6. Carwyn Edwards says:

    I’m curious as to why this guide recommends using a custom install of tomcat6 rather than the CentOS native tomcat5? Similalrly mod_proxy_ajp is part of the version of apache in CentOS 5 (can be used instead of mod_jk).

    Both these steps give two extra packages to download, install and maintain (both highly relevant to security).

    vs ..
    yum install tomcat5
    yum install httpd

    Similarly OpenJDK is a native part of CentOS 5..

    yum install java-openjdk

    Installing all these extra packages by hand seems to create more work in terms of maintenance vs:

    yum update

    ?

    Granted there’s no maven in CentOS 5 and ant is 1.6 not the 1.7 that DSpace now requires.

    • Rob Ingram says:

      Hi,

      The Tomcat decision was purely a case of ‘why use tomcat5 when tomcat6 has been available for a while now’.

      The Java decision was due to only finding a few reports of using OpenJDK successfully with DSPace. I thought the safest option was to stick with a standard distribution. If you can advise on the effectiveness of OpenJDK with DSpace and mod_proxy_ajp then that would be great. :)

      Rob.

  7. Thanks to your nice tutorial I was able to set up easily a DSpace-Test-Server on CentOS 5.6.
    Now, I would like to know how to set it up to work with SSL and the xmlui interface.
    What I did so far is to add the SSL connector in server.xml and in the httpd.conf the following section as suggested by the Dspace Wiki:
    “# Should mod_jk send SSL information to Tomcat (default is On)
    JkExtractSSL On
    # What is the indicator for SSL (default is HTTPS)
    JkHTTPSIndicator HTTPS
    # What is the indicator for SSL session (default is SSL_SESSION_ID)
    JkSESSIONIndicator SSL_SESSION_ID
    # What is the indicator for client SSL cipher suit (default is SSL_CIPHER)
    JkCIPHERIndicator SSL_CIPHER
    # What is the indicator for the client SSL certificated (default is SSL_CLIENT_CERT)
    JkCERTSIndicator SSL_CLIENT_CERT”

    I’ve set up a constraint for the webapp, so any login will be redirected to a secured website as suggested here:

    https://wiki.duraspace.org/display/DSPACE/ServletSecurity

    Now, I can access normally to my DSpace-Server (http://xxx.xxx.xxx.xxx/xmlui/), and when I try to login I will be redirected, as it supposed to be, but the page isn’t found: https://xxx.xxx.xxx.xxx:8443/xmlui/password-login. And that’s the major problem I have. Til now I haven’t found what I’m missing so far, some config in https.conf? So maybe someone has a suggestion or a solution for that.
    Thanks,
    Thomas

  8. Pingback: Dspace Installation on CentoS » The Web Keeper

  9. Hossein Zolfi says:

    Thanks Rob for your instructions :)

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Follow

Get every new post delivered to your Inbox.

%d bloggers like this: