suche 36x36
Latest versionsfixlist
11.1.0.7 FixList
10.5.0.9 FixList
10.1.0.6 FixList
9.8.0.5 FixList
9.7.0.11 FixList
9.5.0.10 FixList
9.1.0.12 FixList
Have problems? - contact us.
Register for free anmeldung-x26
Contact form kontakt-x26

DB2 - Problem description

Problem IT17717 Status: Closed

"UOW LOG SPACE USED" IN APP SNAPSHOT NEVER RESET WHEN USING XA
TRANSACTION

product:
DB2 FOR LUW / DB2FORLUW / A50 - DB2
Problem description:
The "UOW log space used" value can grow to impossible high 
values when the application is running in an XA environment. 
 
This is because the counter value will not get reset when doing 
the XPREPARE, and the counter will just increase. 
 
e.g. the following java code will cause the counter to increase, 
although there is a commit that should reset the counter to 0. 
 
public class Main { 
 
    public static void main(String[] args) { 
        try{ 
            DB2XADataSource db2XADataSource = new 
DB2XADataSource(); 
            db2XADataSource.setDatabaseName(args[0]); 
            db2XADataSource.setUser(args[1]); 
            db2XADataSource.setPassword(args[2]); 
 
            XAConnection xaConnection = 
db2XADataSource.getXAConnection(); 
            XAResource xaResource = 
xaConnection.getXAResource(); 
            Xid xid2 = new MyXid(new byte[]{0x20}, new 
byte[]{0x22}); 
            for(int i=0;i<1000000;i++) { 
                xaResource.start(xid2, XAResource.TMNOFLAGS); 
                String sql = "insert into test select * from 
syscat.tables fetch first 10 rows only"; 
 
xaConnection.getConnection().createStatement().execute(sql); 
                xaResource.end(xid2, XAResource.TMSUCCESS); 
                xaResource.prepare(xid2); 
                xaResource.commit(xid2, false); 
                System.out.println("Iteration"+i); 
            } 
 
        } 
        catch (Exception e) 
        { 
            System.out.print(e.getMessage()); 
        } 
    } 
}
Problem Summary:
**************************************************************** 
* USERS AFFECTED:                                              * 
* ALL                                                          * 
**************************************************************** 
* PROBLEM DESCRIPTION:                                         * 
* See Error Description                                        * 
**************************************************************** 
* RECOMMENDATION:                                              * 
* Upgrade to Db2 10.5 Fix Pack 9 or higher                     * 
****************************************************************
Local Fix:
Using MON_GET_UNIT_OF_WORK to retrieve the log space used 
information.
Solution
First fixed in Db2 10.5 Fix Pack 9
Workaround
not known / see Local fix
Timestamps
Date  - problem reported    :
Date  - problem closed      :
Date  - last modified       :
28.10.2016
29.09.2017
29.09.2017
Problem solved at the following versions (IBM BugInfos)
9.0.
Problem solved according to the fixlist(s) of the following version(s)