zoukankan      html  css  js  c++  java
  • Zookeeper环境搭建(Windows)

    下载

    官网
    下载最新的版本,我下载的是3.6.1的版本。
    下载下来的文件是apache-zookeeper-3.6.1-bin.tar.gz
    解压出来是这样的包括文件夹:
    bin
    conf
    docs
    lib
    文件:
    LICENSE
    NOTICE
    README.md
    README_packaging.md

    更改配置文件

    配置文件在conf/zoo.cfg

    # The number of milliseconds of each tick
    tickTime=2000
    # The number of ticks that the initial 
    # synchronization phase can take
    initLimit=10
    # The number of ticks that can pass between 
    # sending a request and getting an acknowledgement
    syncLimit=5
    # the directory where the snapshot is stored.
    # do not use /tmp for storage, /tmp here is just 
    # example sakes.
    dataDir=D:Toolsapache-zookeeper-3.6.1-bi\data
    dataLogDir=D:Toolsapache-zookeeper-3.6.1-binlog
    # the port at which the clients will connect
    clientPort=2181
    # the maximum number of client connections.
    # increase this if you need to handle more clients
    #maxClientCnxns=60
    #
    # Be sure to read the maintenance section of the 
    # administrator guide before turning on autopurge.
    #
    # http://zookeeper.apache.org/doc/current/zookeeperAdmin.html#sc_maintenance
    #
    # The number of snapshots to retain in dataDir
    #autopurge.snapRetainCount=3
    # Purge task interval in hours
    # Set to "0" to disable auto purge feature
    #autopurge.purgeInterval=1
    
    ## Metrics Providers
    #
    # https://prometheus.io Metrics Exporter
    #metricsProvider.className=org.apache.zookeeper.metrics.prometheus.PrometheusMetricsProvider
    #metricsProvider.httpPort=7000
    #metricsProvider.exportJvmInfo=true
    admin.serverPort=8888
    

    指定了data路径和log路径
    注意最后一行是更改端口号的,AdminServer的默认端口号是8080,如果不想用8080端口就可以指定别的端口,我这里指定的是8888.

    双击bin/zkServer.cmd

    操作参考链接

    Zookeeper还有一套UI可视化界面(ZKUI

  • 相关阅读:
    安装Kali Linux虚拟机02
    前端入门之——知识补充 day11
    套接字编程知识回顾01
    关于js中 document.body.scrollTop 不能返回正确值的原因
    前端入门之——后台管理页面布局 学习 day10
    前端入门之——jquery day9
    pickle序列化与反序列化 + eval说明
    json序列化与反序列化
    项目中日志输出常用的设置
    logging模块基础3
  • 原文地址:https://www.cnblogs.com/LoganChen/p/13594394.html
Copyright © 2011-2022 走看看