Results 1 to 5 of 5
  1. #1
    Join Date
    Aug 2011
    Location
    Mumbai,India
    Posts
    49

    Unanswered: How to maintain copies of system table and ddl

    Hi,

    How to maintain copies of system table and ddl??

    Is it possible without taking tablespace level backup.

    DB2 v9.5 fp5.

    Request help.

  2. #2
    Join Date
    May 2003
    Location
    USA
    Posts
    5,737
    Look at the db2look command in the Command Reference manual. Make sure you use a different terminator such a '@' so you could easily re-generate the stored procedures, functions, triggers if necessary. There are lots of options, such as caputuring statistics, grants, etc that you can use.

    For db2set, db cfg, and dbm cfg, just put those in a scipt to display the contents and pipe to a file.
    M. A. Feldman
    IBM Certified DBA on DB2 for Linux, UNIX, and Windows
    IBM Certified DBA on DB2 for z/OS and OS/390

  3. #3
    Join Date
    Aug 2011
    Location
    Mumbai,India
    Posts
    49
    Will db2look output also contain ddl's of system tables??

    My actual moto is to take backup of system table data and ddls.

    i can do it by taking tablespace level backup SYSCATSPACE.

    but i am looking for an alternative.

    Request help.
    Last edited by shore; 08-26-11 at 08:52.

  4. #4
    Join Date
    May 2003
    Location
    USA
    Posts
    5,737
    Quote Originally Posted by shore View Post
    Will db2look output also contain ddl's of system tables??

    My actual moto is to take backup of system table data and ddls.

    i can do it by taking tablespace level backup SYSCATSPACE.

    but i am looking for an alternative.

    Request help.
    No, you cannot do that. Even if you could, you it would be of no use whatsoever since you cannot create system catalog tables (they are created automatically when a database is created), and only a very small number of columns in the catalog are updateable. If you want to take a backup, backup the entire database. In the event of a disaster, if have the complete db2look output from the old database, you can create a new database, then run the db2look output, then you will have the system catalog schema and system catalog data (with possibly some minor exceptions that can be fixed if do a runstats on all the tables).

    DB2 LUW is not like DB2 z/OS and we don't backup just the system catalog.
    M. A. Feldman
    IBM Certified DBA on DB2 for Linux, UNIX, and Windows
    IBM Certified DBA on DB2 for z/OS and OS/390

  5. #5
    Join Date
    Aug 2011
    Location
    Mumbai,India
    Posts
    49
    Thanks Marcus.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •