Open-Xchange on RedHat 9 and Fedora Core 1/2/3/4 How-to

Version 1.6 (2005/09/26)

Introduction
This page ...

... will try to help you to setup Open-Xchange on your RedHat 9, Fedora Core 1, 2 3 or 4 box.

Open-Xchange ("OX") is a GPL Groupware solution provided by Netline. It's the "community" version of Novell/SUSE LINUX Openexchange Server ("SLOX").

Important: the way the software is installed here is good enough for testing purposes, but certainly not for a production environment (weak passwords, too many things done with the root user ...) !!! You have been warned ...

License

Copyright (c) 2004 Laurent FRANCOISE.
Copyright (c) 2004-2005 Sietse Visser.
Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is included in the section entitled "GNU Free Documentation License".

GNU Free Documentation License

The license is here.

Legal

I am not responsible of the possible data losses caused by the use of this document ... blablabla ...

Select a distribution

Show Show RedHat 9 howto
Show Show Fedora Core 1 howto
Show Show Fedora Core 2 howto
Show Show Fedora Core 3 howto
Show Show Fedora Core 4 howto

Select another distribution than

The following chapters show the howto for . Click below for another distribution.

Show Show RedHat 9 howto
Show Show Fedora Core 1 howto
Show Show Fedora Core 2 howto
Show Show Fedora Core 3 howto
Show Show Fedora Core 4 howto

Before starting ...

The Open-Xchange software will be installed in$OX_INSTALL. For instance, OX_INSTALL=/usr/local/ox.

Most software is installed using apt-get and rpm.

I assume that you use a fresh install of RH9, FC1 or FC2, updated with atrpm from atrpms.net.

Most software is installed using yum and rpm.

I assume that you use a fresh install of FC3, updated with 'yum dist-upgrade'.

I suppose that your web host is called "myhost".

Pre-install
Fedora and atrpms

First, make a fresh installation. Then go to atrpms.net, install the signing key, find the kickstart package from the installation page and install it.
Run apt-get update && apt-get dist-upgrade 3 times to update your system.
Then, add some lines in your /etc/apt/sources.list, and install some RPM's.

Fedora install
First, install a fresh copy of , do a yum update, add some lines in your /etc/apt/sources.list, and install some RPM's:

For RedHat 9:

# Copy the next 5 lines to /etc/apt/sources.list
# jpackage.org; http://jpackage.org/repos.php
rpm             http://mirrors.sunsite.dk/jpackage 1.5/generic free
rpm-src         http://mirrors.sunsite.dk/jpackage 1.5/generic free non-free
rpm             http://mirrors.sunsite.dk/jpackage 1.5/redhat-9 free
rpm-src         http://mirrors.sunsite.dk/jpackage 1.5/redhat-9 free
rpm             http://apt.sw.be redhat/9/en/i386 dag


#Update rpm database, and install some RPM's:
apt-get update
apt-get install postgresql postgresql-server postgresql-libs
apt-get install httpd httpd-manual
apt-get install xerces-j2
apt-get install jdom
apt-get install postgresql-jdbc
apt-get install mod_jk-ap20
apt-get install perl-Convert-ASN1
apt-get install perl-ldap
apt-get install perl-IO-Socket-SSL
apt-get install perl-Net-SSLeay
apt-get install perl-Authen-SASL
apt-get install perl-XML-NamespaceSupport
apt-get install perl-XML-SAX
apt-get source java-1.4.2-sun
apt-get source javamail
apt-get source jaf
apt-get source jta

For Fedora Core 1:

# Copy the next 5 lines to /etc/apt/sources.list
# jpackage.org; http://jpackage.org/repos.php
rpm             http://mirrors.sunsite.dk/jpackage 1.5/generic free
rpm-src         http://mirrors.sunsite.dk/jpackage 1.5/generic free non-free
rpm             http://mirrors.sunsite.dk/jpackage 1.5/fedora-1 free
rpm-src         http://mirrors.sunsite.dk/jpackage 1.5/fedora-1 free
rpm             http://apt.sw.be redhat/fc1/en/i386 dag

#Update rpm database, and install some RPM's:
apt-get update
apt-get install postgresql postgresql-server postgresql-libs
apt-get install httpd httpd-manual
apt-get install xerces-j2
apt-get install jdom
apt-get install postgresql-jdbc
apt-get install mod_jk-ap20
apt-get install perl-Convert-ASN1
apt-get install perl-Net-LDAP
apt-get install perl-IO-Socket-SSL
apt-get install perl-Net-SSLeay
apt-get install perl-Authen-SASL
apt-get install perl-XML-NamespaceSupport
apt-get install perl-XML-SAX
apt-get source java-1.4.2-sun
apt-get source javamail
apt-get source jaf
apt-get source jta

