kafka远程部署完后启动,远程断开kafka也自动断开
求助!!!
使用kafka和zookeeper搭建集群,zookeeper已经搭建OK,kafka配置参数也已经完成,所有的过程都是远程连接服务器部署安装。部署完成后zookeeper和kafka都能够启动运行正常 ,但是当远程连接一断开,再次远程登录kafka就会自动断开,启动kafka使用的是
bin/kafka-server-start.sh -daemon config/server.properties
kafka版本:kafka_2.10-0.10.2.0
在配置kafka的server.properties的参数是按照如下:
broker.id=1
port=9092
host.name=192.168.3.1
log.dirs=/home/user/home/www/kafka_2.10-0.10.1.0/logs(此处由实际的路径设置)
zookeeper.connect=192.168.3.1:2181,192.168.3.2:2181,192.168.3.3:2181
报错信息来自kafkaServer.out
[2017-04-18 05:38:06,023] INFO [Kafka Server 1], shut down completed (kafka.server.KafkaServer)
[2017-04-18 05:38:06,023] FATAL Fatal error during KafkaServerStartable startup. Prepare to shutdown (kafka.server.KafkaServerStartable)
java.io.FileNotFoundException: /home/ubuntu/home/www/kafka_2.10-0.10.2.0/logs/__consumer_offsets-49/00000000000000000000.index (No such file or directory)
at java.io.RandomAccessFile.open0(Native Method)
at java.io.RandomAccessFile.open(RandomAccessFile.java:316)
at java.io.RandomAccessFile.<init>(RandomAccessFile.java:243)
at kafka.log.AbstractIndex$$anonfun$resize$1.apply(AbstractIndex.scala:102)
at kafka.log.AbstractIndex$$anonfun$resize$1.apply(AbstractIndex.scala:101)
at kafka.utils.CoreUtils$.inLock(CoreUtils.scala:213)
at kafka.log.AbstractIndex.resize(AbstractIndex.scala:101)
at kafka.log.AbstractIndex$$anonfun$trimToValidSize$1.apply$mcV$sp(AbstractIndex.scala:163)
at kafka.log.AbstractIndex$$anonfun$trimToValidSize$1.apply(AbstractIndex.scala:163)
at kafka.log.AbstractIndex$$anonfun$trimToValidSize$1.apply(AbstractIndex.scala:163)
at kafka.utils.CoreUtils$.inLock(CoreUtils.scala:213)
at kafka.log.AbstractIndex.trimToValidSize(AbstractIndex.scala:162)
at kafka.log.LogSegment.recover(LogSegment.scala:250)
at kafka.log.Log$$anonfun$loadSegments$4.apply(Log.scala:231)
at kafka.log.Log$$anonfun$loadSegments$4.apply(Log.scala:188)
at scala.collection.TraversableLike$WithFilter$$anonfun$foreach$1.apply(TraversableLike.scala:772)
at scala.collection.IndexedSeqOptimized$class.foreach(IndexedSeqOptimized.scala:33)
at scala.collection.mutable.ArrayOps$ofRef.foreach(ArrayOps.scala:108)
at scala.collection.TraversableLike$WithFilter.foreach(TraversableLike.scala:771)
at kafka.log.Log.loadSegments(Log.scala:188)
at kafka.log.Log.<init>(Log.scala:116)
at kafka.log.LogManager$$anonfun$loadLogs$2$$anonfun$3$$anonfun$apply$10$$anonfun$apply$1.apply$mcV$sp(LogManager.scala:157)
at kafka.utils.CoreUtils$$anon$1.run(CoreUtils.scala:57)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
[2017-04-18 05:38:06,024] INFO [Kafka Server 1], shutting down (kafka.server.KafkaServer)
非常感谢!!!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
使用 screen 或 nohup 方式启动kafka