Closed purpletech77 closed 5 years ago
FYI - Spark on K8S has been merged upstream and is now being maintained as part of Apache Spark so issues should be reported on https://issues.apache.org/jira/
This is expected behaviour though I don't believe well documented.
The service account is only used for the driver and executor pods. However the submission client i.e. the local code running where you run spark-submit
uses your own K8S config to monitor the ongoing progress of the driver and therefore needs to have sufficient permissions to do this.
@purpletech77 , How did you got this issue solved in the end? I came across the same and got no clue.
@waynegj As I tried to explain there is some monitoring of the ongoing progress of the driver pod that happens on the submission client i.e. the place where you run spark-submit
. This uses your personal K8S config (typically ~/.kube/config
or the file specified by the KUBECONFIG
environment variable) so if the configured context there doesn't have the correct permissions the job monitoring will fail.
So the solution is to ensure that you have appropriate credentials in your local K8S config to be able to launch and monitor pods. How you get these credentials is a detail of your specific K8S cluster.
@rvesse , Thanks for the sharing. After some digging I found this might be related to support of aws-iam-authenticator in io.fabric8.kubernetes-client(as adressed in https://github.com/fabric8io/kubernetes-client/pull/1224), The same error occurred both on Spark 2.3.1 and 2.3.2 if I configured everything correct. Can you shed some light on how to decide the fabric8 kubernetes-client being used in spark-submit?
@waynegj Well that PR is very new and neither Spark 2.3.1/2.3.2 would have a version of Fabric 8 client that is remotely new enough to incorporate that change.
This whole spark-submit kuberentes is horribly busted. The 10K of code to deploy single driver container and it can't even log what went wrong.
This repository is no longer used for tracking issues related to running Spark on Kubernetes. Please use the official Apache Spark JIRA project to report issues. Also, this project isn't the means to use this feature anymore - the official Spark releases from upstream are the way to do it.
Please move discussions to the official Apache channels. Thanks!