小编sac*_*a.p的帖子

Apache Spark Spark-提交 k8s API https 错误

火花版本:2.4.4

k8s版本:1.18

我有一个 Spark 和一个 k8s 集群。

我遵循 Spark 文档:https://spark.apache.org/docs/2.4.4/running-on-kubernetes.html

当我在 k8s 上使用 HTTP 代理提交作业时:一切正常。

但是,使用 k8s 上的本机 HTTPS API 时,我收到此错误:

以前我必须将 k8s API 证书导入到我的主 Spark (keytool)。

internal.WatchConnectionManager: Exec Failure: HTTP 403, Status: 403 - pods "spark-pi-1598541432880-driver" is forbidden: User "system:anonymous" cannot watch resource "pods" in API group "" in the namespace "default"
java.net.ProtocolException: Expected HTTP 101 response but was '403 Forbidden'
    at okhttp3.internal.ws.RealWebSocket.checkResponse(RealWebSocket.java:216)
    at okhttp3.internal.ws.RealWebSocket$2.onResponse(RealWebSocket.java:183)
    at okhttp3.RealCall$AsyncCall.execute(RealCall.java:141)
    at okhttp3.internal.NamedRunnable.run(NamedRunnable.java:32)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
    at java.lang.Thread.run(Thread.java:748)

Run Code Online (Sandbox Code Playgroud)

这很奇怪,因为没有匿名用户。

我已经尝试向 k8s …

java api https apache-spark kubernetes

1
推荐指数
1
解决办法
1904
查看次数

标签 统计

apache-spark ×1

api ×1

https ×1

java ×1

kubernetes ×1