Web linux-server.50webs.com

Linux Mail Server

Using m4 to Configure sendmail:

The sendmail distribution contains m4 source files that build the sendmail.cf file. Sample m4 source files probably are included with your Linux system. If your Linux distribution doesn't include the m4 source files, you can download them from ftp://ftp.sendmail.org/, where they are stored as part of the latest sendmail distribution.

This section builds a custom sendmail.cf file using the m4 source files that come with a Red Hat system. On a Red Hat system, the m4 source files are in an RPM package separate from the package that includes the sendmail program. If your Red Hat system does not have the m4 source files, you need to install the RPM package. The figure below shows a gnorpm query for the sendmail-cf RPM file on our sample Red Hat system.

Contents of the sendmail-cf RPM

The sample configuration files are contained in the /usr/share/sendmail-cf/cf directory on our Red Hat system. Several of these are generic files preconfigured for different operating systems. The directory contains generic configurations for BSD, Solaris, SunOS, HP Unix, Ultrix, and (of course) Red Hat Linux. The Red Hat configuration is named redhat.mc. The directory also contains prototype files designed for use with any operating system. Despite the fact that there is a Red Hat source file, this book modifies the tcpproto.mc file. The tcpproto.mc file is a prototype configuration for any system on a TCP/IP network. It is not specific to Red Hat. It comes as part of the basic sendmail distribution, and can be modified for any operating system. It is a clean, vendor-neutral starting point for explaining m4 configuration. In reality, you will probably use the configuration provided by your vendor and will not build a configuration from scratch. However, it is good to know how to build a configuration from scratch if you ever need to, and the skills used to build a configuration are the same ones you will use to customize a vendor-provided configuration.

.