Reply
Highlighted
Contributor
Posts: 47
Registered: ‎05-21-2018

Cloudera Director Error: JAVA_HOME is not set and Java could not be found

getting below error while executing 

 

sudo yum install cloudera-director-server cloudera-director-client

 

  • [root@aa2 cloudera-director-server]# [root@aa2 cloudera-director-server]# jps5009 Jps[root@aa2 cloudera-director-server]# java -versionjava version "1.8.0_171"Java(TM) SE Runtime Environment (build 1.8.0_171-b11)Java HotSpot(TM) 64-Bit Server VM (build 25.171-b11, mixed mode)[root@aa2 cloudera-director-server]# javac -versionjavac 1.8.0_171[root@aa2 cloudera-director-server]# cat /root/.bash_profile # .bash_profile# Get the aliases and functionsif [ -f ~/.bashrc ]; then . ~/.bashrcfi# User specific environment and startup programsJAVA_HOME=/usr/bin/java/jdk1.8.0_171/PATH=$PATH:$JAVA_HOME/binexport PATH[root@aa2 cloudera-director-server]# echo $JAVA_HOME/usr/bin/java/jdk1.8.0_171/[root@aa2 cloudera-director-server]# cat cloudera-director-server.out +======================================================================+| Error: JAVA_HOME is not set and Java could not be found |+----------------------------------------------------------------------+| Please download the latest Sun JDK from the Sun Java web site || > http://java.sun.com/javase/downloads/ < || || Cloudera Director Server requires Java 1.7 or later. || NOTE: This script will find Sun Java whether you install using the || binary or the RPM based installer. |+======================================================================+[root@aa2 cloudera-director-server]#
  • Picture11.png 
Contributor
Posts: 47
Registered: ‎05-21-2018

Re: Cloudera Director Error: JAVA_HOME is not set and Java could not be found

[ Edited ]

[root@aa2 cdhgcp]# systemctl start cloudera-director-server

 

Job for cloudera-director-server.service failed because the control process exited with error code. Se e "systemctl status cloudera-director-server.service" and "journalctl -xe" for details.

 

[root@aa2 cdhgcp]# cat /etc/default/cloudera-director-server export

 

DIRECTOR_SERVER_ETC_DIR=/etc/cloudera-director-server export DIRECTOR_SERVER_LOG_DIR=/var/log/cloudera-director-server export DIRECTOR_SERVER_PID_DIR=/var/run/cloudera-director-server export DIRECTOR_SERVER_LIB_DIR=/var/lib/cloudera-director-server export DIRECTOR_SERVER_PLUGIN_DIR=/var/lib/cloudera-director-plugins export JAVA_HOME=/usr/bin/java/jdk1.8.0_171/

 

[root@aa2 cdhgcp]#

Contributor
Posts: 47
Registered: ‎05-21-2018

Re: Cloudera Director Error: JAVA_HOME is not set and Java could not be found

i followed this link:

 

https://www.cloudera.com/documentation/director/2-8-x/topics/director_get_started_gpc_install_dir_se...

 

 

unable to locate state.h2.db

/var/lib/cloudera-director-server/state.h2.db

 

[root@aa2 cloudera-director-server]# pwd
/var/lib/cloudera-director-server


[root@aa2 cloudera-director-server]# ll
total 0


[root@aa2 cloudera-director-server]#

 

Posts: 932
Kudos: 28
Solutions: 16
Registered: ‎05-27-2014

Re: Cloudera Director Error: JAVA_HOME is not set and Java could not be found

Hi @prabhat10 ,

 

I researched the error and found out it may be possible due to the JDK version. Can you please try and install the one from Director's Repo and use that JDK instead?

 

Hope this helps,

Li

Li Wang, Technical Resolution Manager


Was your question answered? Make sure to mark the answer as the accepted solution.
If you find a reply useful, say thanks by clicking on the thumbs up button.

Learn more about the Cloudera Community:

Terms of Service

Community Guidelines

How to use the forum

Announcements