geronimo-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Kamalanathan Raman" <Kamalanathan_Ra...@infosys.com>
Subject javax.mail.MessagingException: .. could not connect to SMTP host -Reg
Date Thu, 22 Feb 2007 09:31:06 GMT

Hi ,



Iam trying to send a notification mail using the java mail in Geronimo
1.1.1 . When I try to send the mail iam getting this following exception
, can any one give a pointer regarding where iam going wrong and what to
do...





javax.mail.SendFailedException: Send failure
(javax.mail.MessagingException: Could not connect to SMTP host:
localhost, port: 25 (java.net.ConnectException: Connection refused:
connect))

      at javax.mail.Transport.send(Transport.java:161)

      at javax.mail.Transport.send(Transport.java:46)

      at
com.symcor.common.util.SendMail.sendNotification(SendMail.java:171)

      at
com.symcor.common.util.SendMail.sendNotification(SendMail.java:92)

      at
com.symcor.eds.app.RunEDSService.sendMail(RunEDSService.java:411)

      at com.symcor.eds.app.RunEDSService.main(RunEDSService.java:338)

Caused by: javax.mail.MessagingException: Could not connect to SMTP
host: localhost, port: 25 (java.net.ConnectException: Connection
refused: connect)

      at
com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransport.java:867)

      at
com.sun.mail.smtp.SMTPTransport.protocolConnect(SMTPTransport.java:156)

      at javax.mail.Service.connect(Service.java:215)

      at javax.mail.Service.connect(Service.java:83)

      at javax.mail.Service.connect(Service.java:68)

      at com.sun.mail.smtp.SMTPTransport.connect(SMTPTransport.java:93)

      at javax.mail.Transport.send(Transport.java:92)

      ... 5 more

Caused by: java.net.ConnectException: Connection refused: connect

      at java.net.PlainSocketImpl.socketConnect(Native Method)

      at java.net.PlainSocketImpl.doConnect(Unknown Source)

      at java.net.PlainSocketImpl.connectToAddress(Unknown Source)

      at java.net.PlainSocketImpl.connect(Unknown Source)

      at java.net.SocksSocketImpl.connect(Unknown Source)

      at java.net.Socket.connect(Unknown Source)

      at java.net.Socket.connect(Unknown Source)

      at java.net.Socket.<init>(Unknown Source)

      at java.net.Socket.<init>(Unknown Source)

      at
com.sun.mail.util.SocketFetcher.getSocket0(SocketFetcher.java:131)

      at
com.sun.mail.util.SocketFetcher.getSocket(SocketFetcher.java:113)

      at
com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransport.java:836)

      ... 11 more

2007-02-22 14:50:47,674 INFO  com.symcor.common.util.SendMail
-sendNotification(...):exit

2007-02-22 14:50:47,674 ERROR root -main[]:Send failure
(javax.mail.MessagingException: Could not connect to SMTP host:
localhost, port: 25 (java.net.ConnectException: Connection refused:
connect))

javax.mail.SendFailedException: Send failure
(javax.mail.MessagingException: Could not connect to SMTP host:
localhost, port: 25 (java.net.ConnectException: Connection refused:
connect))

      at javax.mail.Transport.send(Transport.java:161)

      at javax.mail.Transport.send(Transport.java:46)

      at
com.symcor.common.util.SendMail.sendNotification(SendMail.java:171)

      at
com.symcor.common.util.SendMail.sendNotification(SendMail.java:92)

      at
com.symcor.eds.app.RunEDSService.sendMail(RunEDSService.java:411)

      at com.symcor.eds.app.RunEDSService.main(RunEDSService.java:338)

Caused by: javax.mail.MessagingException: Could not connect to SMTP
host: localhost, port: 25 (java.net.ConnectException: Connection
refused: connect)

      at
com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransport.java:867)

      at
com.sun.mail.smtp.SMTPTransport.protocolConnect(SMTPTransport.java:156)

      at javax.mail.Service.connect(Service.java:215)

      at javax.mail.Service.connect(Service.java:83)

      at javax.mail.Service.connect(Service.java:68)

      at com.sun.mail.smtp.SMTPTransport.connect(SMTPTransport.java:93)

      at javax.mail.Transport.send(Transport.java:92)

      ... 5 more

Caused by: java.net.ConnectException: Connection refused: connect

      at java.net.PlainSocketImpl.socketConnect(Native Method)

      at java.net.PlainSocketImpl.doConnect(Unknown Source)

      at java.net.PlainSocketImpl.connectToAddress(Unknown Source)

      at java.net.PlainSocketImpl.connect(Unknown Source)

      at java.net.SocksSocketImpl.connect(Unknown Source)

      at java.net.Socket.connect(Unknown Source)

      at java.net.Socket.connect(Unknown Source)

      at java.net.Socket.<init>(Unknown Source)

      at java.net.Socket.<init>(Unknown Source)

      at
com.sun.mail.util.SocketFetcher.getSocket0(SocketFetcher.java:131)

      at
com.sun.mail.util.SocketFetcher.getSocket(SocketFetcher.java:113)

      at
com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransport.java:836)

      ... 11 more





Thanks and Regards,

Kamal



**************** CAUTION - Disclaimer *****************
This e-mail contains PRIVILEGED AND CONFIDENTIAL INFORMATION intended solely for the use of
the addressee(s). If you are not the intended recipient, please notify the sender by e-mail
and delete the original message. Further, you are not to copy, disclose, or distribute this
e-mail or its contents to any other person and any such actions are unlawful. This e-mail
may contain viruses. Infosys has taken every reasonable precaution to minimize this risk,
but is not liable for any damage you may sustain as a result of any virus in this e-mail.
You should carry out your own virus checks before opening the e-mail or attachment. Infosys
reserves the right to monitor and review the content of all messages sent to or from this
e-mail address. Messages sent to or from this e-mail address may be stored on the Infosys
e-mail system.
***INFOSYS******** End of Disclaimer ********INFOSYS***
Mime
View raw message