Installing eGroupWare
Last modified on:
07-18-2006 - Created.
11-18-2006 - Just HTML changes.
By: Max Hetrick
Printer friendly: http://www2.maxsworld.org/howtos/egroupware.html
I’m in the middle of evaluating calendaring software for my employer, and so far this one is my favorite one I’ve worked with. I figured I’d document the installation so I can refer to it later when I need it. It’s a little tricky to install and get setup. The documentation is fairly good at helping you along, but they forget to tell you little things, like create the database before you run the setup…these kinds of things. So I’ll do a step-by-step on CentOS and share. That should make it easy enough.
System:
Below are the packages I have installed with particular versions.
- CentOS 4.3
- PostgreSQL 7.4.13
- Apache 2.0
- PHP 4.3.9
Requirements:
- PostgreSQL 7.2+
- Apache 1.33+
- PHP 4.3+
For the cowards ;), they offer a “canned” installation called XAMPP. This contains Apache, PHP, Pear, all the good stuff you need that eGroupWare requires. For these kinds of things, I simply install the bare minimum from a CentOS 4.3 Server CD and add all the applications that I need. This keeps a new install very small, tight, and fast. A bare minimum install from CentOS Server CD is around 689Mb.
Install Prerequisites
If you don’t already have Apache, PostgreSQL, and PHP setup, then follow along. Otherwise, skip over this section. Unless otherwise stated, assume running everything from root.
1) PostgreSQL Setup
First thing to do is install Postgresql. I’m assuming very little security here, so if you require further security measures on your database, then please seek help and guidance from PostgreSQL.org.
[root@yourbox ~]# yum install postgresql postgresql-server postgresql-devel
Next, start and stop the postgresql server. This will initialize the database.
[root@yourbox ~]# service postgresql start Initializing database: [ OK ] Starting postgresql service: [ OK ] [root@yourbox ~]# service postgresql stop Stopping postgresql service: [ OK ]
Next configure postgresql to allow for TCP/IP connections.
[root@yourbox ~]# vim /var/lib/pgsql/data/postgresql.conf #tcpip_socket = false tcpip_socket = true # While I’m here, I usually change some memory options around too. #sort_mem = 1024 sort_mem = 16384 #vacuum_mem = 8192 vacuum_mem = 16384
Write and quit the configuration file. Configure the permissions for postgresql.
[root@yourbox ~]# vim /var/lib/pgsql/data/pg_hba.conf # Add the following to allow the egroupware user to connect. host egroupware egroupware 127.0.0.1/24 password
Restart the postgresql server and configure it on.
[root@yourbox ~]# service postgresql start [root@yourbox ~]# chkconfig postgresql on
2) Create eGroupWare DB and User
Let’s go ahead and create the database and password for the eGroupWare software. I’ll use generic values, but you can change them to something more useful if you’d like. Don’t forget if you choose a different user and password to change it in the file above you just configured.
[root@yourbox ~]# su - postgres
# Create the user
-bash-3.00$ createuser –no-adduser –no-createdb -P egroupware
Enter password for new user: type_your_pw
Enter it again: type_it_again
CREATE USER
# Create the database
-bash-3.00$ createdb –owner egroupware egroupware
CREATE DATABASE
# Test out the connection
-bash-3.00$ psql egroupware
Welcome to psql 7.4.13, the PostgreSQL interactive terminal.
Type: \copyright for distribution terms
\h for help with SQL commands
\? for help on internal slash commands
\g or terminate with semicolon to execute query
\q to quit
egroupware=# \q
-bash-3.00$ exit
3) Install and Configure Apache
Again, skip over if this is completed. This provides no security measures, consult Apache’s documentation if you wish to configure things more strict.
[root@yourbox ~]# yum install httpd httpd-devel [root@yourbox ~]# vim /etc/httpd/conf/httpd.conf #ServerName new.host.name:80 ServerName yourserver.yourdomain.example:80
Start and configure Apache to be on.
[root@yourbox ~]# service httpd start [root@yourbox ~]# chkconfig httpd on
4) Install Remaining Packages
Let’s install the remaining packages eGroupWare is going to need. These include mainly PHP packages. A few of these packages might not be needed, but I just install them anyways. They aren’t that big in size. For instance, the LDAP items aren’t needed if you’re not planning on using the the mailing module for eGroupWare.
[root@yourbox ~]# yum install php php-pear php-imap php-ldap php-pgsql php-gd php-devel php-mbstring
Installation/Configuration of eGroupWare:
1) Download and Unpack
They have platform independent RPMs available, but I found it easier to just install from the source package. Grab either the .zip or .tar.gz from SourceForge.net.
Next, unpack the files into your document root of Apache. You can change the name of the unzipped directory to something else if you’d like. I’m keeping it default for this.
[root@yourbox ~]# cd /var/www/html/ [root@yourbox ~]# tar -xzf /path/to/eGroupWare-1.x-xxx.tar.gz [root@yourbox ~]# chown -R apache.apache egroupware
2) Configure PHP
Before you begin the installation, let’s go ahead and configure a few things that eGroupWare is going to want from PHP.
[root@yourbox ~]# vim /etc/php.ini # Change the memory_limit to 16MB memory_limit = 16M # Change the following line for UNICODE ;mbstring.func_overload = 0 mbstring.func_overload = 7
Make sure you restart the Apache after these changes.
[root@yourbox ~]# service httpd restart
Pear needs a logging package installed as well.
[root@yourbox ~]# pear install log [snip] install ok: Log 1.9.6
3) Installing eGroupWare
eGroupWare is easily setup from a web interface. Point your browser to http://yourbox/egroupware/setup to begin. Click on Run installation tests.

