Hello Clifford,
I must admit that your bounce looks very peculiar...
Have you tried either of these instead? I have used qmail-inject in
scripts like this before, and never had any difficulties....
open(MAIL, "|$mailprog -h ");
open(MAIL, "|$mailprog -a $email");
Do you get the same bounce?
If you continue to have troubles, show us your /var/qmail/control/*
files...best of luck.
-Martin
--
Martin A. Brown --- Wonderfrog Enterprises --- [EMAIL PROTECTED]
On Fri, 17 Dec 1999, clifford thurber wrote:
-->Hello,
-->I made a post earlier to this list open a PERL program I have written which
-->basic opens one file handle ot a CSV file containing usernames and email
-->adresses parses them and then sends users mail by writing to a file handle
-->opened to qmail. Here is the snippet of code that achieves this:
-->
-->$mailprog = "/usr/local/var/qmail/bin/qmail-inject";
-->
-->open(MAIL, "|$mailprog");
-->
-->print MAIL "To: $email\n";
-->print MAIL "From: $from\n";
-->print MAIL "Subject:$subject\n";
-->print MAIL "MIME-Version: 1.0\n";
-->print MAIL "Content-Type: text\/html\; charset\=us-ascii\;
-->name=\"newsl.html\"\n";
-->print MAIL "Content-Transfer-Encoding: 7bit\n";
-->print MAIL "Content-Disposition: inline\; filename=\"newsl.html\"\n";
-->print MAIL "Content-Base: http:\/\/www\.liveuniverse\.com\n";
-->
-->
-->print MAIL " etc .....
-->close(MAIL);
-->
-->The problem is that every message is being bounced back b/c somewhere qmail
-->is appending the name of our machine(snapper.raremedium.com) onto the
-->recipients e-mail address. It then sees the name of our box and decideds
-->this is a local delivery which is of course undeliverable as we are trying
-->to send mail to a list of remote users. Can anyone help me with this. For
-->instance below my script assigned the value $email ="[EMAIL PROTECTED]"
-->which is correct. Now when qmail recieves it, it decides to append the name
-->of our machine (snapper.raremedium.com) onto this address. Can someone
-->please give me some insight into this. I think I am going crazy. Below is
-->the output of the mail log. Anyway thanks in advance.
-->
-->
-->Dec 16 14:39:23 ketel-1 qmail: 945373163.430257 starting delivery 20110:
-->msg 721
-->291 to local [EMAIL PROTECTED]@snapper.raremedium.com
-->
-->and then later on the logfile I will see the failure message with :
-->
-->.... Dec 16 14:43:21 ketel-1 qmail: 945373163.430257 delivery 20110:
-->failure: Sorry,_
-->no_mailbox_here_by_that_name._(#5.1.1)/
-->
-->Clifford Thurber
-->Web Systems Administrator
-->LiveUniverse.com
-->[EMAIL PROTECTED]
-->565 5th Ave. 29th Fl.
-->New York, NY 10017
-->Ph:212 883 6940 (131)
-->Fax:212 856 9134
-->