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



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. Good and optimum introduction to J2ME application
View Tutorial          By: sabextcc10@gmail.com at 2013-01-14 10:37:57

2. hey i found answer for
Error loading win32c

View Tutorial          By: Dinesh557 at 2008-09-23 05:14:09

3. well understood
View Tutorial          By: shanthini at 2014-04-07 17:19:20

4. it is a good example to understand.
View Tutorial          By: nivedha at 2011-07-12 05:15:39

5. its very helpful..thank you..
View Tutorial          By: roja at 2013-06-16 12:37:32

6. Exception in thread "Thread-0" java.lang
View Tutorial          By: yash at 2009-09-16 06:12:32

7. Guys,

Please explain detail steps w

View Tutorial          By: Parthasarathy at 2010-06-02 08:13:12

8. Thank you very much for explaning the things in su
View Tutorial          By: Sunil Yadav at 2010-05-27 04:04:31

9. Hi,
The code runs fine on my emulator even

View Tutorial          By: Ramin at 2011-07-07 07:23:45

10. Thanks for the post !
View Tutorial          By: percy at 2011-11-24 08:56:23