It took more than 1 days to pack hive, and finally it was ready. The installation steps are documented below.
One: Before installing hive, you need to install Hadoop and MySQL. It's not in here.
II: Download hive0.9.0 (http://archive.apache.org/dist/hive/hive-0.9.0/) and upload it to Ubuntu User directory. Then copy to the/usr directory and unzip. After decompression, change the folder name to hive. The rest is to modify the configuration.
Three: Modify the configuration:
1. Add the Add environment variable in the/etc/profile file.
2. Enter the MySQL shell and enter
(Create user ' hive ' @ ' localhost ' identified by ' hive ';--creating hive User, password also hive);
(Grant all privileges on * * to ' hive ' @ ' localhost ' with grant option;--assign permissions)
(ALTER DATABASE hive character Set latin1;--change character set, consistent with hive)
Create a Database hive
The configuration for MySQL is complete.
3. Download a database connection package (Mysql-connector-java-5.1.18-bin.jar//other version OK) and put it in the/usr/hive/lib folder.
4. Go to the/usr/hive/conf folder.
(1). Copy the Hive-default.xml.template file and rename it to Hive-site.xml.
Go to this file and modify the following several places:
Save exit.
(2). Copy the Hive-env.sh.template file and rename it to hive-env.sh.
Go to this file and modify the following several places:
Save exit.
(3). Copy the Hive-log4j.properties.template file and rename it to Hive-log4j.properties.
Go to this file and modify the following several places:
Save exit.
So the configuration ends. Enter the bin/hive shell into the hive> command line. Enter show tables, such as:
End.
hadoop1.0.0 hbase0.92.0 MySQL and Hive 0.9.0