HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials

HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials (http://www.howtoforge.com/forums/index.php)
-   HOWTO-Related Questions (http://www.howtoforge.com/forums/forumdisplay.php?f=2)
-   -   Vacation/Autoreply plugin question using Virtual Users And Domains with Postfix (http://www.howtoforge.com/forums/showthread.php?t=4399)

triak 18th May 2006 23:27

Vacation/Autoreply plugin question using Virtual Users And Domains with Postfix
 
Hi, I'm a bit stuck here.
I have put up a production mailsystem, and now I need to implement a Vacation/Autoreply feature.
The setup is created from Falco's exellent how-to: "Virtual Users And Domains With Postfix , Courier And MySQL (+ SMTP-AUTH, Quota, SpamAssassin, ClamAV)", with the difference of sql-server running on a another host.

I have setup Squirrelmail for webmail access and it works like a charm.Squirrelmail has a plugin called "Courier Vacation" that creates text files containing information like away-message, cc-address etc. in the virtual users Maildir directory.
There's a maildroprc file that test's the existence of theese files and accts accordingly. Mail is either autoreplyed or not, kept fowarded to local mailbox or deleted.

My humble question is: How can I pipe the mails trough maildrop after they have been scaned for viruses etc. What entryes to master.cf main.cf?
I figure Falco's setup uses procmail for final delivery, can i configure maildrop to do the same thing with this extra funcionality?

TIA: Johannes Kullberg - TMI TRIAK

A link to the plugin: http://www.squirrelmail.org/plugin_view.php?id=187

falko 19th May 2006 16:24

I don't know if this works, but you can get an autoresponder by installing sqwebmail: http://www.howtoforge.com/forums/sho...ight=sqwebmail

triak 20th May 2006 10:33

Yes but...
 
We have allready many customers using the Squirrelmail package. It's not an option to start using some other webmail. I really need to get this one working with the maildrop script. Falco, does procmail do the final delivery to the mailbox? Could it be possible to have it done by maildrop?
The problem with this one is that the system is in production and I can't go the "trial & error" way. I need a solution that works out of the box :=)

-J-

todgerme 21st May 2006 14:12

you have two options:

forget procmail!

a) follow the maildrop filering guide and implement an autoresponder by piping the mail from maildrop .mailfilter file or

b) take a look at Yaa (http://freshmeat.net/projects/yaa/).

I have plans to cover these very soon and write a guide for autoresponders so if you can sit tight, i'll try and get something up asap for you.

triak 5th June 2006 20:35

Vacation using maildrop allmoast working....
 
2 Attachment(s)
The Squirrelmail courier-vacation plugin works and a global maildroprc instructs maildrop to read the users vacation directory for vacation messages. The "forward" and "keep messages" functions are working. BUT! the autoreply itself to the sender is not working for some strange reason. I suspect it has someting to do with maildrop marco's. The orginal from address disappears. Heres a clip from the mail log:

Jun 5 20:01:59 localhost postfix/qmgr[21568]: 486EBF0113: from=<triak@abc.fi>, size=1246, nrcpt=1 (queue active)
Jun 5 20:01:59 localhost amavis[20433]: (20433-08) Passed, \n<triak@abc.fi> -> <triak@xyz.fi>, Message-ID: <13665903.48051149526706011.JavaMail.triak@abc.fi> , Hits: -1.826

Jun 5 20:01:59 localhost postfix/pickup[21567]: 62907F0116: uid=5000 from=<>
Jun 5 20:01:59 localhost postfix/cleanup[22065]: 62907F0116: message-id=<20060605170159.62907F0116@mail.abc.fi>
Jun 5 20:01:59 localhost postfix/pipe[22082]: 486EBF0113: to=<triak@xyz.fi>, relay=maildrop, delay=0, status=sent (axyz.fi)
Jun 5 20:01:59 localhost postfix/cleanup[22065]: 62907F0116: to=<unknown>, relay=none, delay=0, status=bounced (No recipients specified)

Postfix is trying to send the replymail, but does not know the recipient.
The problem is obvious, but how can I fix this so that the correct string is passed back to postfix?
I will attach my maildroprc and master.cf configuration files.
The maildrop filtering is added to Falco's virtual system using this howto:
http://www.howtoforge.com/postfix_mailfilter

The holidays here in Finland are just starting and I'm in a bit of trouble here...
Plz help a bit :=)

triak 7th June 2006 09:25

Nobody knows the answer?
 
I have been searching maildrop and postfix documents, googling my ass off,
asking friends etc. ... Does anybody know how to deal with this problem. My customer's are starting to get stressed, and I really need to get this vacation thing working.....
TIA: Johannes

falko 7th June 2006 14:23

It seems as if the recipient is not set correctly in

Code:

maildrop  unix  -      n      n      -      -      pipe
  flags=DRhu user=vmail argv=/usr/local/maildrop/bin/maildrop -d ${user}@${nexthop} ${extension} ${recipient} ${user} ${nexthop} ${sender}

in master.cf. What happens if you replace ${recipient} with a hard-coded email address (e.g. yours) for testing purposes? Do you receive the autoreply emails then?

triak 7th June 2006 15:15

Nope, does not help
 
Changing the recipient macro does not affect anyting.
The log is exactly the same and no autoreply address is beeing delivered to cleanup daemon.
How is the macro's forwarded to maildrop? $1 $2 $3 etc. Maybe the numbers are getting mixed up....

falko 7th June 2006 15:52

Did you restart Postfix?
What's in master.cf now?

triak 7th June 2006 16:37

Tried both reload and restart
 
Now I have the following string:

maildrop unix - n n - - pipe
flags=hu user=vmail argv=/usr/local/maildrop/bin/maildrop -d ${user}@${nexthop} ${extension} triak@abc.fi ${user} ${nexthop} ${sender}

$1 is ${user}@${nexthop}
$2 is ${extension}

Is this the way macros get distributed to maildrop?


All times are GMT +2. The time now is 18:51.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.