Skip to main content
dkozlowski
Gold ⭐️
Apr 25, 2017 3:08 PM UTC

livy.spark cannot start

  • Oct 5, 2026 9:24 AM UTC
  • 0 replies
  • 1504 views
  • Translate All

PROBLEM:

I have just started with livy through Zeppelin and have made some livy interpreter config changes i.e. spark memory. When running

%livy.spark
sc.version

I am getting

Cannot start spark

SOLUTION:

When checking the application log from RM UI I noticed the following

...
End of LogType:launch_container.sh

LogType:stderr
Log Upload Time:Tue Apr 18 15:13:02 +0200 2017
LogLength:142
Log Contents:
Invalid maximum heap size: -Xmx0m
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
...

As you can see, the Xmx value is set to 0m. Doing the further research I noticed the following in livy interpreter:

livy.spark.executor.memory 512
livy.spark.driver.memory 512

Seting the values to

livy.spark.executor.memory 512m
livy.spark.driver.memory 512m

saving the changes and restarting livy interpreter fixed the problem