next up previous contents index
Next: 4. sympa.conf parameters Up: Sympa Mailing Lists Management Software Previous: 2. what does Sympa consist of   Contents   Index

Subsections

3. Installing Sympa

Sympa is a program written in PERL. It also calls a short program written in C for tasks which it would be unreasonable to perform via an interpreted language.

3.1 Obtaining Sympa, related links

The Sympa distribution is available from http://listes.cru.fr/sympa/. All important resources are referenced there:

3.2 Prerequisites

Sympa installation and configuration are relatively easy tasks for experienced UNIX users who have already installed PERL packages.

Note that most of the installation time will involve putting in place the prerequisites, if they are not already on the system. No more than a handful of ancillary tools are needed, and on recent UNIX systems their installation is normally very straightforward. We strongly advise you to perform installation steps and checks in the order listed below; these steps will be explained in detail in later sections.

3.2.1 System requirements

You should have a UNIX system that is more or less recent in order to be able to use Sympa. In particular, it is necessary that your system have an ANSI C compiler (in other words, your compiler should support prototypes), as well as XPG4-standard NLS (Native Language Support, for languages other than English) extensions.

Sympa has been installed and tested on the following systems, therefore you should not have any special problems:

Anyone willing to port it to NT ? ;-)

If your UNIX system has a gencat command as well as catgets(3) and catopen(3) functions, it is likely that it has NLS extensions and that these extensions comply with the XPG4 specifications.

Finally, most UNIX systems are now supplied with an ANSI C compiler; if this is not the case, you can install the gcc compiler, which you will find on the nearest GNU site, for example in France.

To complete the installation, you should make sure that you have a sufficiently recent release of the sendmail MTA, i.e. release 8.9.x or a more recent release. You may also use postfix or qmail.

3.2.2 Install Berkeley DB (NEWDB)

UNIX systems often include a particularly unsophisticated mechanism to manage indexed files. This consists of extensions known as dbm and ndbm, which are unable to meet the needs of many more recent programs, including Sympa, which uses the DB package initially developed at the University of California in Berkeley, and which is now maintained by the company Sleepycat software. Many UNIX systems like Linux, FreeBSD or Digital UNIX 4.x have the DB package in the standard version. If not you should install this tool if you have not already done so.

You can retrieve DB on the Sleepycat site, where you will also find clear installation instructions.

3.2.3 Install PERL and CPAN modules

To be able to use Sympa you must have release 5.004_03 or later of the PERL language, as well as several CPAN modules.

At make time, the check_perl_modules.pl script is run to check for installed versions of required PERL and CPAN modules. If a CPAN module is missing or out of date, this script will install it for you.

You can also download and install CPAN modules yourself. You will find a current release of the PERL interpreter in the nearest CPAN archive. If you do not know where to find a nearby site, use the CPAN multiplexor; it will find one for you.

3.2.4 Required CPAN modules

The following CPAN modules required by Sympa are not included in the standard PERL distribution. We try to keep this list up to date ; if you have any doubts run the check_perl_modules.pl script.

Since release 2, Sympa requires an RDBMS to work properly. It stores users' subscriptions and preferences in a database. Sympa is also able to extract user data from within an external database. These features require that you install database-related PERL libraries. This includes the generic Database interface (DBI) and a Database Driver for your RDBMS (DBD) :

If you plan to interface Sympa with an LDAP directory to build dynamical mailing lists, you need to install PERL LDAP libraries :

3.2.5 Create a UNIX user

The final step prior to installing Sympa: create a UNIX user (and if possible a group) specific to the program. Most of the installation will be carried out with this account. We suggest that you use the name sympa for both user and group. Note that UID.GID must be the same as your httpd. If you are running a dedicated httpd server, this can be sympa.sympa, otherwise it is possible either to define a virtual httpd server setting UID.GID, or to run Sympa as nobody.nobody. This second solution is not advisable because the information managed by Sympa will be owned by nobody.

Numerous files will be located in the Sympa user's login directory. Throughout the remainder of this documentation we shall refer to this login directory as ~sympa/.

3.3 Compilation and installation

Before using Sympa, you must customize the sources in order to specify a small number of parameters specific to your installation.

