• 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 all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

SMTP Connection Refused

 
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,

When I am sending mails from my website and I get the following error message:
-------------------------------------------------------------
Could not connect to SMTP host: mail.sdfpak.org,
port: 25;
nested exception is:
java.net.ConnectException: Connection refused
javax.mail.MessagingException: Could not connect to
SMTP host: mail.sdfpak.org, port: 25;
nested exception is:
java.net.ConnectException: Connection refused
at com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransport.java:695)
at com.sun.mail.smtp.SMTPTransport.protocolConnect(SMTPTransport.java:168)
at
javax.mail.Service.connect(Service.java:227)
at
javax.mail.Service.connect(Service.java:131)
.
.
.
.
-------------------------------------------------------------

One thing is worth noting that I can send emails from my local machine using same smtp server after authenticating the server. But SMTP connections are refused on the machine where I have hosted the website.

Any ideas how to solve this problem or what is causing it?


regards,
Jawed Nazar Ali
 
author
Posts: 113
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You mentioned two different machines. Sounds like your ISP only accepts connections from their customer machines. Your website box is hosted by a different ISP, correct? This type of limitation is set up to foil spammers.

Does your website ISP have a mail server you can use?
 
Consider Paul's rocket mass heater.
    Bookmark Topic Watch Topic
  • New Topic