StaleConnectionException on Linux systems
Due to a Linux semaphore issue, WebSphere Application Server on a Linux
platform can incur a data source failure in either of these JDBC configurations:
- Using the DB2 Universal JDBC Type 2 driver to connect to a local DB2 database
- Using the DB2 Universal JDBC Type 2 driver to connect to a local DB2 Connect
for z/OS database that restricts local DB2 clients from running within an
agent. (That is, if the DB2_IN_APP_PROCESS setting is not the default value,
or if the setting is Yes. Set the value to No to fix the problem and avoid
performing the following procedure.)
The issue often triggers the JVM logs to display the DB2 stale connection
exception SQL1224. Because the SQL exception code can vary, however,
check the DB2 trace log when you encounter a stale connection. If you see
the following error data, the Linux semaphore behavior is the problem: '71' -SQLCC_ERR_CONN_CLOSED_BY_PARTNER and SQLCODE -XXXX
To work around the problem, set the loopback for your database. For example,
if your database is WAS, host name is LHOST, and database service
port number is 50000, issue the following commands from the DB2 command
line window:
db2 catalog TCPIP node RHOST remote LHOST server 50000
db2 uncatalog db WAS
db2 catalog WAS as WASAlias at node loop authentication server
//If you connect to WASAlias, it is connect through loopback; if you connect to WAS, it is "normal" connect.
db2 catalog WASAlias as WAS at node RHOST
Verify the catalog entry by issuing the following commands from the DB2
command line window:
db2 connect to WAS user xxx
passwd: xxx
Searchable topic ID:
stalelinux
Last updated: Jun 21, 2007 8:07:48 PM CDT
WebSphere Business Integration Server Foundation, Version 5.0.2
http://publib.boulder.ibm.com/infocenter/wasinfo/index.jsp?topic=/com.ibm.wasee.doc/info/ee/ae/rdat_stalelinux.html