简体   繁体   English

CDH4 Hive配置

[英]CDH4 Hive Configuration

I am facing Permission denied error while creating HIVE table . 我在创建HIVE表时面临Permission denied错误。 Below is the detail description what I did . 以下是我所做的详细说明。

I have 2 node clusture running on Ubuntu12.04 . 我在Ubuntu12.04上运行了2个节点clusture。 I have installed CDH4.7.0 and they are up and running . 我已安装CDH4.7.0,它们已启动并正在运行。 I have installed HIVE by issuing below command . 我通过发出以下命令安装了HIVE。 Apart from this command I did nothing for configuration as I have no idea what to do after installation: 除了这个命令,我没有做任何配置,因为我不知道安装后要做什么:

sudo apt-get install hive

After installation I started HIVE . 安装完毕后我就开始了HIVE。 But when I am trying to create table I am getting below exception . 但是当我试图创建表格时,我会遇到异常。 I am not sure what permission I need to provide to which folder or user . 我不确定我需要向哪个文件夹或用户提供什么权限。

FAILED: Error in metadata: MetaException(message:Got exception: org.apache.hadoop.security.AccessControlException Permission denied: user=root, access=WRITE, inode="/user":hdfs:hadoop:drwxr-xr-x

I am running HIVE query under root user . 我在root用户下运行HIVE查询。

This Error is related to HDFS;you can solve this problem temporary by disabling the dfs permission.By adding below property code to hdfs-site.xml 此错误与HDFS有关;您可以通过禁用dfs权限临时解决此问题。通过将以下属性代码添加到hdfs-site.xml

<property>
    <name>dfs.permissions</name>
    <value>false</value>
  </property>

if you want more options : Permission denied at hdfs 如果您想要更多选项: hdfs权限被拒绝

或者,您可以使用它来解决它:

hadoop fs -chmod -R 777 /user/hive/warehouse/

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM