Hot Topic (More than 10 Replies) @sendmail failure codes? (Read 2341 times)
BOBSCOTT
Senior Member
Members
*****
Offline


That Darn Computer #$X#
{curse words}

Posts: 1195
Joined: Nov 22nd, 2002
@sendmail failure codes?
Jun 6th, 2007 at 8:45pm
Print Post Print Post  
I know A non-zero return value indicates a failure but do the codes have specific meanings? is there a list available?

any clue what a -3 means?

Thanks
  

Team – Together Everyone Achieves More
Back to top
 
IP Logged
 
Ray the Reaper
Global Moderator
Members
Lantica Support
*****
Offline


The One & The Only

Posts: 2482
Joined: Aug 20th, 2003
Re: @sendmail failure codes?
Reply #1 - Jun 6th, 2007 at 8:54pm
Print Post Print Post  
I believe a -3 is an error code that may be returned if the SMTP server that you are using requires a user name and password to use.

SendMail in 2.0 will be able to pass the username and password to the SMTP server

-Ray
  

Raymond Yoxall Consulting
ray.yoxall@gmail.com
ryoxall@lantica.com
Sesame Applications, Design and Support
Back to top
IP Logged
 
BOBSCOTT
Senior Member
Members
*****
Offline


That Darn Computer #$X#
{curse words}

Posts: 1195
Joined: Nov 22nd, 2002
Re: @sendmail failure codes?
Reply #2 - Jun 6th, 2007 at 9:05pm
Print Post Print Post  
Thanks  Smiley

2.0 is just around the corner now! Less then 3 weeks  Smiley
  

Team – Together Everyone Achieves More
Back to top
 
IP Logged
 
Bob_Hansen
Senior Member
Members
*****
Offline


WOW, They have the Internet
on computers now!

Posts: 1861
Location: Salem, NH
Joined: Nov 24th, 2002
Re: @sendmail failure codes?
Reply #3 - Jun 7th, 2007 at 12:20am
Print Post Print Post  
The "-3" is probably not the pure code from the SMTP server.  It is usually 3 digits, no minus sign.

The first digit tells you if your command was accepted and processed. There are five different values for that:

   1. Mail server has accepted the command, but does not yet take any action. A confirmation message is required.
   2. Mail server has completed the task successfully without errors.
   3. Mail server has understood the request, but requires further information to complete it.
   4. Mail server has encountered a temporary failure. If the command is repeated without any change, it might be
     completed. Try again, it may help!
   5. Mail server has encountered a fatal error. Your request can't be processed.


From this site: http://www.emailaddressmanager.com/tips/codes.html ....

Quote:
Email Delivery Codes: Errors
dots Error Delivery Codes
How many times you got your outgoing emails back and wondered what is wrong with it? Every time when your email can not be delivered, the SMTP server sends you a notification, which includes a standard error message, associated with the real problem.

# Each code is composed of three digits (X.X.X). The first digit gives the status of the email message: 2 means the email was succesfully sent;
# 4 means there was a temporary problem while sending the email (your email server may try to send it again or you have to resend it, depending on your server settings). Such error messages are using codes like 4.X.X, where X.X are used in order to give more precise information about the error;
# 5 means there is a permanent/fatal error related to the email (the email address of the receiver does not exist, it doesn't accept emails from you, etc). Such error messages are using codes like 5.X.X, where X.X are used in order to give more precise information about the error.


Here is a complete list of email delivery error codes, based on the Extended SMTP (ESMTP) standards, where X can be 4 or 5, depending on the error type (Persistent Transient or Permanent):

    * X.1.0 Other address status
    * X.1.1 Bad destination mailbox address
    * X.2.0 Bad destination system address
    * X.1.3 Bad destination mailbox address syntax
    * X.1.4 Destination mailbox address ambiguous
    * X.1.5 Destination mailbox address valid
    * X.1.6 Mailbox has moved
    * X.1.7 Bad sender's mailbox address syntax
    * X.1.8 Bad sender's system address

    * X.2.0 Other or undefined mailbox status
    * X.2.1 Mailbox disabled, not accepting messages
    * X.2.2 Mailbox full
    * X.2.3 Message length exceeds administrative limit.
    * X.2.4 Mailing list expansion problem

    * X.3.0 Other or undefined mail system status
    * X.3.1 Mail system full
    * X.3.2 System not accepting network messages
    * X.3.3 System not capable of selected features
    * X.3.4 Message too big for system

    * X.4.0 Other or undefined network or routing status
    * X.4.1 No answer from host
    * X.4.2 Bad connection
    * X.4.3 Routing server failure
    * X.4.4 Unable to route
    * X.4.5 Network congestion
    * X.4.6 Routing loop detected
    * X.4.7 Delivery time expired

    * X.5.0 Other or undefined protocol status
    * X.5.1 Invalid command
    * X.5.2 Syntax error
    * X.5.3 Too many recipients
    * X.5.4 Invalid command arguments
    * X.5.5 Wrong protocol version

    * X.6.0 Other or undefined media error
    * X.6.1 Media not supported
    * X.6.2 Conversion required and prohibited
    * X.6.3 Conversion required but not supported
    * X.6.4 Conversion with loss performed
    * X.6.5 Conversion failed

    * X.7.0 Other or undefined security status
    * X.7.1 Delivery not authorized, message refused
    * X.7.2 Mailing list expansion prohibited
    * X.7.3 Security conversion required but not possible
    * X.7.4 Security features not supported
    * X.7.5 Cryptographic failure
    * X.7.6 Cryptographic algorithm not supported
    * X.7.7 Message integrity failure
  