For Fedora Core 2:

# Copy the next 5 lines to /etc/apt/sources.list
# jpackage.org; http://jpackage.org/repos.php
rpm             http://mirrors.sunsite.dk/jpackage 1.5/generic free
rpm-src         http://mirrors.sunsite.dk/jpackage 1.5/generic free non-free
rpm             http://mirrors.sunsite.dk/jpackage 1.5/fedora-2 free
rpm-src         http://mirrors.sunsite.dk/jpackage 1.5/fedora-2 free
rpm		http://apt.sw.be fedora/2/en/i386 dag

#Update rpm database, and install some RPM's:
apt-get update
apt-get install postgresql postgresql-server postgresql-libs
apt-get install httpd httpd-manual
apt-get install xerces-j2
apt-get install jdom
apt-get install postgresql-jdbc
apt-get install mod_jk-ap20
apt-get install perl-Convert-ASN1
apt-get install perl-ldap
apt-get install perl-IO-Socket-SSL
apt-get install perl-Net-SSLeay
apt-get install perl-Authen-SASL
apt-get install perl-XML-NamespaceSupport
apt-get install perl-XML-SAX
apt-get source java-1.4.2-sun
apt-get source javamail
apt-get source jaf
apt-get source jta

# The ANT version and some other stuff of FC2 is not useable
rpm -e ant ant-core jaf-20030319 javamail-20031006 mx4j commons-modeler

For Fedora Core 3:

We need packages from Dag Wieer's and the jpackage repository, so we install his key.
Please note, it took me ages to figure out the correct order for the installation of the packages. So if you divert from the order below, things may go wrong.

# Install dag.wieers his key
rpm --import http://dag.wieers.com/packages/RPM-GPG-KEY.dag.txt

# Get the repo definitions for jpackage
cd /etc/yum.repos.d
wget http://jpackage.org/jpackage.repo

yum update
Download jdk, javamail, jaf and jta from Sun:
Go to http://java.sun.com/j2se/1.5.0/download.html and download jdk-1_5_0_04-linux-i586.bin for the jdk
Go to http://java.sun.com/products/javamail/downloads/index.html and download javamail-1_3_2-upd.zip.
Go to http://java.sun.com/products/javabeans/glasgow/jaf.html and download jaf-1_0_2-upd2.zip.
Go to http://java.sun.com/products/jta/ and download the class files and javadocs.

Now let's install the Sun JDK, and make rpm's out of javamail, jaf and jta.

cp <jdk linux bin file> /usr/src/redhat/SOURCES/jdk-1_5_0_04-linux-i586.bin
cp <javamail file> /usr/src/redhat/SOURCES/javamail-1_3_2.zip
cp <jaf file> /usr/src/redhat/SOURCES/jaf-1_0_2-upd.zip
cp <jta classes file> /usr/src/redhat/SOURCES/jta-1_0_1B-classes.zip
cp <jta doc file> /usr/src/redhat/SOURCES/jta-1_0_1B-doc.zip

rpm -Uvh http://mirrors.dotsrc.org/jpackage/1.6/generic/non-free/SRPMS/jaf-1.0.2-4jpp.nosrc.rpm \
         http://mirrors.dotsrc.org/jpackage/1.6/generic/non-free/SRPMS/jta-1.0.1-0.b.4jpp.nosrc.rpm \
         http://mirrors.dotsrc.org/jpackage/1.6/generic/non-free/SRPMS/javamail-1.3.2-1jpp.nosrc.rpm \
         http://mirrors.dotsrc.org/jpackage/1.6/generic/non-free/SRPMS/java-1.5.0-sun-1.5.0.04-1jpp.nosrc.rpm

