...
Stop all CDAP programs on the master cluster.
Stop CDAP on the master cluster.
Copy any HDFS files that have not yet been copied using either your distro's solution or
distcp
.Run the CDAP replication status tool to retrieve the cluster state:
Code Block [master] $ cdap run io.cdap.cdap.data.tools.ReplicationStatusTool -m -o /tmp/master_state
Copy the master state onto your slave cluster:
Code Block [master] $ scp /tmp/master_state <slave>:/tmp/master_state
Verify that replication has copied the required data onto the slave:
Code Block [slave] $ cdap run io.cdap.cdap.data.tools.ReplicationStatusTool -i /tmp/master_state ... Master and Slave Checksums match. HDFS Replication is complete. HBase Replication is complete.
Run Hive's
metatool
to update the locations for the Hive tables:Code Block [slave] $ hive --service metatool -updateLocation hdfs://[slave-namenode-host]:[slave-namenode-port] \ hdfs://[master-namenode-host]:[master-namenode-port] \ -tablePropKey avro.schema.url -serdePropKey avro.schema.url
Start CDAP on the slave:
Code Block [slave] $ cdap master start