• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Jeanne Boyarsky
  • Ron McLeod
Sheriffs:
  • Paul Clapham
  • Liutauras Vilda
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
Bartenders:

cannot send mail thru jsp

 
Ranch Hand
Posts: 378
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
i know alot of people faced this problem before.
i searched google.com i search javaranch.com, no one article can help me solve the problem.
I runs it in my localhost server, it runs well.
But when i runs it in my company's server, it give this error :
----
javax.mail.SendFailedException: Sending failed; nested exception is: class javax.mail.MessagingException: Could not connect to SMTP host: mail.as.com.my, port: 25; nested exception is: java.net.ConnectException: Connection timed out: connect
----

i used telnet to ping the mail server, it was okay and give me 220 (in localhost)..but when i telnet it in the company's remote, it give me this:

..Could not open a connection to host on port 25...

could someone list down the possible causes so that i and everyone else can know how many possible causes for this problem.

I'll really appreciate if someone can help..
thanks in advance.

~Nick


[ August 17, 2007: Message edited by: Nicky Eng ]
 
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Is whichever host name you're using instead of "mail.as.com.my" reachable from the machine where you are running this code? Does it allow connections from it?
 
I'm so happy! And I wish to make this tiny ad happy too:
We need your help - Coderanch server fundraiser
https://coderanch.com/wiki/782867/Coderanch-server-fundraiser
reply
    Bookmark Topic Watch Topic
  • New Topic