cd /usr/src/redhat/SPECS
rpmbuild -ba java-1.5.0-sun.spec
yum install xorg-x11-deprecated-libs
rpm -Uvh /usr/src/redhat/RPMS/*/java-1.5.0-sun*

rpmbuild -ba javamail.spec
rpmbuild -ba jaf.spec
rpmbuild -ba jta.spec
rpm -Uvh ../RPMS/noarch/jaf* ../RPMS/noarch/jta* ../RPMS/noarch/javamail*

# Install some OX-required packages
rpm -Uvh http://apt.sw.be/packages/perl-Net-SSLeay/perl-Net-SSLeay-1.25-1.1.fc3.rf.i386.rpm \
         http://apt.sw.be/packages/perl-IO-Socket-SSL/perl-IO-Socket-SSL-0.96-1.1.fc3.rf.noarch.rpm \
         http://apt.sw.be/packages/perl-Authen-SASL/perl-Authen-SASL-2.08-1.1.fc3.rf.noarch.rpm

yum install \
    postgresql postgresql-server postgresql-libs httpd httpd-manual \
    xerces-j2 jdom mod_jk-ap20 perl-Convert-ASN1 perl-XML-NamespaceSupport  ant \
    tomcat5 tomcat5-admin-webapps xml-commons-apis

rpm -Uvh http://download.fedora.redhat.com/pub/fedora/linux/core/updates/3/i386/postgresql-jdbc-7.4.8-1.FC3.1.i386.rpm

service tomcat5 start
You can check whether tomcat installed allright by visiting http://myhost:8080/manager.

For Fedora Core 4:

We need packages from Dag Wieer's and the jpackage repository, so we install his key.
Please note, it took me ages to figure out the correct order for the installation of the packages. So if you divert from the order below, things may go wrong.

# Install dag.wieers his key
rpm --import http://dag.wieers.com/packages/RPM-GPG-KEY.dag.txt

# Get the repo definitions for jpackage
cd /etc/yum.repos.d
wget http://jpackage.org/jpackage.repo

yum update
Download jdk, javamail, jaf and jta from Sun:
Go to http://java.sun.com/j2se/1.5.0/download.html and download jdk-1_5_0_04-linux-i586.bin for the jdk
Go to http://java.sun.com/products/javamail/downloads/index.html and download javamail-1_3_2-upd.zip.
Go to http://java.sun.com/products/javabeans/glasgow/jaf.html and download jaf-1_0_2-upd2.zip.
Go to http://java.sun.com/products/jta/ and download the class files and javadocs.

Now let's install the Sun JDK, and make rpm's out of javamail, jaf and jta.

cp <jdk linux bin file> /usr/src/redhat/SOURCES/jdk-1_5_0_04-linux-i586.bin
cp <javamail file> /usr/src/redhat/SOURCES/javamail-1_3_2.zip
cp <jaf file> /usr/src/redhat/SOURCES/jaf-1_0_2-upd.zip
cp <jta classes file> /usr/src/redhat/SOURCES/jta-1_0_1B-classes.zip
cp <jta doc file> /usr/src/redhat/SOURCES/jta-1_0_1B-doc.zip

rpm -Uvh http://mirrors.dotsrc.org/jpackage/1.6/generic/non-free/SRPMS/jaf-1.0.2-4jpp.nosrc.rpm \
         http://mirrors.dotsrc.org/jpackage/1.6/generic/non-free/SRPMS/jta-1.0.1-0.b.4jpp.nosrc.rpm \
         http://mirrors.dotsrc.org/jpackage/1.6/generic/non-free/SRPMS/javamail-1.3.2-1jpp.nosrc.rpm \
         http://mirrors.dotsrc.org/jpackage/1.6/generic/non-free/SRPMS/java-1.5.0-sun-1.5.0.04-1jpp.nosrc.rpm

cd /usr/src/redhat/SPECS
rpmbuild -ba java-1.5.0-sun.spec
yum install xorg-x11-deprecated-libs
rpm -Uvh /usr/src/redhat/RPMS/*/java-1.5.0-sun*

rpmbuild -ba javamail.spec
rpmbuild -ba jaf.spec
rpmbuild -ba jta.spec
rpm -Uvh ../RPMS/noarch/jaf* ../RPMS/noarch/jta* ../RPMS/noarch/javamail*

# Install some OX-required packages
rpm -Uvh http://apt.sw.be/packages/perl-Net-SSLeay/perl-Net-SSLeay-1.25-2.2.fc4.rf.i386.rpm \
         http://apt.sw.be/packages/perl-IO-Socket-SSL/perl-IO-Socket-SSL-0.96-1.2.fc4.rf.noarch.rpm \
         http://apt.sw.be/packages/perl-Authen-SASL/perl-Authen-SASL-2.09-1.2.fc4.rf.noarch.rpm

