Comment on Tutorial - Sending Email from Java application (JavaMail sample program) By Narayanan



Comment Added by : Rod

Comment Added at : 2011-11-13 15:09:52

Comment on Tutorial : Sending Email from Java application (JavaMail sample program) By Narayanan
Hello, I have been using a very similar code on development of a email verification system. All have worked fine in local system (i.e. my computer) but now, when I deploy to production server I'm getting the following exception.

DEBUG: setDebug: JavaMail version 1.4.4
DEBUG: getProvider() returning javax.mail.Provider[TRANSPORT,smtp,com.sun.mail.smtp.SMTPTransport,Sun Microsystems, Inc]
DEBUG SMTP: useEhlo true, useAuth true
DEBUG SMTP: trying to connect to host "smtpout.mysmtpserver.ext", port 3535, isSSL false
DEBUG SMTP: EOF: [EOF]
DEBUG SMTP: could not connect to host "smtpout.mysmtpserver.ext", port: 3535, response: -1

javax.mail.MessagingException: Could not connect to SMTP host: smtpout.secureserver.net, port: 25, response: -1
at com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransport.java:1922)
at com.sun.mail.smtp.SMTPTransport.protocolConnect(SMTPTransport.java:638)

This is just beyond my knowledge. I have tried changing the port to 25 but still get the same error. And again, works fine locally but crashes in server.
I would greatly appreciate it if you could at least give me a light here.
Thanks in advance.


View Tutorial



Ask a Question

Subscribe to Tutorials

Related Tutorials

Program using concept of byte long short and int in java

Update contents of a file within a jar file

Tomcat and httpd configured in port 8080 and 80

Java File

Java String

Count number of vowels, consonants and digits in a String in Java

Reverse a number in Java

Student marks calculation program in Java

Handling Fractions in Java

Calculate gross salary in Java

Calculate average sale of the week in Java

Vector in Java - Sample Program

MultiLevel Inheritance sample in Java

Multiple Inheritance sample in Java

Java program using Method Overriding

Archived Comments

1. Thanks a lot lot lot for this, but when I run the
View Tutorial          By: Kedjimo at 2011-10-06 06:13:10

2. i want to know how to connect to a remote mysql da
View Tutorial          By: lixiang at 2013-04-23 04:32:58

3. Hi i have created the 5 files and in main program
View Tutorial          By: Anandkumar at 2011-09-10 05:13:59

4. doesn't work with 3 , 7 and 5 but with numbers hig
View Tutorial          By: asd at 2013-05-11 09:25:30

5. Hi,
I done very simple, just copy the strut

View Tutorial          By: sridhar at 2009-03-01 19:17:10

6. I'm a begner but i dont know the way to ask quisti
View Tutorial          By: sajid kahn at 2013-05-23 19:15:26

7. Why use recursion in Java, even for Strings? The s
View Tutorial          By: Kristoffer L at 2012-11-21 01:51:36

8. Thank you, saved my life
View Tutorial          By: Zs at 2013-04-13 22:51:54

9. i have download the all 5 codes.but how can i run
View Tutorial          By: Chathu at 2011-01-30 02:28:53

10. Hi,
I am designing a client server multipla

View Tutorial          By: Varun Gupta at 2012-10-15 00:01:57