Contribute to the DSpace Development Fund

The newly established DSpace Development Fund supports the development of new features prioritized by DSpace Governance. For a list of planned features see the fund wiki page.

Older Instructions

(GraceCarpenter, September 2004)

This is my unofficial write-up of how to install DSpace 1.2 on Windows. Although
this process probably works on several versions of Windows, I personally have experience only with Windows XP. Please feel free to modify/correct/add to these instructions! This document owes much to Tom Corrigan's write-up from 7/3/03, and is also based as closely as possible on the official installation instructions from the DSpace System Documentation.

Please remember that DSpace was written with Unix-like platforms in mind;
although you can run it under Windows, it may not be ideal for a
production server. To my knowledge, very little testing of DSpace has been done
under Windows. Also keep in mind that even when using Windows as your DSpace
platform, you'll need to be reasonably comfortable with a Unix-like command
line environment, since you'll be using the Linux emulator Cygwin. In fact, if
at all possible, you should probably get it up and running under Linux/Unix
before tackling Windows; if you run into problems in the install, you will have
a much greater pool of knowledgeable users and developers to whom you can turn
for help.

This document uses the same conventions as the official DSpace documentation
to refer to the various DSpace directories:

*the source directory is referred to as [dspace-source]
*the install directory is referred to as [dspace]

In general, whenever you see a directory name in italics and surrounded by
square brackets in this document, you should replace it with the actual
directory name on your machine. For more information on the different DSpace
directories, see the official DSpace documentation. Be sure to keep the source
directory and install directory separate!

In order to do the installation you must be logged in as a user who has full
administrative rights on the machine. Also, remember that you will be doing
most of the install from the command line, and you will make your life a lot
simpler if you do the two following things:

*Make your Windows user name short, and avoid blanks and special characters.
*Make your directory names short, and avoid blanks and special characters.

Pre-requisites:

1.The Linux emulator Cygwin, along with the
Cygwin version of the open source relational database PostgreSQL.

When downloading Cygwin, you must install
PostgreSQL, in addition to installing the default Cygwin packages. You do this
by choosing the PostgreSQL option in the Database category in the Cygwin setup
program. This is the only setup of PostgreSQL that is necessary; there is no
need to recompile PostgreSQL as described in the DSPace install document.

(**??Copy the postgresql.jar to
c:[dspace-source]\lib.**)

We suggest you use c:\cygwin for the installation
directory. Make other choices as appropriate to your environment.

2.Download cygipc. Store
the download in c\cygwin. Start a Cygwin command shell and execute:

{{

Unknown macro: {cd /cygdrive/c/cygwinunzip2 cygipc-x.xx.tar.bz2tar xvf cygipc-x.xx.tar}}

}

3.Java 1.4 or later (standard SDK is fine, you don't need J2EE).

You'll need to set the JAVA_HOME system environment variable, and also add the $JAVA_HOME/bin directory to your classpath. You can do this either by using the Windows Control Panel or by writing a shell script that you run in Cygwin at the start of every Cygwin session. Since you'll
probably be using Java (as well as Ant and Tomcat, below) for more than justDSpa ce, it probably makes more sense to use the Control Panel. If you're unsure about how to set environment variables through the Control Panel, please see your Windows documentation.

4.Apache Ant 1.5 or later (Java make-like tool)
(See note above regarding setting environment variables.)

5.Jakarta Tomcat 4.x/5.x or equivalent, such as
Jetty or Caucho Resin.
(See note above regarding setting environment
variables.)

Installation Steps

1.Download the latestDSp ace source code release, and unzip it using WinZip. (The directory you unzip it to will be referred to now as [dspace-source].

2.Download the other required Java libraries:

*JavaBeans Activation Framework--place activation.jar from the ZIP file in [dspace-source]/lib

*Java Servlet 2.3 and JSP 1.2--go to this page and click the 'continue' button next to 'Download class files 1.2'. Place servlet.jar in [dspace-source]/lib

*JavaMail API--place mail.jar in [dspace-source]/lib

(Remember that you should replace [dspace-source] with the actual name of your DSpace source directory).

3.Open a Cygwin command shell and execute

{{

Unknown macro: { ipc-daemon &initdb /cygdrive/c/pgsql/data}}

}

Then activate PostgreSQL in the same Cygwin command
shell with the following command:

{{

Unknown macro: {postmaster -D /usr/local/pgsql/data >/usr/local/pgsql/data/logfile 2>&1 &}}

}

    • ??Is the pgsl/data dir already
      there?**

4.Create a dspace
database, owned by the current user:

{{

Unknown macro: {createuser -U [username] -d -A -P dspace ; createdb -U dspace -E UNICODE dspace}}

}

(Don't forget that Linux/Cygwin is CASE-SENSITIVE.)When prompted for a password use "dspace"

5.Edit [dspace-source]/config/dspace.cfg, in particular you'll
need to set these properties:

{{

Unknown macro: {dspace.urldspace.hostnamedspace.namedb.password (the password you entered in the previous step)mail.servermail.from.addressfeedback.recipientmail.adminalert.recipient (not essential but very useful!)}}

}

You should type in the directory names as DOS paths (not Cygwin paths), but use the forward slash instead of the backslash (), e.g. c:/dspace.

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...

6.Edit the dsrun file in [dspace-source]/bin and add the following line just after the existing FULLPATH statement:

{{

Unknown macro: {FULLPATH=`cygpath --path --windows "$FULLPATH"`}}

}

(The ` character is located underneath the tilde on the standard American keyboard.)

7.From the Cygwin command shell window execute

{{

Unknown macro: {cd [dspace-source] ant fresh_install}}

}

8.Copy the DSpace Web application archives (.war files) to the appropriate directory in your
Tomcat/Jetty/Resin installation. For example:

{{

Unknown macro: {cp [dspace-source]/build/*.war [tomcat]/webapps}}

}

(Don't forget that if you're re-installing DSpace, you'll need to first stop Tomcat and delete the existing [tomcat]/webapps/dspace directory.)

9.Create an initial administrator account:

{{

Unknown macro: {[dspace]/bin/create-administrator}}

}

Now the moment of truth! Start up (or restart) Tomcat. Visit the base
URL of your server, e.g. http://dspace.myu.edu:8080/dspace. You should see the
DSpace home page. Congratulations!

  • No labels