Jas
Jas

Reputation: 15103

z.load in apache zeppelin results in error

enter image description herei'm trying z.load in apache zeppelin as following:

%dep
z.load("/zeppelin-0.5.6-incubating-bin-all/lplibs/hive/csv-serde-1.0.5-jar-with-dependencies.jar")

I get an ERROR and it says (not sure this is the error):

Must be used before SparkInterpreter (%spark) initialized
Hint: put this paragraph before any Spark code and restart Zeppelin/Interpreter

this zeppelin section is the first i have in my notebook so i'm not sure what its complaining about..

Upvotes: 4

Views: 4832

Answers (2)

sag
sag

Reputation: 5461

There might be a chance that Sparkcontext has already been started by other notebook.

So as Kangrok mentioned, just restart Spark interpreter.

But apart from that, why don't you use the latest zeppelin, in which you don't need to use %dep to load your dependencies. Instead it can load from Interpreter screen.

More details can be found here https://zeppelin.incubator.apache.org/docs/0.6.0-incubating-SNAPSHOT/manual/dependencymanagement.html

Upvotes: 1

Kangrok Lee
Kangrok Lee

Reputation: 101

Right now I can't check your problem, but you should restart interpreter (pushing restart button) before loading dependency jar file.

Upvotes: 1

Related Questions