Hive Metastore
Hive metastore is the central repository which is used to store Hive metadata. We use embedded H2 database as the default hive metastore. Therefore only one hive session can access the metastore.
Using remote MYSQL database as Hive metastore.
You can configure hive metastore to MYSQL database as follows.
Edit hive-site.xml located at WSO2_BAM2_HOME/repository/conf/advanced/ directory.
<property> <name>javax.jdo.option.ConnectionURL</name> <value>jdbc:mysql://localhost/test_database</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</name> <value>root</value> <description>username to use against metastore database</description> </property> <property> <name>javax.jdo.option.ConnectionPassword</name> <value>root</value> <description>password to use against metastore database</description> </property>
Put MYSQL driver into WSO2_BAM2_HOME/repository/components/lib
Now You have successfully configured the hive metastore to MYSQL database. Now restart the BAM server.
2 comments:
Hi
Can you also share tips on connecting WSO2BAM hive to a fully distributed Hadoop cluster.
We have commented/uncommented the recommended sections from hive-site.xml, but the hive script fails.
Although it seems like the Hive Tables are created, but looks like it fails to submit jobs to Hadoop ( select xyz from hive_table fails)
Thanks
Rajiv
Thank you for your post.hawkscode is one of the best IT service provider. It provides ERP development, IOS development,android development.
Post a Comment