Customize / configure postfix with multiple recipients

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

Customize / configure postfix with multiple recipients

Manjiri
Hello,

I am interested to know if it is possible to configure postfix such that, if a message is sent to multiple recipients. Out of which, if one is an invalid address and other is a valid address. Then, right now the postfix rejects the mail with a 550 error (Recipient address rejected: User unknown in virtual mailbox table) and mail is not delivered to the valid address recipient. Can I customize / configure postfix to deliver the mail to the valid address recipient ?

Thank You.

Sincerely,
Manjiri
Reply | Threaded
Open this post in threaded view
|

Re: Customize / configure postfix with multiple recipients

Noel Jones-2
On 10/8/2010 10:34 AM, Manjiri wrote:

>
> Hello,
>
> I am interested to know if it is possible to configure postfix such that, if
> a message is sent to multiple recipients. Out of which, if one is an invalid
> address and other is a valid address. Then, right now the postfix rejects
> the mail with a 550 error (Recipient address rejected: User unknown in
> virtual mailbox table) and mail is not delivered to the valid address
> recipient. Can I customize / configure postfix to deliver the mail to the
> valid address recipient ?

Postfix normally acts as you request -- within a single
message, valid users are accepted and delivered, invalid users
are rejected.

Please show full (non-verbose) logs of a transaction with both
valid and invalid recipients, and your "postconf -n" output.


   -- Noel Jones
Reply | Threaded
Open this post in threaded view
|

Re: Customize / configure postfix with multiple recipients

Brian Evans - Postfix List
In reply to this post by Manjiri
  On 10/8/2010 11:34 AM, Manjiri wrote:
> Hello,
>
> I am interested to know if it is possible to configure postfix such that, if
> a message is sent to multiple recipients. Out of which, if one is an invalid
> address and other is a valid address. Then, right now the postfix rejects
> the mail with a 550 error (Recipient address rejected: User unknown in
> virtual mailbox table) and mail is not delivered to the valid address
> recipient. Can I customize / configure postfix to deliver the mail to the
> valid address recipient ?

This is partially a mail CLIENT issue.
Postfix will accept unknown recipients up to $smtpd_hard_error_limit
(default: normal: 20, overload: 1) and still deliver a mail.

Reply | Threaded
Open this post in threaded view
|

Re: Customize / configure postfix with multiple recipients

Manjiri
In reply to this post by Noel Jones-2
I am sending a message to
"newuser@messaging.cerner.com"(valid) and "manjiri2@messaging.cerner.com" (invalid)

maillog:
Oct  8 11:12:51 goonie postfix/smtpd[19685]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled
Oct  8 11:12:51 goonie postfix/smtpd[19685]: warning: 10.184.60.37: address not listed for hostname cern-nm019057.northamerica\
.cerner.net
Oct  8 11:12:51 goonie postfix/smtpd[19685]: connect from unknown[10.184.60.37]
Oct  8 11:12:51 goonie postfix/smtpd[19685]: 6E5CFF00A5: client=unknown[10.184.60.37]
Oct  8 11:12:51 goonie postfix/smtpd[19685]: 6E5CFF00A5: reject: RCPT from unknown[10.184.60.37]: 550 5.1.1 <manjiri2@messagin\
g.cerner.com>: Recipient address rejected: User unknown in virtual mailbox table; from=<mike@messaging.cerner.com> to=<manjiri\
2@messaging.cerner.com> proto=ESMTP helo=<CERN-NM019057>
Oct  8 11:12:51 goonie postfix/smtpd[19689]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled
Oct  8 11:12:51 goonie postfix/smtpd[19689]: warning: 10.184.60.37: address not listed for hostname cern-nm019057.northamerica\
.cerner.net
Oct  8 11:12:51 goonie postfix/smtpd[19689]: connect from unknown[10.184.60.37]
Oct  8 11:12:51 goonie postfix/smtpd[19689]: 7B0C1F00A5: client=unknown[10.184.60.37]
Oct  8 11:12:51 goonie postfix/smtpd[19689]: 7B0C1F00A5: reject: RCPT from unknown[10.184.60.37]: 550 5.1.1 <manjiri2@messagin\
g.cerner.com>: Recipient address rejected: User unknown in virtual mailbox table; from=<mike@messaging.cerner.com> to=<manjiri\
2@messaging.cerner.com> proto=ESMTP helo=<CERN-NM019057>
Oct  8 11:12:51 goonie postfix/smtpd[19685]: lost connection after RSET from unknown[10.184.60.37]
Oct  8 11:12:51 goonie postfix/smtpd[19685]: disconnect from unknown[10.184.60.37]
Oct  8 11:12:51 goonie postfix/smtpd[19689]: lost connection after RSET from unknown[10.184.60.37]
Oct  8 11:12:51 goonie postfix/smtpd[19689]: disconnect from unknown[10.184.60.37]

