MapInfo Products KnowledgeBase

Product: Enterprise Products
Version: na
Platform: Not Platform Related
Category: Errors

Summary:
Error "java.net.ConnectException: Connection refused" received when running an application that hits a web server.

Question:
The following error is thrown when the application is run:

IOException geocoding: java.net.ConnectException: Connection refused
java.net.ConnectException: Connection refused
at java.net.PlainSocketImpl.socketConnect(PlainSocketImpl.java)



Answer:
It seems as if the server might be down, or that the listening port is not open. Open up a DOS/UNIX command window and type the command:

" netstat -a | grep 8080 "

where "8080" is the listening port for the server in question.

If the listening port is open, the standard output will be printed to the screen. Here is an example:

Prompt:\>netstat -a | grep 8080
54 21: TCP TORGO:8080 TORGO:0 LISTENING
Prompt:\>

If it is closed, the command shell prompt will be returned and nothing will be printed to the screen. In this case, make sure that the server has been started successfully.

Last Modified: 08/17/2001 10:30:26 AM
Document URL: http://testdrive.mapinfo.com/techsupp/miprod.nsf/kbase_by_product/2B211E588CC23C0685256AA900608996

Error "java.net.ConnectException: Connection refused" received when running an application that hits a web server. ^2B211E588CC23C0685256AA900608996^Y