%general-entities; ]> $LastChangedBy$ $Date$ Sendmail-&sendmail-version; Sendmail Introduction to <application>Sendmail</application> The Sendmail package contains a Mail Transport Agent (MTA). Package information Download (HTTP): Download (FTP): Download size: &sendmail-size; Estimated disk space required: &sendmail-buildsize; Estimated build time: &sendmail-time; <application>Sendmail</application> dependencies Required and Optional , , , , , nph, and or (for creating PDF documentation) Installation of <application>Sendmail</application> Before building Sendmail, create the users, groups and directories that Sendmail requires with the following commands: groupadd smmsp && groupadd mail && useradd -c "Sendmail Daemon" -g smmsp -G mail smmsp && chmod 1777 /var/mail && mkdir /var/spool/mqueue Install Sendmail with the following commands: cat > devtools/Site/site.config.m4 << "EOF" define(`confMANGRP',`root') define(`confMANOWN',`root') define(`confSBINGRP',`root') define(`confUBINGRP',`root') define(`confUBINOWN',`root') EOF cd sendmail && sh Build && cd ../cf/cf && cp generic-linux.mc sendmail.mc && mkdir /etc/mail && sh Build sendmail.cf && sh Build install-cf && cd ../../ && sh Build install && cp -R cf/* /etc/mail && cp cf/cf/{submit,sendmail}.mc /etc/mail && for manpage in sendmail editmap mailstats makemap praliases smrsh do install -m444 $manpage/$manpage.8 /usr/share/man/man8 done && install -m444 sendmail/aliases.5 /usr/share/man/man5 && install -m444 sendmail/mailq.1 /usr/share/man/man1 && install -m444 sendmail/newaliases.1 /usr/share/man/man1 && install -m444 vacation/vacation.1 /usr/share/man/man1 Note: See the source tree sendmail/README file for information on linking optional packages into the build. Install the Sendmail Installation and Operations Guide with the following commands: cd doc/op && sed -i -e 's/groff/GROFF_NO_SGR=1 groff/' Makefile && make op.txt op.pdf && install -d -m 755 /usr/share/doc/sendmail-&sendmail-version; && install -m 644 op.ps op.txt op.pdf /usr/share/doc/sendmail-&sendmail-version; && cd ../../ Note: remove op.pdf from the make and install commands if you don't have Ghostscript installed. Command explanations cat > devtools/Site/site.config.m4 << "EOF": This creates a configuration file changing some of the default settings. sh Build; sh Build sendmail.cf; sh Build install-cf; sh Build install: Sendmail uses an m4 based build script to create the various Makefile's. These commands build and install the package. for manpage in...;do...;done; install ...: The man pages are installed already formatted and man displays them somewhat garbled. These commands replace the formatted pages with pages man can display properly. Configuring <application>Sendmail</application> Config files /etc/mail/* /etc/mail/* Configuration information Create the /etc/mail/local-host-names and /etc/mail/aliases files using the following commands: echo $(hostname) > /etc/mail/local-host-names cat > /etc/mail/aliases << "EOF" postmaster: root MAILER-DAEMON: root EOF newaliases -v Sendmail's primary configuration file, /etc/mail/sendmail.cf, is complex and not meant to be directly edited. The recommended method to make changes is to modify /etc/mail/sendmail.mc, and various m4 files, then run the m4 macro processor from within /etc/mail as follows: m4 m4/cf.m4 sendmail.mc > sendmail.cf A full explanation of the files to modify, and the available parameters can be found in /etc/mail/README. To automate the running of Sendmail at startup, install the /etc/rc.d/init.d/sendmail init script included in the package. sendmail make install-sendmail The -qNm option to sendmail, where N is number of minutes, controls how often Sendmail will process the mail queue. A default of 5 minutes is used in the init script. Individual workstation users may want to set this as low as 1 minute, large installations handling more mail may want to set it higher. Contents Installed Programs Installed Directory editmap, hoststat, mailstats, mailq, makemap, newaliases, praliases, purgestat, sendmail, smrsh and vacation /etc/mail and /usr/share/doc/sendmail-&sendmail-version; Short Descriptions editmap queries and edits Sendmail map files. editmap hoststat prints Sendmail's persistent host status. hoststat mailstats displays Sendmail statistics. mailstats mailq prints a summary of outbound mail messages waiting for delivery. mailq makemap creates Sendmail map files. makemap newaliases rebuilds /etc/mail/aliases.db from the contents of /etc/mail/aliases. newaliases praliases displays current Sendmail aliases. praliases purgestat causes Sendmail to clear (purge) all its host-status information. purgestat sendmail is the Sendmail mail transport agent. sendmail smrsh is a restricted shell for Sendmail. smrsh vacation is an email auto responder. vacation