Gossamer Forum
Home : Products : Gossamer Links : Discussions :

Bulk Mail error

Quote Reply
Bulk Mail error
I'm testing out the bulk mailer that comes with Links SQL but i'm getting an error... However, the mailer works fine for the e-mailing of validation codes to new users.

Here's the debug log:

Sending emails ...

GT::Mail::BulkMail Error: From address (`casti@casti.ca') rejected by server (501 5.1.7 where is <...> in that?)

A fatal error has occured:From address (`casti@casti.ca') rejected by server. at GT::Mail::BulkMail::_smtp_send line 42, chunk 13.
Please enable debugging in setup for more details.

Stack Trace
======================================
Links (300): Links::environment called at d:/InetPub/wwwroot/cgi-bin/admin/Links.pm line 450 with no arguments.Links (300): Links::fatal called at GT::Mail::BulkMail::_smtp_send line 42 with arguments (From address (`casti@casti.ca') rejected by server. at GT::Mail::BulkMail::_smtp_send line 42, chunk 13.
).Links (300): GT::Mail::BulkMail::_smtp_send called at d:/InetPub/wwwroot/cgi-bin/admin/GT/Mail/BulkMail.pm line 637 with arguments (GT::Mail::BulkMail=HASH(0x3cf8498), harvey.yuen@casti.ca, casti@casti.ca, "CASTI Publishing Inc.", Test, Test).Links (300): GT::Mail::BulkMail::_send_one called at GT::Mail::BulkMail::_send_coderef line 7 with arguments (GT::Mail::BulkMail=HASH(0x3cf8498)).Links (300): GT::Mail::BulkMail::_send_coderef called at d:/InetPub/wwwroot/cgi-bin/admin/GT/Mail/BulkMail.pm line 563 with arguments (GT::Mail::BulkMail=HASH(0x3cf8498), CODE(0xb62f38c)).Links (300): GT::Mail::BulkMail::send called at d:\InetPub\wwwroot\cgi-bin\admin\nph-email.cgi line 128 with arguments (GT::Mail::BulkMail=HASH(0x3cf8498), CODE(0xb62f38c)).Links (300): main::main called at d:\InetPub\wwwroot\cgi-bin\admin\nph-email.cgi line 31 with no arguments.

System Information
======================================
Perl Version: 5.006001
Links SQL Version: 2.0.4
DBI.pm Version: 1.14
Persistant Env: mod_perl (0) SpeedyCGI (0)
@INC =
d:/InetPub/wwwroot/cgi-bin/admin
c:/Perl/lib
c:/Perl/site/lib
.

CGI INPUT
======================================
emailsto => 3


CGI Cookies
======================================
def_files_page => 25
def_pages_screen => 20
def_sort => name
def_working_dir =>


ENVIRONMENT
======================================
COMPUTERNAME => CASTI01
COMSPEC => C:\WINNT\system32\cmd.exe
CONTENT_LENGTH => 0
GATEWAY_INTERFACE => CGI/1.1
GT_TMPDIR => d:/InetPub/wwwroot/cgi-bin/admin/tmp
HTTP_COOKIE => def_sort=name; def_working_dir= ; def_files_page=25; def_pages_screen=20
INCLUDE => D:\Program Files\Mts\Include
LIB => D:\Program Files\Mts\Lib
NUMBER_OF_PROCESSORS => 1
OS => Windows_NT
OS2LIBPATH => C:\WINNT\system32\os2\dll;
PATH => C:\Perl\bin\;C:\WINNT\system32;C:\WINNT;d:\MSSQL7\BINN;D:\Program Files\Mts
PATHEXT => .COM;.EXE;.BAT;.CMD;.VBS;.JS;.VBE;.JSE;.WSF;.WSH
PROCESSOR_ARCHITECTURE => x86
PROCESSOR_IDENTIFIER => x86 Family 6 Model 8 Stepping 3, GenuineIntel
PROCESSOR_LEVEL => 6
PROCESSOR_REVISION => 0803
QUERY_STRING => emailsto=3
REQUEST_METHOD => GET
SERVER_PROTOCOL => HTTP/1.1
SYSTEMDRIVE => C:
SYSTEMROOT => C:\WINNT
USERPROFILE => C:\WINNT\Profiles\Default User
WINDIR => C:\WINNT


and here's a log that Perl made:

*** 'd:\InetPub\wwwroot\cgi-bin\admin\nph-email.cgi' error message at: 2001/06/08 15:00:46
GT::SQL::Driver::MYSQL (300): Preparing query: SELECT * FROM Links_MailingIndex WHERE Mailing = '3' at d:/InetPub/wwwroot/cgi-bin/admin/GT/SQL/Driver/MYSQL.pm line 35.
GT::SQL::Driver::MYSQL (300): Preparing query: SELECT extra FROM Links_MailingIndex WHERE Mailing = '3' at d:/InetPub/wwwroot/cgi-bin/admin/GT/SQL/Driver/MYSQL.pm line 35.
GT::SQL::Driver::MYSQL (300): Preparing query: SELECT ID,Email FROM Links_EmailMailings WHERE Mailing = '3' at d:/InetPub/wwwroot/cgi-bin/admin/GT/SQL/Driver/MYSQL.pm line 35.
GT::SQL::Driver::MYSQL (300): Preparing query: SELECT * FROM Links_Users WHERE Email = 'harvey.yuen@casti.ca' at d:/InetPub/wwwroot/cgi-bin/admin/GT/SQL/Driver/MYSQL.pm line 35.
From address (`casti@casti.ca') rejected by server. at GT::Mail::BulkMail::_smtp_send line 42, <SMTP> chunk 13.


Sounds like a server error but I'd sure like some advice.

Quote Reply
Re: Bulk Mail error In reply to
Hi,

This means your SMTP server does not allow you to send email that is from 'casti@casti.ca'. Often this means you must send mail from a specific user. Try changing your email address in Setup->Email Options, or contact your ISP to ask them about this.

Cheers,

Alex

--
Gossamer Threads Inc.
Quote Reply
Re: Bulk Mail error In reply to
I think i figured out what was going on with the RFC 501 reply code. Since it's a syntactical error i went into the SQL database and changed the 'mailfrom' field in the table 'mailingindex'. I added brackets <> to the casti@casti.ca so it would be <casti@casti.ca>. That's what i thought the server error was saying; that it couldn't find an address between < and >. I edited the bulkmail.pm module so that it wouldn't validate my sender's e-mail.

Then i sent the mail and this is the new server response:

Sending emails ...

GT::Mail::BulkMail Error: Recipient (harvey.yuen@casti.ca) refused by server: 5.1.3 where is <...> in that?

There was an error while sending the email to harvey.yuen@casti.ca
0 sent.

Mailing complete (4.00 s)


I'm thinking that my SMTP server is looking for a recipient address between the brackets < and > again. So i went into the database and changed the address in the emailmailings table. That is, i added the brackets but now nph-email is giving me errors because it's also validating the address, I think, and taking it from the SQL table.

What do you think? If it is the server requiring < and > enclosing email addresses then which scripts do I have to edit? does anybody have any tips?

Quote Reply
Re: Bulk Mail error In reply to
Hi,

Sorry, I totally misread that first post. You are on the right track. Let me see if I can get a fix for you shortly.

Cheers,

Alex

--
Gossamer Threads Inc.
Quote Reply
Re: Bulk Mail error In reply to
The fix will be in the next version of Links SQL, for a fix until then, change the following lines of admin/GT/Mail/BulkMail.pm:

Code:
774: print $out "MAIL FROM: $from";
print $out "MAIL FROM: <$from>";

789: print $out "RCPT TO: $to";
print $out "RCPT TO: <$to>";
Sorry about that, it hasn't caused a problem until now.

Let me know if you have any questions/problems.

Jason Rhinelander
Gossamer Threads
jason@gossamer-threads.com
Quote Reply
Re: Bulk Mail error In reply to
Thanks for the help, Smile
Your solution worked just fine.

Harvey Yuen
CASTI Publishing Inc.
http://www.casti.ca/