What happens when Spark master fails?

前端 未结 3 1975
情歌与酒
情歌与酒 2020-12-15 23:26

Does the driver need constant access to the master node? Or is it only required to get initial resource allocation? What happens if master is not available after Spark cont

3条回答
  •  醉酒成梦
    2020-12-16 00:16

    Below are the steps spark application does, when it starts,

    1. Starts the Spark Driver
    2. Spark Driver, connects to spark master for resource allocation.
    3. Spark Driver, sends the jar attached in spark context to master server.
    4. Spark Driver, keeps polling master server to get the job status.
    5. If there is a shuffling or broadcast in code, data is routed via spark driver. That is why, it is required for spark driver to have sufficient memory.
    6. If there is any operation like take, takeOrdered, or collect, data is accumulater on driver.

    So, yes, failing on master will result in executors not able to communicate with it. So, they will stop working. Failing of master will make driver unable to communicate with it for job status. So, your application will fail.

提交回复
热议问题