Hive Performance Tuning
Copyright © 2012-2015 Hortonworks, Inc.
Except where otherwise noted, this document is licensed under Creative Commons Attribution ShareAlike 4.0 License |
2015-12-21
Abstract
The Hortonworks Data Platform, powered by Apache Hadoop, is a massively scalable and 100% open source platform for storing, processing and analyzing large volumes of data. It is designed to deal with data from many sources and formats in a very quick, easy and cost-effective manner. The Hortonworks Data Platform consists of the essential set of Apache Hadoop projects including MapReduce, Hadoop Distributed File System (HDFS), HCatalog, Pig, Hive, HBase, ZooKeeper and Ambari. Hortonworks is the major contributor of code and patches to many of these projects. These projects have been integrated and tested as part of the Hortonworks Data Platform release process and installation and configuration tools have also been included.
Unlike other providers of platforms built using Apache Hadoop, Hortonworks contributes 100% of our code back to the Apache Software Foundation. The Hortonworks Data Platform is Apache-licensed and completely open source. We sell only expert technical support, training and partner-enablement services. All of our technology is, and will remain, free and open source.
Please visit the Hortonworks Data Platform page for more information on Hortonworks technology. For more information on Hortonworks services, please visit either the Support or Training page. Feel free to contact us directly to discuss your specific needs.
Contents
- 1. Hive Architectural Overview
- 2. Hive High Performance Best Practices
- Use the Tez Query Execution Engine
- Use the ORC File Format
- Use Column Statistics and the Cost-Based Optimizer (CBO)
- Design Data Storage Smartly
- Better Workload Management by Using Queues
- Hive Setup for Using Multiple Queues
- Guidelines for Interactive Queues
- Guidelines for a Mix of Batch and Interactive Queues
- Create and Configure YARN Capacity Scheduler Queues
- Refreshing YARN Queues with Changed Settings
- Setting Up Interactive Queues for HDP 2.2
- Hive, Tez, and YARN Settings in Ambari 2.x and HDP 2.x
- Setting Up Queues for Mixed Interactive and Batch Workloads
- 3. Configuring Memory Usage
- 4. Query Optimization
List of Figures
- 1.1. SQL Query Execution Process
- 1.2. SQL Query Execution Process
- 2.1. Tez Query Execution Compared to MapReduce
- 2.2. ORC File Structure
- 2.3. Hive Data Abstractions
- 2.4. Cluster Configuration Using Queues
- 2.5. Hive Setup Using Multiple Queues
- 2.6. Multiple HiveServer2 Installation
- 2.7. YARN Capacity Scheduler
- 2.8. Ambari Capacity Scheduler View
- 2.9. Interactive Query Pane of Hive Configuration Page in Ambari
- 2.10. Optimization Pane of Hive Configuration Page in Ambari
- 2.11. Ordering Policy Setting in Ambari
- 3.1. Tez Container Configuration in Hive Web UI of Ambari
- 4.1. Garbage Collection Time
List of Tables