IBM Support

IC75112: DB2 MIGHT ENCOUNTER 'DEADLOCK' ERROR WHEN PERFORMING DROP TABLE AND RENAME TABLE SIMULTANEOUSLY.

Subscribe

You can track all active APARs for this component.

 

APAR status

  • Closed as program error.

Error description

  • When concurrently perform RENAME TABLE and DROP TABLE on two
    different tables but with similar namings, the two statements
    may lead to a deadlock among the catalog tables,
    SYSIBM.SYSVIEWDEP and SYSIBM.SYSDEPENDENCIES.
    The problem is more likely to happen if the table being dropped
    has dependent views and other objects (e.g. index or trigger)
    defined on it.
    
    To identify the problem, you need to use DB2 event monitor to
    collect detailed information for deadlocks.
    When the deadlock error occurs, in the event monitor output you
    will see the following entries:
    
    
      Table of lock waited on      : SYSDEPENDENCIES
      Schema of lock waited on    : SYSIBM
      Data partition id for table  : 0
      Tablespace of lock waited on : SYSCATSPACE
      Type of lock: End of table
      Mode of lock: U  - Update
      Mode application requested on lock: U  - Update
        Text    : RENAME TABLE NEWTON.T1
    
      Table of lock waited on      : SYSVIEWDEP
      Schema of lock waited on    : SYSIBM
      Data partition id for table  : 0
      Tablespace of lock waited on : SYSCATSPACE
      Type of lock: Row
      Mode of lock: S  - Share
      Mode application requested on lock: X  - Exclusive
        Text    : DROP TABLE NEWTON.T2
    

Local fix

  • Perform DROP TABLE statement and RENAME TABLE statement
    sequentially.
    

Problem summary

  • ****************************************************************
    * USERS AFFECTED:                                              *
    * All users of version 9.7 on Linux, Unix and Windows          *
    * platforms.                                                   *
    ****************************************************************
    * PROBLEM DESCRIPTION:                                         *
    * When concurrently perform RENAME TABLE and DROP TABLE on two *
    * different tables but with similar namings, the two           *
    * statements may lead to a deadlock among the catalog tables,  *
    * SYSIBM.SYSVIEWDEP and SYSIBM.SYSDEPENDENCIES.                *
    * The problem is more likely to happen if the table being      *
    * dropped has dependent views and other objects (e.g. index or *
    * trigger) defined on it.                                      *
    *                                                              *
    * To identify the problem, you need to use DB2 event monitor   *
    * to collect detailed information for deadlocks.               *
    * When the deadlock error occurs, in the event monitor output  *
    * you will see the following entries:                          *
    *                                                              *
    *                                                              *
    *   Table of lock waited on      : SYSDEPENDENCIES             *
    *   Schema of lock waited on    : SYSIBM                       *
    *   Data partition id for table  : 0                           *
    *   Tablespace of lock waited on : SYSCATSPACE                 *
    *   Type of lock: End of table                                 *
    *   Mode of lock: U  - Update                                  *
    *   Mode application requested on lock: U  - Update            *
    *     Text    : RENAME TABLE NEWTON.T1                         *
    *                                                              *
    *   Table of lock waited on      : SYSVIEWDEP                  *
    *   Schema of lock waited on    : SYSIBM                       *
    *   Data partition id for table  : 0                           *
    *   Tablespace of lock waited on : SYSCATSPACE                 *
    *   Type of lock: Row                                          *
    *   Mode of lock: S  - Share                                   *
    *   Mode application requested on lock: X  - Exclusive         *
    *     Text    : DROP TABLE NEWTON.T2                           *
    ****************************************************************
    * RECOMMENDATION:                                              *
    * Upgrade to DB2 LUW Version 9.7 FixPak 5 or higher levels.    *
    ****************************************************************
    

Problem conclusion

  • First fixed in DB2 LUW Version 9.7 FixPak 5.
    

Temporary fix

  • Perform DROP TABLE statement and RENAME TABLE statement
    sequentially.
    

Comments

APAR Information

  • APAR number

    IC75112

  • Reported component name

    DB2 FOR LUW

  • Reported component ID

    DB2FORLUW

  • Reported release

    970

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt

  • Submitted date

    2011-03-17

  • Closed date

    2012-01-19

  • Last modified date

    2012-01-19

  • APAR is sysrouted FROM one or more of the following:

    IC74950

  • APAR is sysrouted TO one or more of the following:

Fix information

  • Fixed component name

    DB2 FOR LUW

  • Fixed component ID

    DB2FORLUW

Applicable component levels

  • R970 PSN

       UP

[{"Business Unit":{"code":"BU048","label":"IBM Software"},"Product":{"code":"SSEPGG","label":"DB2 for Linux, UNIX and Windows"},"Component":"","ARM Category":[],"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"9.7","Edition":"","Line of Business":{"code":"LOB10","label":"Data and AI"}}]

Document Information

Modified date:
19 January 2012