By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
440,592 Members | 1,958 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 440,592 IT Pros & Developers. It's quick & easy.

How to check data integrity of a DB2 instance?

P: n/a
Hello,

Sorry if this is a basic question but I can't seem to find the answer
in the DB2 tutorial series or my DB2 manuals. How does one check the
data integrity and referential integrity of an instance before running
a backup? I see how one can run "db2ckbkp" after the backup has run,
and I've seen some discussion of checksums in past postings, but what
I'm looking for is more of:

#!/bin/sh
<command to check the data integrity of DB2 instance>
<command to check the referential integrity of a DB2 instance, if not
handled by the previous command>
DB2 BACKUP DATABASE . . .

If anyone is familiar with Informix, something like the "oncheck" or
"onutil check" commands. Thanks to all and any responses, including
flames.

Brice Avila

Nov 12 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
"Brice" <br********@hotmail.com> wrote in message
news:11*********************@c13g2000cwb.googlegro ups.com...
Hello,

Sorry if this is a basic question but I can't seem to find the answer
in the DB2 tutorial series or my DB2 manuals. How does one check the
data integrity and referential integrity of an instance before running
a backup? I see how one can run "db2ckbkp" after the backup has run,
and I've seen some discussion of checksums in past postings, but what
I'm looking for is more of:

#!/bin/sh
<command to check the data integrity of DB2 instance>
<command to check the referential integrity of a DB2 instance, if not
handled by the previous command>
DB2 BACKUP DATABASE . . .

If anyone is familiar with Informix, something like the "oncheck" or
"onutil check" commands. Thanks to all and any responses, including
flames.

Brice Avila

db2ckbkp only checks the backup itself, not the underlying condition of the
database (although in some situations, the backup may fail if there certain
objects are corrupted).

1. You should look at the db2dart command.

2. Also, look at the tablespace "state" using the command:

list tablespaces show detail

The tablespace "state" is in hex, which can be decoded using the Command
Reference manual for this command.

3. Also look at the INSPECT command.

See the Command Reference manual for all the above commands.

4. To check the RI, use "SET INTEGRITY" SQL statement (See SQL Reference Vol
2).
Nov 12 '05 #2

P: n/a
Mark,

Thanks for you help. I'll look into these.

Brice

Nov 12 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.