Unix Technical Forum

Migrate DB2

This is a discussion on Migrate DB2 within the DB2 forums, part of the Database Server Software category; --> Hello people, I would like your assistance here. I have a DB2 V8 database on Windows 2003. I would ...


Go Back   Unix Technical Forum > Database Server Software > DB2

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 02-27-2008, 07:32 AM
DMina@laiki.com
 
Posts: n/a
Default Migrate DB2

Hello people,

I would like your assistance here.
I have a DB2 V8 database on Windows 2003.
I would like to migrate this database on AIX 5.3 (keep the same
database version).
Any documentation how to achieve this?
Any procedure or migration tool?
Will a backup and restore do?

Thank you

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 02-27-2008, 07:32 AM
Serge Rielau
 
Posts: n/a
Default Re: Migrate DB2

DMina@laiki.com wrote:
> Hello people,
>
> I would like your assistance here.
> I have a DB2 V8 database on Windows 2003.
> I would like to migrate this database on AIX 5.3 (keep the same
> database version).
> Any documentation how to achieve this?
> Any procedure or migration tool?
> Will a backup and restore do?

Backup/restore will not work due to the difference in endian-nes.
You will need to look at db2move or my backup schema article:
http://www.ibm.com/developerworks/db...dm-0602rielau/

If you have more than one schema and they are not well encapsulated the
procedures can be easily extended.

Cheers
Serge
--
Serge Rielau
DB2 Solutions Development
IBM Toronto Lab
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 02-27-2008, 07:32 AM
Mark A
 
Posts: n/a
Default Re: Migrate DB2

<DMina@laiki.com> wrote in message
news:1143526906.263551.272160@t31g2000cwb.googlegr oups.com...
> Hello people,
>
> I would like your assistance here.
> I have a DB2 V8 database on Windows 2003.
> I would like to migrate this database on AIX 5.3 (keep the same
> database version).
> Any documentation how to achieve this?
> Any procedure or migration tool?
> Will a backup and restore do?
>
> Thank you
>


Use db2look to pull all the DDL and run that on your new system (changing
the container names of tablespaces as needed). Make sure you use the right
options to pull all the DDL including the tablespaces and bufferpools.

Then use "db2move export" to pull the data, and then "db2move load" to load
the data back to the new system.


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 02-27-2008, 07:32 AM
Mondongo
 
Posts: n/a
Default Re: Migrate DB2

Another thing you can do is to create your new AIX db from scratch and
federate it with your existing one on windows 2003.

Use db2look...etc. etc. (as stated in your responses) to create the
empty objects in your AIX db and then import the data either with
insert into or with declare cursor + load (depending on the size of the
table to migrate).

Small tables: use insert into
Big tables: use declare cursor + load.

I hope this helps.

DMina@laiki.com wrote:
> Hello people,
>
> I would like your assistance here.
> I have a DB2 V8 database on Windows 2003.
> I would like to migrate this database on AIX 5.3 (keep the same
> database version).
> Any documentation how to achieve this?
> Any procedure or migration tool?
> Will a backup and restore do?
>
> Thank you


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5 (permalink)  
Old 02-27-2008, 07:33 AM
DMina@laiki.com
 
Posts: n/a
Default Re: Migrate DB2

Thank you very much for the responses.

Another question: how do i move user defined functions and procedures?

Thanks

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #6 (permalink)  
Old 02-27-2008, 07:33 AM
Mark A
 
Posts: n/a
Default Re: Migrate DB2

<DMina@laiki.com> wrote in message
news:1143612488.005562.115910@j33g2000cwa.googlegr oups.com...
> Thank you very much for the responses.
>
> Another question: how do i move user defined functions and procedures?
>
> Thanks
>


They will be in the db2look output (if you use the correct parms to extract
them). However, you will have put them in a separate file to reapply them,
and include a terminator such as @ at the end of each object The ";"
terminator will be used at the end of each statement), and then use the
following to create them:
db2 -td@ -vf file-name (where file-name contains the syntax of the
procedures, UDF's, and triggers).


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #7 (permalink)  
Old 02-27-2008, 07:33 AM
Serge Rielau
 
Posts: n/a
Default Re: Migrate DB2

DMina@laiki.com wrote:
> Thank you very much for the responses.
>
> Another question: how do i move user defined functions and procedures?
>
> Thanks
>

SQL Functions and Procedures should be part of db2look.
You may have to run the script a few times due to dependencies.
For external UDF/Procedures (C/Java/CLR) you have to make sure you
migrate the libraries.

Cheers
Serge
--
Serge Rielau
DB2 Solutions Development
IBM Toronto Lab
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 07:12 PM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com