file0001332675785 0

db2setup on Windows – Repair Option

Sometimes with DB2 on Windows installs just don’t go right. There is a repair mode on db2setup that can help. The Problems There are a number of problems that can manifest. One is a completely successful install on Windows, but the menu items just don’t show up under “all programs” on the start menu. Today, I received this error message...

select2 0

DB2 Administrative SQL Cookbook: Generating a Comma Separated List of Columns in a MON_GET Table Function

Purpose To generate a comma separated list of columns in a MON_GET table function, in the same order you should get the columns if you query the table. This SQL should handle larger tables like MON_GET_DATABASE that have a very large number of columns. This is especially useful when pulling data into Excel to play with it or getting it...

804b26eba5cc743127edb24221f259aa 2

SQL0752N on Rollforward After Redirected Restore

I’d like to think that I’m pretty decent at backup and recovery. I’ve done hundreds of restores in my career in a vast array of scenarios for real-world recovery, data movement, and fixing developers’ mistakes. Today I saw an error I’ve never seen before, so I thought I’d share. The Scenario This restore was grabbing an older backup image from...

select2 0

DB2 Administrative SQL Cookbook: When Were Runstats Done (Beyond STATS_TIME)?

Purpose To list all RUNSTATS done in a database in the last three days, whether manual or automatic. Version Tested on 10.5. Should work on 10.1 and up. Statement select pid, tid, substr(eventtype, 1, 10), substr(objtype, 1, 30) as objtype, substr(objname_qualifier, 1, 20) as objschema, substr(objname, 1, 10) as objname, substr(first_eventqualifier, 1, 26) as event1, substr(second_eventqualifiertype, 1, 2) as event2_type,...

IanB 3

Determining Log Span

Some time ago, I wrote a post that suggested using the NUM_LOG_SPAN database configuration parameter to prevent long-running transactions from filling your transaction log. Using NUM_LOG_SPAN will indeed prevent the problem of long running transcations causing log file saturation, but what if you just want to find applications could become a problem, before the problem happens? Understanding LSNs Most DBAs...

file0001569077358 0

Comparing dsmtop and db2top

dsmtop is a long-awaited refresh of the wildly popular db2top. Like db2top, dsmtop is a free tool, included with DB2. It is in the base DB2 install starting with 11.1, and can be installed on DB2 10.1 or 10.5. History of db2top As I personally recall, db2top first came out of IBM AlphaWorks. My understanding of IBM AlphaWorks is that...

red mask black box 2

Finding the Subnet Mask on AIX

This is something DB2 DBAs may need to do as a part of setting up TSAMP. Nearly every server I’ve done before has had a subnet mask of 255.255.255.0, but I ran into a server recently that wasn’t, and thought I would share how I figured out what it should be (alone, in the middle of the night, during an...

7

Reclaimable Table Spaces

In DB2 9.7, IBM changed the format of table spaces to be “reclaimable”. This has a ton of advantages, but conversion is ridiculously painful. Why Was the Format Changed? Previously, row addresses (referenced in indexes) were relative to the beginning of the table space. This has a number of implications, the main one being that if tables are moved within...

RFE_Subscribe_Roland 5

IBM’s DB2 RFE Program

RFE stands for “Request for Enhancement”. IBM has this program for a number of products, but until late 2016, the RFEs for DB2 on LUW were not publicly available to vote on. Now they are, and we’re seeing action on them. The Problem It can be frustrating to have an issue that IBM describes as “working as designed”. Sometimes these...