Db2

Db2

Connect with Db2, open source, and other data experts to gain value from your data, share insights, and solve problems.

 View Only
  • 1.  DB2 cross platform migration from on prem to GCP

    Posted 8 days ago

    Hi All,

    I am in the process of migrating an on prem DB2 database to GCP. The on prem DB2 server are windows and GCP Db2 servers are ubuntu 22.04. DB2 version is 11.5.9. Since the OS versions are different a simple backup and restore won't work. I am following the below guide to migrate (our application is Maximo)

    How to move Maximo DB2 database between different platforms

    Ibm remove preview
    How to move Maximo DB2 database between different platforms
    Moving Maximo DB2 database from Windows to Linux
    View this on Ibm >

    The issue is the db2move export is taking a long time, as the current DB size is around 750GB? It is writing at 10-12GB per hour which is really slow and not a feasible approach for production migration. Any recommendations on how to tackle this migration and reduce the downtime required?

    Abhinav



    ------------------------------
    Abhinav Bhuria
    ------------------------------


  • 2.  RE: DB2 cross platform migration from on prem to GCP

    Posted 8 days ago

    Try LOAD from CURSOR method - you will avoid writing intermediate files; did you try db2move export using pipes?



    ------------------------------
    Jan Nelken
    Db2 (LUW) DBA
    Open for work
    Katowice or Krakow
    +48 783 109 863
    ------------------------------



  • 3.  RE: DB2 cross platform migration from on prem to GCP

    Posted 8 days ago

    Hi Jan,

    I am exploring that option, but it requires connectivity between the on prem and the gcp db2 servers correct? Also how fast is this as compared to db2move
    I haven't tried the db2move using pipes will check it out?

    Abhinav



    ------------------------------
    Abhinav Bhuria
    ------------------------------



  • 4.  RE: DB2 cross platform migration from on prem to GCP

    Posted 8 days ago
    Load from cursor and db2move using pipes share the same advantage: data movement does not require physical writes to and physical reads from intermediate disk files it's memory to memory transfer.

    You need to be able to connect to source and target; with db2move using either pipes or physical intermediate files on disk you need connection as well.





  • 5.  RE: DB2 cross platform migration from on prem to GCP

    Posted 8 days ago

    PS 

    You really need connectivity between client and source and between client and target; you do not need connectivity directlyt between source and target.



    ------------------------------
    Jan Nelken
    Db2 (LUW) DBA
    Open for work
    Katowice or Krakow
    +48 783 109 863
    ------------------------------



  • 6.  RE: DB2 cross platform migration from on prem to GCP

    Posted 8 days ago

    Hi Jan,

    Thanks for the response

    So just for clarification. If I have on prem machine A and GCP machine B, in order to use load from cursors or db2move using pipes I can provision a machine C on network, which should be able to connect to both GCP DB2 server and the on prem machine A correct?

    Can you point me to some documentation or examples for this, that would be very helpful?

    Abhinav



    ------------------------------
    Abhinav Bhuria
    ------------------------------



  • 7.  RE: DB2 cross platform migration from on prem to GCP

    Posted 8 days ago

    Start here:

    https://www.ibm.com/docs/en/db2/12.1.x?topic=data-moving-using-cursor-file-type

    Let us know if you need more...:-)



    ------------------------------
    Jan Nelken
    Db2 (LUW) DBA
    Open for work
    Katowice or Krakow
    +48 783 109 863
    ------------------------------



  • 8.  RE: DB2 cross platform migration from on prem to GCP

    Posted 6 days ago

    Hi Abhinav,

    If you have a network connectivity between your local and GCP sites, you have a number of options depending on your skills & abilities.

    1) The one with minimum downtime would be configuration of a logical replication of all tables with a tool like IBM Data Replication (preferably CDC or Q).
    The problem is, that you must have the corresponding skills to install & configure it keeping in mind possible pitfalls (like dealing with trigger-initiated changes, possible errors of an adaptive apply method used by this replication solution, etc) you may face. You must have some scripting skills as well to configure a huge number of source-target pairs.
    The databases synchronization may take a while due to a slow network performance, but this method requires a downtime during the target database switch only.
    You have to alter sequences & generated column values manually with some scripting during the final downtime.

    2) Local offline migration DB2 Windows -> DB2 Ubuntu first, then DB2 HADR between local and GCP DB2 on the same platform.
    You should use some custom approach based on DB2 load from a remote cursor, since db2move doesn't provide any parallelism, can't load tables with some types of columns (like generated always, but maximo databases don't have them afaik). Such a local migration should be much faster than a remote one because of slow network -> downtime should be much smaller.



    ------------------------------
    Mark Barinstein
    ------------------------------



  • 9.  RE: DB2 cross platform migration from on prem to GCP

    Posted 5 days ago

    Hi Abhinav,

    the approach proposed by Mark usinage a data replications is effectively the pne which will provide you the fastest was to migrate the Database data for your source db to the target GCP as long as you have skills and experience in the data replication tool.

    otherwise, trou will have to use db2 load from cursor command to migrate each source table to its corresponding target table (After having created all tables, indexes,.. in the Target dB using db2look).

    best way. Is to use several connection to the database in order you can migrate tables in parallel ( pay attention to not process all the tables in parallel if z you don't want to have performance issues at network and/or disk level).


    -----------

    Christian Arnoux
    -----------



    ------------------------------
    Christian Arnoux
    ------------------------------