On Wed, Mar 24, 2010 at 04:51:33PM +0200, Isak Badenhorst wrote: > I have asked before with no sucess and want ask again because I have spent > quite a few days now searching for the answer with no luck. Maybe I am just > not reading well enough but I cannot find my answer. > > I have just moved from sendmail and have this one problem. I have a local > server in the office with mail to anyu...@domain.com delivered locally using > mysql virtual mailboxes. I also use fetchmail to get mail from my ISP for > these mailboxes and everything just works perfect. My problem is that I > have two users, us...@domain.com and us...@domain.com that I do not want to > deliver local but use the relayhost to deliver to the ISP because this users > use laptops and need to download their mail directly from the ISP server. > These users does not have a virtual local account. I have tried transport > maps but it seems that is not the correct way to do it. Can anyone please > point me in the right direction or is this not possible?
Your description of the environment is too sketchy for a precise response that tells you exactly what to do. All the relevant tools are described in http://www.postfix.org/ADDRESS_REWRITING_README.html The key mechanisms (in the order in which are processed) are: virtual_alias_maps - recursively rewrites recipient addresses (in any domain) that have an entry in the specified tables. transport_maps - selects a transport:next for a domain or recipient smtp_generic_maps - rewrites envelope and header addresses of mail that is delivered via the smtp(8) transport during delivery, so the transport and nexthop are not changed by this rewriting You can combine virtual rewriting, transport selection and generic rewriting in many ways to support a large variety of mail routing scenarios. -- Viktor. P.S. Morgan Stanley is looking for a New York City based, Senior Unix system/email administrator to architect and sustain our perimeter email environment. If you are interested, please drop me a note.