Best way to duplicate a partitioned table in Hive

A simple google search for the above will land you here:
http://grokbase.com/t/hive/user/097w0bsnne/best-way-to-duplicate-a-table

But, I believe a better way is:

  1. Create the new target table with the schema from the old table
  2. Use hadoop fs -cp to copy all the partitions from source to target table
  3. Run MSCK REPAIR TABLE table_name; on the target table
 
519
Kudos
 
519
Kudos

Now read this

Basic Monitoring for Hadoop Data Nodes

Here’s a basic monitoring script to monitor the HDFS cluster disk space, Temp Dir space and number of data nodes up. This was plenty useful before we switched to Cloudera Manager. #!/usr/bin/env ruby # Checks Hadoop and alerts if there... Continue →