#Zookeeper的日志可以用LogFormatter查看
##命令方式如下
java -classpath .:slf4j-api-1.7.2.jar:zookeeper-3.4.6.jar org.apache.zookeeper.server.LogFormatter /var/lib/zookeeper/version-2/log.1
##window的bat批量方式
@echo off
echo 查看zookeeper日志:
set /p log_path=请输入日志路径:
set class_path=".;*"
java -classpath %class_path% org.apache.zookeeper.server.LogFormatter %log_path%
@pause
#使用说明:“look_Log”目录里面日志需要的jar也都放好了,你如果jdk安装好了并配置了window环境变量的,直接运行“look_Log/looklog.bat”然后入日志路径(包含文件名称:例如“version-2/log.1”)
1