您的位置:首页 > 数据库 > MySQL

Statistics in Hive的mysql配置

2014-01-27 11:10 375 查看
HIVE执行insert overwrite时候默认会有临时的统计数据在derby数据库中。改成mysql库配置如下:

<property>
<name>hive.stats.dbclass</name>
<!-- <value>jdbc:derby</value>-->
<value>jdbc:mysql</value>
<description>The default database that stores temporary hive statistics.</description>
</property>
<property>
<name>hive.stats.jdbcdriver</name>
<!--  <value>org.apache.derby.jdbc.EmbeddedDriver</value>-->
<value>com.mysql.jdbc.Driver</value>
<description>The JDBC driver for the database that stores temporary hive statistics.</description>
</property>

<property>
<name>hive.stats.dbconnectionstring</name>
<!-- <value>jdbc:derby:;databaseName=TempStatsStore;create=true</value> -->
<value>jdbc:mysql://IP:port/hive_datapool?CreateDatabaseIfNotExist=true&user= your_user&password= your_ password </value>
<description>The default connection string for the database that stores temporary hive statistics.</description>
</property>


更详细的官方文档:https://cwiki.apache.org/confluence/display/Hive/StatsDev
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  Hive