masqmail

view INSTALL @ 419:d209b4846f2b

The pid files goes to /var/run/masqmail.pid now. Added --with-piddir. Now we can change the pid dir to /run on system that did this transition.
author markus schnalke <meillo@marmaro.de>
date Tue, 29 May 2012 21:35:17 +0200
parents 5781ba87df95
children 09da6e72cd30
line source
1 Additional information may be available in docs/ or on the website.
2 For installing on GNU/Linux distributions read docs/INSTALL.linux.
5 Installation instructions
6 -------------------------
8 To compile masqmail you need glib (>= 1.2) (http://www.gtk.org). Your
9 distribution probably provides it. Glib-2.0 works out of the box, for
10 glib-1.2, you need to adjust configure.ac. See the comment in there.
12 You need a user and a group for masqmail to run. If
14 grep '^mail:' /etc/passwd
15 grep '^mail:' /etc/group
17 shows that the user `mail' and the group `mail' exist, it's probably
18 best to use these. If they don't exist, create them:
20 groupadd -g 12 mail
21 useradd -u 8 -g mail -d /nonexistent -s /bin/false -c "masqmail MTA" mail
23 The 8 and 12 are common uid/gid for the user and group `mail', but you can
24 use any (not yet used) number you like, preferably one lower than 100.
25 If you use other names than `mail' and `mail', you need to use the
26 configure options described below.
29 Compiling is a matter of the usual procedure. In the source directory,
30 after unpacking do:
32 ./configure
33 make
34 make install
38 Additional options for configure
39 --------------------------------
41 See the output of
43 ./configure -h
45 Here is a selection of the options with additional explanations:
47 --with-user=USER
48 sets the user as which masqmail will run. Default is 'mail'. USER has
49 to exist before you 'make install'.
51 --with-group=GROUP
52 sets the group as which masqmail will run. Default is 'mail'. GROUP
53 has to exist before you 'make install'.
56 --with-logdir=LOGDIR
57 sets the directory where masqmail stores its log files. It will be
58 created if it does not exist. Default is /var/log/masqmail/.
60 --with-spooldir=SPOOLDIR
61 sets the directory where masqmail stores its spool files. It will be
62 created if it does not exist. Default is /var/spool/masqmail/.
64 --with-confdir=CONFDIR
65 sets the default configuration directory to CONFDIR, in case you
66 prefer another location than /etc/masqmail/.
69 --disable-resolver
70 disables resolver support. Without the resolver functions, masqmail
71 uses only gethostbyname() to resolve DNS names, and you cannot send
72 mail without a smart host. Not recommended.
74 --disable-auth
75 disables ESMTP AUTH support (enabled by default)
78 --disable-debug
79 disables debugging; setting it on the command line or in the
80 configuration has no effect. Strongly discouraged, since you miss
81 valuable information if something goes wrong.
85 Checking the installation
86 -------------------------
88 Check that 'make install' worked correctly. The following command:
90 ls -ld /usr/local/sbin/masqmail /etc/masqmail /var/log/masqmail/ \
91 /var/spool/masqmail/ /var/spool/masqmail/*
93 should give output similar to
95 -rwsr-xr-x 1 root root 399356 May 10 12:34 /usr/local/sbin/masqmail
96 drwxr-xr-x 2 root root 4096 May 10 12:34 /etc/masqmail
97 drwxr-xr-x 2 mail mail 4096 May 10 12:34 /var/log/masqmail
98 drwxr-xr-x 5 mail mail 4096 May 10 12:34 /var/spool/masqmail
99 drwxr-xr-x 2 mail mail 4096 May 10 12:34 /var/spool/masqmail/input
100 drwxr-xr-x 2 mail mail 4096 May 10 12:34 /var/spool/masqmail/lock
102 Important are the set-user-id bit for /usr/local/sbin/masqmail and
103 the permissions of all files.
107 Making masqmail the default
108 ---------------------------
110 `sendmail' is the de-facto standard name of the system's MTA, no
111 matter which MTA actually runs. If you want to make masqmail the
112 system's MTA (i.e. replace sendmail, postfix, etc), make two symbolic
113 links:
115 ln -s /usr/local/sbin/masqmail /usr/lib/sendmail
116 ln -s /usr/local/sbin/masqmail /usr/sbin/sendmail
118 Now every mailer that used to call sendmail will now call masqmail.
119 If you already had an MTA installed and running, you can kill it and
120 start masqmail. Probably with:
122 /etc/init.d/sendmail restart
124 If this doesn't work as expected, you might need to add a special init
125 script for masqmail. Currently none is distributed with masqmail.
126 (Hopefully this will change soon.) Please ask on the mailing list for
127 help.
129 You can also directly start masqmail as daemon with:
131 /usr/local/sbin/masqmail -bd -q30m
135 Basic Configuration
136 -------------------
138 The only thing you must configure in order to use masqmail is the
139 hostname. It's the name under which masqmail operates. In most cases
140 it is the same as the machine's name, but it can be different.
142 The script `admin/guess-hostname' tries to print the hostname of
143 your machine. The first output line is probably the best choice.
145 Create a minimal config with:
147 echo "host_name = HOSTNAME" >/etc/masqmail/masqmail.conf
149 (Substitute `HOSTNAME' with the real value, of course.)
151 Such a setup (i.e. the default one) does:
152 - deliver mail locally
153 - accept mail on stdin (plain text)
154 - accept mail on stdin (SMTP) (if started with -bs)
155 - accept mail on the local port 25 (SMTP) (if started with -bd)
157 It does not
158 - transfer mail to other machines
159 - accept mail from outside your machine
162 For more elaborate setups, have a look at docs/*setup and
163 docs/INSTALL*. You can also take the example configuration files in
164 examples/ as basis for your own. Take the man pages masqmail.conf(5)
165 and masqmail.route(5) for reference.
167 All configuration files should go into /etc/masqmail.
171 Written by oku.
172 Improved by meillo.