postconf -n:
alternate_config_directories = /etc/postfixNotifications
command_directory = /usr/sbin
config_directory = /etc/postfix
daemon_directory = /usr/libexec/postfix
data_directory = /var/lib/postfix
debug_peer_level = 2
home_mailbox = Maildir/
html_directory = no
mail_owner = postfix
mail_spool_directory = /var/mail
mailq_path = /usr/bin/mailq
manpage_directory = /usr/local/man
message_size_limit = 30720000
mynetworks_style = class
newaliases_path = /usr/bin/newaliases
queue_directory = /var/spool/postfix
readme_directory = no
recipient_delimiter = +
relayhost = [smtp1.cerner.com]
sample_directory = /etc/postfix
sendmail_path = /usr/sbin/sendmail
setgid_group = postdrop
transport_maps = regexp:/etc/postfix/transport
unknown_local_recipient_reject_code = 550
virtual_alias_maps = ldap:virtual_alias_maps
virtual_gid_maps = static:1004
virtual_mailbox_base = /var/mail/vhosts
virtual_mailbox_domains = messaging.cerner.com
virtual_mailbox_maps = ldap:virtual_mailbox_maps
virtual_uid_maps = static:1004


Sorry I am very new to postfix.

Thanks

Noel Jones-2 wrote
On 10/8/2010 10:34 AM, Manjiri wrote:
>
> Hello,
>
> I am interested to know if it is possible to configure postfix such that, if
> a message is sent to multiple recipients. Out of which, if one is an invalid
> address and other is a valid address. Then, right now the postfix rejects
> the mail with a 550 error (Recipient address rejected: User unknown in
> virtual mailbox table) and mail is not delivered to the valid address
> recipient. Can I customize / configure postfix to deliver the mail to the
> valid address recipient ?

Postfix normally acts as you request -- within a single
message, valid users are accepted and delivered, invalid users
are rejected.

Please show full (non-verbose) logs of a transaction with both
valid and invalid recipients, and your "postconf -n" output.


   -- Noel Jones
Reply | Threaded
Open this post in threaded view
|

Re: Customize / configure postfix with multiple recipients

Manjiri
Is it that the entire message is getting rejected because for some reason the postfix is not splitting it up per recipient ?
I have:
default_destination_recipient_limit = 50
smtp_destination_recipient_limit = $default_destination_recipient_limit
 
in the main.cf.default



Manjiri wrote
I am sending a message to
"newuser@messaging.cerner.com"(valid) and "manjiri2@messaging.cerner.com" (invalid)

maillog:
Oct  8 11:12:51 goonie postfix/smtpd[19685]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled
Oct  8 11:12:51 goonie postfix/smtpd[19685]: warning: 10.184.60.37: address not listed for hostname cern-nm019057.northamerica\
.cerner.net
Oct  8 11:12:51 goonie postfix/smtpd[19685]: connect from unknown[10.184.60.37]
Oct  8 11:12:51 goonie postfix/smtpd[19685]: 6E5CFF00A5: client=unknown[10.184.60.37]
Oct  8 11:12:51 goonie postfix/smtpd[19685]: 6E5CFF00A5: reject: RCPT from unknown[10.184.60.37]: 550 5.1.1 <manjiri2@messagin\
g.cerner.com>: Recipient address rejected: User unknown in virtual mailbox table; from=<mike@messaging.cerner.com> to=<manjiri\
2@messaging.cerner.com> proto=ESMTP helo=<CERN-NM019057>
Oct  8 11:12:51 goonie postfix/smtpd[19689]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled
Oct  8 11:12:51 goonie postfix/smtpd[19689]: warning: 10.184.60.37: address not listed for hostname cern-nm019057.northamerica\
.cerner.net
Oct  8 11:12:51 goonie postfix/smtpd[19689]: connect from unknown[10.184.60.37]
Oct  8 11:12:51 goonie postfix/smtpd[19689]: 7B0C1F00A5: client=unknown[10.184.60.37]
Oct  8 11:12:51 goonie postfix/smtpd[19689]: 7B0C1F00A5: reject: RCPT from unknown[10.184.60.37]: 550 5.1.1 <manjiri2@messagin\
g.cerner.com>: Recipient address rejected: User unknown in virtual mailbox table; from=<mike@messaging.cerner.com> to=<manjiri\
2@messaging.cerner.com> proto=ESMTP helo=<CERN-NM019057>
Oct  8 11:12:51 goonie postfix/smtpd[19685]: lost connection after RSET from unknown[10.184.60.37]
Oct  8 11:12:51 goonie postfix/smtpd[19685]: disconnect from unknown[10.184.60.37]
Oct  8 11:12:51 goonie postfix/smtpd[19689]: lost connection after RSET from unknown[10.184.60.37]
Oct  8 11:12:51 goonie postfix/smtpd[19689]: disconnect from unknown[10.184.60.37]

