Current User: Guest Login Register
Please consider registering


Register? | Lost Your Password?

Search Forums:


 






Minimum search word length is 4 characters – Maximum search word length is 84 characters
Wildcard Usage:
*  matches any number of characters    %  matches exactly one character

Postfix Vacation Autoresponder problem

Reply to Post Add a New Topic
UserPost

8:30 am
March 6, 2011


terry

Member

posts 3

been trying for quite a while, never succeed though.

trying on centos 5.5 postfix 2.6/2.7, dovecot 1.2/2.0, openldap 2.3

using openldap to create virtual mailbox (alias user@example.com->user@example.local)

and using recipient_bcc_maps for mysql-vacation.cf for vacation auto response.

by turning on test on, the vacation script will auto reply, turn off test mode, no reply.

using squirrelmail plugin for user to setup vacation (out of office), and can see from mysql database, vacation table got the vacation row inserted.

maillog only show

postfix/pipe[1533]: B72244AAA76: to=<tuta#xxx.com.my@vacation.invalid>, relay=vacation, delay=8.2, delays=8.1/0.01/0/0.12, dsn=2.0.0, status=sent (delivered via vacation service)

if test mode is on, maillog will show 2 actions

server2 postfix/pipe[2157]: C4E924AAA76: to=<tuta#xxx.com.my@vacation.invalid>, relay=vacation, delay=4.3, delays=4.1/0.01/0/0.18, dsn=2.0.0, status=sent (delivered via vacation service)

server2 postfix/virtual[2158]: E204F4AAA76: to=<support@xxx.local>, orig_to=<support@xxx.com.my>, relay=virtual, delay=8, delays=8/0/0/0.01, dsn=2.0.0, status=sent (delivered to maildir)

 

and i will receive the auto reply email with subject test mode.

please help and thanks a lot.

9:39 am
March 8, 2011


consultant

Admin

posts 353

Hi terry,

 

1. Verify if mysql-vacation.cf is working using

 

postmap -q user@example.local mysql:/etc/postfix/mysql-vacation.cf

Replace user@example.local with the email address where you have configured a vacation message.
The output should contain an email address for the vacation.invalid domain. 

2. If it works, try sending an email to user@example.com

5:34 am
March 9, 2011


terry

Member

posts 3

[root@server2 postfix]# postmap -q terry@xxx.com ldap:/etc/postfix/ldap-alias.cf

terry@xxx.local

[root@server2 postfix]# postmap -q terry@xxx.local ldap:/etc/postfix/ldap-user.cf

terry/
[root@server2 postfix]# postmap -q terry@xxx.com mysql:/etc/postfix/mysql-vacation.cf

terry#xxx.com@vacation.invalid

[root@server2 postfix]# postmap -q terry@xxx.local mysql:/etc/postfix/mysql-vacation.cf

<no result>

testing below with test mode off, however no auto reply

test sending email from support@xxx.com to terry@xxx.com, maillog show 3 entry

server2 postfix/virtual[31496]: E61414AAA78: to=<terry@xxx.local>, orig_to=<terry@xxx.com>, relay=virtual, delay=4.6, delays=4.5/0/0/0.06, dsn=2.0.0, status=sent (delivered to maildir)

server2 postfix/pipe[31676]: E61414AAA78: to=<terry#xxx.com@vacation.invalid>, relay=vacation, delay=4.7, delays=4.5/0.02/0/0.13, dsn=2.0.0, status=sent (delivered via vacation service)

server2 postfix/qmgr[29479]: E61414AAA78: removed

test sending email from support@xxx.com to terry@xxx.local, maillog show 2 entry

server2 postfix/virtual[31789]: 01BD64AAA78: to=<terry@xxx.local>, relay=virtual, delay=4.4, delays=4.4/0.01/0/0.02, dsn=2.0.0, status=sent (delivered to maildir)

server2 postfix/qmgr[29479]: 01BD64AAA78: removed

test sending email from support@xxx.com to terry#xxx.com@vacation.invalid, maillog show 2 entry

server2 postfix/pipe[31933]: 5A1C84AAA78: to=<terry#xxx.com@vacation.invalid>, relay=vacation, delay=4.6, delays=4.5/0.01/0/0.15, dsn=2.0.0, status=sent (delivered via vacation service)

server2 postfix/qmgr[29479]: 5A1C84AAA78: removed

 

as you can see in postfix after delivered via vacation service,

the mail is removed from queue and no more further action, where should i trace?

8:46 am
March 10, 2011


consultant

Admin

posts 353

Hi terry,

 

Vacation is not working because of your alias which changes terry@xxx.com to terry@xxx.local and vacation contains terry@xxx.com

 

To fix the problem, replace /etc/postfix/mysql-vacation.cf with the one below so that it will change terry@xxx.local back to terry@xxx.com

 

host = localhost
user = postfix
password = postfix
dbname = postfix
query = SELECT email FROM vacation WHERE email = '%u@%2.com' AND active = '1'
result_format = %u#%d@vacation.invalid

Reply to Post

Reply to Topic:
Postfix Vacation Autoresponder problem

Guest Name (Required):

Guest Email (Required):

Smileys
Confused Cool Cry Embarassed Frown Kiss Laugh Smile Surprised Wink Yell
Post New Reply

Guest URL (required)

Math Required!
What is the sum of:
6 + 1
   


About the Linux Mail Server Setup and Howto Guide Forum

Forum Timezone: America/New_York

Most Users Ever Online: 60

Currently Online:
23 Guests

Currently Browsing this Topic:
1 Guest

Forum Stats:

Groups: 2
Forums: 5
Topics: 343
Posts: 1062

Membership:

There are 966 Members
There have been 91 Guests

There is 1 Admin

Top Posters:

shanmugasundaram s – 46
Kendermin – 15
Ginger – 14
bighorn – 14
iron_michael86 – 12
Raminda – 11

Recent New Members: waveney, achal, niesul14, hesaum, sreevinodss, nasonov

Administrators: consultant (353 Posts)