Copying a table from one redshift cluster to another redshift cluster (without using s3)

Can I copy a table from one redshift cluster to another redshift cluster?

I know that copying tables can be achieved using s3 as a temporary storage (i.e. unload s3 from the first cluster and then copy from s3 to another cluster).

+6
source share
1 answer

So the answer is NO. Below is the answer I received from AWS support.

Hello, Thank you very much for contacting AWS Support. With Amazon RedShift, we don’t have a mechanism for directly copying data from a table in a RedShift cluster to another table in another RedShift cluster. The usual procedure to achieve a similar result would be:

(1) UNLOAD to S3, then COPY from S3

With this approach, you use S3 as an intermediate storage. First, you offload the data from the source cluster to S3, then COPY the data from S3 to the target cluster. This is a method that you are familiar with, as well as a method that we recommend. RedShift was designed to work with S3 and can achieve high performance at relatively low cost. For more information about UNLOADD and COPY operations in RedShift, see the following AWS documentation:

http://docs.aws.amazon.com/redshift/latest/dg/t_Unloading_tables.html http://docs.aws.amazon.com/redshift/latest/dg/t_loading-tables-from-s3.html

(2) Using a cluster snapshot

An alternative approach would be to create a snapshot of the source cluster and then restore the snapshot as the target cluster. After that, delete unnecessary tables from the target cluster. The problem is that if you need only a small fraction of the data (for example, one of ten tables) in the target cluster, then you can use a (relatively) large cluster for a (relatively) small application.

For more information about managing RedShift cluster snapshots, see the following AWS documentation:

http://docs.aws.amazon.com/redshift/latest/mgmt/managing-snapshots-console.html

Therefore, we prefer the UNLOAD and COPY process, which is fairly straightforward and cost-effective.

+15
source

Source: https://habr.com/ru/post/986552/


All Articles