码农知识堂 - 1000bd
  •   Python
  •   PHP
  •   JS/TS
  •   JAVA
  •   C/C++
  •   C#
  •   GO
  •   Kotlin
  •   Swift
  • 解决报错: YarnScheduler: Initial job has not accepted any resources


    文章目录

    • 一、问题描述
    • 二、解决方案

    一、问题描述

    在运行某个Pyspark代码时报错如下:

    Warning: Ignoring non-Spark config property: deploy-mode
    Setting default log level to "WARN".
    To adjust logging level use sc.setLogLevel(newLevel). For SparkR, use setLogLevel(newLevel).
    22/08/02 11:35:34 WARN [Thread-4] Utils: Service 'SparkUI' could not bind on port 4040. Attempting port 4041.
    22/08/02 11:35:34 WARN [Thread-4] Utils: Service 'SparkUI' could not bind on port 4041. Attempting port 4042.
    22/08/02 11:35:34 WARN [Thread-4] Utils: Service 'SparkUI' could not bind on port 4042. Attempting port 4043.
    22/08/02 11:35:34 WARN [Thread-4] Utils: Service 'SparkUI' could not bind on port 4043. Attempting port 4044.
    22/08/02 11:35:34 WARN [Thread-4] Utils: Service 'SparkUI' could not bind on port 4044. Attempting port 4045.
    22/08/02 11:35:34 WARN [Thread-4] Utils: Service 'SparkUI' could not bind on port 4045. Attempting port 4046.
    22/08/02 11:35:34 WARN [Thread-4] Utils: Service 'SparkUI' could not bind on port 4046. Attempting port 4047.
    22/08/02 11:35:34 WARN [Thread-4] Utils: Service 'SparkUI' could not bind on port 4047. Attempting port 4048.
    22/08/02 11:35:35 WARN [Thread-4] Client: Neither spark.yarn.jars nor spark.yarn.archive is set, falling back to uploading libraries under SPARK_HOME.
    
    • 1
    • 2
    • 3
    • 4
    • 5
    • 6
    • 7
    • 8
    • 9
    • 10
    • 11
    • 12

    二、解决方案

    上面是因为在yarn上执行spark作业时,其他的app占用了集群资源,导致新的job无法使用足够的资源,可以Kill掉相应的job再试试:

    lsof -i:4041
    lsof -i:4042
    kill -9 进程id
    
    • 1
    • 2
    • 3

    查了下其他的说法:spark-shell里面又单独的设置了spark的context,因为spark-shell里已经有一个context对象了,所以新建创建的数据无法使用。

  • 相关阅读:
    SpringBoot配置Swagger3,解决报错信息
    Python 操作 MySQL 数据库
    EasyExcel实现文件上传-批量插入 文件下载
    Linux Shell相关记笔记
    如何与墨西哥大众VW Mexico建立EDI连接
    1964springboot VUE小程序在线学习管理系统开发mysql数据库uniapp开发java编程计算机网页源码maven项目
    HedgeDoc安装教程
    【动手学深度学习PyTorch版】18 使用块的网络 VGG
    基于Python+DenseNet121算法模型实现一个图像分类识别系统案例
    基于DBACAN的道路轨迹点聚类
  • 原文地址:https://blog.csdn.net/qq_35812205/article/details/126128929
  • 最新文章
  • 攻防演习之三天拿下官网站群
    数据安全治理学习——前期安全规划和安全管理体系建设
    企业安全 | 企业内一次钓鱼演练准备过程
    内网渗透测试 | Kerberos协议及其部分攻击手法
    0day的产生 | 不懂代码的"代码审计"
    安装scrcpy-client模块av模块异常,环境问题解决方案
    leetcode hot100【LeetCode 279. 完全平方数】java实现
    OpenWrt下安装Mosquitto
    AnatoMask论文汇总
    【AI日记】24.11.01 LangChain、openai api和github copilot
  • 热门文章
  • 十款代码表白小特效 一个比一个浪漫 赶紧收藏起来吧!!!
    奉劝各位学弟学妹们,该打造你的技术影响力了!
    五年了,我在 CSDN 的两个一百万。
    Java俄罗斯方块,老程序员花了一个周末,连接中学年代!
    面试官都震惊,你这网络基础可以啊!
    你真的会用百度吗?我不信 — 那些不为人知的搜索引擎语法
    心情不好的时候,用 Python 画棵樱花树送给自己吧
    通宵一晚做出来的一款类似CS的第一人称射击游戏Demo!原来做游戏也不是很难,连憨憨学妹都学会了!
    13 万字 C 语言从入门到精通保姆级教程2021 年版
    10行代码集2000张美女图,Python爬虫120例,再上征途
Copyright © 2022 侵权请联系2656653265@qq.com    京ICP备2022015340号-1
正则表达式工具 cron表达式工具 密码生成工具

京公网安备 11010502049817号