phpGroupWare Administration Manual
Prev | Chapter 2. Installation | Next

# 2.3. Obtaining and Installing phpgroupware

## 2.3.1. Installing from TarBall

Installing from a TarBall is very easy. The files should be installed in the webserver directory. Example steps (please adjust to your servers config):

> `# cp phpgroupware-version.tar.gz /home/httpd/html`
> `# cd /home/httpd/html`
> `# tar zxf phpgroupware-version.tar.gz`

You may have to get required permissions to do this. Contact your system administrator if you dont have the permission to write to your webserver directory.

You can get current releases of phpGroupWare at the phpGroupware website.

## 2.3.2. Installing from CVS

Installing from a CVS is fairly easy. The files should be checked out in the webserver directory. You may have to get required permissions to install from CVS. Contact your system administrator if you dont have the permission to write to your webserver directory.

### 2.3.2.1. Development Branch in CVS

Follow these steps (please adjust to your servers config):

> `# cd /home/httpd/html`
> `# cvs -z3 -d:pserver:anonymous@subversions.gnu.org:/cvsroot/phpgroupware co phpgroupware`
> `# cd phpgroupware`
> `# cvs co admin addressbook calendar email phpgwapi preferences setup todo notes infolog`

or if you prefer using CVSROOT:

> `# export CVSROOT=':pserver:anonymous@subversions.gnu.org:/cvsroot/phpgroupware'`
> `# cvs co phpgroupware`
> `# cd phpgroupware`
> `# cvs co admin addressbook calendar email phpgwapi preferences setup todo notes infolog`

### 2.3.2.2. Stable Branch in CVS

Follow these steps (please adjust to your servers config and the up-to-date stable Version - 0.9.14 at the moment):

> `# cd /home/httpd/html`
> `# cvs -z3 -d:pserver:anonymous@subversions.gnu.org:/cvsroot/phpgroupware co -r Version-0_9_14-branch phpgroupware`
> `# cd phpgroupware`
> `# cvs co -r Version-0_9_14-branch admin addressbook calendar email phpgwapi preferences setup todo notes infolog`

or if you prefer using CVSROOT:

> `# export CVSROOT=':pserver:anonymous@subversions.gnu.org:/cvsroot/phpgroupware'`
> `# cvs co -r Version-0_9_14-branch phpgroupware`
> `# cd phpgroupware`
> `# cvs co -r Version-0_9_14-branch admin addressbook calendar email phpgwapi preferences setup todo notes infolog`

## 2.3.3. Setting File Permissions

There are a few directories which will need special fie permissions set for phpGroupWare to work properly.

Temp Directory (Required) - This can be /tmp for simplicity, but it is required for several apps to function properly. Simply make sure that the webserver can add/delete files in it.

Files Directory (Required) - This can be should be the files dir under the phpgroupware dir. You will need to give the webserver account owndership of this directory.

> (from phpgroupware root)
> `# mkdir files`
> `# mkdir files/groups`
> `# mkdir files/users`
> `# chown nobody:nobody files` (note: this assumes your webserver runs as user nobody, adjust for your installation)
> `# chmod 700 files`

Root Directory (Not recommended) - If you give the webserver account write access to the phpgroupware directory, then the setup program can create the header.inc.php for you. Otherwise you will need to use the setup program to create it, and then you can manually save it to file.

If you want to do it:

> `# chown :nobody phpgroupware`
> `# chmod 770 phpgroupware`

You may have to get required permissions to do this. Contact your system administrator if you dont have the permission to write to your webserver directory.

## 2.3.4. Setup the database

You need to create empty databases for the setup app to create the tables in.

### 2.3.4.1. MySQL

Ensure that you have a working MySQL installation and that MySQL is running.

> Mandrake or Redhat:
> `/etc/rc.d/init.d/mysqld start`
> other:
> `/usr/local/mysql/bin/safe_mysqld &`

Create the phpgroupware Database and give permissions to the phpgroupware user

> `# mysqladmin -u someuser -p create phpgroupware` (enter password when prompted)
> `# mysql -u someuser -p`
> `mysql> grant all on phpgroupware.* to phpgroupware@localhost identified by "somepassword";`

