LogStach installation issue on Ubuntu

I'm trying to run logstach-5.5.2 on ubuntu-14.04 LTS. but it's giving me following error.
"Could not find any executable java binary. Please install java in your PATH or set JAVA_HOME."
But JAVA_HOME is already set. these are the results of

'java -version'
java version "1.8.0_121"
Java(TM) SE Runtime Environment (build 1.8.0_121-b13)
Java HotSpot(TM) 64-Bit Server VM (build 25.121-b13, mixed mode)

'which java'
/usr/lib/jvm/default-java/bin/java

/Etc/enviornment file

JAVA_HOME="/usr/lib/jvm/default-java"
PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/usr/lib/jvm/default-java/bin:/usr/lib/sbt/default-sbt/bin:/usr/lib/activator/default-activator/bin:"

I've no idea why I'm getting this error. when everything seems fine to me.
NOTE: 'I've downloaded .tar.gz file of logstash.

You haven't shown how you're trying to launch Logstash.

I'm giving following command to run log-stash.
"bin/logstash"

As which user are you trying to run bin/logstash?

user is 'muneeb'. and I've placed logstash in /opt and user 'muneeb' has complete (read write )access to opt.
I've given ownership of /opt to user 'muneeb'.

As user muneeb, what is the output of env?

yes you are right, It's an access issue. I just tried to run logstash from /home/muneeb. and that error has gone. thanks.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.