• Please be aware: Kaspersky Anti-Virus has been deprecated
    With the upgrade to Plesk Obsidian 18.0.64, "Kaspersky Anti-Virus for Servers" will be automatically removed from the servers it is installed on. We recommend that you migrate to Sophos Anti-Virus for Servers.
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

Postfix: Not delivering messages with recipient delimiter

schlimpf

Basic Pleskian
Hi,

i already reported my problem on stackoverflow here but I think this is a plesk problem.

Description of my problem:

I have set the postfix configuration recipient_delimiter = + so that E-Mails to [email protected] are delivered in my [email protected] mailbox.
When I try to send Mails to the address with the delimiter, the mail is not apperaing in my mailbox, nor is it being delivered into my catchall mailbox (whereas [email protected] and also [email protected] are).

In the logfiles it says:

Code:
Nov 18 11:13:47 xxxxxxx postfix-local[6109]: cannot chdir to mailname dir myname+test: No such file or directory
Nov 18 11:13:47 xxxxxxx postfix-local[6109]: Unknown user: [email protected]
Nov 18 11:13:47 xxxxxxx postfix/pipe[6093]: 1AB8A2FE0903: to=<[email protected]>, relay=plesk_virtual, delay=0.27, delays=0.2/0/0/0.06, dsn=2.0.0, status=sent (delivered via plesk_virtual service)
Nov 18 11:13:47 xxxxxxx postfix/qmgr[5791]: 1AB8A2FE0903: removed
I though it may be a problem with the forward_path, but I think it is correctly set:

forward_path = $home/.forward${recipient_delimiter}${extension}, $home/.forward

The problem may be the following:
The plesk_virtual service has returned "successful delivery" (process
exit status 0) to Postfix, therefore Postfix deletes the queue
file.

Instead, the plesk_virtual service should have returned "user
unknown" (process exit status 67) to Postfix. Process exit status
codes are defined in /usr/include/sysexits.h.
(Found here)

Thanks

// EDIT: I found this forum post: http://forum.parallels.com/showthre...-with-recipient-delimiter&p=708246#post708246 Is it possible that this issue is known for 5 years and could not be resolved yet? I dont think that this is a big deal
 
Last edited:
I migrated to a plesk server a few days ago and just noticed that the bounce processing for some of the mailing list apps stopped working since they used verp. I have managed came up with a work around, although I am not entirely sure if it would not get overwritten with an update.

Add to the bottom of the main.cf:
recipient_canonical_classes = envelope_recipient
recipient_canonical_maps = regexp:/etc/postfix/recipient_canonical_map


and created a regex map file /etc/postfix/recipient_canonical_map containing:
/^(.+)\+.+@(.*)/ ${1}@${2}

The caveat is that is does not bounce non-existent addresses... which, from a dictionary attack POV, might not be too entirely bad.

Curious if the Plesk folks might see an unforeseen problem..
 
Just figured I'd share this, this is actually really easy to get to work. The problem with the identifier is that the plesk-virtual mail delivery system is going to look for a directory with the plus-address in it, rather than falling back to directory without an identifier.

Just open up /etc/postfix/master.cf, scroll down to:
Code:
plesk_virtual unix - n n - - pipe flags=DORhu user=popuser:popuser argv=/usr/lib/plesk-9.0/postfix-local -f ${sender} -d ${recipient} -p /var/qmail/mailnames

Now replace "${recipient}" with:
Code:
${user}@${nexthop}

Restart all mail related services and you're ready to go!
 
HEllo
may be we can use a script to replace the line with a cron like

Code:
#!/bin/bash

OLD_REGEX="plesk_virtual unix - n n - - pipe flags=DORhu user=popuser:popuser argv=\/usr\/lib\/plesk-9\.0\/postfix-local -f \${sender} -d \${recipient}"

NEW="plesk_virtual unix - n n - - pipe flags=DORhu user=popuser:popuser argv=\/usr\/lib\/plesk-9.0\/postfix-local -f \${sender} -d \${user}@\${nexthop}"

sed -i "s/$OLD_REGEX/$NEW/g" /etc/postfix/master.cf
 
Back
Top