Kbase P124313: How to attach debugger to a remote AppServer/WebSpeed Server
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  24/04/2008 |
|
Status: Verified
GOAL:
How to attach debugger to remote AppServer/WebSpeed Server
GOAL:
How to run Debugger in attachable mode
GOAL:
How to debug AppServer / Webspeed memory leak problems?
FACT(s) (Environment):
All Supported Operating Systems
OpenEdge 10.1x
FIX:
This solution is to summarize the steps required to configure an AppServer/WebSpeed Agent and allow the debugger to remote connect this AppServer/WebSpeed Server.
This is steps can be useful to troubleshoot runaway AppServer/WebSpeed, AppServer/WebSpeed Server consuming CPU or memory, or just AppServer/WebSpeed Server hanging.
Note that these steps can only be used starting on 10.1A. The new java debugger was first introduced in 9.1D05 but the remote debugging option is available only on 10.1A.
Also, unfortunately, when you first note that a AppServer/WebSpeed Agent is hanging, is not possible to attach the debugger to it. It is necessary to enable debugging.
The reason is because Debugging is initially disabled. The reason for being initially disable is because it may open a potential security hole.
When running the Debugger, you can examine and modify internal variables and database fields. In a production environment, this means that someone could access sensitive business data while in the Debugger. For this reason, Progress Software Corporation strongly recommends that you avoid using the Debugger on a production system. So, if you enable the debugger to troubleshoot a problem, remember to disable after finishing troubleshooting.
Steps to enable debugging and make the AppServer/WebSpeed Agent ready for debug:
1. Open proenv session by selecting proenv icon in OpenEdge group (on Windows) or executing proenv (UNIX)
2. Enable Debugger by running the following command line:
proDebugenable ?enable-all
3. Restart AdminServer.
At proenv do:
proadsv ?stop
proadsv ?start
4. Turn on option called "4GL Debugger Enabled" in the Advanced Features options for the Agent of the AppServer/WebSpeed properties (using Progress Explorer on Windows). On Unix, edit $DLC/properties/ubroker.properties and set debuggerEnabled=1 for the AppServer.
5. Start the appserver Broker.
At proenv do:
asbman ?I <brokername> -start
Once you enable the debugging, you can wait to have the runaway process, consuming CPU or memory, or just AppServer/WebSpeed Server hanging happening again and follow the steps bellow to be able to connect the process:
At the machine were the AppServer/WebSpeed Server is running, make the AppServer debug-ready by running proDebugConfig command line.
6a) A list of PID for each _proapsv/_progres will be displayed, followed by a request to enter the process id for the process you want to debug.
6b) Type the PID and hit ENTER.
6c) A message saying that this process is ready for debugging is displayed, followed by another message line that gives the port number that will be used. Save this port number for step 7d.
To Attach the debugger to the process, at the machine that will run the debugger, start a independent session of the debugger by opening the debugger icon in OpenEdge group (on Windows) or executing proDebugger (UNIX)
7a) from the "Debug" menu select "Attach to process?".
7b) Select "Attach to debug-ready Process"
7c) Enter the hostname of the machine where the AppServer/Webspeed Server is running.
7d) Enter the Port number that you saved on step 6c and click of.
The debugger is now attached to the AppServer.