First, extract the sources from the archive file, for example from the ~sympa/ directory: the archive will create a directory named sympa-2.7/ where all the useful files and directories will be located. In particular, you will have a doc/ directory containing this documentation in various formats; a sample/ directory containing a few examples of configuration files; an nls/ directory where multi-lingual messages are stored; and, of course, the src/ directory for the mail robot and wwsympa for the web interface.

Example:

# su -
$ gzip -dc sympa-2.7.tar.gz | tar xf -

Before running make in the main directory, you should edit and configure Makefile, the first part of which requires customization. We advise against changing anything located after the STOP line.

The Makefile file contains explanations for the fields, which you may have to change. They main ones are :

Since version 3.3 of Sympa colors are sympa.conf parameters (see 4.1.5, page [*])

Once this file has been configured, you need to run the make;make install commands. This generates the binary for the queue program along with the nls, and inserts the Sympa and WWSympa programs in their final slot, while having propagated a few parameters into the PERL files, such the access path to the PERL program. The make command includes the checking of CPAN modules.

If everything goes smoothly, the ~sympa/bin/ directory will contain various PERL programs as well as the queue binary. You will remark that this binary has the set-uid-on-exec bit (owner is the sympa user): this is deliberate, and indispensable if Sympa is to run correctly.

3.3.1 Choosing directory locations

All directories are defined in the /etc/sympa.conf file, which is read by Sympa at runtime. If no sympa.conf file was found during installation, a sample one will be created. For the default organization of directories, please refer to 2.1, page [*].

It would, of course, be possible to disperse files and directories to a number of different locations. However, we recommend storing all the directories and files in the sympa user's login directory.

These directories must be created manually now. You can use restrictive authorizations if you like, since only programs running with the sympa account will need to access them.


3.4 Robot aliases

An electronic list manager such as Sympa is built around two processing steps:

To separate the processing of administrative requests (subscription, unsubscription, help requests, etc.) from the processing of messages destined for mailing lists, a special mail alias is reserved for administrative requests, so that Sympa can be permanently accessible to users. The following lines must therefore be added to the sendmail alias file (often /etc/aliases):

sympa:             "| /home/sympa/bin/queue sympa"
listmaster: 	   "| /home/sympa/bin/queue listmaster"
bounce+*:          "| /home/sympa/bin/bouncequeue sympa"
sympa-request:     postmaster
sympa-owner:       postmaster

sympa-request should be the address of the robot administrator, i.e. a person who looks after Sympa (here postmaster@cru.fr).

sympa-owner is the return address for Sympa error messages.

The alias bounce+* is dedicated to collect bounces. It is useful only if at least one list uses welcome_return_path unique or remind_return_path unique. Don't forget to run newaliases after any change to the /etc/aliases file!

Note: aliases based on listserv (in addition to those based on sympa) can be added for the benefit of users accustomed to the listserv and majordomo names. For example:

listserv:          sympa
listserv-request:  sympa-request
majordomo:         sympa
listserv-owner:    sympa-owner

Note: it will also be necessary to add entries in this alias file when lists are created (see list creation section, 10.1, page [*]).

3.5 Logs

Sympa keeps a trace of each of its procedures in its log file. However, this requires configuration of the syslogd daemon. By default Sympa wil use the local1 facility (syslog parameter in sympa.conf). WWSympa's logging behaviour is defined by the log_facility parameter in wwsympa.conf (by default the same facility as Sympa).
To this end, a line must be added in the syslogd configuration file (/etc/syslog.conf). For example:

local1.*       /var/log/sympa

Then reload syslogd.

Depending on your platform, your syslog daemon may use either a UDP or a UNIX socket. Sympa's default is to use a UNIX socket; you may change this behavior by editing sympa.conf's log_socket_type parameter (4.3.2, page [*]).


3.6 sympa.pl

Once the files are configured, all that remains is to start Sympa. At startup, sympa.pl will change its UID to sympa (as defined in Makefile). To do this, add the following sequence or its equivalent in your /etc/rc.local:

~sympa/bin/sympa.pl
~sympa/bin/archived.pl
~sympa/bin/bounced.pl
~sympa/bin/task_manager.pl

sympa.pl recognizes the following command line arguments:


next up previous contents index
Next: 4. sympa.conf parameters Up: Sympa Mailing Lists Management Software Previous: 2. what does Sympa consist of   Contents   Index
root 2001-11-16