【已解决】Caused by: java.net.SocketException: Connection reset by peer: socket write error

2023-10-09 08:28:18 浏览数 (3)

Caused by: java.net.SocketException: Connection reset by peer: socket write error

问题

在pycharm中运行时报错了ERROR PythonRunner: Python worker exited unexpectedly (crashed) 测试运行print(input_rdd.first())可以打印出来,但是print(input_rdd.count())触发函数就会报错

思路

print(input_rdd.count()) ERROR PythonRunner: Python worker exited unexpectedly (crashed)的意思是Python worker意外退出(崩溃)

21/10/24 10:24:48 ERROR PythonRunner: Python worker exited unexpectedly (crashed) java.net.SocketException: Connection reset by peer: socket write error 对于解决这个问题的方法,小编网上查询了一下,出现这种问题可能是很多情况导致的。就目前小编帮助解决的这个情况,在windows系统本地运行的spark,是软件的问题,数据量有点大,在pycharm上运行可能会报错。

解决

更换到Linux虚拟机运行,或减少测试数据量。

0 人点赞