准备
mkdir output
vi consumer_kafka.sh
nohup kafka-console-consumer --bootstrap-server 172.24.103.8:9092,172.24.103.9:9092,172.24.103.10:9092 --topic monitor_dev >> output/consumer_kafka_out.txt &
echo $! > consumer_kafka.pid
说明:后台运行,并会把进程id保存下来
版权声明:本文为zhiwenshow原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。