source: server/mail/sendmail/sendmail-config.xml@ b9e96a3

10.0 10.1 11.0 6.0 6.1 6.2 6.2.0 6.2.0-rc1 6.2.0-rc2 6.3 6.3-rc1 6.3-rc2 6.3-rc3 7.10 7.4 7.5 7.6 7.6-blfs 7.6-systemd 7.7 7.8 7.9 8.0 8.1 8.2 8.3 8.4 9.0 9.1 basic bdubbs/svn elogind gnome kde5-13430 kde5-14269 kde5-14686 ken/refactor-virt krejzi/svn lazarus nosym perl-modules qt5new systemd-11177 systemd-13485 trunk v1_0 v5_0 v5_0-pre1 v5_1 v5_1-pre1 xry111/git-date xry111/git-date-for-trunk xry111/git-date-test
Last change on this file since b9e96a3 was b9e96a3, checked in by Billy O 'Connor <billyoc@…>, 19 years ago

Add explanation of -q flag and change default to 5 minutes.
Change to newaliases -v to process alias file.

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@592 af4574ff-66df-0310-9fd7-8a98e5e911e0

  • Property mode set to 100644
File size: 2.5 KB
Line 
1<sect2>
2<title>Configuring sendmail</title>
3
4<sect3><title>Config files</title>
5<para><userinput>/etc/mail/aliases.db, /etc/mail/sendmail.cf,
6/etc/mail/submit.cf</userinput> and
7<userinput>/etc/mail/local-host-names</userinput></para>
8</sect3>
9
10<sect3><title>Configuring sendmail</title>
11<para><screen><userinput>
12echo `hostname` > /etc/mail/local-host-names
13cat &gt; /etc/mail/aliases &lt;&lt; "EOF"
14postmaster: root
15MAILER-DAEMON: root
16EOF
17cd /etc/mail &amp;&amp;
18cp -R /usr/src/sendmail-&sendmail-version;/cf/* . &amp;&amp;
19cp -R /usr/src/sendmail-&sendmail-version;/cf/cf/submit.mc . &amp;&amp;
20cp -R /usr/src/sendmail-&sendmail-version;/cf/cf/sendmail.mc . &amp;&amp;
21newaliases -v &amp;&amp;
22</userinput></screen></para>
23
24<para>To start and stop sendmail on system boot/shutdown create the
25sendmail boot script with the following commands: </para>
26
27<note><para>The -qNm option, where N is number of minutes, controls
28how often Sendmail will process the mail queue.&nbsp;&nbsp;A default of 5
29minutes is used here.&nbsp;&nbsp;Individual workstation users may want to set
30this as low as 1 minute, large installations handling more mail will
31want to set it higher.</para></note>
32
33<para><screen><userinput>cat &gt; /etc/rc.d/init.d/sendmail &lt;&lt; "EOF"</userinput>
34#!/bin/sh
35# Begin $rc_base/init.d/sendmail
36
37# Based on sysklogd script from LFS-3.1 and earlier.
38# Rewritten by Gerard Beekmans - gerard@linuxfromscratch.org
39
40source /etc/sysconfig/rc
41source $rc_functions
42
43case "$1" in
44
45 start)
46 echo "Starting sendmail..."
47 loadproc /usr/sbin/sendmail -bs -bd -q5m start
48 ;;
49
50 stop)
51 echo "Stopping Sendmail..."
52 killproc sendmail
53 ;;
54
55 status)
56 statusproc sendmail
57 ;;
58
59 restart)
60 $0 stop
61 sleep 1
62 $0 start
63 ;;
64
65 *)
66 echo "Usage: $0 {start|stop|status|restart}"
67 exit 1
68 ;;
69esac
70
71# End $rc_base/init.d/sendmail
72<userinput>EOF
73chmod 755 /etc/rc.d/init.d/sendmail</userinput></screen></para>
74
75<para>Create the run level symlinks with the following commands:
76
77<screen><userinput>cd /etc/rc.d/init.d &amp;&amp;
78ln -sf ../init.d/sendmail ../rc0.d/K25sendmail &amp;&amp;
79ln -sf ../init.d/sendmail ../rc1.d/K25sendmail &amp;&amp;
80ln -sf ../init.d/sendmail ../rc2.d/K25sendmail &amp;&amp;
81ln -sf ../init.d/sendmail ../rc3.d/S35sendmail &amp;&amp;
82ln -sf ../init.d/sendmail ../rc4.d/S35sendmail &amp;&amp;
83ln -sf ../init.d/sendmail ../rc5.d/S35sendmail &amp;&amp;
84ln -sf ../init.d/sendmail ../rc6.d/K25sendmail</userinput></screen></para>
85</sect3>
86
87</sect2>
Note: See TracBrowser for help on using the repository browser.