<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Re: issue with hadoop -bash: hadoop: command not found in Archives of Support Questions (Read Only)</title>
    <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/24904#M5022</link>
    <description>&lt;P&gt;Thanks alot Gautam , its working fine now after restart , I can access hadoop file system @namenode machine &amp;nbsp;now from command line &amp;nbsp;. many many thanks for your help here !!!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;By the way shall I run this command on data node as well ? i logged in to one of data node and its not able to recognize hadoop there&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;[root@hadoopvm1 ~]# hadoop fs -ls /&lt;BR /&gt;-bash: hadoop: command not found&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;service cloudera-scm-agent restart ?&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Sun, 22 Feb 2015 10:18:13 GMT</pubDate>
    <dc:creator>Navneet346</dc:creator>
    <dc:date>2015-02-22T10:18:13Z</dc:date>
    <item>
      <title>issue with hadoop -bash: hadoop: command not found</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/24879#M5015</link>
      <description>&lt;P&gt;Hi Team facing a very strange issue with cloudera latest installation. I am able to view the HDFS directory from web interface, but when i run a simple hadoop fs -ls in putty shell , it says&amp;nbsp;-bash: hadoop: command not found. &amp;nbsp;while i can see all HDFS files from web interface. Can you please help.&lt;/P&gt;&lt;P&gt;[root@hadoop-vm3 log]# hadoop fs -ls /&lt;BR /&gt;-bash: hadoop: command not found&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Version&lt;/STRONG&gt;: Cloudera Express 5.3.1 (#191 built by jenkins on 20150123-2020 git: b0377087cf605a686591e659eb14078923bc3c83)&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Server Time&lt;/STRONG&gt;: Feb 20, 2015 1:29:11 PM, Eastern Standard Time (EST)&lt;/P&gt;&lt;P&gt;Copyright © 2011-2014 Cloudera, Inc. All rights reserved.&lt;BR /&gt;Hadoop and the Hadoop elephant logo are trademarks of the Apache Software Foundation.&lt;/P&gt;&lt;DIV class="page-header"&gt;Browse Directory&lt;/DIV&gt;&lt;DIV class="row"&gt;&lt;DIV class="input-group"&gt;&lt;SPAN class="input-group-btn"&gt;&lt;SPAN class="input-group-btn"&gt;Go!&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV class="input-group"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="input-group"&gt;&lt;SPAN class="input-group-btn"&gt;&lt;SPAN class="input-group-btn"&gt;/user/hive/warehouse/cdr_test_demo_self_partition&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV class="input-group"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="input-group"&gt;Permission Owner Group Size Replication Block Size Name &lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;drwxrwxrwt&lt;/TD&gt;&lt;TD&gt;admin&lt;/TD&gt;&lt;TD&gt;hive&lt;/TD&gt;&lt;TD&gt;0 B&lt;/TD&gt;&lt;TD&gt;0&lt;/TD&gt;&lt;TD&gt;0 B&lt;/TD&gt;&lt;TD&gt;&lt;A target="_blank"&gt;.hive-staging_hive_2015-02-20_04-40-09_720_8287848305105515146-1&lt;/A&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;drwxrwxrwt&lt;/TD&gt;&lt;TD&gt;root&lt;/TD&gt;&lt;TD&gt;hive&lt;/TD&gt;&lt;TD&gt;0 B&lt;/TD&gt;&lt;TD&gt;0&lt;/TD&gt;&lt;TD&gt;0 B&lt;/TD&gt;&lt;TD&gt;&lt;A target="_blank"&gt;ttime=2015-02-20&lt;/A&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;drwxrwxrwt&lt;/TD&gt;&lt;TD&gt;root&lt;/TD&gt;&lt;TD&gt;hive&lt;/TD&gt;&lt;TD&gt;0 B&lt;/TD&gt;&lt;TD&gt;0&lt;/TD&gt;&lt;TD&gt;0 B&lt;/TD&gt;&lt;TD&gt;&lt;P&gt;&lt;A target="_blank"&gt;ttime=2015-02-21&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 16 Sep 2022 09:22:06 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/24879#M5015</guid>
      <dc:creator>Navneet346</dc:creator>
      <dc:date>2022-09-16T09:22:06Z</dc:date>
    </item>
    <item>
      <title>Re: issue with hadoop -bash: hadoop: command not found</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/24890#M5016</link>
      <description>Check what /etc/alternatives/hadoop points to, most likely it would be&lt;BR /&gt;to an unavailable parcel. The simplest way to resolve this is&lt;BR /&gt;- check all files under /var/lib/alternatives for references to invalid parcels&lt;BR /&gt;- delete those references, ensuring the reference to 5.3.1 is present&lt;BR /&gt;and is the first option&lt;BR /&gt;- restart the Cloudera Manager agent, this will set up alternatives again&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Sat, 21 Feb 2015 05:12:33 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/24890#M5016</guid>
      <dc:creator>GautamG</dc:creator>
      <dc:date>2015-02-21T05:12:33Z</dc:date>
    </item>
    <item>
      <title>Re: issue with hadoop -bash: hadoop: command not found</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/24894#M5017</link>
      <description>&lt;P&gt;Hi Gautam&amp;nbsp;&lt;/P&gt;&lt;P&gt;thanks alot for your reply , need some more info to fix this. can this be fixed from cloudera manager or i need to fix it on each machine by running some command&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I checked&amp;nbsp;&lt;SPAN&gt; /etc/alternatives/hadoop and it points to&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;hadoop -&amp;gt; /opt/cloudera/parcels/CDH-5.3.1-1.cdh5.3.1.p0.5/bin/hadoop&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;while in&amp;nbsp;/var/lib/alternatives &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;also i found that hadoop is there . Now I am not sure what to delete here..?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;So my question is how to restore this for all hadoop command like hadoop/hive etc....just to give you backgroud when this issue started, i got some configuration warning in cloudera manager and it was referring some outdated parcel etc, i just fixed that warning and this issue started. so is there any way i can fix this from cloudera manager. your help will be really appericiated ....&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;one interesting thing i noticed that when i gave the complete path , its able to list files&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;[root@hadoop-vm3 bin]# /opt/cloudera/parcels/CDH-5.3.1-1.cdh5.3.1.p0.5/bin/hadoop fs -ls /&lt;BR /&gt;Found 4 items&lt;BR /&gt;drwxr-xr-x - hbase hbase 0 2015-02-20 05:41 /hbase&lt;BR /&gt;drwxrwxr-x - solr solr 0 2015-02-18 04:50 /solr&lt;BR /&gt;drwxrwxrwt - hdfs supergroup 0 2015-02-20 06:44 /tmp&lt;BR /&gt;drwxr-xr-x - hdfs supergroup 0 2015-02-20 00:54 /user&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;==========================================================================&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;[root@hadoop-vm3 bin]# ls /var/lib/alternatives/&lt;BR /&gt;avro-tools hadoop-httpfs-conf hiveserver2 jre_openjdk mapred solr-conf sqoop-create-hive-table sqoop-version&lt;BR /&gt;beeline hadoop-kms-conf hive-webhcat-conf kite-dataset mta solrctl sqoop-eval statestored&lt;BR /&gt;catalogd hbase hue-conf libnssckbi.so.x86_64 oozie spark-conf sqoop-export whirr&lt;BR /&gt;cli_mt hbase-conf impala-conf links oozie-conf spark-executor sqoop-help yarn&lt;BR /&gt;cli_st hbase-indexer impalad llama pig spark-shell sqoop-import zookeeper-client&lt;BR /&gt;flume-ng hbase-solr-conf impala-shell llamaadmin pig-conf spark-submit sqoop-import-all-tables zookeeper-conf&lt;BR /&gt;flume-ng-conf hcat ip6tables.x86_64 llama-conf print sqoop sqoop-job zookeeper-server&lt;BR /&gt;hadoop hdfs iptables.x86_64 load_gen pyspark sqoop2 sqoop-list-databases zookeeper-server-cleanup&lt;BR /&gt;hadoop-0.20 hive java mahout sentry sqoop2-conf sqoop-list-tables zookeeper-server-initialize&lt;BR /&gt;hadoop-conf hive-conf jre_1.6.0 mahout-conf sentry-conf sqoop-codegen sqoop-merge&lt;BR /&gt;hadoop-fuse-dfs hive-hcatalog-conf jre_1.7.0 mail senty-conf sqoop-conf sqoop-metastore&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;SPAN&gt;==========================================================================&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 21 Feb 2015 20:18:53 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/24894#M5017</guid>
      <dc:creator>Navneet346</dc:creator>
      <dc:date>2015-02-21T20:18:53Z</dc:date>
    </item>
    <item>
      <title>Re: issue with hadoop -bash: hadoop: command not found</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/24895#M5018</link>
      <description>Can you paste the contents of /var/lib/alternatives/HADOOP here?&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Sat, 21 Feb 2015 21:06:33 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/24895#M5018</guid>
      <dc:creator>GautamG</dc:creator>
      <dc:date>2015-02-21T21:06:33Z</dc:date>
    </item>
    <item>
      <title>Re: issue with hadoop -bash: hadoop: command not found</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/24898#M5019</link>
      <description>&lt;P&gt;HI Gautam&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;please find the conetent as below, let me know next...&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;[root@hadoop-vm3 alternatives]# pwd&lt;BR /&gt;/var/lib/alternatives&lt;BR /&gt;[root@hadoop-vm3 alternatives]# cat hadoop&lt;BR /&gt;auto&lt;BR /&gt;/usr/bin/hadoop&lt;/P&gt;&lt;P&gt;/opt/cloudera/parcels/CDH-5.3.1-1.cdh5.3.1.p0.5/bin/hadoop&lt;BR /&gt;10&lt;BR /&gt;[root@hadoop-vm3 alternatives]#&lt;/P&gt;</description>
      <pubDate>Sun, 22 Feb 2015 02:24:40 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/24898#M5019</guid>
      <dc:creator>Navneet346</dc:creator>
      <dc:date>2015-02-22T02:24:40Z</dc:date>
    </item>
    <item>
      <title>Re: issue with hadoop -bash: hadoop: command not found</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/24900#M5020</link>
      <description>That does tally with what I see. Are you able to&lt;BR /&gt;- verify that the file&lt;BR /&gt;"/opt/cloudera/parcels/CDH-5.3.1-1.cdh5.3.1.p0.5/bin/hadoop" actually exists&lt;BR /&gt;- restart the Cloudera Manager agent&lt;BR /&gt;# service cloudera-scm-agent restart&lt;BR /&gt;- check if the /usr/bin/hadoop symlink has been created&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Sun, 22 Feb 2015 06:13:33 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/24900#M5020</guid>
      <dc:creator>GautamG</dc:creator>
      <dc:date>2015-02-22T06:13:33Z</dc:date>
    </item>
    <item>
      <title>Re: issue with hadoop -bash: hadoop: command not found</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/24903#M5021</link>
      <description>&lt;P&gt;yes file does exist and it has below content&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;[root@hadoop-vm3 ~]# cat /opt/cloudera/parcels/CDH-5.3.1-1.cdh5.3.1.p0.5/bin/hadoop&lt;BR /&gt;#!/bin/bash&lt;BR /&gt;# Reference: &lt;A target="_blank" href="http://stackoverflow.com/questions/59895/can-a-bash-script-tell-what-directory-its-stored-in"&gt;http://stackoverflow.com/questions/59895/can-a-bash-script-tell-what-directory-its-stored-in&lt;/A&gt;&lt;BR /&gt;SOURCE="${BASH_SOURCE[0]}"&lt;BR /&gt;BIN_DIR="$( dirname "$SOURCE" )"&lt;BR /&gt;while [ -h "$SOURCE" ]&lt;BR /&gt;do&lt;BR /&gt;SOURCE="$(readlink "$SOURCE")"&lt;BR /&gt;[[ $SOURCE != /* ]] &amp;amp;&amp;amp; SOURCE="$DIR/$SOURCE"&lt;BR /&gt;BIN_DIR="$( cd -P "$( dirname "$SOURCE" )" &amp;amp;&amp;amp; pwd )"&lt;BR /&gt;done&lt;BR /&gt;BIN_DIR="$( cd -P "$( dirname "$SOURCE" )" &amp;amp;&amp;amp; pwd )"&lt;BR /&gt;LIB_DIR=$BIN_DIR/../lib&lt;/P&gt;&lt;P&gt;# Autodetect JAVA_HOME if not defined&lt;BR /&gt;. $LIB_DIR/bigtop-utils/bigtop-detect-javahome&lt;/P&gt;&lt;P&gt;export HADOOP_LIBEXEC_DIR=//$LIB_DIR/hadoop/libexec&lt;/P&gt;&lt;P&gt;exec $LIB_DIR/hadoop/bin/hadoop "$@"&lt;BR /&gt;[root@hadoop-vm3 ~]#&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 22 Feb 2015 10:09:40 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/24903#M5021</guid>
      <dc:creator>Navneet346</dc:creator>
      <dc:date>2015-02-22T10:09:40Z</dc:date>
    </item>
    <item>
      <title>Re: issue with hadoop -bash: hadoop: command not found</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/24904#M5022</link>
      <description>&lt;P&gt;Thanks alot Gautam , its working fine now after restart , I can access hadoop file system @namenode machine &amp;nbsp;now from command line &amp;nbsp;. many many thanks for your help here !!!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;By the way shall I run this command on data node as well ? i logged in to one of data node and its not able to recognize hadoop there&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;[root@hadoopvm1 ~]# hadoop fs -ls /&lt;BR /&gt;-bash: hadoop: command not found&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;service cloudera-scm-agent restart ?&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Sun, 22 Feb 2015 10:18:13 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/24904#M5022</guid>
      <dc:creator>Navneet346</dc:creator>
      <dc:date>2015-02-22T10:18:13Z</dc:date>
    </item>
    <item>
      <title>Re: issue with hadoop -bash: hadoop: command not found</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/24905#M5023</link>
      <description>Glad to know it is resolved now. You can try the same procedure on all your&lt;BR /&gt;cluster nodes where /usr/bin/hadoop is not symlinked correctly.&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Sun, 22 Feb 2015 10:32:33 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/24905#M5023</guid>
      <dc:creator>GautamG</dc:creator>
      <dc:date>2015-02-22T10:32:33Z</dc:date>
    </item>
    <item>
      <title>Re: issue with hadoop -bash: hadoop: command not found</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/25488#M5024</link>
      <description>&lt;P&gt;i am having same problem , but when i opened&amp;nbsp;/var/lib/alternatives &amp;nbsp; &amp;nbsp; &amp;nbsp;, i found hadoop file and most of other files empty ! with zero size&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 11 Mar 2015 08:04:08 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/25488#M5024</guid>
      <dc:creator>tarekabouzeid91</dc:creator>
      <dc:date>2015-03-11T08:04:08Z</dc:date>
    </item>
    <item>
      <title>Re: issue with hadoop -bash: hadoop: command not found</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/25492#M5025</link>
      <description>&lt;P&gt;HI tarek&amp;nbsp;&lt;/P&gt;&lt;P&gt;you can try running this , this will fix the issue.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;service cloudera-scm-agent restart&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 11 Mar 2015 09:35:27 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/25492#M5025</guid>
      <dc:creator>Navneet346</dc:creator>
      <dc:date>2015-03-11T09:35:27Z</dc:date>
    </item>
    <item>
      <title>Re: issue with hadoop -bash: hadoop: command not found</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/25493#M5026</link>
      <description>&lt;P&gt;i tried it but it doesn't work , but i got this fixed by copying all files in path&amp;nbsp;/var/lib/alternatives from a working VM to the VM that has the problem , then restarted the agent and got it fixed , thanks so much&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 11 Mar 2015 10:19:00 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/25493#M5026</guid>
      <dc:creator>tarekabouzeid91</dc:creator>
      <dc:date>2015-03-11T10:19:00Z</dc:date>
    </item>
    <item>
      <title>Re: issue with hadoop -bash: hadoop: command not found</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/25710#M5027</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;I have CDH 5.3.1 installed on my machine.I am facing the same issue.I have followed all the above steps for deleting empty link,setting up environment variables etc.I think the problem is with incorret path to environment variables.&lt;/P&gt;&lt;P&gt;when i run /opt/cloudera/parcels/CDH-5.3.1-1.cdh5.3.1.p0.5/bin/hadoop status&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;the o/p is&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;/opt/cloudera/parcels/CDH-5.3.1-1.cdh5.3.1.p0.5/bin/....lib/hadoop/bin/hadoop:line 138:/usr/lib/jvm/jdk1.8.0_40: Is a directory&lt;/P&gt;&lt;P&gt;/opt/cloudera/parcels/CDH-5.3.1-1.cdh5.3.1.p0.5/bin/....lib/hadoop/bin/hadoop:line 138:exec: /usr/lib/jvm/jdk1.8.0_40:cannot execute:Is a directory&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It might be a silly mistake with paths setting.:(&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 19 Mar 2015 16:14:19 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/25710#M5027</guid>
      <dc:creator>onkar</dc:creator>
      <dc:date>2015-03-19T16:14:19Z</dc:date>
    </item>
    <item>
      <title>Re: issue with hadoop -bash: hadoop: command not found</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/25743#M5028</link>
      <description>&lt;P&gt;Hi I am able to reslove some part of the error.I can execute all hadoop,hive,impala and hbase commands from&lt;/P&gt;&lt;P&gt;/opt/cloudera/parcels/CDH-5.3.1-1.cdh5.3.1.p0.5/bin.how am i suppose to link these directories in etc/alternatives to create symlinks?what is the use of these symlinks? how can i run the command directly from /home/cloudera?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In the CM UI everything looks good but when is start flume i get and error "Failed to start agent because dependencies were not found in classpath".I think this error is related to classpath configurations.Are symlinks involved with classpath .?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 20 Mar 2015 09:51:07 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/25743#M5028</guid>
      <dc:creator>onkar</dc:creator>
      <dc:date>2015-03-20T09:51:07Z</dc:date>
    </item>
    <item>
      <title>Re: issue with hadoop -bash: hadoop: command not found</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/50051#M5029</link>
      <description>&lt;P&gt;I was having same issue and was getting same error but when I was running any command through directory where I have installed CDH, I was able to run all the commands - hadoop, hdfs, spark-shell ect.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;e.g. if your CHD installation location is - /dat/anlt1/cld/cloudera/CDH-5.8.3-1.cdh5.8.3.p0.2/bin&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;you can test -&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;$ cd /dat/anlt1/cld/cloudera/CDH-5.8.3-1.cdh5.8.3.p0.2/bin&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;[root@xyz bin]# ./hadoop and if it work then you need to set up environment variable in your Unix master server&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;For RHEL -&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;[root@xyz~]# echo "$PATH" /usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;[root@xyz~]# export PATH=$PATH:/path/to/CHD_Installation_bin_path&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;for me it's - /dat/anlt1/cld/cloudera/CDH-5.8.3-1.cdh5.8.3.p0.2/bin&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;[root@xyz~]# echo "$PATH"&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin:/dat/anlt1/cld/cloudera/CDH-5.8.3-1.cdh5.8.3.p0.2/bin&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;to make permanent change -&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;$ echo "export PATH=$PATH:/dat/anlt1/cld/cloudera/CDH-5.8.3-1.cdh5.8.3.p0.2/bin" &amp;gt;&amp;gt; /etc/profile&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;after that restart(reboot) your server.&lt;/P&gt;</description>
      <pubDate>Fri, 27 Jan 2017 04:32:46 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/issue-with-hadoop-bash-hadoop-command-not-found/m-p/50051#M5029</guid>
      <dc:creator>Navnit</dc:creator>
      <dc:date>2017-01-27T04:32:46Z</dc:date>
    </item>
  </channel>
</rss>

