Defcon1-Header
Tool-BarfreeBSD ArticlesSearch Our SiteHOMEfreeBSD LinksContribute to FreeBSD HelpFreeBSD FilesFreeBSD Script Corner

Q-Mail - Howto

- Author: zartik

- File Information: This text document may be copied, deleted, and published as desired provided credit is given to the author. If any alterations are made, each and every change must be commented as change to the original document, thank you.
- Purpose: Provide a 1,2,3 setup guide to qmail.

Part One:
---------
 Welp, if you are reading this and setting up qmail on a production server ... eek. This is intended as a 2 minute guide to install a basic qmail setup with pop3 access on a freebsd machine. I explain it assuming you want to use the Maildir method implemented by qmail. This document is just going to tell you the how's of it, for the why's and much more information please read the documents in the /var/qmail/doc directory or visit www.qmail.org .

Part Two:
---------
 This is going to be simple, since FreeBSD comes with that nice little section called ports. As with all ports, type make install in the following
dirs:
 - /usr/ports/mail/qmail
 - /usr/ports/mail/popper
 - /usr/ports/security/checkpassword

Tough, huh? The installs for these really set just about everything up for you.
The only things left are to add this line to /etc/inetd.conf, and make sure you put it all on one line, I broke it up due to it's length:

 pop3  stream tcp   nowait root  /var/qmail/bin/qmail-popup
 qmail-popup   spot.org    /bin/checkpassword
 /var/qmail/bin/qmail-pop3d   Maildir

For every user you want to have mail, you need to run the fancy
little maildirmake utility. Here is an example:

 My current home directory is: /usr/home/zartik
 Now to add maildir to it, do: /var/qmail/bin/maildirmake /usr/home/zartik/Maildir
 And then: echo ./Maildir/ > .qmail

Last step, select your 'rc' file, this is to start qmail when you boot.

 cp /var/qmail/boot/maildir /var/qmail/rc

You need to make sure /var/qmail/bin is in the path on startup or else qmail won't start properly. Your other option is to edit /var/qmail/rc now and put
the path /var/qmail/bin before qmail-start in the file. Now just type:

 killall -HUP inetd
 csh -cf '/var/qmail/rc &'

Congrats, qmail is up and running and you will be recieving mail from all your favorite online relatives.

 By: Zartik

© 1997 - 20013 Defcon1, www.defcon1.org , Copyrights for all materials on this web site are held by the individual authors, artists, photographers or creators. Materials may not be reproduced or otherwise distributed without permission of www.defcon1.org and the content's original author.

Defcon1-Header2
Tool-Bar-2Defcon1  Webmail