Re: multiple copies delivered

2011-06-30 Thread mouss
Le 29/06/2011 01:07, Jay G. Scott a écrit :
> Hello,
> 
>   This machine has a list of legitimate users but does not deliver
> mail locally.  (It's a mail gateway.)
> 
>   Presently user schumi gets copies of his mail delivered to three
> systems.  The three destinations are listed in virtual_alias_maps.
> 
> schumi: sch...@inm.arlut.utexas.edu, sch...@ns8.arlut.utexas.edu, 
> sch...@vme.arlut.utexas.edu

this is not a virtual alias. this looks like a "local" alias. for
virtual aliases, specify the full address (with the domain part) and do
not use a ':'.

> 
>   By management fiat, mail that is addressed incorrectly to
> sch...@nonexistent.arlut.utexas.edu
> should be delivered to sch...@arlut.utexas.edu.  It is, but
> I get multiple copies.  recipient_canonical_maps:
> 
> /^schumi@.*\.arlut\.utexas\.edu$/   sch...@arlut.utexas.edu

why use canonical? use a virtual alias instead.

> 
>   From the logs I see that the alias gets expanded into three,
> and then canonicalized, so that each target gets three copies of the
> email.

virtual_alias_maps =
...
hash:/path/to/valias.hash
pcre:/path/to/valias.pcre

== valias.hash
# single line follows
sch...@example.com sch...@inm.arlut.utexas.edu,
sch...@ns8.arlut.utexas.edu, sch...@vme.arlut.utexas.edu

sch...@inm.arlut.utexas.edu sch...@inm.arlut.utexas.edu
sch...@ns8.arlut.utexas.edu sch...@ns8.arlut.utexas.edu
sch...@vme.arlut.utexas.edu sch...@vme.arlut.utexas.edu

== valias.pcre
/^scuhmi@.*\.arlut\.utexas\.edu$/   sch...@arlut.utexas.edu


> 
>   Obviously, I want to get rid of the duplicates.
> 
>   For outgoing mail I must avoid MX lookups as part of my
> load balancing and fault tolerance, so I must set relayhost.
> Only the official mail servers have MX records in DNS, so any
> other machines that accept mail must be listed in the transport_maps.
> 
> 
> postconf -n
> 


Re: multiple copies delivered

2011-06-29 Thread Sahil Tandon
On Tue, 2011-06-28 at 18:07:07 -0500, Jay G. Scott wrote:

> Presently user schumi gets copies of his mail delivered to three
> systems.  The three destinations are listed in virtual_alias_maps.
> 
> schumi: sch...@inm.arlut.utexas.edu, sch...@ns8.arlut.utexas.edu, 
> sch...@vme.arlut.utexas.edu

The ':' is invalid, so what is the actual (hint: copy and paste to
minimize human error) content of your virtual alias map?

> By management fiat, mail that is addressed incorrectly to
> sch...@nonexistent.arlut.utexas.edu should be delivered to
> sch...@arlut.utexas.edu.  It is, but I get multiple copies.

Before proceeding any further, I am just curious: in order for
sch...@nonexistent.arlut.utexas.edu to be accepted, that hostname must
be defined (either explicitly or via wildcard) in a Postfix address
class -- where does this occur in your configuration?

Based on a cursory glance, it seems to me that a simple virtual alias
mapping is more suitable than jumping through canonical hoops.  

Oh, and in your follow-up: please, show logs that relate to your problem
description.

-- 
Sahil Tandon 


Re: multiple copies delivered--still have problem

2011-06-29 Thread Jay G. Scott
On Wed, Jun 29, 2011 at 09:05:15AM -0500, Jay G. Scott wrote:
> 
> wait a sec.  i think my test procedure is not working.
> i won't be able to check until this afternoon.
> it may be the other configurations i thought i was trying
> weren't actually being used at all.

the test procedure is okay.  my problem w/ postfix still exists.
thanks in advance.

> 
> j.
> 
> -- 
> Jay Scott 512-835-3553g...@arlut.utexas.edu
> Head of Sun Support, Sr. System Administrator
> Applied Research Labs, Computer Science Div.   S224
> University of Texas at Austin

-- 
Jay Scott   512-835-3553g...@arlut.utexas.edu
Head of Sun Support, Sr. System Administrator
Applied Research Labs, Computer Science Div.   S224
University of Texas at Austin


Re: multiple copies delivered

2011-06-29 Thread Jay G. Scott

wait a sec.  i think my test procedure is not working.
i won't be able to check until this afternoon.
it may be the other configurations i thought i was trying
weren't actually being used at all.

j.

-- 
Jay Scott   512-835-3553g...@arlut.utexas.edu
Head of Sun Support, Sr. System Administrator
Applied Research Labs, Computer Science Div.   S224
University of Texas at Austin


multiple copies delivered

2011-06-28 Thread Jay G. Scott

Hello,

This machine has a list of legitimate users but does not deliver
mail locally.  (It's a mail gateway.)

Presently user schumi gets copies of his mail delivered to three
systems.  The three destinations are listed in virtual_alias_maps.

schumi: sch...@inm.arlut.utexas.edu, sch...@ns8.arlut.utexas.edu, 
sch...@vme.arlut.utexas.edu

By management fiat, mail that is addressed incorrectly to
sch...@nonexistent.arlut.utexas.edu
should be delivered to sch...@arlut.utexas.edu.  It is, but
I get multiple copies.  recipient_canonical_maps:

/^schumi@.*\.arlut\.utexas\.edu$/   sch...@arlut.utexas.edu

From the logs I see that the alias gets expanded into three,
and then canonicalized, so that each target gets three copies of the
email.

Obviously, I want to get rid of the duplicates.

For outgoing mail I must avoid MX lookups as part of my
load balancing and fault tolerance, so I must set relayhost.
Only the official mail servers have MX records in DNS, so any
other machines that accept mail must be listed in the transport_maps.


postconf -n

command_directory = /usr/sbin
config_directory = /etc/postfix
content_filter = pmx:127.0.0.1:10025
daemon_directory = /usr/libexec/postfix
data_directory = /var/lib/postfix
debug_peer_level = 2
html_directory = /opt/depot/postfix-2.7.1/html
inet_interfaces = all
local_recipient_maps = 
local_transport = error:local mail delivery is disabled
mail_owner = postfix
mailbox_size_limit = 0
mailq_path = /usr/bin/mailq.postfix
manpage_directory = /usr/local/man
masquerade_domains = $mydomain
masquerade_exceptions = adm amanda apache avahi beaglidx bin daemon dbus
distcache dovecot ejabberd exim flexlm ftp games gdmgopher haldaemon halt 
hsqldb listen lp mail mailman mailnull mysql nagios named netdump news 
nfsnobody noaccess nobody nobody4 nscd ntp nuucp nx operator otrs  pcap 
pegasus postfix postgres pvm root rpc rpcuser  rpm sabayon shutdown smmsp 
smtp squid sshd sweepsync sync sys tomcat utwww uucp vcsa webalizer  
xfs zope
message_size_limit = 0
mydestination = 
mydomain = arlut.utexas.edu
myhostname = ns6.arlut.utexas.edu
mynetworks = 127.0.0.0/8, 10.0.0.0/8
myorigin = $mydomain
newaliases_path = /usr/bin/newaliases.postfix
queue_directory = /var/spool/postfix
readme_directory = /opt/depot/postfix-2.7.1/README
recipient_canonical_maps = regexp:/etc/postfix/pfrecipient_canonical
recipient_delimiter = +
relay_domains = arlut.utexas.edu
relay_recipient_maps = hash:/etc/postfix/pfknown_users
relayhost = [ns4.arlut.utexas.edu]
sample_directory = /etc/postfix
sendmail_path = /usr/sbin/sendmail.postfix
setgid_group = postdrop
smtp_generic_maps = hash:/etc/postfix/pfgenerics
smtpd_data_restrictions = reject_multi_recipient_bounce
transport_maps = hash:/etc/postfix/pftransport
unknown_local_recipient_reject_code = 550
virtual_alias_maps = hash:/etc/postfix/pfmalias hash:/etc/aliases

j.