2002-08-27 06:23:32 +08:00
|
|
|
<sect2>
|
|
|
|
<title>Configuring exim</title>
|
|
|
|
|
|
|
|
<sect3><title>Config files</title>
|
2003-04-05 23:17:18 +08:00
|
|
|
<para><userinput>/etc/exim.conf</userinput>, <userinput>/etc/aliases</userinput></para>
|
2002-08-27 06:23:32 +08:00
|
|
|
</sect3>
|
|
|
|
|
|
|
|
<sect3><title>Configuration of exim</title>
|
|
|
|
<para>Create the exim configuration files with the following commands:
|
|
|
|
</para>
|
2003-04-06 00:32:17 +08:00
|
|
|
<para><screen><userinput>cat >> /etc/aliases << "EOF"</userinput>
|
2002-08-27 06:23:32 +08:00
|
|
|
postmaster: root
|
|
|
|
MAILER-DAEMON: root
|
2003-04-06 00:32:17 +08:00
|
|
|
<userinput>EOF
|
|
|
|
exim -v -bi &&
|
2003-02-02 00:51:51 +08:00
|
|
|
/usr/sbin/exim -bd -q1m</userinput></screen></para>
|
|
|
|
|
2002-08-27 06:23:32 +08:00
|
|
|
<note><para>To protect an existing <filename>/etc/aliases</filename>
|
|
|
|
file, we will append these aliases to it if it exists. This file
|
|
|
|
should be checked and duplicate aliases removed, if
|
|
|
|
present.</para></note>
|
|
|
|
|
|
|
|
|
|
|
|
<para>To start and stop exim on system boot/shutdown create the
|
|
|
|
exim boot script with the following commands: </para>
|
|
|
|
|
|
|
|
<para><screen><userinput>cat > /etc/rc.d/init.d/exim << "EOF"</userinput>
|
|
|
|
#!/bin/sh
|
|
|
|
# Begin $rc_base/init.d/exim
|
|
|
|
|
|
|
|
# Based on sysklogd script from LFS-3.1 and earlier.
|
|
|
|
# Rewritten by Gerard Beekmans - gerard@linuxfromscratch.org
|
|
|
|
|
|
|
|
source /etc/sysconfig/rc
|
|
|
|
source $rc_functions
|
|
|
|
|
|
|
|
case "$1" in
|
|
|
|
|
|
|
|
start)
|
|
|
|
echo "Starting exim..."
|
|
|
|
loadproc /usr/sbin/exim -bd -q1m
|
|
|
|
;;
|
|
|
|
|
|
|
|
stop)
|
|
|
|
echo "Stopping exim..."
|
|
|
|
killproc exim
|
|
|
|
;;
|
|
|
|
|
|
|
|
status)
|
|
|
|
statusproc exim
|
|
|
|
;;
|
|
|
|
|
|
|
|
restart)
|
|
|
|
$0 stop
|
|
|
|
sleep 1
|
|
|
|
$0 start
|
|
|
|
;;
|
|
|
|
|
|
|
|
*)
|
|
|
|
echo "Usage: $0 {start|stop|status|restart}"
|
|
|
|
exit 1
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
|
|
|
|
# End $rc_base/init.d/exim
|
|
|
|
<userinput>EOF
|
|
|
|
chmod 755 /etc/rc.d/init.d/exim</userinput></screen></para>
|
|
|
|
|
|
|
|
<para>Create the run level symlinks with the following commands:
|
|
|
|
</para>
|
|
|
|
<para>
|
|
|
|
<screen><userinput>cd /etc/rc.d/init.d &&
|
|
|
|
ln -sf ../init.d/exim ../rc0.d/K25exim &&
|
|
|
|
ln -sf ../init.d/exim ../rc1.d/K25exim &&
|
|
|
|
ln -sf ../init.d/exim ../rc2.d/K25exim &&
|
|
|
|
ln -sf ../init.d/exim ../rc3.d/S35exim &&
|
|
|
|
ln -sf ../init.d/exim ../rc4.d/S35exim &&
|
|
|
|
ln -sf ../init.d/exim ../rc5.d/S35exim &&
|
|
|
|
ln -sf ../init.d/exim ../rc6.d/K25exim</userinput></screen></para>
|
|
|
|
</sect3>
|
|
|
|
|
|
|
|
</sect2>
|