FAQ
Hi



I am facing an issue while starting my hadoop cluster.



When I run the command:



$ bin/hadoop namenode -format



I found this exception:



/home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 2:
$'\r': command not found

/home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 7:
$'\r': command not found

/home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 10:
$'\r': command not found

/home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 13:
$'\r': command not found

/home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 16:
$'\r': command not found

/home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 19:
$'\r': command not found

/home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 29:
$'\r': command not found

/home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 32:
$'\r': command not found

/home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 35:
$'\r': command not found

/home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 38:
$'\r': command not found

/home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 41:
$'\r': command not found

/home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 46:
$'\r': command not found

/home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 49:
$'\r': command not found

/home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 52:
$'\r': command not found

/bin/java: No such file or directorymin/java/jdk1.6.0_13

/bin/java: No such file or directorymin/java/jdk1.6.0_13

/bin/java: cannot execute: No such file or directorydk1.6.0_13



Also in "home/HadoopAdmin/hadoop-0.18.3/bin/conf/hadoop-env.sh"I set my
java home as where I have installed java as:



export JAVA_HOME=/home/HadoopAdmin/java/jdk1.6.0_13



Please help me on this issue.



Regards

Aseem Puri

Search Discussions

  • Vikas at Aug 26, 2009 at 6:41 am
    can you run "dos2unix /home/HadoopAdmin/hadoop-0.18.3/bin/../conf/*.sh" and
    then try again.

    Thanks,
    -Vikas.
    On Wed, Aug 26, 2009 at 11:56 AM, Puri, Aseem wrote:

    Hi



    I am facing an issue while starting my hadoop cluster.



    When I run the command:



    $ bin/hadoop namenode -format



    I found this exception:



    /home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 2:
    $'\r': command not found

    /home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 7:
    $'\r': command not found

    /home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 10:
    $'\r': command not found

    /home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 13:
    $'\r': command not found

    /home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 16:
    $'\r': command not found

    /home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 19:
    $'\r': command not found

    /home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 29:
    $'\r': command not found

    /home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 32:
    $'\r': command not found

    /home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 35:
    $'\r': command not found

    /home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 38:
    $'\r': command not found

    /home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 41:
    $'\r': command not found

    /home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 46:
    $'\r': command not found

    /home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 49:
    $'\r': command not found

    /home/HadoopAdmin/hadoop-0.18.3/bin/../conf/hadoop-env.sh: line 52:
    $'\r': command not found

    /bin/java: No such file or directorymin/java/jdk1.6.0_13

    /bin/java: No such file or directorymin/java/jdk1.6.0_13

    /bin/java: cannot execute: No such file or directorydk1.6.0_13



    Also in "home/HadoopAdmin/hadoop-0.18.3/bin/conf/hadoop-env.sh"I set my
    java home as where I have installed java as:



    export JAVA_HOME=/home/HadoopAdmin/java/jdk1.6.0_13



    Please help me on this issue.



    Regards

    Aseem Puri




  • Prashant Chauhan at May 29, 2012 at 10:10 am
    Thanks

    This solution works for me on hadoop-1.0.3
    Actually i have edited .sh file using wordpad and then after notepad++.
    i am finding solution of the problem since 10 - 15 days.


    thank you
    Thanks a lot

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupcommon-user @
categorieshadoop
postedAug 26, '09 at 6:27a
activeMay 29, '12 at 10:10a
posts3
users3
websitehadoop.apache.org...
irc#hadoop

People

Translate

site design / logo © 2022 Grokbase