天天看点

zk ui安装 (选装,页面查看zk的数据)

# 使用WEB UI查看监控集群-zk ui安装
cd /usr/local

git clone https://github.com/DeemOpen/zkui.git

yum install -y maven

# 更换使用阿里云maven源
vim /etc/maven/settings.xml 
	<mirrors>  

	    <mirror>
	        <id>nexus-aliyun</id>
	        <mirrorOf>central</mirrorOf>
	        <name>Nexus aliyun</name>
	        <url>http://maven.aliyun.com/nexus/content/groups/public</url>
	    </mirror>

	</mirrors>

cd zkui/

mvn clean install

# 修改配置文件默认值
vim config.cfg
    serverPort=9090     #指定端口
    zkServer=localhost:2181,localhost:2182,localhost:2183 # 不使用127.0.0.1
    sessionTimeout=300

    # userSet中是登陆web界面的用户名和密码
	#管理员
	#admin:manager
	#用户
	#appconfig:appconfig

# 启动程序至后台
vim start.sh
	#!/bin/bash

	nohup java -jar target/zkui-2.0-SNAPSHOT-jar-with-dependencies.jar &

# 浏览器访问
# 防火墙放行9090端口,后期改用nginx代理
http://192.168.0.187:9090/