Run Compaction on Hive Tables
You must use the Hive pre-upgrade tool JAR you downloaded to run compaction on Hive tables. The pre-upgrade tool looks for files in an ACID table that contains update or delete events, and generates scripts to compact these tables. You can run the pre-upgrade tool command on the command line before or after upgrading Ambari. You do not actually use Ambari to run this command.