Storm WordCount错误:管道到子进程似乎被破坏,没有输出读取

时间:2016-03-03 15:40:03

标签: java python apache-storm topology

风暴0.10.0
我之前的问题(Apache storm : Could not load main class org.apache.storm.starter.ExclamationTopology)已经解决了。

你好我的机器上有一个单节点集群正在运行,风暴配置文件如下:(storm.yaml)

storm.zookeeper.servers:
#     - "server1"
#     - "server2"
  - "localhost" 
storm.zookeeper.port: 2181
nimbus.host: "localhost"
storm.local.dir: "/var/stormtmp" 
java.library.path: "/usr/local"
supervisor.slots.ports:
  - 6700
  - 6701
  - 6702
  - 6703
worker.childopts: "-Xmx768m"
nimbus.childopts: "-Xmx512m"
supervisor.childopts: "-Xmx256m"

我在群集上运行了这个WordCount拓扑(在这里找到拓扑并简单地运行它)https://dl.dropboxusercontent.com/s/kc933u6vz2crqkb/storm-starter-0.0.1-SNAPSHOT-jar-with-dependencies.jar (这是python)

但是螺栓在端口6703 localhost上抛出以下错误

  

java.lang.RuntimeException:backtype.storm.multilang.NoOutputException:管道到子进程似乎被破坏了!没有输出读取。序列化程序异常:在backtype.storm.utils.ShellProcess.readShellMs

所以我认为拓扑中有问题所以检查了我的WordCount-3-1457017776-worker-6701.log(文件)并发现了这个:

b.s.d.executor [INFO] TRANSFERING tuple TASK: 8 TUPLE: source: split:18, stream: default, id: {}, ["moon"]
b.s.d.executor [INFO] BOLT ack TASK: 18 TIME:  TUPLE: source: spout:25, stream: default, id: {}, [the cow jumped over the moon]
b.s.t.ShellBolt [INFO] ShellLog pid:1714, name:split Traceback (most recent call last):
  File "/var/stormtmp/supervisor/stormdist/WordCount-3-1457017776/resources/storm.py", line 172, in run
    self.process(tup)
  File "splitsentence.py", line 5, in process
    words = tup.values[0].split(" ")
IndexError: list index out of range

b.s.t.ShellBolt [ERROR] Halting process: ShellBolt died. Command: [python, splitsentence.py], ProcessInfo pid:1714, name:split exitCode:0, errorString:
java.lang.RuntimeException: backtype.storm.multilang.NoOutputException: Pipe to subprocess seems to be broken! No output read.
Serializer Exception:

        at backtype.storm.utils.ShellProcess.readShellMsg(ShellProcess.java:101) ~[storm-core-0.10.0.jar:0.10.0]
        at backtype.storm.task.ShellBolt$BoltReaderRunnable.run(ShellBolt.java:321) [storm-core-0.10.0.jar:0.10.0]
        at java.lang.Thread.run(Thread.java:745) [?:1.7.0_95]
b.s.d.executor [ERROR]
java.lang.RuntimeException: backtype.storm.multilang.NoOutputException: Pipe to subprocess seems to be broken! No output read.
Serializer Exception:

        at backtype.storm.utils.ShellProcess.readShellMsg(ShellProcess.java:101) ~[storm-core-0.10.0.jar:0.10.0]
        at backtype.storm.task.ShellBolt$BoltReaderRunnable.run(ShellBolt.java:321) [storm-core-0.10.0.jar:0.10.0]
        at java.lang.Thread.run(Thread.java:745) [?:1.7.0_95]

所以我相信索引超出范围(由于第5行发生,元组成为0)导致螺栓死亡并且管道被破坏,所以我无法进行更多的数据处理,是我的了解这个问题是否正确? 这有什么问题吗?或者可能是我可以测试的不同拓扑?请帮帮我这是我在风暴上运行的第一个拓扑

0 个答案:

没有答案