将storm升级到1.2.3时storm列表出错

tquggr8v  于 2021-06-24  发布在  Storm
关注(0)|答案(1)|浏览(504)

在storm.yaml(版本1.0.0)中,我有下一个配置: nimbus.host: "%nimbus%" 升级版本时,我更改为: nimbus.seeds: ["%nimbus%"] 在部署所有拓扑的脚本中,我使用next命令检查风暴列表(在版本1.0.0中): storm list -c nimbus.host=localhost 下一个错误是:

Running: /usr/lib/jvm/java-8-oracle/bin/java -client -Ddaemon.name= -Dstorm.options=nimbus.host%3Dlocalhost -Dstorm.home=/usr/share/storm-1.2.3 -Dstorm.log.dir=/usr/share/storm-1.2.3/logs -Djava.library.path=/usr/local/lib:/opt/local/lib:/usr/lib -Dstorm.conf.file= -cp /usr/share/storm-1.2.3/*:/usr/share/storm-1.2.3/lib/*:/usr/share/storm-1.2.3/extlib/*:/usr/share/storm-1.2.3/extlib-daemon/*:/usr/share/storm-1.2.3/conf:/usr/share/storm-1.2.3/bin org.apache.storm.command.list
2952 [main] WARN  o.a.s.u.NimbusClient - Using deprecated config nimbus.host for backward compatibility. Please update your storm.yaml so it only has config nimbus.seeds
3033 [main] WARN  o.a.s.u.NimbusClient - Ignoring exception while trying to get leader nimbus info from localhost. will retry with a different seed host.
org.apache.storm.thrift.TApplicationException: Internal error processing getLeader
    at org.apache.storm.thrift.TServiceClient.receiveBase(TServiceClient.java:79) ~[storm-core-1.2.3.jar:1.2.3]
    at org.apache.storm.generated.Nimbus$Client.recv_getLeader(Nimbus.java:1166) ~[storm-core-1.2.3.jar:1.2.3]
    at org.apache.storm.generated.Nimbus$Client.getLeader(Nimbus.java:1154) ~[storm-core-1.2.3.jar:1.2.3]
    at org.apache.storm.utils.NimbusClient.getConfiguredClientAs(NimbusClient.java:93) [storm-core-1.2.3.jar:1.2.3]
    at org.apache.storm.utils.NimbusClient.getConfiguredClientAs(NimbusClient.java:66) [storm-core-1.2.3.jar:1.2.3]
    at org.apache.storm.command.list$_main.invoke(list.clj:22) [storm-core-1.2.3.jar:1.2.3]
    at clojure.lang.AFn.applyToHelper(AFn.java:152) [clojure-1.7.0.jar:?]
    at clojure.lang.AFn.applyTo(AFn.java:144) [clojure-1.7.0.jar:?]
    at org.apache.storm.command.list.main(Unknown Source) [storm-core-1.2.3.jar:1.2.3]
Exception in thread "main" org.apache.storm.utils.NimbusLeaderNotFoundException: Could not find leader nimbus from seed hosts [localhost]. Did you specify a valid list of nimbus hosts for config nimbus.seeds?
    at org.apache.storm.utils.NimbusClient.getConfiguredClientAs(NimbusClient.java:120)
    at org.apache.storm.utils.NimbusClient.getConfiguredClientAs(NimbusClient.java:66)
    at org.apache.storm.command.list$_main.invoke(list.clj:22)
    at clojure.lang.AFn.applyToHelper(AFn.java:152)
    at clojure.lang.AFn.applyTo(AFn.java:144)
    at org.apache.storm.command.list.main(Unknown Source)

升级版本时,我将命令更改为: storm list -c nimbus.seeds=[localhost] 但是,下一个错误是:

Exception in thread "main" java.lang.ExceptionInInitializerError
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Class.java:348)
    at clojure.lang.RT.classForName(RT.java:2154)
    at clojure.lang.RT.classForName(RT.java:2163)
    at clojure.lang.RT.loadClassForName(RT.java:2182)
    at clojure.lang.RT.load(RT.java:436)
    at clojure.lang.RT.load(RT.java:412)
    at clojure.core$load$fn__5448.invoke(core.clj:5866)
    at clojure.core$load.doInvoke(core.clj:5865)
    at clojure.lang.RestFn.invoke(RestFn.java:408)
    at clojure.core$load_one.invoke(core.clj:5671)
    at clojure.core$load_lib$fn__5397.invoke(core.clj:5711)
    at clojure.core$load_lib.doInvoke(core.clj:5710)
    at clojure.lang.RestFn.applyTo(RestFn.java:142)
    at clojure.core$apply.invoke(core.clj:632)
    at clojure.core$load_libs.doInvoke(core.clj:5753)
    at clojure.lang.RestFn.applyTo(RestFn.java:137)
    at clojure.core$apply.invoke(core.clj:634)
    at clojure.core$use.doInvoke(core.clj:5843)
    at clojure.lang.RestFn.invoke(RestFn.java:408)
    at org.apache.storm.command.config_value$loading__5340__auto____12317.invoke(config_value.clj:16)
    at org.apache.storm.command.config_value__init.load(Unknown Source)
    at org.apache.storm.command.config_value__init.<clinit>(Unknown Source)
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Class.java:348)
    at clojure.lang.RT.classForName(RT.java:2154)
    at clojure.lang.RT.classForName(RT.java:2163)
    at clojure.lang.RT.loadClassForName(RT.java:2182)
    at clojure.lang.RT.load(RT.java:436)
    at clojure.lang.RT.load(RT.java:412)
    at clojure.core$load$fn__5448.invoke(core.clj:5866)
    at clojure.core$load.doInvoke(core.clj:5865)
    at clojure.lang.RestFn.invoke(RestFn.java:408)
    at clojure.lang.Var.invoke(Var.java:379)
    at org.apache.storm.command.config_value.<clinit>(Unknown Source)
Caused by: java.lang.IllegalArgumentException: Field NIMBUS_SEEDS must be an Iterable but was a class java.lang.String
    at org.apache.storm.validation.ConfigValidationUtils$2.validateField(ConfigValidationUtils.java:125)
    at org.apache.storm.validation.ConfigValidationUtils$NestableFieldValidator.validateField(ConfigValidationUtils.java:48)
    at org.apache.storm.validation.ConfigValidation$ListEntryTypeValidator.validateField(ConfigValidation.java:304)
    at org.apache.storm.validation.ConfigValidation$ListEntryTypeValidator.validateField(ConfigValidation.java:299)
    at org.apache.storm.validation.ConfigValidation.validateField(ConfigValidation.java:707)
    at org.apache.storm.validation.ConfigValidation.validateFields(ConfigValidation.java:742)
    at org.apache.storm.validation.ConfigValidation.validateFields(ConfigValidation.java:721)
    at org.apache.storm.config$validate_configs_with_schemas.invoke(config.clj:74)
    at org.apache.storm.config$read_storm_config.invoke(config.clj:79)
    at org.apache.storm.config$fn__975.invoke(config.clj:100)
    at org.apache.storm.config__init.load(Unknown Source)
    at org.apache.storm.config__init.<clinit>(Unknown Source)
    ... 35 more
Exception in thread "main" java.lang.ExceptionInInitializerError
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Class.java:348)
    at clojure.lang.RT.classForName(RT.java:2154)
    at clojure.lang.RT.classForName(RT.java:2163)
    at clojure.lang.RT.loadClassForName(RT.java:2182)
    at clojure.lang.RT.load(RT.java:436)
    at clojure.lang.RT.load(RT.java:412)
    at clojure.core$load$fn__5448.invoke(core.clj:5866)
    at clojure.core$load.doInvoke(core.clj:5865)
    at clojure.lang.RestFn.invoke(RestFn.java:408)
    at clojure.core$load_one.invoke(core.clj:5671)
    at clojure.core$load_lib$fn__5397.invoke(core.clj:5711)
    at clojure.core$load_lib.doInvoke(core.clj:5710)
    at clojure.lang.RestFn.applyTo(RestFn.java:142)
    at clojure.core$apply.invoke(core.clj:632)
    at clojure.core$load_libs.doInvoke(core.clj:5753)
    at clojure.lang.RestFn.applyTo(RestFn.java:137)
    at clojure.core$apply.invoke(core.clj:634)
    at clojure.core$use.doInvoke(core.clj:5843)
    at clojure.lang.RestFn.invoke(RestFn.java:408)
    at org.apache.storm.command.config_value$loading__5340__auto____12317.invoke(config_value.clj:16)
    at org.apache.storm.command.config_value__init.load(Unknown Source)
    at org.apache.storm.command.config_value__init.<clinit>(Unknown Source)
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Class.java:348)
    at clojure.lang.RT.classForName(RT.java:2154)
    at clojure.lang.RT.classForName(RT.java:2163)
    at clojure.lang.RT.loadClassForName(RT.java:2182)
    at clojure.lang.RT.load(RT.java:436)
    at clojure.lang.RT.load(RT.java:412)
    at clojure.core$load$fn__5448.invoke(core.clj:5866)
    at clojure.core$load.doInvoke(core.clj:5865)
    at clojure.lang.RestFn.invoke(RestFn.java:408)
    at clojure.lang.Var.invoke(Var.java:379)
    at org.apache.storm.command.config_value.<clinit>(Unknown Source)
Caused by: java.lang.IllegalArgumentException: Field NIMBUS_SEEDS must be an Iterable but was a class java.lang.String
    at org.apache.storm.validation.ConfigValidationUtils$2.validateField(ConfigValidationUtils.java:125)
    at org.apache.storm.validation.ConfigValidationUtils$NestableFieldValidator.validateField(ConfigValidationUtils.java:48)
    at org.apache.storm.validation.ConfigValidation$ListEntryTypeValidator.validateField(ConfigValidation.java:304)
    at org.apache.storm.validation.ConfigValidation$ListEntryTypeValidator.validateField(ConfigValidation.java:299)
    at org.apache.storm.validation.ConfigValidation.validateField(ConfigValidation.java:707)
    at org.apache.storm.validation.ConfigValidation.validateFields(ConfigValidation.java:742)
    at org.apache.storm.validation.ConfigValidation.validateFields(ConfigValidation.java:721)
    at org.apache.storm.config$validate_configs_with_schemas.invoke(config.clj:74)
    at org.apache.storm.config$read_storm_config.invoke(config.clj:79)
    at org.apache.storm.config$fn__975.invoke(config.clj:100)
    at org.apache.storm.config__init.load(Unknown Source)
    at org.apache.storm.config__init.<clinit>(Unknown Source)
    ... 35 more
Running: /usr/lib/jvm/java-8-oracle/bin/java -client -Ddaemon.name= -Dstorm.options=nimbus.seeds%3D%5Blocalhost%5D -Dstorm.home=/usr/share/storm-1.2.3 -Dstorm.log.dir= -Djava.library.path= -Dstorm.conf.file= -cp /usr/share/storm-1.2.3/*:/usr/share/storm-1.2.3/lib/*:/usr/share/storm-1.2.3/extlib/*:/usr/share/storm-1.2.3/extlib-daemon/*:/usr/share/storm-1.2.3/conf:/usr/share/storm-1.2.3/bin org.apache.storm.command.list
Exception in thread "main" java.lang.IllegalArgumentException: Field NIMBUS_SEEDS must be an Iterable but was a class java.lang.String
    at org.apache.storm.validation.ConfigValidationUtils$2.validateField(ConfigValidationUtils.java:125)
    at org.apache.storm.validation.ConfigValidationUtils$NestableFieldValidator.validateField(ConfigValidationUtils.java:48)
    at org.apache.storm.validation.ConfigValidation$ListEntryTypeValidator.validateField(ConfigValidation.java:304)
    at org.apache.storm.validation.ConfigValidation$ListEntryTypeValidator.validateField(ConfigValidation.java:299)
    at org.apache.storm.validation.ConfigValidation.validateField(ConfigValidation.java:707)
    at org.apache.storm.validation.ConfigValidation.validateFields(ConfigValidation.java:742)
    at org.apache.storm.validation.ConfigValidation.validateFields(ConfigValidation.java:721)
    at org.apache.storm.config$validate_configs_with_schemas.invoke(config.clj:74)
    at org.apache.storm.config$read_storm_config.invoke(config.clj:79)
    at org.apache.storm.command.list$_main.invoke(list.clj:22)
    at clojure.lang.AFn.applyToHelper(AFn.java:152)
    at clojure.lang.AFn.applyTo(AFn.java:144)
    at org.apache.storm.command.list.main(Unknown Source)

有人能帮我解决这个错误吗?谢谢您。
附上:
1.0.0版本的配置文件

storm.local.hostname: "%local.ip%"

storm.zookeeper.servers:
    - "%zookeeper%"

nimbus.host: "%nimbus%"

# netty transport

storm.messaging.transport: "org.apache.storm.messaging.netty.Context"
storm.messaging.netty.buffer_size: 16384
storm.messaging.netty.max_retries: 10
storm.messaging.netty.min_wait_ms: 1000
storm.messaging.netty.max_wait_ms: 5000

drpc.servers:
  - "%nimbus%"
drpc.port: 3772
drpc.invocations.port: 3773

### supervisor.* configs are for node supervisors

# Define the amount of workers that can be run on this machine. Each worker is assigned a port to use for communication

supervisor.slots.ports:    
    - 6701
    - 6702
    - 6703
    - 6704
    - 6705
    - 6706
    - 6707
    - 6708
    - 6709
    - 6710
    - 6711
    - 6712
    - 6713
    - 6714
    - 6715
    - 6716    
    - 6717    
supervisor.childopts: "-Xmx256m"

# how long supervisor will wait to ensure that a worker process is started

supervisor.worker.start.timeout.secs: 120

# how long between heartbeats until supervisor considers that worker dead and tries to restart it

supervisor.worker.timeout.secs: 30

# how frequently the supervisor checks on the status of the processes it's monitoring and restarts if necessary

supervisor.monitor.frequency.secs: 3

# how frequently the supervisor heartbeats to the cluster state (for nimbus)

supervisor.heartbeat.frequency.secs: 5
supervisor.enable: true
supervisor.cpu.capacity: 200.0
supervisor.memory.capacity.mb: 4096.0

### worker.* configs are for task workers

worker.heap.memory.mb: 1024
worker.childopts: "-Xmx%HEAP-MEM%m -XX:+PrintGCDetails -Xloggc:artifacts/gc.log -XX:+PrintGCDateStamps -XX:+PrintGCTimeStamps -XX:+UseGCLogFileRotation -XX:NumberOfGCLogFiles=10 -XX:GCLogFileSize=1M -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=artifacts/heapdump"
worker.gc.childopts: ""

### check https://github.com/apache/storm/blob/master/conf/defaults.yaml for compelte defaults

日志/nimbus.log出错
2019-11-20 17:30:07.158 o.a.s.t.processfunction pool-14-thread-8[error]处理getleader java.lang.runtimeexception时出现内部错误:找不到nimbus leader参与者主机,是否已启动nimbus主机?在org.apache.storm.zookeeper$到\u nimbusinfo.invoke(zookeeper。clj:241)~[风暴核心-1.2.3。jar:1.2.3]在org.apache.storm.zookeeper$zk\u leader\u elector$reify\u 2212.getleader(zookeeper。clj:294)~[风暴核心-1.2.3。jar:1.2.3]在sun.reflect.nativemethodaccessorimpl.invoke0(本机方法)~[?:1.8.0\u 201]处sun.reflect.nativemethodaccessorimpl.invoke(nativemethodaccessorimpl。java:62)~[?:1.8.0\u 201]在sun.reflect.delegatingmethodaccessorimpl.invoke(delegatingmethodaccessorimpl。java:43)~[?:1.8.0\u 201]位于java.lang.reflect.method.invoke(method。java:498)在clojure.lang.reflector.invokematchingmethod(reflector。java:93) ~[clojure-1.7.0.jar:?]位于clojure.lang.reflector.invokeNorgInstanceMember(reflector。java:313)~[clojure-1.7.0.jar:?]在org.apache.storm.daemon.nimbus$mk\u-reified\u-nimbus$reify\uu9284.getleader(nimbus。clj:2428)~[风暴核心-1.2.3。jar:1.2.3]在org.apache.storm.generated.nimbus$processor$getleader.getresult(nimbus。java:4092) ~[风暴核心-1.2.3。jar:1.2.3]在org.apache.storm.generated.nimbus$processor$getleader.getresult(nimbus。java:4071)~[风暴核心-1.2.3。jar:1.2.3]在org.apache.storm.thrift.processfunction.process(processfunction。java:38)~[风暴核心-1.2.3。jar:1.2.3]在org.apache.storm.thrift.tbaseprocessor.process(tbaseprocessor。java:39) ~[风暴核心-1.2.3。jar:1.2.3]位于org.apache.storm.security.auth.simpletransportplugin$simplewrapprocessor.process(simpletransportplugin.com)。java:162)~[风暴核心-1.2.3。jar:1.2.3]在org.apache.storm.thrift.server.abstractnonblockingserver$framebuffer.invoke(abstractnonblockingserver。java:518)~[风暴核心-1.2.3。jar:1.2.3]在org.apache.storm.thrift.server.invocation.run(调用。java:18)~[风暴核心-1.2.3。jar:1.2.3]位于java.util.concurrent.threadpoolexecutor.runworker(threadpoolexecutor。java:1149)[?:1.8.0201]位于java.util.concurrent.threadpoolexecutor$worker.run(threadpoolexecutor。java:624)[?:1.8.0\u 201]在java.lang.thread.run(thread。java:748) [?:1.8.0_201]

a0zr77ik

a0zr77ik1#

您编写的list命令有点错误。应该是的 storm list -c nimbus.seeds='[\"localhost\"]' . 一旦终端解释器处理完字符串,它需要与storm.yaml中的相同。所以使用 nimbus.seeds='[\"localhost\"] 最后像这样传递一根线 nimbus.seeds=["localhost"] Storm。

相关问题