After a long time, I finally installed hive on hadoop2.2. For future materials, I will record the entire process here. If something is wrong, please make a picture! (Installing hive is a little simpler, because you only need to deploy it on one machine)
Download: hive-0.9.0.tar.gz
Decompress the package to a path,
First, copy the extracted mysql-connector-java-5.1.22-bin.jar to the Lib path under/hive
Set environment variables and modify/etc/profile
Hive_home =/opt/hive-0.13.1.
Hadoop_conf_dir = $ hadoop_home/etc/hadoop
Hive_conf_dir = $ hive_home/Conf
Path = $ path: $ hive_home/bin
Export hive_conf_dir hadoop_conf_dir hive_home path
Then configure the hive-size.xml, this configuration can refer to the official website
<Property>
<Name> hive. MetaStore. Local </Name>
<Value> true </value>
</Property>
<Property>
<Name> javax. JDO. Option. connectionurl </Name>
<Value> JDBC: mysql: // mysql_server: 3306/hive? Createdatabaseifnotexist = true </value>
</Property>
<Property>
<Name> javax. JDO. Option. connectiondrivername </Name>
<Value> com. MySQL. JDBC. Driver </value>
</Property>
<Property>
<Name> javax. JDO. Option. connectionusername </Name>
<Value> hadoop (MySQL user name) </value>
</Property>
<Property>
<Name> javax. JDO. Option. connectionpassword </Name>
<Value> hadoop (password) </value>
</Property>
Bytes -------------------------------------------------------------------------------------------
Then I can use the hive command instead of hive.
Bytes -------------------------------------------------------------------------------------------
This article from the "big talk technology" blog, please be sure to keep this source http://youling87.blog.51cto.com/5271987/1438232