首页 文章

使用Docker的Yahoo经理错误在[ActorSelection [锚](akka:// kafka-manager-system /)上超时)

提问于
浏览
8

为了复制此问题,请在下面的 yaml 文件上运行 docker run zookeeper 然后 docker-compose up .

我正在使用zookeeper最新图片,wurstmeister / kafka:0.9.0.0-1和sheepkiller/kafka-manager:latest . 我运行 docker-compose up 并且finallzy使它工作但现在我收到以下错误:

enter image description here

我已经搜索了git并且无法使用堆栈 . 在我保存群集之前,一切看起来都很好 . 在Kafka日志中,我得到:

[warn] o.a.z.ClientCnxn - 服务器空的会话0x0,意外错误,关闭套接字连接并尝试重新连接kafka-manager_1 | java.net.ConnectException:连接拒绝了kafka-manager_1 | at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method)〜[na:1.8.0_151] kafka-manager_1 | at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:717)〜[na:1.8.0_151] kafka-manager_1 |在org.apache.zookeeper.ClientCnxnSocketNIO.doTransport(ClientCnxnSocketNIO.java:361)〜[org.apache.zookeeper.zookeeper-3.4.6.jar:3.4.6-1569965] kafka-manager_1 | at org.apache.zookeeper.ClientCnxn $ SendThread.run(ClientCnxn.java:1081)~ [org.apache.zookeeper.zookeeper-3.4.6.jar:3.4.6-1569965]

我也看到了这个:

INFO Got user-level KeeperException when processing sessionid:0x160fb22e9f50000 type:create cxid:0x2a zxid:0x3e txntype:-1 reqpath:n/a Error Path:/brokers/ids Error:KeeperErrorCode = NodeExists for /brokers/ids (org.apache.zookeeper.server.PrepRequestProcessor)

这可以通过启动zookeeper并获取下面的yaml文件配置并运行 docker-compose up 来复制 . 我已经休息了一个星期,我不知道为什么它不起作用 .

Yaml文件:

zookeeper:
  image: confluent/zookeeper
  ports:
    - "2181:2181"

kafka:
  image: wurstmeister/kafka:0.9.0.0-1
  ports:
    - "9092:9092"
  links:
    - zookeeper:zk
  environment:
    - KAFKA_ADVERTISED_HOST_NAME
    - KAFKA_ADVERTISED_PORT=9092
    - KAFKA_DELETE_TOPIC_ENABLE=true
    - KAFKA_LOG_RETENTION_HOURS=1
    - KAFKA_MESSAGE_MAX_BYTES=10000000
    - KAFKA_REPLICA_FETCH_MAX_BYTES=10000000
    - KAFKA_GROUP_MAX_SESSION_TIMEOUT_MS=60000
    - KAFKA_NUM_PARTITIONS=2
    - KAFKA_DELETE_RETENTION_MS=1000


kafka-manager:
  image: sheepkiller/kafka-manager:latest
  ports:
    - "9000:9000"
  links:
    - zookeeper
    - kafka
  environment:
    ZK_HOSTS: zookeeper:2181
    APPLICATION_SECRET: letmein
    KM_ARGS: -Djava.net.preferIPv4Stack=true

簇:

enter image description here

更多群集设置:

enter image description here
然后我得到:

enter image description here

然后:

enter image description here

我运行docker run -it -d zookeeper,然后在该yml文件上进行docker-compose . 它启动但在我创建集群时崩溃 .

Docker配置:

容器:53运行:2暂停:0停止:51图像:13服务器版本:17.12.0-ce存储驱动程序:overlay2支持文件系统:extfs支持d_type:true本机覆盖Diff:true记录驱动程序:json-file Cgroup驱动程序: cgroupfs插件:卷:本地网络:桥接主机ipvlan macvlan null覆盖日志:awslogs流利gcplogs gelf journald json-file logentries splunk syslog Swarm:inactive运行时:runc默认运行时:runc Init二进制:docker-init containerd版本:89623f28b87a6004d4b785663257362d1658a729 runc version: b2567b37d7b75eb4cf325b77297b140ea686ce8f初始版本:949e6fa安全选项:seccomp配置文件:默认内核版本:4.9.60-linuxkit-aufs操作系统:适用于Windows的Docker OSType:linux架构:x86_64 CPU:2总内存:1.934GiB名称:linuxkit-00155dc95329 ID:YJE3 :ZJKS:BJCF:TY4W:BU2Y:U7ZO:5P4B:PYMQ:SLVH:KTXD:V2OS:XKCD Docker Root目录:/ var / lib / docker调试模式(客户端):false调试模式(服务器):true文件描述符:19 Goroutines:36系统时间:2018-01-23T09:47:18.7698506Z EventsListeners:1注册表:https://index.docker.io/v1/标签:实验:true不安全注册表:127.0.0.0/8实时恢复已启用:false

1 回答

  • 0

    调整下面提到的配置,您的超时错误将被修复 .

    • kafka-manager.broker-view-thread-pool-size = <3 * number_of_brokers>

    • kafka-manager.broker-view-max-queue-size = <3 *所有主题的分区总数>

    • kafka-manager.broker-view-update-seconds = <kafka-manager.broker-view-max-queue-size /(10 * number_of_brokers)>

    • kafka-manager.offset-cache-thread-pool-size = <默认为处理器数量>

    • kafka-manager.offset-cache-max-queue-size = <默认值为1000>

    • kafka-manager.kafka-admin-client-thread-pool-size = <默认为处理器数量>

    • kafka-manager.kafka-admin-client-max-queue-size = <默认值为1000>

相关问题