Question & Answer
Question
This document provides troubleshooting methods for when you encounter the following error in your db2diag.log: Database marked bad. DIA8511C A locked file was encountered. ZRC=0x870F000E
Cause
Another application is accessing and obtaining a lock on file(s) belonging to Db2. The most common cause is an anti-virus application running or a file system (non-Db2) backup. When this occurs Db2 brings the database down by marking it bad, in order to preserve data integrity. The next time the database is restarted it will go through crash recovery.
db2diag -rc 0x870f000e
Input ZRC string '0x870f000e' parsed as 0x870F000E (-2029060082).
ZRC value to map: 0x870F000E (-2029060082)
V7 Equivalent ZRC value: 0xFFFFF60E (-2546)
ZRC class :
Global Processing Error (Class Index: 7)
Component:
SQLO ; oper system services (Component Index: 15)
Reason Code:
14 (0x000E)
Identifer:
SQLO_LOCK
Identifer (without component):
SQLZ_RC_LOCK
Description:
ERROR_LOCK_VIOLATION (DOS)
Answer
Possible causes include anti-virus or file system backups that are scheduled to run concurrently with Db2.
The following directories below should be excluded. Note that the Db2 installation path and database path will vary since they can be placed anywhere.
- Windows®:
Db2 installation path: C:\Program Files\IBM\DB2
Database path (default): <instance name>\NODExxxx i.e. C:\DB2\NODE0000
- UNIX® and Linux®:
Instance path: <instance home>/sqllib i.e. /home/db2inst1/sqllib
Db2 installation path: i.e. /usr/opt/db2_08_01, /opt/IBM/db2/v9
Database path (default): <instance name>/NODExxxx i.e. /home/db2inst1/db2inst1/NODE0000
To determine which process or application is locking a file, you may use the following tools:
- Windows®
Use Process Monitor from the link in the Related URL section of this document.
- UNIX® and Linux®:
Use the command fuser or lsof
Related Information
[{"Type":"MASTER","Line of Business":{"code":"LOB10","label":"Data and AI"},"Business Unit":{"code":"BU058","label":"IBM Infrastructure w\/TPS"},"Product":{"code":"SSEPGG","label":"Db2 for Linux, UNIX and Windows"},"ARM Category":[{"code":"a8m500000008PmFAAU","label":"Operating System or Hardware-\u003EOS Configuration"}],"ARM Case Number":"","Platform":[{"code":"PF002","label":"AIX"},{"code":"PF010","label":"HP-UX"},{"code":"PF016","label":"Linux"},{"code":"PF027","label":"Solaris"},{"code":"PF033","label":"Windows"}],"Version":"10.1.0;10.5.0;11.1.0;11.5.0;9.1.0;9.5.0;9.7.0;9.8.0"}]
Was this topic helpful?
Document Information
Modified date:
11 April 2022
UID
swg21211307