yum install \
    postgresql postgresql-server postgresql-libs httpd httpd-manual \
    xerces-j2 jdom mod_jk perl-Convert-ASN1 perl-XML-NamespaceSupport  ant \
    tomcat5 tomcat5-admin-webapps xml-commons-apis

# Yes, next is an 'old' version; the FC4 version is based on postgresql 8, and does not work.
# Don't let yum update it!
rpm -Uvh http://download.fedora.redhat.com/pub/fedora/linux/core/updates/3/i386/postgresql-jdbc-7.4.8-1.FC3.1.i386.rpm

service tomcat5 start
The two warnings can be ignored when starting tomcat5.
You can check whether tomcat installed allright by visiting http://myhost:8080/manager.
LDAP stuff
RedHat 9

The RedHat 9 LDAP server is not compiled with --enable-aci, so I downloaded the source rpm, edited the openldap.spec file (it is here for the curious), and generated new RPM's.
Download openldap-clients-2.0.27-8.i386.rpm and openldap-servers-2.0.27-8.i386.rpm and then:

rpm -Uvh openldap-servers-2.0.27-8.i386.rpm openldap-clients-2.0.27-8.i386.rpm
service ldap start
Fedora Core 1

The FC1 LDAP server is not compiled with --enable-aci, so I downloaded the source rpm, edited the openldap.spec file (it is here for the curious), and generated new RPM's.
Download openldap-clients-2.1.22-8.i386.rpm and openldap-servers-2.1.22-8.i386.rpm and then:

rpm -Uvh openldap-servers-2.1.22-8.i386.rpm openldap-clients-2.1.22-8.i386.rpm
service ldap start
Fedora Core 2

The FC2 LDAP server is not compiled with --enable-aci, so Micah Quinn downloaded the source rpm, edited the openldap.spec file (it is here for the curious), and generated new RPM's.
Download openldap-clients-2.1.29-1.i386.rpm and openldap-servers-2.1.29-1.i386.rpm and then:

rpm -Uvh openldap-servers-2.1.29-1.i386.rpm openldap-clients-2.1.29-1.i386.rpm
service ldap start
Fedora Core 3

The FC3 LDAP server is not compiled with --enable-aci, so Micah Quinn downloaded the source rpm, edited the openldap.spec file (it is here for the curious), and generated new RPM's.
Install openldap-servers-2.2.13_aci-2.i386.rpm:

rpm -e openldap-servers # Just in case, remove old version first
rpm -Uvh http://sietse.net/exoops/modules/OpenXchange/fc3/openldap-servers-2.2.13_aci-2.i386.rpm
yum install openldap-clients
service ldap start
Fedora Core 4

The FC4 LDAP server is not compiled with --enable-aci, so Micah Quinn downloaded the source rpm, edited the openldap.spec file (it is here for the curious), and generated new RPM's.
Install openldap-servers-2.2.23_aci-5.i386.rpm:

rpm -e openldap-servers # Just in case, remove old version first
rpm -Uvh http://sietse.net/exoops/modules/OpenXchange/fc4/openldap-servers-2.2.23_aci-5.i386.rpm
yum install openldap-clients
service ldap start
Java stuff

I found documentation for most needed javastuff on http://docs.indymedia.org/view/Local/UkDevServer.

Here is the short version.

Download software from Sun

Download the following software from Sun and put them in /usr/src/redhat/SOURCES:

http://java.sun.com/products/javamail/downloads/index.html and download javamail-1_3_3-ea-upd.zip.
http://java.sun.com/products/javabeans/glasgow/jaf.html and download jaf-1_0_2-upd2.zip.
http://java.sun.com/products/jta/ and download the class files and javadocs.

Create packages for the Sun software
cd /usr/src/redhat/SPECS
vi java-1.4.2-sun.spec -- change buildver to 08 rpmbuild -ba java-1.4.2-sun.spec
rpm -Uvh /usr/src/redhat/RPMS/i586/java-1.4.2-sun-1.4.2.08-1jpp.i586.rpm
rpm -Uvh /usr/src/redhat/RPMS/i586/java-1.4.2-sun-devel-1.4.2.08-1jpp.i586.rpm
vi /usr/src/redhat/SPECS/javamail.spec -- remove the line Obsoletes: javamail-monolithic
   -- change 1_3_2 to 1_3_3-ea
   -- change 1.3.2 to 1.3.3ea
