Skip to Main Content

Breadcrumb

Question and Answer

Connor McDonald

Thanks for the question, padma.

Asked: June 16, 2016 - 4:38 pm UTC

Last updated: June 18, 2016 - 1:28 am UTC

Version: 11.2.0.4.8

Viewed 10K+ times! This question is

You Asked

Hello Tom

I have been assigned on migrating few 2TB databases which is going fine except for 1 table in all these databases.
I will name the problematic table as BLOB_TABLE_SOURCE. It's size varies from 500Gb to 700GB with 8 columns out of which 5 are BLOB columns.
We have a window of 50hrs to move these databases for go-live.
Tried doing expdp/impdp on BLOB_TABLE_SOURCE itself but it's very slow and doesn't fit in our go-live permitted window.
can you suggest me what options do I have to move this table between databases?

Thank you
-Padma

and Connor said...

OK, let's take a step back for a second.

Depending on the *kind* of migration you need to do, there may be the possibility of not really have to unload/reload your data at all. You might be able just to *convert* the data.

I've written a blog post on this. See here

https://connormcdonald.wordpress.com/2015/06/06/cross-platform-database-migration/

This was used to migrate a multi-TB database with about a 1hr outage.

Take a look at that...if you still want to talk about blob movement, ping us back via a review.

Rating

  (1 rating)

Is this answer out of date? If it is, please let us know via a Comment

Comments

BLOB data alternate approaches

padma katapalli, June 17, 2016 - 4:53 pm UTC

Hello Tom

While this def might be the best way to do, we are limited to on using RMAN.

Also DEV/UAT don't have RMAN. Can you suggest other alternative ways to get this BLOB data to another database.

Regards
-padma


Connor McDonald
June 18, 2016 - 1:28 am UTC

What do you mean "dont have RMAN" ? *Every* Oracle database has RMAN.

If you are saying "we are not ALLOWED to use RMAN"...well that's a different story, and a pretty sad one at that. Because that's like saying "We need to remove some rows, but are not allow to use DELETE".

Why invest in a product like the Oracle Database and then not take advantage of its features?...That's madness.

Anyway...if you want burn up resources and outage windows using non-RMAN methods, I guess I can't stop you.

A CTAS lets you pull blobs across the network, for example

SQL> desc supporting_files@np12
 Name                                                                    Null?    Type
 ----------------------------------------------------------------------- -------- ------------------------------------
 ID                                                                      NOT NULL NUMBER
 DESCRIPTION                                                                      VARCHAR2(4000)
 ADMIN_ID                                                                NOT NULL NUMBER
 FILE_CONTENT                                                                     BLOB
 FILE_NAME                                                                        VARCHAR2(255)
 FILE_MIME_TYPE                                                                   VARCHAR2(255)
 FILE_CHARACTER_SET                                                               VARCHAR2(255)
 FILE_UPDATED_DATE                                                                TIMESTAMP(6) WITH LOCAL TIME ZONE
 FILE_SIZE                                                               NOT NULL NUMBER
 ROW_VERSION                                                             NOT NULL NUMBER
 CREATED_ON                                                              NOT NULL TIMESTAMP(6) WITH LOCAL TIME ZONE
 CREATED_BY                                                              NOT NULL VARCHAR2(255)
 MODIFIED_ON                                                             NOT NULL TIMESTAMP(6) WITH LOCAL TIME ZONE
 MODIFIED_BY                                                             NOT NULL VARCHAR2(255)

mcdonac@db11
SQL> select count(*) from asktom.ate_supporting_files@np12;

  COUNT(*)
----------
         1

SQL> create table local_blob_copy as select  * from supporting_files@np12;

Table created.



So you could do this in parallel, or your own parallelism, ie, multiple CTAS's running in parallel, each with a different WHERE clause to pull over different chunks of the table.

Hope this helps.

More to Explore

Data Pump

All of the database utilities including Data Pump are explained in the Utilities guide.