INSTALL.mbox.md (2368B)
1 The qmail package includes a local delivery agent, qmail-local, which 2 provides user-controlled mailing lists, cross-host alias loop detection, 3 and many other important qmail features. 4 5 There's one important difference between qmail-local and binmail: 6 qmail-local delivers mail by default into ~user/Mailbox, rather than 7 /var/spool/mail/user. It uses mbox format, with lockf locking on systems 8 that don't have flock (HP/UX, Solaris), and flock locking otherwise. 9 10 This file explains how to switch your system to ~user/Mailbox. You 11 aren't required to do this; for further discussion of /var/spool/mail, 12 and an explanation of how to continue using binmail for local 13 deliveries, see INSTALL.vsm.md. 14 15 The basic procedure for switching to ~user/Mailbox is simple: 16 17 * Move each /var/spool/mail/user to ~user/Mailbox. For safety, do 18 this in single-user mode. 19 20 * As root, set up a symbolic link from /var/spool/mail/user to 21 ~user/Mailbox for each user. /var/spool/mail should be mode 1777, 22 so users will not be able to accidentally remove these links. 23 24 A few mail programs are unable to handle symbolic links, so you will 25 have to configure them to look at ~user/Mailbox directly: 26 27 * procmail: Change SYSTEM_MBOX in config.h and recompile; or, with 28 recent versions, define MAILSPOOLHOME in src/authenticate.c. 29 30 An alternative to symbolic links is hlfsd. Consult the documentation for 31 hlfsd if it is included in your operating system. 32 33 If /var/spool/mail is large, you can gain extra speed by configuring 34 all your mail software to look at ~user/Mailbox directly: 35 36 * Most MUAs: Put "setenv MAIL $HOME/Mailbox" in your system-wide 37 .cshrc and "MAIL=$HOME/Mailbox; export MAIL" in your system-wide 38 .profile. 39 40 * elm: Change "mailbox" to "Mailbox" around line 388 of newmbox.c and 41 recompile. (elm looks at $MAIL, but without this change elm will 42 fail if two users try to read mail simultaneously.) 43 44 * pine: Put "inbox-path=Mailbox" in your system-wide pine.conf. 45 (For pine versions more recent than 3.91, see also FAQ 6.2.) 46 47 * qpopper 2.2: Change /.mail to /Mailbox in pop_dropcopy.c and 48 recompile with -DHOMEDIRMAIL in CFLAGS. 49 50 Some vendors, in a misguided attempt to solve the security problems of 51 /var/spool/mail, have made all their mail software setgid mail. After 52 you move the mailboxes, you can -- and, for security, should -- remove 53 those setgid-mail bits.