/[gentoo]/xml/htdocs/doc/en/virt-mail-howto.xml
Gentoo

Diff of /xml/htdocs/doc/en/virt-mail-howto.xml

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.50 Revision 1.54
1<?xml version='1.0' encoding='UTF-8'?> 1<?xml version='1.0' encoding='UTF-8'?>
2<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/virt-mail-howto.xml,v 1.50 2006/04/09 07:42:45 fox2mike Exp $ --> 2<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/virt-mail-howto.xml,v 1.54 2007/03/02 07:24:46 nightmorph Exp $ -->
3<!DOCTYPE guide SYSTEM "/dtd/guide.dtd"> 3<!DOCTYPE guide SYSTEM "/dtd/guide.dtd">
4 4
5<guide link="/doc/en/virt-mail-howto.xml"> 5<guide link="/doc/en/virt-mail-howto.xml">
6<title>Virtual Mailhosting System with Postfix Guide</title> 6<title>Virtual Mailhosting System with Postfix Guide</title>
7 7
21<abstract> 21<abstract>
22This document details how to create a virtual mailhosting system based upon 22This document details how to create a virtual mailhosting system based upon
23postfix, mysql, courier-imap, and cyrus-sasl. 23postfix, mysql, courier-imap, and cyrus-sasl.
24</abstract> 24</abstract>
25 25
26<version>1.0.27</version> 26<version>1.2</version>
27<date>2006-04-09</date> 27<date>2006-09-04</date>
28 28
29<!-- 29<!--
30Contents 30Contents
31 31
32I. Introduction 32I. Introduction
50<title>Introduction</title> 50<title>Introduction</title>
51<section> 51<section>
52<body> 52<body>
53 53
54<p> 54<p>
55For most gentoo users, a simple mail client and fetchmail will do. However, if 55For most Gentoo users, a simple mail client and fetchmail will do. However, if
56you're hosting a domain with your system, you'll need a full blown MTA (Mail 56you're hosting a domain with your system, you'll need a full blown MTA (Mail
57Transfer Agent). And if you're hosting multiple domains, then you'll definitely 57Transfer Agent). And if you're hosting multiple domains, then you'll definitely
58need something more robust to handle all of the email for your users. This 58need something more robust to handle all of the email for your users. This
59system was designed to be an elegant solution to that problem. 59system was designed to be an elegant solution to that problem.
60</p> 60</p>
120for a domain. Ideally you would have control of at least two domains to take 120for a domain. Ideally you would have control of at least two domains to take
121advantage of your new virtual domain functionality. 121advantage of your new virtual domain functionality.
122</impo> 122</impo>
123 123
124<impo> 124<impo>
125Make sure <path>/etc/hostname</path> is set to the right hostname for your mail 125Make sure <path>/etc/conf.d/hostname</path> is set to the right hostname for
126server. Verify your hostname is set correctly with <c>hostname</c>. Also 126your mail server. You can apply any changes you make to this file by running
127verify that there are no conflicting entries in <path>/etc/hosts</path>. 127<c>/etc/init.d/hostname restart</c>. Verify your hostname is set correctly with
128<c>hostname</c>. Also verify that there are no conflicting entries in
129<path>/etc/hosts</path>.
128</impo> 130</impo>
129 131
130<note> 132<note>
131It is recommended that you read this entire document and familiarize yourself 133It is recommended that you read this entire document and familiarize yourself
132with all the steps before attempting the install. If you run into problems with 134with all the steps before attempting the install. If you run into problems with
149# <i>emerge postfix</i> 151# <i>emerge postfix</i>
150</pre> 152</pre>
151 153
152<warn> 154<warn>
153Verify that you have not installed any other MTA, such as ssmtp, exim, or 155Verify that you have not installed any other MTA, such as ssmtp, exim, or
154qmail, or you will surely have BIG problems. 156netqmail, or you will surely have BIG problems.
155</warn> 157</warn>
156 158
157<p> 159<p>
158After postfix is installed, it's time to configure it. Change the following 160After postfix is installed, it's time to configure it. Change the following
159options in <path>/etc/postfix/main.cf</path>: 161options in <path>/etc/postfix/main.cf</path>. Remember to replace
162<c>$variables</c> with your own names.
160</p> 163</p>
161 164
162<pre caption="/etc/postfix/main.cf"> 165<pre caption="/etc/postfix/main.cf">
163myhostname = $host.domain.name 166myhostname = $host.domain.name
164mydomain = $domain.name 167mydomain = $domain.name
541# <i>emerge apache mod_php phpmyadmin</i> 544# <i>emerge apache mod_php phpmyadmin</i>
542</pre> 545</pre>
543 546
544<p> 547<p>
545There are plenty of guides out there about how to set up apache with php. Like 548There are plenty of guides out there about how to set up apache with php. Like
546this one: <uri>http://www.linuxguruz.org/z.php?id=31</uri>. There are also 549this one: <uri>http://www.linuxguruz.com/z.php?id=31</uri>. There are also
547numerous posts on <uri>http://forums.gentoo.org</uri> detailing how to solve 550numerous posts on <uri>http://forums.gentoo.org</uri> detailing how to solve
548problems with the installation (search for 'apache php'). So, that said, I'm 551problems with the installation (search for 'apache php'). So, that said, I'm
549not going to cover it here. Set up the apache and php installs, then continue 552not going to cover it here. Set up the apache and php installs, then continue
550with this howto. Now, a word for the wise: .htaccess the directory that you put 553with this howto. Now, a word for the wise: .htaccess the directory that you put
551phpmyadmin in. If you do not do this, search engine spiders will come along and 554phpmyadmin in. If you do not do this, search engine spiders will come along and
607Now enter the phpmyadmin page and browse the tables. You'll want to add in your 610Now enter the phpmyadmin page and browse the tables. You'll want to add in your
608local aliases, edit your user table to add a test user, and change your 611local aliases, edit your user table to add a test user, and change your
609transport table to add information about your domains. The default values 612transport table to add information about your domains. The default values
610supplied with the dumpfile should be a sufficient guide to what values need to 613supplied with the dumpfile should be a sufficient guide to what values need to
611go where. Make sure that if you put information in the database that it is 614go where. Make sure that if you put information in the database that it is
612accurate. For instance, make sure the local users home dir exists and that the 615accurate. For instance, make sure the local user's home dir exists and that the
613correct uid/gid values are in place. The maildirs should be created 616correct uid/gid values are in place. The maildirs should be created
614automatically by postfix when the user receives their first email. So, in 617automatically by postfix when the user receives their first email. So, in
615general, it's a good idea to send a "Welcome" mail to a new user 618general, it's a good idea to send a "Welcome" mail to a new user after you
616after you setup their account to make sure the .maildir gets created. 619setup their account to make sure the .maildir gets created.
617</p> 620</p>
618 621
619</body> 622</body>
620</section> 623</section>
621</chapter> 624</chapter>
638# <i>chown vmail: /home/vmail</i> 641# <i>chown vmail: /home/vmail</i>
639</pre> 642</pre>
640 643
641<p> 644<p>
642So now when you're setting up vmail accounts, use the vmail uid, gid, and 645So now when you're setting up vmail accounts, use the vmail uid, gid, and
643homedir. When you're setting up local accounts, use that users uid, gid, and 646homedir. When you're setting up local accounts, use that user's uid, gid, and
644homedir. We've been meaning to create a php admin page for this setup but 647homedir. We've been meaning to create a php admin page for this setup but
645haven't gotten around to it yet, as phpmyadmin generally works fine for us. 648haven't gotten around to it yet, as phpmyadmin generally works fine for us.
646</p> 649</p>
647 650
648</body> 651</body>
683# <i>/etc/init.d/courier-authlib restart</i> 686# <i>/etc/init.d/courier-authlib restart</i>
684# <i>/etc/init.d/saslauthd restart</i> 687# <i>/etc/init.d/saslauthd restart</i>
685</pre> 688</pre>
686 689
687<p> 690<p>
688We're almost there I promise! Next, set up the rest of the necessary config's 691We're almost there, I promise! Next, set up the rest of the necessary configs
689for postfix to interract with the database for all it's other transport needs. 692for postfix to interract with the database for all its other transport needs.
693Remember to replace each value with the name of your own user, user id,
694password, alias, email address, and so on.
690</p> 695</p>
691 696
692<pre caption="/etc/postfix/mysql-aliases.cf"> 697<pre caption="/etc/postfix/mysql-aliases.cf">
693# <i>nano -w /etc/postfix/mysql-aliases.cf</i> 698# <i>nano -w /etc/postfix/mysql-aliases.cf</i>
694# mysql-aliases.cf 699# mysql-aliases.cf
882documentation, including README.POSTFIX.gz, to understand what's being done 887documentation, including README.POSTFIX.gz, to understand what's being done
883here. 888here.
884</p> 889</p>
885 890
886<p> 891<p>
887One further note, current versions of mailman install to /usr/local/mailman. If 892One further note, current versions of mailman install to
888you're like me and wish to change the default install location, it can be 893<path>/usr/local/mailman</path>. If you're like me and wish to change the
889overridden in the ebuild file by changing the INSTALLDIR variable. 894default install location, it can be overridden in the ebuild file by changing
895the INSTALLDIR variable.
890</p> 896</p>
891 897
892<pre caption="Install mailman"> 898<pre caption="Install mailman">
893# <i>emerge mailman</i> 899# <i>emerge mailman</i>
894</pre> 900</pre>

Legend:
Removed from v.1.50  
changed lines
  Added in v.1.54

  ViewVC Help
Powered by ViewVC 1.1.20