【问题标题】:Configure external jars with HDI Jupyter Spark (Scala) notebook使用 HDI Jupyter Spark (Scala) 笔记本配置外部 jar
【发布时间】:2017-07-24 18:42:21
【问题描述】:

我有一个外部自定义 jar,我想将它与 Azure HDInsight Jupyter 笔记本一起使用; HDI 中的 Jupyter 笔记本使用 Spark Magic 和 Livy。

在笔记本的第一个单元格中,我正在尝试使用 jars 配置:

%%configure -f
{"jars": ["wasb://$container$@$account#.blob.core.windows.net/folder/my-custom-jar.jar"]}

但我收到的错误信息是:

Starting Spark application
The code failed because of a fatal error:
    Status 'shutting_down' not supported by session..

Some things to try:
a) Make sure Spark has enough available resources for Jupyter to create a Spark context. For instructions on how to assign resources see http://go.microsoft.com/fwlink/?LinkId=717038
b) Contact your cluster administrator to make sure the Spark magics library is configured correctly.
Current session configs: {u'jars': [u'wasb://$container$@$account#.blob.core.windows.net/folder/my-custom-jar.jar'], u'kind': 'spark'}
An error was encountered:
Status 'shutting_down' not supported by session.

我想知道我是否只是不理解 Livy 在这种情况下是如何工作的,因为我能够在同一个集群上成功地包含一个 spark-package (GraphFrames):

%%configure -f
{ "conf": {"spark.jars.packages": "graphframes:graphframes:0.3.0-spark2.0-s_2.11" }}

一些可能很方便的附加参考资料(以防我遗漏了什么):

【问题讨论】:

  • 这方面有什么进展吗?我与h2opysparkling 遇到了同样的事情。

标签: apache-spark jupyter-notebook azure-hdinsight livy


【解决方案1】:

哦,我能弄明白,忘了更新我的问题。如果您将 jar 放在 HDI 集群的默认存储帐户中,这可以工作。

HTH!

【讨论】:

    【解决方案2】:

    以防人们来这里在 EMR 上添加罐子。

    %%configure -f
    {"name": "sparkTest", "conf": {"spark.jars": "s3://somebucket/artifacts/jars/spark-avro_2.11-2.4.4.jar"}}
    

    document相反,直接使用jars是不行的。

    【讨论】:

      猜你喜欢
      • 2021-06-26
      • 2018-12-08
      • 2018-01-13
      • 2021-06-14
      • 1970-01-01
      • 1970-01-01
      • 2017-09-24
      • 2017-12-01
      • 1970-01-01
      相关资源
      最近更新 更多