Skip to Main Content
Postfix: The Definitive Guide
book

Postfix: The Definitive Guide

by Kyle D. Dent
December 2003
Beginner content levelBeginner
278 pages
10h 47m
English
O'Reilly Media, Inc.
Content preview from Postfix: The Definitive Guide

Separate Message Store

The last configuration we’ll consider is hosting virtual domains with a system using a proprietary message store. To work with these systems, Postfix hands off messages using a protocol like LMTP, letting the proprietary system handle delivery to the correct mail box.

Since Postfix must receive messages before handing them off to the LMTP server, it has to know that it should accept mail for each of the virtual domains. List them in virtual_mailbox_domains :

virtual_mailbox_domains = ora.com, oreilly.com

You also have to list each email address, so Postfix can accept messages for valid addresses and reject unknown users. Use the virtual_mailbox_maps parameter to point to a lookup file with valid addresses:

virtual_mailbox_maps = hash:/etc/postfix/virtual

In the /etc/postfix/virtual file, the righthand value isn’t used because all messages are passed along to the POP/IMAP server. You must still include a righthand value because lookup tables must have a key and a value, but the value you use doesn’t matter:

info@ora.com         General Information Address
info@oreilly.com     General Information Address

In order to have Postfix pass mail for virtual domains through to your POP/IMAP server, specify the correct transport in the virtual_transport parameter in main.cf. You have to know how your LMTP server socket is set up. Assuming it’s on the same host as Postfix and uses a socket file located at /var/imap/socket/lmtp, the transport lookup table for the example domains looks ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Linux Cookbook, 2nd Edition

Linux Cookbook, 2nd Edition

Carla Schroder
Linux Under the Hood

Linux Under the Hood

Sander van Vugt
Kubernetes: Up and Running, 2nd Edition

Kubernetes: Up and Running, 2nd Edition

Brendan Burns, Joe Beda, Kelsey Hightower

Publisher Resources

ISBN: 0596002122Errata Page