Hadoop: Cannot use Jps command
did you install the package java-1.6.0-openjdk-devel who provides the jps tool?
$ sudo yum provides /usr/lib/jvm/java-1.6.0-openjdk.x86_64/bin/jps
Loaded plugins: product-id, subscription-manager
Updating certificate-based repositories.
Unable to read consumer identity
1:java-1.6.0-openjdk-devel-1.6.0.0-1.45.1.11.1.el6.x86_64 : OpenJDK Development Environment
Repo : installed
Matched from:
Other : Provides-match: /usr/lib/jvm/java-1.6.0-openjdk.x86_64/bin/jps
That is actually not a Hadoop problem. Hadoop does not use JPS.
If JPS can't be found, you have to put it into your path or create an alias.
The JPS executable can be found under $JAVA_HOME/bin/jps
.
The alias for example could be:
alias jps='/usr/lib/jvm/jdk1.6.0_33/bin/jps'
Or if you don't care about using JPS, you could instead do a
ps aux | grep java
which will approx. give you the same result ;)
Use this command if you cannot use jps
ps -aux | grep java | awk '{print $12}'
It will show files as: