配置Metastore到MySql
(1)在/usr/local/hadoop/module/hive-1.2.1/conf/目录下创建一个hive-site.xml
[root@hadoop101 ~]# cd /usr/local/hadoop/module/hive-1.2.1/conf/
[root@hadoop101 conf]# touch hive-site.xml
[root@hadoop101 conf]# vi hive-site.xml
(2)根据官方文档配置参数,拷贝数据到hive-site.xml文件中
https://cwiki.apache.org/confluence/display/Hive/AdminManual+MetastoreAdmin
<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="configuration.xsl"?>
<configuration>
<property>
<name>javax.jdo.option.ConnectionURL</name>
<value>jdbc:mysql://localhost:3306/metastore?createDatabaseIfNotExist=true</value>
<description>JDBC connect string for a JDBC metastore</description>
</property>
<property>
<name>javax.jdo.option.ConnectionDriverName</name>
<value>com.mysql.jdbc.Driver</value>
<description>Driver class name for a JDBC metastore</description>
</property>
<property>
<name>javax.jdo.option.ConnectionUserName