Comments on How To Set Up A Postfix Autoresponder With Autoresponse

How To Set Up A Postfix Autoresponder With Autoresponse Autoresponse is an autoresponder for the Postfix MTA. It allows you to create autoresponder messages for email accounts from the shell and also by emailing the autoresponder text to a certain email address.

32 Comment(s)

Add comment

Please register in our forum first to comment.

Comments

By:

will this work with the "Perfect Ubuntu Server 8.10"

--Steve

By: Brendan Lally

Does NOT work with non virtual user mail accounts.

By: Jun

 

Jun 18 15:14:19 x postfix/smtpd[15108]: NOQUEUE: reject: RCPT from x: 550 5.1.1 <[email protected]>: Recipient address rejected: User unknown in virtual mailbox table; from=<[email protected]> to=<[email protected]> proto=ESMTP helo=<220mmjpchang>

 

Here is error from our log...

 

Thanks

By: JQ

I am using local user and virtual users. autoresponse seems to work - I got an email response. But, the response email is empty. No subject, no content. I have created enable a response file for user actually. What is wrong?

By: JustinHoMi

I'm having the same problem. The autoresponses are blank. Did you ever figure this out?

By: PJ

I set this up, and it works great.  However, I need to integrate Amavis and SpamAssassin according to these instructions, flurdy.com/docs/postfix/, but I can't get them all to work together.  How can I accomplish this?  Thanks

By: Anonymous

you could try iRedMail (google it)

it installs postfix, dovecot, anti virus, anti spam, etc etc the lot.

all well documented, worked great for me...

By: Gatis Rumbens

I can confirm. It's not working with AMAVIS-NEW. It seems that autoresponder don't queue message to next content filter. Maybe is neccasary change something in master.cf ..after pipe to external auoresponse script it should be returned back.

By: catalin bargaoanu

works like a charm... good job...

BR

By: MDH

Hi, one little issue.

The autoreposnder replies to the FROM address of the orignal sender. This is an issue when there is some aliasing going on (ie he REPLY TO address differs to the FROM address).

Do you know how I could force the autoresponder to always use the REPLY-TO address?

Thanks in advance

 

By: MDH

I installed iRedMail (centos+postfix-dovecot) server then added autoreponse as per your instructions, and within 20 minutes from starting the whole process, I had a fully functional Enterprise ready email sever with autoreponse configured at the sametime as mailbox creation.

awesome job thanks!

By:

 When I test using emailsetup autoresponse,  the maillog shows:
 
Aug 26 16:20:31 gamma postfix/smtpd[5491]: NOQUEUE: reject: RCPT from gamma.sjgeophysics.com[127.0.0.1]: 550 5.1.1 <[email protected]>: Recipient address rejected: User unknown in virtual mailbox table; from=<[email protected]> to=<[email protected]> proto=ESMTP helo=<192.168.123.42>
 
My mail server use SMTP_AUTH. If I send a normail email, log shows:
 Aug 26 16:18:33 gamma postfix/smtpd[5249]: connect from gamma.mydomain.com[127.0.0.1]
