
jasons at adventureaquarium
Feb 11, 2010, 8:42 AM
Post #11 of 12
(2811 views)
Permalink
|
> -----Original Message----- > From: Kyle Wheeler [mailto:kyle-qmail [at] memoryhole] > Sent: Thursday, February 11, 2010 11:22 AM > To: qmail [at] list > Subject: Re: Forward Email by address > > > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA256 > > On Thursday, February 11 at 10:47 AM, quoth Jason Staudenmayer: > >Send log: > >2010-02-11 10:35:53.596874500 info msg 183747: bytes 2434 > from <jasons [at] adventureaquarium> qp 26339 uid 502 > >2010-02-11 10:35:53.599350500 starting delivery 179050: msg > 183747 to local forwardme-testflow [at] adventureaquarium > >2010-02-11 10:35:53.599394500 status: local 2/10 remote 0/15 > >2010-02-11 10:35:53.603253500 delivery 179049: success: did_1+0+0/ > >2010-02-11 10:35:53.603302500 status: local 1/10 remote 0/15 > >2010-02-11 10:35:53.610868500 delivery 179050: success: r > >2010-02-11 10:35:53.610916500 status: local 0/10 remote 0/15 > > > >I'm seeing a connection atempt to the new server, and if it > did forwardme-testflow doesn't exisit. I think I have > something wrong here. > > > >.qmail-forwardme-default: > >|qmail-remote 10.252.0.2 ${SENDER} ${EXT}@adventureaquarium.com > > Strictly speaking, that IP address *SHOULD* be inside brackets > (according to the qmail-remote man page), like this: > > |qmail-remote [10.252.0.2] ${SENDER} ${EXT}@adventureaquarium.com > > Like I said, though, using qmail-remote directly will result in two > things: 1. weird log messages (e.g. the "success: r") and 2. failures > won't be recognized properly. > > To do it reliably, you need a wrapper to deal with the way that > qmail-remote handles reporting the outcome of a delivery attempt. > > Since nobody seems interested in that part of what I wrote, here's a > simple wrapper script that would do such a thing: > > #!/bin/sh > /var/qmail/bin/qmail-remote "$@" | \ > while read -d $'\0' result ; do > case "$result" in > K*) # success > echo ${result:1} > exit 0;; > Z*) # temporary failure > echo ${result:1} > exit 71;; > D*) # permanent failure > echo ${result:1} > exit 31;; > esac > done > > (and, for what it's worth, that's a slight modification of a script > that's in my "Qmail Quickstarter" book) > > ~Kyle > - -- > Last comes the beverage of the Orient shore, Mocha, far off, the > fragrant berries bore. Taste the dark fluid with a dainty lip, > Digestion waits on pleasure as you sip. > -- Thanks Kyle, I'll try the script and fix the brackets (I wasn't sure if they should stay). What about the address itself though? Is there any way to get it to forward without the forwardme- part prefixed? THANKS Jason ..><((((>
|