For more detailed user documentation on MySQL see their website: [http://www.mysql.com]

### 2.3.4.2. PostgreSQL

Ensure that you have a working PostgreSQL installation and that PostgreSQL is running.

> Mandrake or Redhat :
> `/etc/rc.d/init.d/postgresql start`
> Others:
> `/usr/bin/postmaster -D /var/lib/pgsql/data or /usr/bin/pg_ctl -D /var/lib/pgsq/data start` (adjust for your install dirs)

Create the phpgroupware database and user

> `# /usr/bin/createdb phpgroupware`
> `# /usr/bin/createuser phpgroupware --pwprompt`

For more detailed user documentation on Postgresql see their website: [http://www.postgresql.org]

## 2.3.5. Setup/Configure phpGroupWare

### 2.3.5.1. configure header file

Point your browser to http://yourserverroot/phpgroupware/setup/ which will create (or upgrade) the header.inc.php and database tables. Setup will attempt to determine what version of the phpGroupWare databases and header.inc.php you have installed, and upgrade to the most recent version.

Most values for the header setup can be left as the default, be sure to enter a password for header admin, and change the password for your DB, and for configuration.

*addme* What is mcrypt for?

*addme* Explain what the Domain select box is for

Once you have finished your configuration, you can have phpGroupWare write it directly if you changed permissions on the directory, or you can download or view it with your browser, and save it in the directory yourself.

### 2.3.5.2. Site Configuration

After header configuration, you will be prompted to enter your Setup/Config Login, or your Header login if you want to go back and change something.

| You are advised to backup your existing database before running the setup script to avoid problems!

| You have to press the button, not hit enter on the setup/index.php script

Your first step is to install all application databases, simply click on the Install to have phpGroupWare add all the necessary tables.

Next, click on Edit Current Configuration. You will be prompted with a list of configuration options.

Table 2-1. Edit Current Configuration

Prompt | Notes
--- | ---
full path for temporary files | usually /tmp
full path for user and group files | directory must exist and have user and group directories underneath it.
location of phpGroupWare URL | full domain name or just relative link, no trailing slash
hostname of machine | Fully qualified hostname
default ftp server | *addme* what is this for?
use correct mimetype for FTP | *addme* what might this affect?
HTTP proxy server |
HTTP proxy port |
Which type of Authentication | [a]
Where to store user accounts | [b]
Minimum account ID |
Maximum account ID |
manage homedirectory and loginshell attributes | *addme* what is this?
LDAP home directory prefix |
LDAP default shell |
Auto create account records? | *addme* what is this?
if no ACL records... |
LDAP host |
LDAP accounts context |
LDAP root dn |
LDAP root password |
LDAP encryption type |
app_session encryption | *addme* what is this?
title for your site |
Show powered by logo on |
Country Selection |
use pure HTML |
Use cookies |
check for new version? | *addme* what does this check, stable version or CVS?
cache the phpgw_info array | *addme* what effect does this have on speed, what tradeoffs?
Notes: SQL use SQL table (default) SQL/SSL use encrypted SQL access LDAP use LDAP server mail use mail server (IMAP/POP3) HTTP use HTTP authentication (.htaccess) PAM use PAM authentication (note currently working) SQL store in SQL table LDAP store in LDAP server Contacts *addme* what is this?

Next, select click here to add admin account and optionally, three demo accounts. Fill in the fields on the next screen and uncheck the box at the bottom if you don't want the demo accounts created. Click on Submit when finished.

Click Install Languages to add at least one language to the system. On the next screen, select all the languages you want by single clicking them, then click on Install.

There shouldn't be anything to do under Manage Applications at this time, this is where you will return after an upgrade to update and table differences.

after your done, click on logout to complete the install and end the session.

## 2.3.6. Testing the install

If your config is setup properly you can now login. Point your browser to the installed location and login with the new admin username and password you created.

## 2.3.7. Installing additional applications

Once you have the core phpGroupWare install up and running, you may want to download and install additional applications.

You should consult any README or INSTALL files that come with the new application first, as most require you to create additional tables in the database, and add additional translation data to the lang table (typically a file called lang.sql)

You install the new application within the phpGroupWare install tree by copying the application directory into the phpGroupWare install location, and enabling the application through the Administration page.

Download the .tar.gz file for the application, or check out the source with cvs with

> `# export CVSROOT=':pserver:anonymous@subversions.gnu.org:/cvsroot/phpgwapps'`
> `# cvs login` (just hit enter if prompted for a password)
> `# cvs co headlines`

Move the headlines directory into your phpGroupWare install directory.

Log into phpGroupWare as an administrative user, and go to the Administration page.

In the first section, choose the Applications link.

Click on add, and fill in the form.

Application name should be identical to the name of the directory you moved into the phpGroupWare install, in this case use headlines

Application title is shown in the navigation bar and other places to refer to the new application. Enter Headlines for this example.

Enabled can be used to disable an application for all users temporially. You should normal check the box to enable the application.

Back in the Administration page, you need to enable the application for specific users or user groups by editing them, and checking the new Headlines box that appears in the middle of the account editing page.

Once you have added the Headlines app to your account, you should see a Headlines entry in the Administration and Preferences pages, and there should be an icon for the Headlines application in the navigation bar.

Once you enable a few of the Headlines sites through the Administration page link, you should see headlines grabbed from the sites you selected when you click on the Headlines icon in the navigation bar.

Prev | Home | Next
Tested Systems | Up | Troubleshooting