I'm using Webshpere 7 and I can't connect my debugger to Webshphere.
I've tried this on the command line...
/opt/IBM/WebSphere/AppServer/java/bin/java -agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=0.0.0.0:3389 Test
Using 0.0.0.0 in the address makes it work!! I can connect from out side the machine.
This only seems to be the case with Websphere 7(IBM JDK 1.6), Websphere 6 (IBM JDK 1.5) does not have this "feature"
The Webpage for Websphere (/ibm/console) does not let me put this in to the console page.
Application servers > server1 > Debugging service
The "JVM debug port" on this page does not let me enter a 0.0.0.0:7777 as the port number.
Can anyone tell me where I can enter this value?
Thanks
By default Sles Linux does not expose a port outside the box.
So by setting the debug port in WS to 7777 via the webpage(IBM/console) only exposes the port internally to the box. To expose it you need to enter “0.0.0.0:7777”, but the web page does not allow this as a value.
So to change it by hand go to this file on the box...
/opt/IBM/WebSphere/AppServer/profiles/WRSProfile/config/cells/WRSNodeCell/nodes/WRSNode/servers/server1/server.xml
Then replace 7777 with 0.0.0.0:7777 in the file. (there are 3 places to change this in the file)
<services xmi:type="debugservice:DebugService"
xmi:id="DebugService_1331818723840" enable="true"
jvmDebugPort="0.0.0.0:7777"
jvmDebugArgs="-agentlib:jdwp=transport=dt_socket,
server=y,suspend=n,
address=0.0.0.0:7777"
BSFDebugPort="4444" BSFLoggingLevel="0"/>
...
<jvmEntries xmi:id="JavaVirtualMachine_1183122130078"
verboseModeClass="false" verboseModeGarbageCollection="false"
verboseModeJNI="false" maximumHeapSize="1024" runHProf="false"
hprofArguments="" debugMode="true"
debugArgs="-agentlib:jdwp=transport=dt_socket,
server=y,suspend=n,
address=0.0.0.0:7777"
genericJvmArguments="">
Then stop and start the server.
/opt/IBM/WebSphere/AppServer/bin # ./stopServer.sh server1
..
/opt/IBM/WebSphere/AppServer/bin # ./startServer.sh server1
You can now connect a debugger to the machine!