Bob Hansen
Sesame Database Manager Professional
Sensible Solutions Inc.
Salem, NH
603-898-8223
Skype ID = sensiblesolutions
Back to top
IP Logged
 
Acebanner
Full Member
***
Offline



Posts: 123
Location: New York City
Joined: Jan 23rd, 2008
Re: @sendmail failure codes?
Reply #4 - Sep 8th, 2008 at 4:14pm
Print Post Print Post  
I'm getting -1, -7 and -9 error codes from my SendMail commands. Any idea what these codes would mean?
I've tried the command using login/password options, and even tried different mail servers, without success.
  
Back to top
IP Logged
 
Hammer
YaBB Administrator
Lanticans
*****
Offline


Fire bad. Tree pretty.

Posts: 3436
Location: Ohio
Joined: Nov 22nd, 2002
Re: @sendmail failure codes?
Reply #5 - Sep 8th, 2008 at 5:08pm
Print Post Print Post  
Acebanner wrote on Sep 8th, 2008 at 4:14pm:
I'm getting -1, -7 and -9 error codes from my SendMail commands. Any idea what these codes would mean?
I've tried the command using login/password options, and even tried different mail servers, without success.


-1 means that you are not getting a connection at all. It is timing out or the name of your mail server is wrong or it wants a different port than 25. Stuff like that.

-9 indicates and incorrect login or password.

-7 is a weird one to get as it is just sending a final CRLF pair after everything else. There may be something bad in the message formatting if you are getting that one.

As this involves logins and passwords, you might want to get with Support directly so they can help you troubleshoot without having to post sensitive information.
  

- Hammer
The plural of anecdote is not data.
Back to top
IP Logged
 
Acebanner
Full Member
***
Offline



Posts: 123
Location: New York City
Joined: Jan 23rd, 2008
Re: @sendmail failure codes?
Reply #6 - Sep 8th, 2008 at 5:48pm
Print Post Print Post  
Thanks Erika, I'll report back once I've triple-checked everything.

I was able to send emails from Sesame from my home computer using SendMail using my personal email server (I did not need log/pass information) but it did something rather weird. The file attachment I wanted added to the email was added, and it shows up on the received email, but it has zero bytes! The file attachment is an RTF file I created using MergeFilePrint. So I thought to add a Loiter command, but that didn't help. Even specifying a file that was pre-existing (not created by the MergeFilePrint command) produced the same result, a file attachment of zero bytes. Turning off Norton360 (do not purchase it under any circumstance) did not help either.

Has anyone else had similar problems with file attachements using SendMail?

Right now I've figured out a way to use @ASynchShell to command-line file attach using Outlook as a workaround, but I'd rather use SendMail if possible. I'll keep trying. Smiley
  
Back to top
IP Logged
 
Ray the Reaper
Global Moderator
Members
Lantica Support
*****
Offline


The One & The Only

Posts: 2482
Joined: Aug 20th, 2003
Re: @sendmail failure codes?
Reply #7 - Sep 8th, 2008 at 6:11pm
Print Post Print Post  
If you have a second, try sending a test e-mail to support@lantica.com with just a simple text file as an attachment using Sendmail.

That would narrow it down to either the sending of the attachment or the receiving.

-Ray
  

Raymond Yoxall Consulting
ray.yoxall@gmail.com
ryoxall@lantica.com
Sesame Applications, Design and Support
Back to top
IP Logged
 
Acebanner
Full Member
***
Offline



Posts: 123
Location: New York City
Joined: Jan 23rd, 2008
Re: @sendmail failure codes?
Reply #8 - Sep 8th, 2008 at 6:45pm
Print Post Print Post  
Ok, the following programming returns an error code of -4:

Code
Select All
var n as Int

n = @SendMail("smtp.acebanner.com", "Test email from AceBanner, per Ray's request.", "cjc@acebanner.com", "support@lantica.com", "", "", "Test message.", "", "", "C:\Sesame2\Merge\EstimateMerge.rtf")

