Results 1 to 7 of 7
  1. #1
    Join Date
    Nov 2007
    Posts
    62

    Unanswered: Do I need db2relocatedb ?

    Hello,

    I have two db2 instances with same names on separate machines.
    There is database in each of these instances with the same name and the same structure( I mean same number of tablespaces the same size of container files ).
    The only difference is data on these db's .

    So if I want to move db from one instance to another do I need db2relocatedb ?
    (basically I'm asking because instance names are the same, if they would be different there would be no question)

    thanks
    Vilius

  2. #2
    Join Date
    Jan 2009
    Location
    Zoetermeer, Holland
    Posts
    746
    I'd go for a "redirected restore".

  3. #3
    Join Date
    Nov 2007
    Posts
    62
    Redirected restore is not an option because it consumes a lot of time (backup time + restore time (only restore takes 4h on my db) )

    I must do that as fast as possible

    Vilius

  4. #4
    Join Date
    Jan 2009
    Location
    Zoetermeer, Holland
    Posts
    746
    Quote Originally Posted by vilius
    on separate machines
    Tell me more about storage. Local disks or SAN? Can the LUN containing the data be mounted by the other server? Are you entering the serverroom with a screwdriver between your teeth to change disks?
    If not, you dó have to copy the data....... and I repeat myself: "redirected restore"

  5. #5
    Join Date
    Nov 2007
    Posts
    62
    Yes disks are on SAN. I can mount them on target system with no problems.

  6. #6
    Join Date
    Jan 2009
    Location
    Zoetermeer, Holland
    Posts
    746
    In that case db2relocatedb would be the fastest. Be carefull, test and .... I'd make a backup first

  7. #7
    Join Date
    Dec 2008
    Location
    Toronto, Canada
    Posts
    399
    Quote Originally Posted by vilius
    Hello,

    I have two db2 instances with same names on separate machines.
    There is database in each of these instances with the same name and the same structure( I mean same number of tablespaces the same size of container files ).
    The only difference is data on these db's .

    So if I want to move db from one instance to another do I need db2relocatedb ?
    (basically I'm asking because instance names are the same, if they would be different there would be no question)

    thanks
    Vilius
    so generally you need to move data (if db structures are the same), right?

    I guess you would need to ftp your backup file from one server to another and then do restore.

    I just did the move of the database from one instance to another within same server and it was fast. I backuped db on one instance and restored on another, then deleted the source db. My target db did not exist so I did not have to use 'restore redirect'. You might want to drop the target db right before restoring and in this case you don't have to use 'restore redirect'.
    Last edited by MarkhamDBA; 02-03-09 at 16:44.
    DB2 9.5/9.7 on Unix/AIX 6.1/Linux

Posting Permissions

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