Full Mail Server Solution w/ Virtual Domains & Users - Page 04 (Postfix on the MX Servers - Virtual Users)
B. Setting up Postfix for Virtual Users & DomainsEven though the mail exchangers won't be delivering mail to the virtual users and domains, they will be rejecting based on valid/invalid destinations. We therefore need the mx servers to be able to connect to the SQL server to verify destinaions. Go ahead and put the information into postconf: # postconf -e 'virtual_alias_domains =' There are several 'gotchas' here. This configuration will host the virtual user mailboxes in /vmail. Should you need to store your mailboxes in another location, change the virtual_mailbox_base line accordingly. The virtual_minimum_uid and virtual_uid_maps point to user id 150. This user id is for a specifically create "Virtual Mail" user. It uses the standard "mail" group, with the default (Debian) gid of 8. You can create the user and directory like this: # useradd -r -u 150 -g mail -d
/var/vmail -s /sbin/nologin -c "Virtual Mailbox" vmail Now we need to install the NFS client tools: # apt-get install nfs-common portmap The directory then needs to be mounted to the NFS share. To do a simple test, run the following: # mount files-1.internal.example.com:/vmail /vmail You should now have access to the /vmail share from files-1. Try writing a file (It shouldn't work!):
# cd /vmail NOTE: You should get a read-only error! Assuming everything is working, go ahead and unmount the NFS: # cd / And then make the mount permanent by putting the following into your /etc/fstab: [...] Go ahead and mount the file system one last time: # mount /vmail ... and you're good to go! C. Postfix MySQL ConfigurationPostfix was installed with MySQL support, but that doesn't mean it already knows how to use our database. It needs to be provided with various SQL-query information for each type of table in our database. This information is stored in the MySQL files defined in the main.cf file. Note that in the following files, the last line contains a single comment (Preceeded by #) with the full query. Recent versions of Postfix can use this instead of the other statements. If you're using a newer version, just comment out all of the other lines, and uncomment the query statement. /etc/postfix/mysql_virtual_alias_maps.cf user = vmail_user /etc/postfix/mysql_virtual_domains_maps.cf user = vmail_user /etc/postfix/mysql_virtual_mailbox_limit_maps.cf user = vmail_user /etc/postfix/mysql_virtual_mailbox_maps.cf user = vmail_user /etc/postfix/mysql_virtual_transports.cf user = vmail_user
|
www.seamlessenterprise.com
One number. One voicemail. Seize the lead. Sprint Mobile Integration.
www.seamlessenterprise.com
One Number. One Voicemail.
Make it easier for clients to reach you. Turn your desk phone and mobile phone into one with Sprint Mobile Integration.
www.seamlessenterprise.com
One number. One voicemail. Sprint Mobile Integration.
www.seamlessenterprise.com
One number. one voicemail. Seize the lead with Sprint. Learn more
AT&T Synaptic Compute as a Service. Boost your power on demand.
Trial: IBM Cognos Express Reporting, Analysis & Planning
Learn benefits of Simpana software.
View the Gartner Video
Sprint 4G - The Ultimate Mobile Broadband
Click here
SAP-Business Objects Crystal Reports Server
Complete reporting without hidden costs. Free Trial



![Creative Commons Attribution License [Creative Commons Attribution License]](http://creativecommons.org/images/public/somerights20.gif)

print: 

Recent comments
1 hour 59 min ago
3 hours 39 min ago
15 hours 52 min ago
18 hours 7 min ago
1 day 1 hour ago
1 day 5 hours ago
1 day 10 hours ago
1 day 13 hours ago
2 days 17 hours ago
2 days 18 hours ago