Skip to Main Content

Java EE (Java Enterprise Edition) General Discussion

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Could not connect to SMTP host: <host>, port: 25, response: -1

843830Aug 18 2004 — edited Aug 19 2004
Hey everyone,

I have a JavaMail code base that I wrote for a utility at work. It works just fine while at work. However, I brought the code home to work on another utility from home, I am trying to use a friends SMTP server that he has in his suad.org setup. When I change all the pertinent information that is different (such as the SMTP server), I get the following stack trace:

javax.mail.MessagingException: Could not connect to SMTP host: 206.124.134.166, port: 25, response: -1
at com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransport.java:996)
at com.sun.mail.smtp.SMTPTransport.protocolConnect(SMTPTransport.java:197)
at javax.mail.Service.connect(Service.java:233)
at javax.mail.Service.connect(Service.java:134)
at com.xerox.mail.TemplateMail.transportMail(TemplateMail.java:134)
at com.xerox.mail.TemplateMail.sendMail(TemplateMail.java:90)
at com.xerox.mail.TemplateMail.main(TemplateMail.java:154)

I've searched the forums and haven't found anyone with the problem of a response of -1. All the other issues pertain to having connections refused, etc.

So, does anyone know what that response means? I've switched from the DNS name of suad.org and the IP that it resolves to, etc. No difference. I'm starting to wonder if he has his port set up on his SMTP server to be a different port. The problem with that theory is that I would expect a connection refused of some sort.

Thank you for your help.

--Ryan
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Sep 16 2004
Added on Aug 18 2004
1 comment
406 views