File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Debugging on Remote Machine

 
Nipun Bahr
Ranch Hand
Posts: 55
Eclipse IDE Tomcat Server
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,

Please suggest how can I debug my application in eclipse IDE on weblogic installed in remote machine.

I am creating an ear file in local machine and deploying on weblogic installed on remote machine.
 
sudipto shekhar
Ranch Hand
Posts: 823
Chrome Eclipse IDE Oracle
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Nipun Bahr wrote:Hi All,

Please suggest how can I debug my application in eclipse IDE on weblogic installed in remote machine.



Apply the break point in the source, restart the WLS server in debug mode and then try to hit the application.

Please let us know if this works.
 
Nipun Bahr
Ranch Hand
Posts: 55
Eclipse IDE Tomcat Server
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Hi Sudipto ,

Sorry for late reply.

When I try to hit the weblogic server on remote machine, I am getting the following error-

"Failed to connect to remote VM. Connection timed out.
org.eclipse.jdi.TimeoutException"


I configured the debug configurations in Eclipse mentioning my remote machine IP and port number.

Please suggest a way to proceed.
 
sudipto shekhar
Ranch Hand
Posts: 823
Chrome Eclipse IDE Oracle
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I would suggest you to go through this tutorial for remote debuggin.

http://www.myeclipseide.com/documentation/quickstarts/remotedebugging/

Also, I found the following discussion, hope this helps:

http://www.myeclipseide.com/PNphpBB2-viewtopic-t-24612.html
 
Nipun Bahr
Ranch Hand
Posts: 55
Eclipse IDE Tomcat Server
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Sudipto,

Thanks for your reply.

I am able to debug now

Earlier I was not able to connect I think due to some firewalls. I tried then with port number 80 and I am able to debug.

One think is that the debugging process is quite slow, so can we go for some other port number?? provided that it should by pass the firewall.

I tried randomly with other port numbers(excluding 80), It did not work
 
sudipto shekhar
Ranch Hand
Posts: 823
Chrome Eclipse IDE Oracle
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Nipun,

How did you change the debug port?

In the setDomainEnv script, use the following:

DEBUG_PORT="9999"
export DEBUG_PORT

You can also check and change your setting through console using the following steps:

- Go to Servers view and right click on your server (make sure your server is not running)
- Click on open launch configuration
- Change your settings.
- Click Apply/OK

Hope this helps.
 
Nipun Bahr
Ranch Hand
Posts: 55
Eclipse IDE Tomcat Server
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Sudipto,

I made the changes in address value of startweblogic.cmd file as below-

set JAVA_OPTIONS=-Xdebug -Xnoagent -Xrunjdwp:transport=dt_socket,address=80,server=y,suspend=n %SAVE_JAVA_OPTIONS%

and this is the port number i.e. 80 which I am hitting from my eclipse debug configurations.
 
sudipto shekhar
Ranch Hand
Posts: 823
Chrome Eclipse IDE Oracle
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Were you able to connect this time??
 
Nipun Bahr
Ranch Hand
Posts: 55
Eclipse IDE Tomcat Server
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Yes , I am able to debug with above said settings.

Only issue is that debugging process is slow.
 
Nipun Bahr
Ranch Hand
Posts: 55
Eclipse IDE Tomcat Server
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I am facing one issue.

Once I debug and disconnect, again it does not connect to remote machine and shows a message-

Failed to connect to remote VM. Connection refused.
Connection refused: connect


Please suggest.
 
sudipto shekhar
Ranch Hand
Posts: 823
Chrome Eclipse IDE Oracle
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Nipun Bahr wrote:Hi,

I am facing one issue.

Once I debug and disconnect, again it does not connect to remote machine and shows a message-

Failed to connect to remote VM. Connection refused.
Connection refused: connect


Please suggest.


What do you mean debug and disconnect?? How do you start debugging again?
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic