Writing to HDFS from Java, getting “could only be replicated to 0 nodes instead of minReplication”

后端 未结 11 868
时光取名叫无心
时光取名叫无心 2021-02-01 18:59

I’ve downloaded and started up Cloudera\'s Hadoop Demo VM for CDH4 (running Hadoop 2.0.0). I’m trying to write a Java program that will run from my windows 7 machine (The same

11条回答
  •  再見小時候
    2021-02-01 19:24

    Go to linux VM and check the hostname and iP ADDRESS(use ifconfig cmd). Then in the linux vm edit /etc/host file with

    IPADDRESS (SPALCE) hostname

    example : 192.168.110.27 clouderavm

    and change the all your hadoop configuration files like

    core-site.xml

    hdfs-site.xml

    mapred-site.xml

    yarn-site.xml

    change localhost or localhost.localdomain or 0.0.0.0 to your hostname

    then Restart cloudera manger.

    in the windows machine edit C:\Windows\System32\Drivers\etc\hosts

    add one line at the end with

    you vm machine ip and hostname (same as you done on the /etc/host file in the vm)

    VMIPADRESS VMHOSTNAME

    example :

    192.168.110.27 clouderavm

    then check now, it should work, for detail configuration check following VIDEO from you tube

    https://www.youtube.com/watch?v=fSGpYHjGIRY

提交回复
热议问题