Zsh: command not found: start-all.sh

I have recently installed hadoop version 3.2.1-1 using AUR on my manjaro linux distribution but whenever I try to run command to start all the hadoop services using:

It end up saying:
zsh: command not found: start-all.sh

How do I fix this? Please help me.

  • Is the file start-all.sh located in a directory that’s in your $PATH?
  • Does the file start-all.sh have execute permission set for yourself an/or the user group you belong to?

If the answer to the first question is “no”, then you can get around that in two ways, i.e.:

  1. Prepend the name of the file with an absolute or relative path. For instance, if you are in the directory where the file is located, then you can start it with… :arrow_down:
  1. Add the directory to your $PATH in ~/.zshrc, like so… :arrow_down:
export PATH="$PATH:/where/the/file/is" 

In the latter case, you will have to log out and back in for the changes to take effect.

If the file does not have execute permission for you, change its permissions. If the file is owned by you, you can do… :arrow_down:

chmod 755 start-all.sh 

If it’s not owned by you, you’ll have to prepend the command with sudo. :arrow_down:

sudo chmod 755 start-all.sh 

However, you will still need to keep the condition into account regarding the file being or not being in your $PATH.

Hope this helps. :wink:

Thanks, I found the file location to be: /usr/lib/hadoop/sbin/start-all.sh

And then, I did this
~ >>> cd /usr/lib/hadoop/sbin
/usr/…/hadoop/sbin >>> ./start-all.sh

But it gave me this error:

ERROR: JAVA_HOME is not set and could not be found.

I mean I have installed java on my system from official repositories and I also verified it in every way:

~ >>> which java
~ >>> whereis java
java: /usr/bin/java /usr/share/java /usr/lib/jvm/java-8-openjdk/bin/java
~ >>> java -version
openjdk version “1.8.0_262”
OpenJDK Runtime Environment (build 1.8.0_262-b10)
OpenJDK 64-Bit Server VM (build 25.262-b10, mixed mode)

You don’t have to cd to the directory. You could also start the script with… :arrow_down:


That’s a different subject, and I’m afraid I cannot help you with that. I know nothing about Hadoop.

In addition to that, there is never a guarantee that AUR packages will work in Manjaro. The AUR was primarily set up for Arch, and Arch is a little bit ahead of Manjaro ─ the Arch Stable branch corresponds to Manjaro Unstable. :shrug: