
coyote at inc
Nov 26, 2009, 5:31 AM
Post #3 of 4
(1583 views)
Permalink
|
|
Re: qmail-smtpd => missing link => qmail-send
[In reply to]
|
|
If you send a message to a qmail server, and you are successful, than you will se: ok_250_XXXXXXXXX_qp_12331 <= and this is the queue-pid number, what is comes up in the qmail-send logs. If I make a connection to an qmail smtpd szerver, than I communicate with the qmail-smtpd program, and this program sends back to me the answers. From this, It seems to me, that qmail-smtpd sees the queue PID, which can be the missing link. Only what we have to do, to somehow log this into the qmail-smtpd log. (whitout mailforont, still don't like the idea) This is right or not? Peter, Szekeres Bruce Guenter írta: > On Wed, Nov 11, 2009 at 06:43:45PM +0100, CoyoteTM-INC-Szeki wrote: >>> Easily, and not very weird. I do it in mailfront. Add code to dump the >>> accept_buf to stderr in acceptmessage() in qmail-smtpd.c >> So it is possible to get the qmail-queue pid info at the stage, when >> qmail-smtpd fires it up. > > Certainly. It's the "qp" variable in smtp_data. > >> As I have read and understand so far, mailfront replaces qmail-smtpd, >> which idea I fear of. (or makes a new frontend for qmail-smtpd?) > > mailfront replaces qmail-smtpd, yes, as well as qmail-qmqpd and > qmail-qmtpd, and qmail-popup and qmail-pop3d. > >> Is it a hard work to modify qmail-smtpd.c to log that info? (without >> mailfront) > > Yes. In acceptmessage, after each "out" call, add something like: > > write(2,X,str_len(X)); > > where "X" is the parameter to out. Alternately, you could modify the > out function to write to stderr as well, possibly with another substdio > buffer. This will let you see all SMTP responses, for good and bad (can > result in log spam). > > PS. this should go back to the qmail mailing list. >
|