Wednesday, February 17, 2010

"ERROR: transport error 202: connect failed: Operation timed out"

This is a problem that can be encountered on NetBeans platform when trying to debug a project.

In another post someone said
Shared archive: sharing disabled for server vm
ERROR: transport error 202: gethostbyname: unknown host ["transport.c",L41]
FATAL ERROR in native method: JDWP No transports initialized, jvmtiError=JVMTI_ERROR_INTERNAL(113)
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510) ["debugInit.c",L500]
JDWP exit error JVMTI_ERROR_INTERNAL(113): No transports initialized
JDWP exit error JVMTI_ERROR_INTERNAL(113): No transports initializedJava Result: 134
BUILD SUCCESSFUL (total time: 6 seconds)
This worked for me on OS X:

# sudo su -
# echo `/bin/hostname` >> /etc/hosts

Of course, there are many other commands that can be used to achieve the same thing.

After this, the debugger connected right away, instead of a lengthy timeout and then failure.

The problem occurred in my case because a VPN connection (Cisco AnyConnect) change my hostname / dns servers.

No comments: