Mail forwarding loop while restoring old mails
Hi,
I imported some old mails using pilerimport command and accessed the mails on mail piler. But when I try to restore an old mail, I get the following error in /var/log/mail/log :
Jun 13 16:16:38 mail postfix/pipe[3828]: 90E194271: to=xxx@xxx.com, relay=dovecot, delay=1.1, delays=1.1/0.01/0/0.04, dsn=5.4.6, status=bounced (mail forwarding loop for xxx@xxx.com)
piler -V is as follows:
piler 0.1.24-master-branch, build 836, Janos SUTO sj@acts.hu
Build Date: Fri May 30 16:16:00 IST 2014 ldd version: ldd (Debian EGLIBC 2.13-38+deb7u1) 2.13 gcc version: gcc version 4.7.2 (Debian 4.7.2-5) Configure command: ./configure --localstatedir=/var --with-database=mysql --enable-starttls --enable-tcpwrappers
Comments (13)
-
repo owner -
reporter Yes I have piler and postfix on the same host. I am able to restore new mails without any problem. Only the mails that were imported are the ones that are giving that error message.
-
reporter In all the mails that are giving status=bounced, I noticed that the message header contains "Delivered-to: xxx@xxx.com" line. I don't know if that might be of any help. But just making you aware of it.
-
repo owner Try the following: edit config-site.php, and set SMARTHOST to point to your mail server where your mailboxes are.
-
reporter It was already set to point to the mail server which is the localhost itself.
Many online resources told me that it is due to the Delivered-to: xxx@xxx.com line in the message header that this forwarding loop occurs. Could you please help on how to resolve this issue?
-
reporter Just FYI, I tried to restore a mail to an address that was not mentioned in the Delivered-To: line. That mail was restored with a status= sent. Its happening only to those id's that are mentioned in the Delivered-To line.
-
repo owner Try to set the following in config-site.php:
$config['RESTORE_EMAILS_AS_ATTACHMENT'] = 1;
This causes the gui to send the restored email as an attachment.
-
reporter -
reporter It didn't help. I'm getting the same error message when I try to restore the mail.
-
repo owner Ehh, I was wrong: 0.1.24 doesn't have this feature. You need the master branch to try it.
Btw. how is it possible that some emails have and some don't have the "Delivered-to: " header?
-
reporter Isn't mine already master branch'd? If not can you give me the link to do so?
Well, I've been told that prior to 2010, they were using a different server and post 2010 they used a new server and only post-2010 are all the mails having the "Delivered-to:" header.
-
reporter Its working now. I did the following:
create /etc/postfix/header and add the following into the file: /^Delivered-To:.*/ REPLACE X-Bad-Delivered-To: removed
edit main.cf and add the following line: header_checks = regexp:/etc/postfix/header
then restart postfix.
This is working.
-
reporter - changed status to resolved
- Log in to comment
What is your setup like? Do you have postfix and piler on the same host?