rpmbuild -ba javamail.spec
vi /usr/src/redhat/SPECS/jaf.spec -- change 1_0_2-upd to 1_0_2-upd2 rpmbuild -ba jaf.spec
rpmbuild -ba jta.spec
cd /usr/src/redhat/RPMS/noarch
rpm -Uvh jaf-1.0.2-4jpp.noarch.rpm javamail-1.3.3ea-1jpp.noarch.rpm javamail-monolithic-1.3.3ea-1jpp.noarch.rpm jta-1.0.1-0.b.3jpp.noarch.rpm
Ant
RedHat 9
apt-get install ant
Ant
Fedora Core 1
apt-get install ant
Ant
Fedora Core 2
wget http://mirrors.sunsite.dk/jpackage/1.5/generic/free/RPMS/ant-1.5.4-2jpp.noarch.rpm
wget http://mirrors.sunsite.dk/jpackage/1.5/generic/free/RPMS/ant-optional-full-1.5.4-2jpp.noarch.rpm
rpm -Uvh ant-1.5.4-2jpp.noarch.rpm ant-optional-full-1.5.4-2jpp.noarch.rpm
Jakarta Tomcat 5
RedHat 9
apt-get install tomcat5 tomcat5-admin-webapps
service tomcat5 start
Fedora Core 1
apt-get install tomcat5 tomcat5-admin-webapps
service tomcat5 start
Fedora Core 2
wget http://mirrors.sunsite.dk/jpackage/1.5/generic/free/RPMS/jakarta-commons-modeler-1.1-2jpp.noarch.rpm
wget http://mirrors.sunsite.dk/jpackage/1.5/generic/free/RPMS/jakarta-commons-digester-1.5-3jpp.noarch.rpm wget http://mirrors.sunsite.dk/jpackage/1.5/generic/free/RPMS/mx4j-1.1.1-5jpp.noarch.rpm
rpm -Uvh mx4j-1.1.1-5jpp.noarch.rpm
apt-get install jakarta-commons-*
ln -s /usr/share/java/jakarta-commons-beanutils-1.6.1.jar /usr/share/java/commons-beanutils.jar
ln -s /usr/share/java/jakarta-commons-collections-2.1.1.jar /usr/share/java/commons-collections.jar
ln -s /usr/share/java/jakarta-commons-digester-1.5.jar /usr/share/java/commons-digester.jar

# The following apt-get should end without warning!
apt-get install tomcat5
service tomcat5 start

This installation will trigger a lot of other packages; just install them.

And check it works in your favorite web Browser: the URL is http://myhost:8080 or http://myhost:8080/manager.

Configure Postgres

First, start postgres:

service postgresql start

Edit the file /var/lib/pgsql/data/postgresql.conf and make sure there is a line with:

tcpip_socket = true

Edit the file /var/lib/pgsql/data/pg_hba.conf and make sure the following is in there:

local   all         all                                             trust
host    all         all         127.0.0.1         255.255.255.255   trust