It may take up to a few minutes to actually process everything that the install script needs to check, so just be patient for a few. Once it’s complete with checking, you’ll get something like the image below. If you receive any red X’s, then make sure to take care of the error message. As the image shows, the warnings are for other database programs that I’m not using so they are safe to ignore. Once you’re finished correcting errors, click Click here to re-run installation tests, otherwise click Continue to the Header Admin.

The next screen is rather self-explanatory. Basically, you can leave everything default with the exception of usernames and passwords. Make sure you change the usernames, and provide passwords for the different accounts. You you can also block access to the setup part of the program later on by either IP addresses or hostnames. That’s a nice feature to limit folks from accessing your setup. They also offer encryption options here. I haven’t experimented with it…I left it off.

On the same page, make sure you fill out the database portions correctly at the bottom. Whatever you created your database, username, and password as earlier ensure you have them filled in correctly. Also, configure a user account for allowing acess to the configuration options of eGroupWare.

Since you configured the directory to have permissions for Apache, go ahead and click the Write config button. The next screen will simply state it created the header.inc.php file. Click Continue. If everything is right, you should see a sign on screen. That’s about it for installation of the actual package. You can go ahead and sign into the Setup/Config screen, and continue on to the next section.

4) Configuring eGroupWare
Step 1 is to install the applications within eGroupWare. At this point you can choose to install all of the applications, or you can choose to install them from a backup. For example, if you were moving an installation to another machine and needed to restore from a backup. Click Install all applications. This also takes a few minutes to complete, and when it does click Re-Check My Installation.

Step 2 is to configure a files and backup directory. Click on Edit Current Configuration to enter the next screen. You’ll have to create these two paths manually.
[root@yourbox html]# mkdir -p /var/lib/egroupware/default/files [root@yourbox html]# mkdir /var/lib/egroupware/default/backup [root@yourbox html]# chown -R apache.apache /var/lib/egroupware/default/
There are many sections to this part of the configuration, but as long as you create the directories outlined above, then all of the defaults will be ok. Of interest to you might be the Mailserver and Authentication/Accounts sections. Here you can specify mailserver information, and specifics dealing with accounts and passwords, such as password length and such. When you’re finished go ahead and click Save at the bottom of the screen.
Step 3 is the last section that’s necessary for completion. Click the button Create admin account to create an administrator login account. At the same time, you can create three demo accounts if you wish by checking the Create demo accounts box. When you’re through, make sure to save.

That’s it as far as configuration is concerned. You can remove any packages or applications that you don’t want to use if you click on the Manage Applications section. Be careful about removing some packages, however, because of dependency issues. You can also configure languages and backups from this screen as well.
If you’re all done changing things, on the left-hand menu click logout. Above that you’ll see Back to user login. This takes you to the login screen. Sign in with the account you just created to start either adding users, groups, accounts and to start configuring the actual usage of the program itself.
Check the Docs
The actual usage of the program is beyond the scope of this how-to, so be sure to visit eGroupWare’s Docs for assitance with use of the application. You can do a lot of cool things with this application, so if you’re looking for a well supported open-source groupware program…now you have it installed to play with. Point your users to http://yourbox/egroupware to login.
Upgrading
1) Backup Database
The first thing to do is to make a backup of your database before you start mucking around with upgrading. You either do this via command line tools, or you can do this through the graphical utility eGroupWare provides. Command line is:
[root@yourbox ~]# su - postgres [root@yourbox ~]# pg_dump –clean –blobs –format=c egroupware > egw.pg_dump
Through the GUI, browse to http://yourmachine/egroupware/setup/ and login to the Setup/Config Admin Login section. Here browse to Step 6 and backup your database. It’s as straightforward as it comes.
2) Backup eGroupWare Web Directory/Setup New Package
Move over to Apache’s directory and backup the web items. Don’t delete this directory, because you’ll need some files out of it in a bit.
[root@yourbox ~]# service httpd stop [root@yourbox ~]# cd /var/www/html [root@yourbox html]# mv egroupware egroupware_backup [root@yourbox html]# tar -xzvf eGroupWare-1.whatever.tar.gz [root@yourbox html]# chown -R apache.apache egroupware [root@yourbox html]# cp egroupware_backup/header.inc.php egroupware/ [root@yourbox html]# service httpd start
Browse to http://yourmachine/egroupware/setup and login to the Setup/Config Admin Login screen again. Go ahead and choose the upgrade button. It’ll take a moment if you select to create a backup of the database before continuing. That’s up to you, since you already completed that step above. If you didn’t get any errors in the Status box, then you’re good to select the Re-Check My Installation.





