[TriLUG] stupid sendmail question

Jeremy Portzer jeremyp at pobox.com
Thu Jul 18 17:28:55 EDT 2002


Thanks for the link... masquerading is cool, and I would have to do that
if this server were handling outgoing mail.  However, all I want to do is
forward incoming mail for the old domain to the new domain.  (All outgoing
mail will be handled by the new domain's server.)  I'm pretty sure
masquerading isn't for my situation.

The virtual user table *can* be used for virtual hosting of local
accounts, but it should easily work to forward to remote accounts also, as
many virtual hosting companies do (without the aliases file).

I've done some more testing, with Wade's correction of this in the
virtusertable:
@old-domain.ocm         %1 at new-domain.ocm

This should "catch-all" any address going to @old-domain and forward it to
new-domain.  It works fine *if the username exists locally*.  This is NOT
what it says on http://www.sendmail.org/virtual-hosting.html  -- it should
work regardless of the user's local existence.

Say, jeremy at mailserver.ocm exists; my local user account.  Sending mail to
jeremy at old-domain.ocm works fine -- it forwards to jeremy at new-domain.ocm .
(It does NOT deliver locally, which is correct) 

Now, say otheruser doesn't exist on mailserver.ocm, but does exist on
new-domain.ocm. The mail should still forward to otheruser at new-domain.ocm,
because of the catch-all.  But it doesn't... it bounces as User Not Found.

Ugh, I guess I need to get the Sendmail book and really delve deeply into
this.  Either that or switch to postfix. :-)

--Jeremy

On Thu, 18 Jul 2002, Jon Carnes wrote:

> Check out:
>   http://www.sendmail.org/m4/masquerading.html
> 
> The virtual user tables are only for converting virtual hosting of local
> accounts, not remote accounts.
> 
> You could simply make a rather large /etc/aliases file that has an entry for
> every old user and forwards the mail on to the user's new email address.
> Why is it that politics always makes so much work for IT?
> 
> Jon
> ----- Original Message -----
> From: "Jeremy Portzer" <jeremyp at pobox.com>
> To: <trilug at trilug.org>
> Sent: Thursday, July 18, 2002 3:46 PM
> Subject: [TriLUG] stupid sendmail question
> 
> 
> >
> > Okay, so I want to configure a box to receive mail for "old-domain.ocm"
> > and forward it to "new-domain.ocm" (leaving the user portion the same).
> > New-domain.ocm is a different server.  Yes, I know it would be simpler to
> > program that server to receive mail for old-domain, but I can't do that
> > for strange political reasons.
> >
> > I've been told this can be done in sendmail with an entry in
> > /etc/mail/virtusertable like this:
> >
> > %1 at old-domain.ocm         %1 at new-domain.ocm
> >
> > ("makemap hash virtusertable.db < virtusertable" to apply the changes, of
> > course)
> >
> > If I don't put old-domain.ocm in /etc/mail/local-host-names (formerly
> > sendmail.cw), then I get Relaying Denied messages.  But if I do add
> > old-domain.ocm to that list, sendmail tries to receive mail locally
> > instead of following the virtusertable instructions (usually resulting in
> > User Not Found).  What am I doing wrong?
> >
> > Thanks for any tips.  I'm sure I'm missing something completely obvious
> > here.  Running RHL 6.2 (don't ask) with sendmail 8.11.6-1.6.y .
> >
> > --Jeremy
> >
> > _______________________________________________
> > TriLUG mailing list
> >     http://www.trilug.org/mailman/listinfo/trilug
> > TriLUG Organizational FAQ:
> >     http://www.trilug.org/~lovelace/faq/TriLUG-faq.html
> 
> _______________________________________________
> TriLUG mailing list
>     http://www.trilug.org/mailman/listinfo/trilug
> TriLUG Organizational FAQ:
>     http://www.trilug.org/~lovelace/faq/TriLUG-faq.html
> 




More information about the TriLUG mailing list