zoukankan      html  css  js  c++  java
  • 【Spark篇】---Spark故障解决(troubleshooting)

    一、前述

    本文总结了常用的Spark的troubleshooting。

    二、具体

    1、shuffle file cannot find:磁盘小文件找不到。

    1) connection timeout ----shuffle file cannot find

    提高建立连接的超时时间,或者降低gc,降低gc了那么spark不能堆外提供服务的时间就少了,那么超时的可能就会降低。

    2) fetch data fail  ---- shuffle file cannot find

    提高拉取数据的重试次数以及间隔时间。

    3) OOM/executor lost ---- shuffle file cannot find

    提高堆外内存大小,提高堆内内存大小。

    2、reduce OOM

    BlockManager拉取的数据量大,reduce task处理的数据量小

    解决方法:

    1) 降低每次拉取的数据量

    2) 提高shuffle聚合的内存比例

    3) 提高Executor的内存比例

    3、序列化问题

    自定义类时别忘实现序列化。

    4、Null值问题

    val rdd = rdd.map{x=>{

    x+”~”;

    }}

    rdd.foreach{x=>{

    System.out.println(x.getName())

    }}

  • 相关阅读:
    MySQL(错误1064)
    如何判断是手机还是电脑访问网站
    Oracle表分区
    分离Date数据
    多对多
    一对多
    SQLalchemy基础
    paramiko上传下载
    paramiko
    automap
  • 原文地址:https://www.cnblogs.com/LHWorldBlog/p/8506167.html
Copyright © 2011-2022 走看看