Edit the file /var/lib/pgsql/data/pg_hba.conf, and make sure the end of the file looks like (note the #-signs):

# "local" is for Unix domain socket connections only
local   all         all                               ident sameuser
# IPv4 local connections:
#host    all         all         127.0.0.1/32          ident sameuser
# IPv6 local connections:
#host    all         all         ::1/128               ident sameuser
local   all         all                               trust
host    all         all         127.0.0.1/32          trust

Now restart postgres:

service postgresql restart
Users and groups

We need a few users and groups on Unix and Postgres to make the installation go without an error message.

useradd ox
su - postgres
createuser -A -D -P openxchange # asks a password, use xxx
createdb openxchange
exit
Installation

Go to http://mirror.open-xchange.org/ox/EN/community/download.htm and download open-xchange-0.8.0-5.tar.bz2
Make sure you set $OX_INSTALL to a sensible value, e.g. /usr/local/ox.

cd /usr/src/
tar xjvf /path/to/open-xchange-0.8.0-5.tar.bz2
cd /usr/src/open-xchange-0.8.0-5
export OX_INSTALL=/usr/local/ox
# On RedHat-9
./configure \
--prefix=$OX_INSTALL \
--with-mailjar=/usr/share/java/javamail.jar \
--with-activationjar=/usr/share/java/activation.jar \
--with-jdomjar=/usr/share/java/jdom.jar \
--with-xercesjar=/usr/share/java/xerces-j2.jar \
--with-jsdkjar=/usr/share/java/servletapi5.jar \
--with-jdbcjar=/usr/share/pgsql/pg73jdbc3.jar \
--enable-webdav \
--with-htdocsdir=/var/www/html \
--with-cgibindir=/var/www/cgi-bin \
--with-dbname=openxchange \
--with-dbuser=openxchange \
--with-dbpass=xxx \
--with-dbhost=localhost \
--with-runuid=ox \
--with-rungid=ox

# I added the following lines to the configure command for my own domainname:
--with-domain=sietse.net \
--with-organization="Home of Vogons" \
--with-basedn="dc=sietse,dc=net" \
--with-rootdn="cn=admin,dc=sietse,dc=net" \

# On Fedora Core 1
./configure \
--prefix=$OX_INSTALL \
--with-mailjar=/usr/share/java/javamail.jar \
--with-activationjar=/usr/share/java/activation.jar \
--with-jdomjar=/usr/share/java/jdom.jar \
--with-xercesjar=/usr/share/java/xerces-j2.jar \
--with-jsdkjar=/usr/share/java/servletapi5.jar \
--with-jdbcjar=/usr/share/java/postgresql.jar \
--enable-webdav \
--with-htdocsdir=/var/www/html \
--with-cgibindir=/var/www/cgi-bin \
--with-dbname=openxchange \
--with-dbuser=openxchange \
--with-dbpass=xxx \
--with-dbhost=localhost \
--with-runuid=ox \
--with-rungid=ox

# I added the following lines to the configure command for my own domainname:
--with-domain=sietse.net \
--with-organization="Home of Vogons" \
--with-basedn="dc=sietse,dc=net" \
--with-rootdn="cn=admin,dc=sietse,dc=net" \

# On Fedora Core 2
./configure \
--prefix=$OX_INSTALL \
--with-mailjar=/usr/share/java/javamail.jar \
--with-activationjar=/usr/share/java/activation.jar \
--with-jdomjar=/usr/share/java/jdom.jar \
--with-xercesjar=/usr/share/java/xerces-j2.jar \
--with-jsdkjar=/usr/share/java/servletapi5.jar \
--with-jdbcjar=/usr/share/java/pg74.215.jdbc3.jar \
--enable-webdav \
--with-htdocsdir=/var/www/html \
--with-cgibindir=/var/www/cgi-bin \
--with-dbname=openxchange \
--with-dbuser=openxchange \
--with-dbpass=xxx \
--with-dbhost=localhost \
--with-runuid=ox \
--with-rungid=ox

# I added the following lines to the configure command for my own domainname:
--with-domain=sietse.net \
--with-organization="Home of Vogons" \
--with-basedn="dc=sietse,dc=net" \
--with-rootdn="cn=admin,dc=sietse,dc=net" \

# On Fedora Core 3/4
./configure \
--prefix=$OX_INSTALL \
--with-mailjar=/usr/share/java/javamail.jar \
--with-activationjar=/usr/share/java/activation.jar \
--with-jdomjar=/usr/share/java/jdom.jar \
--with-xercesjar=/usr/share/java/xerces-j2.jar \
--with-jsdkjar=/usr/share/java/servletapi5.jar \
--with-jdbcjar=/usr/share/java/pg74.215.jdbc3.jar \
--enable-webdav \
--with-htdocsdir=/var/www/html \
--with-cgibindir=/var/www/cgi-bin \
--with-dbname=openxchange \
--with-dbuser=openxchange \
--with-dbpass=xxx \
--with-dbhost=localhost \
--with-runuid=ox \
--with-rungid=ox

# I added the following lines to the configure command for my own domainname:
--with-domain=sietse.net \
--with-organization="Home of Vogons" \
--with-basedn="dc=sietse,dc=net" \
--with-rootdn="cn=admin,dc=sietse,dc=net" \

make
make install

You can safely ignore the error message on 'missing' when running configure.

Post-installation
Login.pl

Try to enter the login screen, the URL is http://myhost/cgi-bin/login.pl

If you have an "Internal server error", check your apache logfiles and perl config.

Servlets

Copy intranet.class and webmail.class in the tomcat webapps tree :

cd /var/lib/tomcat5/webapps
mkdir servlet
mkdir servlet/WEB-INF
mkdir servlet/WEB-INF/classes
mkdir servlet/WEB-INF/lib
cd servlet/WEB-INF/
cp $OX_INSTALL/share/servlets/*.class classes/
cp $OX_INSTALL/lib/* lib/
mv lib/uadmin .
chown -R tomcat4:tomcat4 /var/lib/tomcat5

Now we need the file web.xml in /var/lib/tomcat5/webapps/servlet/WEB-INF. Here's mine: web.xml
Then, restart Tomcat.

cd /var/lib/tomcat5/webapps/servlet/WEB-INF
wget http://sietse.net/exoops/modules/OpenXchange/web.xml
service tomcat5 restart

Now, go to the URL http://myhost:8080/servlet/intranet. You should see a message "No running Server found" : it means that all is OK.

Otherwise, try to have a look at the Manager: http://myhost:8080/manager/html

To be able to pass the login prompt, you have to edit the file /etc/tomcat5/tomcat-users.xml and add a line like this:

<user username="themanager" password="thepassword" roles="manager"/>
Mod_jk

You must now explain to Apache that he has to work with Tomcat.

cp /usr/share/doc/mod_jk-ap20-1.2.8/workers.properties.sample /etc/httpd/conf/workers.properties
cp /usr/share/doc/mod_jk-ap20-1.2.8/mod_jk.conf.sample /etc/httpd/conf.d/mod_jk.conf
echo "JkMount /servlet/* ajp13" >> /etc/httpd/conf.d/mod_jk.conf
echo "JkMount /umin/* ajp13" >> /etc/httpd/conf.d/mod_jk.conf
cp /usr/share/doc/mod_jk-1.2.6/workers.properties.sample /etc/httpd/conf/workers.properties
cp /usr/share/doc/mod_jk-1.2.6/mod_jk.conf.sample /etc/httpd/conf.d/mod_jk.conf
echo "JkMount /servlet/* ajp13" >> /etc/httpd/conf.d/mod_jk.conf
echo "JkMount /umin/* ajp13" >> /etc/httpd/conf.d/mod_jk.conf
cp /usr/share/doc/mod_jk-ap20-1.2.5/workers.properties.sample /etc/httpd/conf/workers.properties
cp /usr/share/doc/mod_jk-ap20-1.2.5/mod_jk.conf.sample /etc/httpd/conf.d/mod_jk.conf
echo "JkMount /servlet/* ajp13" >> /etc/httpd/conf.d/mod_jk.conf
echo "JkMount /umin/* ajp13" >> /etc/httpd/conf.d/mod_jk.conf

Then restart Apache :

service httpd restart

You should now be able to go to the URL http://myhost/servlet/intranet and obtain again "No running server found"

Postgresql

It is time to populate the database :

psql -dopenxchange -h localhost -Uopenxchange -W -f $OX_INSTALL/share/init_database.sql
psql -dopenxchange -h localhost -Uopenxchange -W
INSERT INTO sys_gen_rights_template values
('now','admin','now','','default_template','y','y','y','y',
'y','y','y','y','y','y','y','y','y','y','y','y','y','y','y',
'y','y','y','y','y','y','y','y','y','y','y','y','y','y','y',
'y','y','y','y','y','y','y','y','y','y','y','y','y');
\q
LDAP

Edit your /etc/openldap/slapd.conf and from line 81 (RH9) or line 101 (FC1) or 68 (FC2/3) on make it look like:

database        ldbm
#suffix         "dc=my-domain,dc=com"
#rootdn         "cn=Manager,dc=my-domain,dc=com"
# Cleartext passwords, especially for the rootdn, should
# be avoided.  See slappasswd(8) and slapd.conf(5) for details.
# Use of strong authentication encouraged.
# rootpw                secret
# rootpw                {crypt}ijFYNcSNctBYg

# The database directory MUST exist prior to running slapd AND
# should only be accessible by the slapd and slap tools.
# Mode 700 recommended.
directory       /var/lib/ldap

# Indices to maintain for this database
#index objectClass                       eq,pres
#index ou,cn,mail,surname,givenname      eq,pres,sub
#index uidNumber,gidNumber,loginShell    eq,pres
#index uid,memberUid                     eq,pres,sub
#index nisMapName,nisMapEntry            eq,pres,sub

# Replicas of this database
#replogfile /var/lib/ldap/openldap-master-replog
#replica host=ldap-1.example.com:389 tls=yes
#     bindmethod=sasl saslmech=GSSAPI
#     authcId=host/ldap-master.example.com@EXAMPLE.COM

include         $OX_INSTALL/share/openxchange.schema

suffix "dc=example,dc=org"
rootdn "cn=Manager,dc=example,dc=org"
rootpw secret

index uid,mailEnabled,cn,sn,givenname,lnetMailAccess,alias,loginDestination eq,sub

Verify your path to openxchange.schema - you cannot use the varialbe $OX_INSTALL there!
Also, if you changed the basedn and rootdn during the configure step of OpenXchange, you must change suffix and rootdn here also.

Now create a password as stated in the INSTALL file :

perl -e 'print crypt("mypassword",pack("C2",(int(rand 26)+65),(int(rand 26)+65)))."\n";'
CGPbeX4Qyrui2

Edit $OX_INSTALL/share/init_ldap.ldif and modify the line ...

userPassword: secret

... to the result of the perl command. In my example it is:

userPassword: {CRYPT}CGPbeX4Qyrui2

Now insert the LDAP data :

service ldap stop
rm -rf /var/lib/ldap/*
slapadd -l $OX_INSTALL/share/init_ldap.ldif
chown -R ldap:ldap /var/lib/ldap
service ldap start

If you have an error, check your config and try again until it works ... If you need to reset the LDAP database, here's the solution :

Now modify your /etc/openldap/ldap.conf like this :

BASE dc=example,dc=org
HOST localhost

Again, if you don't want to spend another hour checking a stupid bug, don't put any space after the comma in dc=example,dc=org !!!
If you changed basedn during the configure of OpenXchange, you have to change BASE here also.

Create symbolic links like this :

ln -s /etc/openldap/ldap.conf $OX_INSTALL/etc/groupware/ldap.conf
ln -s /etc/openldap/ldap.conf $OX_INSTALL/etc/webmail/ldap.conf
Create a user

First, fix a bug in $OX_INSTALL/sbin/addusersql_ox: change /bin/java in /usr/bin/java.
Then, try your PostgreSQL / LDAP config by adding a user :

$OX_INSTALL/sbin/adduser_ox \
--username="john" \
--passwd="password" \
--name="doe" \
--sname="john" \
--maildomain="example.org" \
--ox_timezone="Europe/Amsterdam"

Check carefully the feedback of the command. Even if you have a green "OK" message, you can have an error message ... If this is the case, don't go further until it is corrected !

If we still follow the INSTALL file, we now add a openxchange group:

$OX_INSTALL/sbin/addgroup_ox --group=developers
WebDav

Perform the following steps to install webdav. It seems to work, but I have not tested it very well.

service tomcat5 stop cd /var/lib/tomcat5/webapps/servlet/WEB-INF/classes
cp $OX_INSTALL/lib/webdav.jar .
jar xvf webdav.jar
cd ../lib
ln -s /usr/share/java/jdom.jar .
ln -s /usr/share/pgsql/pg73jdbc3.jar . # for RedHat 9
ln -s /usr/share/java/postgresql.jar . # for FC 1
ln -s /usr/share/java/pg74.215.jdbc3.jar . # for FC 2/3
touch $OX_INSTALL/var/log/jserv.log
chown tomcat4:tomcat4 $OX_INSTALL/var/log/jserv.log $OX_INSTALL/var/filespool
chown -R tomcat4:tomcat4 /var/lib/tomcat5 echo "JAVA_OPTS=\" -Dopenexchange.propfile=$OX_INSTALL/etc/groupware/system.properties\"" >> /etc/tomcat5/tomcat5.conf
service tomcat5 start

Three other steps have already been done elsewhere:

Start Open Xchange

Now, all should be OK for starting. First, start the openxchange service :

$OX_INSTALL/etc/init.d/openexchange start

Then open the login page http://myhost/cgi-bin/login.pl, and login with the username and password supplied previously to the command adduser_ox :

Open-Xchange in action

To show off webdav: install Mozilla Calendaring, go to mozilla broswer, type in the url http://localhost/servlet/webdav.ical and see what happens!

Webmail

Webmail works out-of-the-box if you have an imap server on the same machine as open-xchange, and the user-id's and passwords of open-xchange and the imap server match.
In case your imap server is somewhere else, the easiest way is to globally change the mailserver for open-xchange:

$OX_INSTALL/sbin/changeuserattr_ox --username=mailadmin --attrib=imapServer --value=yourServer

Still make sure the userid's and passwords match.

Acknowledgements

My acknowledgement goes to Laurent Francoise - I stole this document from him and made it into a Fedora document. He also put me on the right track for LDAP, I would never have found out...

Revisions