If n = 0
{
	@MsgBox("Email was sent succesfully.", "", "")
}
Else
{
	@MsgBox("The email was not sent properly.", "The error code returned was: " + n, "") 



I get a -9 error code if I try putting in the username and password. In that case, my username is "cjc" not "cjc@acebanner.com".
If I put in the username as "cjc@acebanner" (leave the password as is) I get an error code of -7. I double-checked the username and password by using my email service's web-based mail client, so I know I've got the username and password correct.

Now, if I replace "smtp.acebanner.com" with "mail.acebanner.com" and fully enter the username "cjc@acebanner.com" I still get an error code of -7. Removing the @acebanner from the username string brings me back to error code -9.

It sort of worked for me when using my personal email server mail.optonline.net this past weekend when I was experimenting with it, but the attachment wouldn't work (zero bytes).

If I take out user/pass and the attachment, so that the programming looks like this:
Code
Select All
var n as Int

n = @SendMail("mail.acebanner.com", "Test email from AceBanner, per Ray's request.", "cjc@acebanner.com", "support@lantica.com", "", "", "Test message.", "", "", "")

If n = 0
{
	@MsgBox("Email was sent succesfully.", "", "")
}
Else
{
	@MsgBox("The email was not sent properly.", "The error code returned was: " + n, "")
} 



- then I get error code -4! I feel like I can get almost any error code, LOL! If I change the server in the above programming to "smtp.acebanner.com" I still get -4 as an error code. Any idea why this could be?
  
Back to top
IP Logged
 
Ray the Reaper
Global Moderator
Members
Lantica Support
*****
Offline


The One & The Only

Posts: 2482
Joined: Aug 20th, 2003
Re: @sendmail failure codes?
Reply #9 - Sep 8th, 2008 at 9:06pm
Print Post Print Post  
In your normal E-mail program what port is specified for the outgoing SMTP server?

-Ray
  

Raymond Yoxall Consulting
ray.yoxall@gmail.com
ryoxall@lantica.com
Sesame Applications, Design and Support
Back to top
IP Logged
 
Acebanner
Full Member
***
Offline



Posts: 123
Location: New York City
Joined: Jan 23rd, 2008
Re: @sendmail failure codes?
Reply #10 - Sep 11th, 2008 at 12:10pm
Print Post Print Post  
Quote:
In your normal E-mail program what port is specified for the outgoing SMTP server?

-Ray


Sorry for the delay! The port using by the outgoing SMTP server is 2525. The timeout is set to 1 minute (if that matters.)
  
Back to top
IP Logged
 
Ray the Reaper
Global Moderator
Members
Lantica Support
*****
Offline


The One & The Only

Posts: 2482
Joined: Aug 20th, 2003
Re: @sendmail failure codes?
Reply #11 - Sep 11th, 2008 at 3:26pm
Print Post Print Post  
In your C:\Windows\System32\Drivers\etc you will see a file named services.
Open that file with Notepad
You will see an Entry for SMTP that says
Quote:
smtp               25/tcp    mail                   #Simple Mail Transfer Protocol

Change that line to
Quote:
smtp               2525/tcp    mail                   #Simple Mail Transfer Protocol

and save the file.

Restart your computer and Retest Sendmail using your username and password. Let me know if it works.

-Ray

Note if you are running Windows 2000 or Windows NT the directory will be C:\Winnt\System32\Drivers\etc
  

Raymond Yoxall Consulting
ray.yoxall@gmail.com
ryoxall@lantica.com
Sesame Applications, Design and Support
Back to top
IP Logged
 
Acebanner
Full Member
***
Offline



Posts: 123
Location: New York City
Joined: Jan 23rd, 2008
Re: @sendmail failure codes?
Reply #12 - Sep 12th, 2008 at 4:31pm
Print Post Print Post  
I made the change and restarted, but I'm still getting -7 and -9 error codes.
For now I'm using @ASynch() to just call up Outlook with the file already attached, but I think I'll eventually need SendMail to work for mass emailings.
  
Back to top
IP Logged
 
Ray the Reaper
Global Moderator
Members
Lantica Support
*****
Offline


The One & The Only

Posts: 2482
Joined: Aug 20th, 2003
Re: @sendmail failure codes?
Reply #13 - Sep 12th, 2008 at 7:00pm
Print Post Print Post  
Hello Acebanner,

Could you send an e-mail to support@lantica.com with the exact code you are using that is returning the -7 error code.

-Ray
  

Raymond Yoxall Consulting
ray.yoxall@gmail.com
ryoxall@lantica.com
Sesame Applications, Design and Support
Back to top
IP Logged