postconf -n:
alternate_config_directories = /etc/postfixNotifications
command_directory = /usr/sbin
config_directory = /etc/postfix
daemon_directory = /usr/libexec/postfix
data_directory = /var/lib/postfix
debug_peer_level = 2
home_mailbox = Maildir/
html_directory = no
mail_owner = postfix
mail_spool_directory = /var/mail
mailq_path = /usr/bin/mailq
manpage_directory = /usr/local/man
message_size_limit = 30720000
mynetworks_style = class
newaliases_path = /usr/bin/newaliases
queue_directory = /var/spool/postfix
readme_directory = no
recipient_delimiter = +
relayhost = [smtp1.cerner.com]
sample_directory = /etc/postfix
sendmail_path = /usr/sbin/sendmail
setgid_group = postdrop
transport_maps = regexp:/etc/postfix/transport
unknown_local_recipient_reject_code = 550
virtual_alias_maps = ldap:virtual_alias_maps
virtual_gid_maps = static:1004
virtual_mailbox_base = /var/mail/vhosts
virtual_mailbox_domains = messaging.cerner.com
virtual_mailbox_maps = ldap:virtual_mailbox_maps
virtual_uid_maps = static:1004


Sorry I am very new to postfix.

Thanks

Noel Jones-2 wrote
On 10/8/2010 10:34 AM, Manjiri wrote:
>
> Hello,
>
> I am interested to know if it is possible to configure postfix such that, if
> a message is sent to multiple recipients. Out of which, if one is an invalid
> address and other is a valid address. Then, right now the postfix rejects
> the mail with a 550 error (Recipient address rejected: User unknown in
> virtual mailbox table) and mail is not delivered to the valid address
> recipient. Can I customize / configure postfix to deliver the mail to the
> valid address recipient ?

Postfix normally acts as you request -- within a single
message, valid users are accepted and delivered, invalid users
are rejected.

Please show full (non-verbose) logs of a transaction with both
valid and invalid recipients, and your "postconf -n" output.


   -- Noel Jones
Reply | Threaded
Open this post in threaded view
|

Re: Customize / configure postfix with multiple recipients

Wietse Venema
In reply to this post by Manjiri
Manjiri:
>
> Hello,
>
> I am interested to know if it is possible to configure postfix such that, if
> a message is sent to multiple recipients. Out of which, if one is an invalid
> address and other is a valid address. Then, right now the postfix rejects
> the mail with a 550 error (Recipient address rejected: User unknown in
> virtual mailbox table) and mail is not delivered to the valid address
> recipient.

That is not how Postfix works.  Show evidence (an actual
SMTP session) if you believe otherwise.

        Wietse
Reply | Threaded
Open this post in threaded view
|

Re: Customize / configure postfix with multiple recipients

Wietse Venema
In reply to this post by Manjiri
Manjiri Namjoshi:
> I dont know how to collect the smtp conversation .. or how to log the
> smtp session. Can you give me some hints ?

You could telnet to the SMTP port and type the commands to
deliver one message to one good and one bad recipient.

You will discover that Postfix rejects the bad user and
accepts the good user, and that it will accept the message.

> Also, Is it that the entire message is getting rejected because
> for some reason the postfix is not splitting it up per recipient
> ?

You are mistaken. You have no evidence whatsoever that Postfix
rejects the entire message.

It is known that SOME SMTP CLIENT programs will give up delivering
a message when one recipient is not accepted, even when the other
recipients are good.

        Wietse
Reply | Threaded
Open this post in threaded view
|

Re: Customize / configure postfix with multiple recipients

Noel Jones-2
In reply to this post by Manjiri
On 10/8/2010 11:16 AM, Manjiri wrote:
>
> I am sending a message to
> "[hidden email]"(valid) and "[hidden email]"
> (invalid)
>
> maillog:
> Oct  8 11:12:51 goonie postfix/smtpd[19689]: connect from
> unknown[10.184.60.37]

The client connects.

> Oct  8 11:12:51 goonie postfix/smtpd[19689]: 7B0C1F00A5:
> client=unknown[10.184.60.37]

Postfix assigns a QUEUEID of 7B0C1F00A5.  This means one
recipient has been accepted.

> Oct  8 11:12:51 goonie postfix/smtpd[19689]: 7B0C1F00A5: reject: RCPT from
> unknown[10.184.60.37]: 550 5.1.1<manjiri2@messagin\
> g.cerner.com>: Recipient address rejected: User unknown in virtual mailbox
> table; from=<[hidden email]>  to=<manjiri\
> [hidden email]>  proto=ESMTP helo=<CERN-NM019057>

Postfix rejects the bad recipient.

> Oct  8 11:12:51 goonie postfix/smtpd[19689]: lost connection after RSET from
> unknown[10.184.60.37]
> Oct  8 11:12:51 goonie postfix/smtpd[19689]: disconnect from
> unknown[10.184.60.37]

The **CLIENT** disconnects after the error.  This is a client
issue, not a postfix issue.


> postconf -n:
...
Nothing remarkable in postconf output.


   -- Noel Jones