2017-06-21 70 views
0

我知道这是一个跨互联网的着名问题,并有大量的网站显示如何解决这个问题,并且地球上也有很多QA。但没有他们帮助我,我现在感到沮丧。所以我会尽我所能详细说明,如果我忽略了任何内容,我感谢您的帮助。Hadoop:无法加载本机hadoop库

**OS** : Ubuntu 16.04 32 bit 
**Hadoop version** : Hadoop 3.0.0-alpha3 
**bashrc** : 

export HADOOP_HOME=/usr/local/hadoopec/hadoop 
export HADOOP_CONF_DIR=/usr/local/hadoopec/hadoop/etc/hadoop 
export HADOOP_MAPRED_HOME=/usr/local/hadoopec/hadoop 
export HADOOP_COMMON_HOME=/usr/local/hadoopec/hadoop 
export HADOOP_HDFS_HOME=/usr/local/hadoopec/hadoop 
export PATH=$PATH:/usr/local/hadoopec/hadoop/bin 

export JAVA_HOME=/usr/lib/jvm/java-8-openjdk-i386 

export LD_LIBRARY_PATH=/usr/local/hadoopec/hadoop/lib/native/:$LD_LIBRARY_PATH 
#export HADOOP_OPTS="-Djava.library.path=$HADOOP_HOME/lib/native" 

export HADOOP_COMMON_LIB_NATIVE_DIR=$HADOOP_HOME/lib/native 
export HADOOP_OPTS="-Djava.library.path=$HADOOP_HOME/lib" 

**core-site.xml** : 

<property> 
    <name>hadoop.tmp.dir</name> 
    <value>/usr/hadoopec/hadoop/tmp</value> 
    <description>Temporary Directory.</description> 
</property> 

<property> 
    <name>fs.default.name</name> 
    <value>hdfs://localhost:9000</value> 
    <description>Use HDFS as file storage engine</description> 
</property> 

**hdfs-env.sh** 

export HADOOP_OPTS="$HADOOP_OPTS -Djava.library.path=$HADOOP_HOME/lib/native" 
export HADOOP_OPTS="$HADOOP_OPTS -XX:-PrintWarnings -Djava.net.preferIPv4Stack=true" 
export LD_LIBRARY_PATH=/usr/local/hadoopec/hadoop/lib/native/:$LD_LIBRARY_PATH 

**hdfs-site.xml** 

<property> 
<name>dfs.replication</name> 
<value>3</value> 
</property> 

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

<property> 
    <name>dfs.namenode.name.dir</name> 
    <value>/usr/local/hadoopec/hadoop/tmp/hdfs/name</value> 
    </property> 

<property> 
    <name>dfs.datanode.data.dir</name> 
    <value>/usr/local/hadoopec/hadoop/tmp/hdfs/data</value> 
    </property> 

如果有人需要更多的信息,请随时问我。

回答

0

我解决了通过下载hadoop 2.8.0和做所有确切的配置,因为我与以前的hadoop,虽然我不知道究竟是什么导致错误或警告? localhost:50070给我unable to connect错误。如果有人能指出原因,我会很感激。