From owner-freebsd-questions@FreeBSD.ORG Wed Aug 1 13:50:03 2007 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8637116A417 for ; Wed, 1 Aug 2007 13:50:03 +0000 (UTC) (envelope-from derek@computinginnovations.com) Received: from betty.computinginnovations.com (mail.computinginnovations.com [64.81.227.250]) by mx1.freebsd.org (Postfix) with ESMTP id 2CC4313C4B7 for ; Wed, 1 Aug 2007 13:50:03 +0000 (UTC) (envelope-from derek@computinginnovations.com) Received: from p28.computinginnovations.com (dhcp-10-20-30-100.computinginnovations.com [10.20.30.100]) (authenticated bits=0) by betty.computinginnovations.com (8.13.8/8.12.11) with ESMTP id l71DneBf076685; Wed, 1 Aug 2007 08:49:41 -0500 (CDT) Message-Id: <6.0.0.22.2.20070801084438.024a1ab0@mail.computinginnovations.com> X-Sender: derek@mail.computinginnovations.com X-Mailer: QUALCOMM Windows Eudora Version 6.0.0.22 Date: Wed, 01 Aug 2007 08:48:50 -0500 To: Christopher Cowart , Michael Grant From: Derek Ragona In-Reply-To: <20070731221917.GD5107@rescomp.berkeley.edu> References: <62b856460707311103j5e648552kdeb1eba9ecff06e1@mail.gmail.com> <20070731221917.GD5107@rescomp.berkeley.edu> Mime-Version: 1.0 X-ComputingInnovations-MailScanner-Information: Please contact the ISP for more information X-ComputingInnovations-MailScanner: Found to be clean X-ComputingInnovations-MailScanner-From: derek@computinginnovations.com X-Spam-Status: No Content-Type: text/plain; charset="us-ascii"; format=flowed X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: FreeBSD Questions Subject: Re: relaying mail X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 01 Aug 2007 13:50:03 -0000 At 05:19 PM 7/31/2007, Christopher Cowart wrote: >On Tue, Jul 31, 2007 at 08:03:50PM +0200, Michael Grant wrote: > > In one of my domains, I have the MX record for it set up to my server. > > But for one of the users within that domain, their mail needs to be > > shuffled off to a different server at google. But I can't just > > forward it because it's like an MX host I'd need to forward it to. > > And I can't alter the MX to point to google for the entire domain > > because it's only one user within that domain, the other users will be > > screwed in that case. > > > > For example, mydomain.com, let's say the mx for that comes to my box. > > For joe@mydomain.com, I need to send his mail to ASPMX.L.GOOGLE.COM as > > if it were the MX for mydomain.com. > > > > In the old days, one would simply forward email to > > joe%mydomain.com@ASPMX.L.GOOGLE.COM. That would cause mydomain.com's > > sendmail to connect to ASPMX.L.GOOGLE.COM and shove down a message for > > joe@mydomain.com. But that seems long deprecated because it didn't > > seem to work. > > > > I am using sendmail and procmail. Can anyone think of some way I can > > cause something like this to happen for just one user, ideally in a > > .procmailrc file? You can do this with sendmail by user in /etc/mail/virtualusertable. You should see the file /etc/mail/virtualusertable.sample for some explanations of this file. The virtualuser database is read first by sendmail, before aliases. Also the virtualusertable is read serially from top to bottom, so you can specific user maps before a general map for the rest of a domain. -Derek -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. MailScanner thanks transtec Computers for their support.