If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > REORGCHK/RUNSTATS and REORG

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 02-01-07, 19:39
meehange meehange is offline
Registered User
 
Join Date: Jul 2004
Posts: 256
REORGCHK/RUNSTATS and REORG

DB2 8.2 on AIX 5.3

Hey there,

I'm attempting to get the stats up to date and the data REORGed on some fairly large systems (+30k tables, 30-160GB DBs).

I've tried REORGCHK with update statistics and also creating a script that does a RUNSTATS with distribution and detailed indexes all.
This has left me with a few questions....

Does the REORCHK update statistics update the statistics information in the syscat tables? (I checked for example the TABLES.STATS_TIME and it seems not updated)

How come a RUNSTATS followed by a REORGCHK current Statistics takes about 2 hours whereas a REORGCHK update statistics take 6-7 hours?!?

Beyond that....

After doing a REORGCHK update statistics I went on to run REORGs ...
For all tables which had a * in F1-3 I ran a
REORG table <taname> allow read access
For tables/indexes with a * in F4-6 I ran
reorg indexes all for table <tabname> allow read access
For tables/indexes with a * in F7 I ran
reorg indexes all for table <tabname> allow write access cleanup only
and for tables/indexes with a * in F8 I ran
reorg indexes all for table <tabname> allow write access cleanup only pages

Now if I run a REORGCHK with update stats again I still have HUNDREDS of tables/indexes with *... Is this normal?
The way it seems to me is that some index REORGs "undo" table reorgs, is this correct?
Is there a suggested order or method that I'm not following?

Cheers
Reply With Quote
  #2 (permalink)  
Old 02-02-07, 03:54
stolze stolze is offline
Registered User
 
Join Date: Jan 2007
Location: Jena, Germany
Posts: 2,662
You can influence whether REORGCHK updates statistics or not. The default is to do the update:
http://publib.boulder.ibm.com/infoce...63%68%6b%22%20

As for the "*" in the output of REORGCHK, you may still see some of them after the reorg because not all conditions can be met all the time. For example, a table can usually only be clustered by 1 index. All other indexes will not be clustered! But it's hard to tell because you didn't provide some sample output from your REORGCHK and the accompanying REORG commands.
__________________
Knut Stolze
IBM DB2 Analytics Accelerator
IBM Germany Research & Development
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On