Symptom
- Java application is unable to connect to the database after pacemaker cluster failover to standby node.
- The error message encountered during the connection attempt is:
JdbcCon.log
Start: Sun Jan 12 00:08:18 UTC 2025
Error: Couldn't connect to DB
com.sap.sql.log.OpenSQLException: Exception of type com.ibm.db2.jcc.am.StandbyServerSQLException caught:
DB2 SQL Error: SQLCODE=-1776, SQLSTATE= , SQLERRMC=1, DRIVER=4.33.31.
db2diag.log
2025-01-12-00.08.18.375780+000 I320888455E752 LEVEL: Warning
PID : 8084 TID : 139987337078528 PROC : db2sysc 0
INSTANCE: db2abc NODE : 000 DB : ABC
APPHDL : 0-57 APPID: 10.4.2.18.16014.250112081819
AUTHID : SAPABCDB HOSTNAME: abc123
EDUID : 24 EDUNAME: db2agent (ABC) 0
FUNCTION: DB2 UDB, High Availability Disaster Recovery, hdrCheckDb, probe:18200
MESSAGE : SQL1776N The command cannot be issued on an HADR database. Reason
code = "1".
DATA #1 : Hex integer, 4 bytes
0x00000000
DATA #2 : sqeApplication_acbInfo, PD_TYPE_sqeApplication_acbInfo, 4 bytes
x0
DATA #3 : String, 50 bytes
Connections are not allowed on a standby database.
Read more...
Environment
- SAP NetWeaver based on Java
- IBM Db2 for Linux, Unix and Windows with HADR
Product
SAP NetWeaver 7.4 ; SAP NetWeaver 7.5
Keywords
failover, standby, SQL Error, SQLCODE=-1776, SQL1776N, JAVA , KBA , BC-DB-DB6 , DB2 Universal Database for Unix / NT , BC-DB-DB6-DBA , Database Administration , Problem
About this page
This is a preview of a SAP Knowledge Base Article. Click more to access the full version on SAP for Me (Login required).Search for additional results
Visit SAP Support Portal's SAP Notes and KBA Search.