Aug 26 16:18:33 gamma postfix/smtpd[5249]: 252102D70081: client=gamma.mydomain.com[127.0.0.1], sasl_method=LOGIN, [email protected]
Aug 26 16:18:33 gamma postfix/cleanup[5273]: 252102D70081: hold: header Received: from 192.168.123.42 (gamma.mydomain.com [127.0.0.1])??by gamma.mydomain.com (Postfix) with ESMTP id 252102D70081??for <[email protected]>; Thu, 26 Aug 2010 16:18:33 -0700 (PD from gamma.mydomain.com[127.0.0.1]; from=<[email protected]> to=<[email protected]> proto=ESMTP helo=<192.168.123.42>
Aug 26 16:18:33 gamma postfix/cleanup[5273]: 252102D70081: message-id=<[email protected]>
Aug 26 16:18:33 gamma postfix/smtpd[5249]: disconnect from gamma.mydomain.com[127.0.0.1]
 
 Any help? 
 

By: Anonymous

Don't know if it's still important but I searched for an autoreply extensions and found this script very nice. Unfortunately I received the same error "550 unknown recipient..." and went through all parameters in main.cf and finally I found the solution: address extensions must be enabled for this feature to work!

Just uncomment the entry "recipient_delimiter = +" in the file main.cf (in my main.cf I found it on line 426) and restart postfix and then the email-interface for autoresponse is working fine.

Hope this helps all those who are still searching for a solution...

By: Rias A.

Use vi to change line #156 of the script (/usr/local/sbin/autoresponse) to the following line, if you want to replace all occurrences of SENDEREMAIL in the autoresponse text with the sender's e-mail address (variable SENDER):

(cat "${RESPONSES_DIR}/${RECIPIENT}") | sed -e "0,/^$/ { s/^To:.*/To: <${SENDER}>/ }" -e '0,/^$/ { /^Date:/ d }' | ${SENDMAIL} -i -f "${RECIPIENT}" "${SENDER}"

... becomes:

(cat "${RESPONSES_DIR}/${RECIPIENT}") | sed -e "0,/^$/ { s/^To:.*/To: <${SENDER}>/ }" -e "{ s/SENDEREMAIL/${SENDER}/ }" -e '0,/^$/ { /^Date:/ d }' | ${SENDMAIL} -i -f "${RECIPIENT}" "${SENDER}"
( I deliberately used the keyword SENDEREMAIL and not SENDER in case the keyword SENDER comes up inside the text in a different context.)

This change becomes in handy if you want the autoresponse text to contain unsubscribe links etc.. So your autoresponse text could look something like this:

Thank you... blah blah... unsubscribe here: http://www.mydomain.com/unsub.php?id=SENDEREMAIL

And it will be becomes this when it gets sent out:
Thank you... blah blah... unsubscribe here: http://www.mydomain.com/[email protected]


I couldn't figure out how to contact Charles from nefaria.com to ask him if he wants to include this in the next version. If you find him, please ping him :-)

By: Remsztorm

Great work, thanks. I spend lot of time to find this.

 

 

By: nibble

Hi,
 
I followed the tutorial and everything works except the abilitation of autoresponse email.  
when i sending the email EX: "[email protected]", the mail is delivered and see it .. but I do not see any email autoresponse. from shell it works perfectly. 
 
Best Regards,
Luca 

By: Luca

Hi,
I followed the tutorial and everything works except the abilitation of autoresponse email. 
when i sending the email EX: "[email protected]", the mail is delivered and see it .. but I do not see any email autoresponse. from shell it works perfectly. 

Best Regards,
Luca

By: Luthfi

I have been used iRedmail on my system, and then try to Install this script....

and it's Works like magic, Thanks brother for your Great Tutorial.

By: mfable

everything works perfectly, with all instructions from Falco

By: Lucian

Works as described. Many Thanks !

By: Alexander

Help Help ! www.nefaria.com/scriptz/autoresponse-1.6.3.tar.gz returns 404.. and i  found no archived copy, only project officially ending notification saved on web.archive.org  :(  can somebody share it or 1.6.2 let's say? or provide an alive link...  

tia!

 

 

By: Jan Wikholm

One small point: 

you must add each user account to the autoresponse group, e.g. as follows for the system user falko:

usermod -G autoresponse falko 

Using usermod -G without -a will replace the groups. Please also use -a if you want to append groups.

By: Albert

Hi,

I was wondering why am i getting this issue wont auto reply?

Reporting-MTA: dns; mail.mydomain.com.coX-Postfix-Queue-ID: 500ACD40C88X-Postfix-Sender: rfc822; [email protected]: Fri, 14 Oct 2016 23:48:54 -0500 (COT)Final-Recipient: rfc822; [email protected]: failedStatus: 5.1.1Diagnostic-Code: X-Postfix; unknown user: "srs0"

 

Thank you

 

By: Margit

Althougt I use a smtp server with authentication it doesn't work for me. In the log I see the following message:

 Unauthenticated attempt to set autoresponse message for [email protected] from xx.xx.xx.xx!

What's going wrong?

Regards

Margit

 

 

By: Margit

I' ve found why it does not work: I have 2 mail servers: the first only authenticates and sends the mail to the second, the "real" smtp server.

Is there a solution for my problem?

Thanx and regards

Margit

 

By: Kurt Wagner

Hey Luca

Did you ever get that fixed to where you can get it to toggle from e-mail?

By: Michael DeMutis

You can edit the auto responders and their subjects in /var/spool/autoresponse/responses  .. Makes things a LOT easier knowing this!

By: Tung

Dear falko !

Thanks for your instruction this. 

I have done as your instrutions. 

The script work ok for shell, but the system can't work at step 4

Creating/Deleting Autoresponder Messages By Email

When i email to [email protected], i can receive the email [email protected] with the same content for [email protected], no any content : 

Autoresponse enabled for [email protected] by SASL authenticated user: [email protected] from: 192.168.0.200

or 

Autoresponse disabled for [email protected] by SASL authenticated user: [email protected] from: 192.168.0.200

master.cf:

.....

dovecot   unix  -       n       n       -       -       pipe

  flags=DROhu user=vmail:vmail argv=/usr/libexec/dovecot/deliver -f ${sender} -d ${user}@${nexthop}

 

 

autoresponder unix - n n - - pipe

 

     flags=Fq user=autoresponse argv=/usr/local/sbin/autoresponse -s ${sender} -r ${recipient} -S ${sasl_username} -C ${client_address}

Please help me.

Thanks

By: Peter

Hi,

we have two kind of mail addresses as there are more than one domain

the first is in /etc/aliases - there autoresponse works perfect

second is in /etc/postfix/virtual - does not return autoresponse at all

can you please advise on that

thanks in advance

By: Dieter

It is very sad to see all this question which are exactly the same problem i have.

Sending an email does not work, i have AUTH, yes ... but still it gets rejected by 

Server error: '550 5.1.1 <[email protected]>: Recipient address rejected: User unknown in local recipient table'

Who found out what is missing? Do i need to add all addresses with +autoresponse somewhere ?

By: Michael

Still a valid howto in 2020. If you have your smtp in smtps only then you need to add the parameter

also to master.cf

smtps     inet  n       -       y       -       -       smtpd

-o ...

-o ...

-o content_filter=autoresponder:dummy

also the valid link to the newer version of autorespond is:

 

https://www.nefaria.com/scriptz/autoresponse-1.6.3.tar.gz

 

This howto works flawless with postfix 3.1 and dovecot 1.2.2 on Ubuntu 16.04

 

By: Greg

Will this work in combination with Postfixadmin?