Results 1 to 8 of 8
  1. #1
    Join Date
    Oct 2008
    Posts
    82

    Cool Unanswered: Dropped table recovery

    Environment :

    db2 9.7 fp 9- DPF
    OS : linux


    accidentally table has been dropped from database. Can some guide me how to recovere the table without interrupting other tables in the tablespace. More than 100 tables are there in tablespace.

    Please let me know if you need any more information.

    Thanks

  2. #2
    Join Date
    Apr 2012
    Posts
    1,035
    Provided Answers: 18
    Have you carried out the instructions in the documentation ?
    http://www-01.ibm.com/support/knowle.../t0006318.html

  3. #3
    Join Date
    Oct 2008
    Posts
    82
    Yes the tablespace is recoverable. But here my doubt is if we restore the tablespace whether it will be effect to other tables that are there in same tablespace ?

  4. #4
    Join Date
    Apr 2012
    Posts
    1,035
    Provided Answers: 18
    you can restore (entire db, or just the tablespace concerned) to a different DB if you want, then copy table content to real target table. Can restore to a different machine also. You can use (remote-)load-from-cursor to copy table content to the real environment if connectivity allows. Or use export and load otherwise.

  5. #5
    Join Date
    Oct 2008
    Posts
    82
    Here my problem is there is no second database and there is no tsm setup in pre prod.
    I need to do it right way in prod. Thats why I am just checking whethere is there any impact to other tables ? or any other way ? please guide me

  6. #6
    Join Date
    Apr 2012
    Posts
    1,035
    Provided Answers: 18
    If you do a tablespace restore, then of course all objects in that tablespace are impacted during the restore and the rollforward(s). Normally this means a service outage.

    If HPU or DB2 Recovery-Expert is available, they can extract data from a backup image. Recovery-Expert can generate the redo SQL.

  7. #7
    Join Date
    May 2012
    Location
    Canberra, Australia
    Posts
    176
    Provided Answers: 6
    How about using db2adutl to extract the backup image from TSM to disk, move it to the pre-prod system, restore the tablespace and extract the data

  8. #8
    Join Date
    Feb 2015
    Posts
    4
    As this is DPF.

    1) use db2adult to extract the last backup image for all of the nodes to disk

    2) copy the backup images to your DR / pre prod server

    3) on DR perform a restore rebuild of the syscatspace and the tablespaces that your table and associated indexes reside in.

    - create a new instance or use an existing instance with the same number of nodes

    - perform a restore of your catalog parition first (usually node 0), but using the rebuild option.
    db2 restore db mydb from /db2backups rebuild with tablespaces (syscatspace, data, indx)

    - perform a restore of the remaining nodes
    db2_all "<<-0< db2 restore db mydb from /db2backup rebuild with tablespaces(data, indx)"

    4) Copy the logs for all the nodes from just before the drop table to the DR server

    5) On the catalog node rollforward the database to a point in time to just before the drop table

    6) Connect to the restore database on DR and export the data, and use db2look to generate the table DDL.


    Cheers,

Posting Permissions

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