Created on 02-15-2020 02:44 PM - last edited on 02-15-2020 05:20 PM by ask_bill_brooks
when i try to launch command ./bin/livy-server this error appear : Could not find Livy jars directory.
note : I use centos .
Created on 02-15-2020 03:38 PM - edited 02-15-2020 04:08 PM
Not Sure which product you are using. However based on the command it looks like you are running the "livy-server" script from outside of the "bin" directory which may be causing the issue
Because the Logic written inside the script "" is as following:
export LIVY_HOME=$(cd $(dirname $0)/.. && pwd)
.
.
.
start_livy_server() {
LIBDIR="$LIVY_HOME/jars"
if [ ! -d "$LIBDIR" ]; then
LIBDIR="$LIVY_HOME/server/target/jars"
fi
if [ ! -d "$LIBDIR" ]; then
echo "Could not find Livy jars directory." 1>&2
exit 1
fi
.
So ideally you should first change directory to "bin" where the 'livy-server' script is present
and then run it as following OR try using the Full path in the. terminal for the 'livy-server' script
# cd /PATH/TO/LIVY_DIR/bin
# ./livy-server
(OR)
# /PATH/TO/LIVY_DIR/bin/livy-server
.
If you still find it difficult to run then try to put a "echo" statement as following inside the script "livy-server' to see what path it is resolving for the 'LIVY_HOME' and if the "LIVY_HOME/jars" directory exist with correct permission??
export LIVY_HOME=$(cd $(dirname $0)/.. && pwd)
echo "LIVY_HOME calculated as = $LIVY_HOME"
.
Created on 02-17-2020 01:08 AM - edited 02-17-2020 01:30 AM
Hi, is it mandatory to have spark and livy in the same machine ? if not how to export the two variables SPARK-HOME and HADOOP_CONF_DIR ?
I'm sorry, but I'm finding it difficult to understand this .
Created 02-17-2020 01:43 AM
when I add the echo this is the result :
Created 02-17-2020 03:26 AM
Which product and version (HDP /CDH ....etc) are you using and from where have you downloaded the "incubator-livy" ?
Created 02-17-2020 03:42 AM
Thank you for your collaboration, I found the solution. I'm using the wrong version of Livy.