Tech Tips

  1. プログラミング
  2. 171 view

[Hadoop][Hive]EC2上のUbuntu12.04にインストールしてみる

Hiveをインストールしてみる。
とりあえず、動くところまで。
[hadoop@hadoop server]
$wget http://ftp.tsukuba.wide.ad.jp/software/apache/hive/stable/hive-0.10.0.tar.gz
$tar xvf hive-0.10.0.tar.gz
$exit

[ubuntu@hadoop server]
$sudo mv /home/hadoop/hive-0.10.0 /usr/local/hive
$sudo chown -R hadoop:hadoop /usr/local/hive
$sudo su - hadoop

[hadoop@hadoop server]
$vim .bashrc
export HIVE_HOME=/usr/local/hive
export PATH=$PATH:$HIVE_HOME/bin
$source .bashrc
$mkdir /usr/local/hive/logs
$cp /usr/local/hive/conf/hive-log4j.properties.template /usr/local/hive/conf/log4j.properties
$vim /usr/local/hive/conf/log4j.properties
hive.log.file=hive.log

---->
#hive.log.file=hive.log
hive.log.dir=/usr/local/hive/logs/
$cp /usr/local/hive/conf/hive-env.sh.template /usr/local/hive/conf/hive-env.sh
$chmod 755 /usr/local/hive/conf/hive-env.sh
$cp /usr/local/hive/conf/hive-exec-log4j.properties.template /usr/local/hive/conf/hive-exec-log4j.properties
$cp /usr/local/hive/conf/hive-default.xml.template /usr/local/hive/conf/hive-site.xml
$vim /usr/local/hive/conf/hive-site.xml
 481     we are increasing the number of files possibly by a big margin. So, we      merge aggresively.
 482 </property>
---->
 481     we are increasing the number of files possibly by a big margin. So, we      merge aggresively.
 482   </description>
 483 </property>

 490     tables/partitions. It was added by MAPREDUCE-1501
 491 </property>
----->
 490     tables/partitions. It was added by MAPREDUCE-1501
 491   </description>
 492 </property>

 557     <partition-dir>/c1=1/c2=a/
 558     <partition-dir>/c1=2/c2=b/
 559     <partition-dir>/HIVE_DEFAULT_LIST_BUCKETING_DIR_NAME/HIVE_DEFAULT_LIST_BUCKETING_DIR_NAME/
 560     Note: This config won't impact users if they don't list bucketing.
---->
 557     <partition-dir>/c1=1/c2=a/</partition-dir>
 558     <partition-dir>/c1=2/c2=b/</partition-dir>
 559     <partition-dir>/HIVE_DEFAULT_LIST_BUCKETING_DIR_NAME/HIVE_DEFAULT_LIST_BUCKETING_DIR_NAME/</partition-dir>
 560     Note: This config won't impact users if they don't list bucketing.
$hive
WARNING: org.apache.hadoop.metrics.jvm.EventCounter is deprecated. Please use org.apache.hadoop.log.metrics.EventCounter in all the log4j.properties files.
Logging initialized using configuration in jar:file:/usr/local/hive/lib/hive-common-0.10.0.jar!/hive-log4j.properties
Hive history file=/tmp/hadoop/hive_job_log_hadoop_201305311457_1645609290.txt
hive> show databases;
OK
default
Time taken: 5.689 seconds
なんとか動いた。
hive-default.xml.templateになんでこんな閉じタグミスが多いんだろう?

プログラミングの最近記事

  1. PubSubClient の便利さと注意点

  2. Java の環境構築方法メモ

  3. PlatformIO IDE for VSCode を使用して VSCode で Ardu…

  4. ROS Docker イメージで発生した GPG error の解消方法

  5. Streamlit で訪れた国を色づけした世界地図を作成できるアプリケーションを作成してみ…

関連記事

PAGE TOP