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 > Dump DB2

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 09-19-07, 13:04
jackinthebox jackinthebox is offline
Registered User
 
Join Date: Sep 2007
Posts: 1
Dump DB2

Hi,

I'm looking for a possiblity to recreate a DB2 database on a different machine. From phpMyAdmin I know the possibility to create a dump of a database, meaning a file that contains all SQL statements to recreate the database, i.e. all tables and their content. With db2look I was able to create such a file for the structure of the database (just the tables), but not for the content.

Any help would be appreciated!

Thanks!
Jack
Reply With Quote
  #2 (permalink)  
Old 09-19-07, 14:52
ARWinner ARWinner is offline
Registered User
 
Join Date: Jan 2003
Posts: 3,575
If both systems are the same OS and hardware, then you can simply backup the one DB and restore it to the other machine. You might have to do a redirected restore.

Andy
Reply With Quote
  #3 (permalink)  
Old 09-19-07, 19:12
Marcus_A Marcus_A is offline
Registered User
 
Join Date: May 2003
Location: USA
Posts: 5,196
Quote:
Originally Posted by jackinthebox
Hi,

I'm looking for a possiblity to recreate a DB2 database on a different machine. From phpMyAdmin I know the possibility to create a dump of a database, meaning a file that contains all SQL statements to recreate the database, i.e. all tables and their content. With db2look I was able to create such a file for the structure of the database (just the tables), but not for the content.

Any help would be appreciated!

Thanks!
Jack
For the data, use db2move. First do db2move export, and then db2move load (or import). See the Command Reference for details.

I would suggest that you remove all the foreign key DDL from the db2look and then run it after you run the db2move load on the target database.
__________________
M. A. Feldman
IBM Certified DBA on DB2 for Linux, UNIX, and Windows
IBM Certified DBA on DB2 for z/OS and OS/390
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