热门标签 | HotTags
当前位置:  开发笔记 > 编程语言 > 正文

zookeeper下载安装、zookeeper3.4.6下载安装、Windows启动zookeeper、zookeeper启动闪退解决、\..\conf\zoo.cfgfileismissin

zookeeper下载安装、zookeeper-3.4.6下载安装、Windows启动zookeeper、zookeeper启动闪退解决、zookeeper找不到zoo.cfg配置

zookeeper下载安装、zookeeper-3.4.6下载安装、Windows启动zookeeper、zookeeper启动闪退解决、zookeeper找不到zoo.cfg配置:\..\conf\

  • zookeeper下载
    • 官网下载ZooKeeper安装包
    • 官网历史版本下载
  • Windows启动zookeeper
    • 1.解压
    • 2.修改conf文件夹中的zoo_sample.cfg文件名为zoo.cfg
    • 3.在zoo.cfg设置dataDir目录
    • 4.启动zookeeper
  • zookeeper启动异常解决方案
    • zookeeper启动闪退解决
    • zookeeper找不到zoo.cfg配置:\..\conf\zoo.cfg file is missing


zookeeper下载链接:
官网:https://zookeeper.apache.org/releases.html
历史版本:https://archive.apache.org/dist/zookeeper/
zookeeper-3.4.6云盘:https://pan.baidu.com/s/1-YNJW0oSf4vowPtSe-w5Lg?pwd=euxp


zookeeper下载

官网下载ZooKeeper安装包

官网下载ZooKeeper安装包:https://zookeeper.apache.org/releases.html

在这里插入图片描述

官网历史版本下载

官网历史版本下载链接:https://archive.apache.org/dist/zookeeper/

如果想要下载之前一点的版本
在这里插入图片描述

在这里插入图片描述
选择对应tar包下载即可

Windows启动zookeeper

1.解压

下载完成后进行解压,解压目录结构如下图在这里插入图片描述

2.修改conf文件夹中的zoo_sample.cfg文件名为zoo.cfg

zookeeper启动寻找配置文件的目录对应zkEnv前缀文件的相对路径:…\conf\zoo.cfg,需要先将conf文件夹中的zoo_sample.cfg文件名为zoo.cfg
在这里插入图片描述

3.在zoo.cfg设置dataDir目录

# 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=/tmp/zookeeper
# 数据目录改为zookeeper解压目录
dataDir=C:\Users\Administrator\Desktop\zookeeper-3.4.6\data
# 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

4.启动zookeeper

在这里插入图片描述

zookeeper启动异常解决方案

zookeeper启动闪退解决

有的时候会出现双击闪退的情况。针对闪退,可按照一下步骤进行解决:

  1. 编辑zkServer.cmd文件末尾添加pause 。这样运行出错就不会退出,会提示错误信息,方便找到原因。

@echo off
REM Licensed to the Apache Software Foundation (ASF) under one or more
REM contributor license agreements. See the NOTICE file distributed with
REM this work for additional information regarding copyright ownership.
REM The ASF licenses this file to You under the Apache License, Version 2.0
REM (the "License"); you may not use this file except in compliance with
REM the License. You may obtain a copy of the License at
REM
REM http://www.apache.org/licenses/LICENSE-2.0
REM
REM Unless required by applicable law or agreed to in writing, software
REM distributed under the License is distributed on an "AS IS" BASIS,
REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
REM See the License for the specific language governing permissions and
REM limitations under the License.setlocal
call "%~dp0zkEnv.cmd"set ZOOMAIN=org.apache.zookeeper.server.quorum.QuorumPeerMain
echo on
java "-Dzookeeper.log.dir=%ZOO_LOG_DIR%" "-Dzookeeper.root.logger=%ZOO_LOG4J_PROP%" -cp "%CLASSPATH%" %ZOOMAIN% "%ZOOCFG%" %*
pause
endlocal

  1. 重新双击运行zkServer.cmd查看错误异常
    在这里插入图片描述

zookeeper找不到zoo.cfg配置:…\conf\zoo.cfg file is missing

错误原因 ,找不到zoo.cfg配置文件

  1. 编辑zkEnv.cmd
    在这里插入图片描述

  2. 寻找配置文件的目录对应zkEnv前缀文件的相对路径:…\conf\zoo.cfg,需要先将conf文件夹中的zoo_sample.cfg文件名为zoo.cfg
    在这里插入图片描述

  3. 重新双击zkServer.cmd启动

至此,Zookeeper正常启动!


推荐阅读
  • CEPH LIO iSCSI Gateway及其使用参考文档
    本文介绍了CEPH LIO iSCSI Gateway以及使用该网关的参考文档,包括Ceph Block Device、CEPH ISCSI GATEWAY、USING AN ISCSI GATEWAY等。同时提供了多个参考链接,详细介绍了CEPH LIO iSCSI Gateway的配置和使用方法。 ... [详细]
  • 本文分析了Wince程序内存和存储内存的分布及作用。Wince内存包括系统内存、对象存储和程序内存,其中系统内存占用了一部分SDRAM,而剩下的30M为程序内存和存储内存。对象存储是嵌入式wince操作系统中的一个新概念,常用于消费电子设备中。此外,文章还介绍了主电源和后备电池在操作系统中的作用。 ... [详细]
  • 一个不错的JDBC连接池教程(带具体例子)
    1.前言数据库应用,在许多软件系统中经常用到,是开发中大型系统不可缺少的辅助。但如果对数据库资源没有很好地管理(如:没有及时回收数据库的游 ... [详细]
  • SQLPLUS 命令
    定制:sql提示符信息1、显示SQLPLUS帮助,命令如下:HELPINDEX@COPYPAUSESHUTDOWN@@DEFINEPRINTSPOOLDELPR ... [详细]
  • android listview OnItemClickListener失效原因
    最近在做listview时发现OnItemClickListener失效的问题,经过查找发现是因为button的原因。不仅listitem中存在button会影响OnItemClickListener事件的失效,还会导致单击后listview每个item的背景改变,使得item中的所有有关焦点的事件都失效。本文给出了一个范例来说明这种情况,并提供了解决方法。 ... [详细]
  • 开发笔记:深度探索!Android之OkHttp网络架构源码解析
    篇首语:本文由编程笔记#小编为大家整理,主要介绍了深度探索!Android之OkHttp网络架构源码解析相关的知识,希望对你有一定的参考价值。 ... [详细]
  • FF——————————–直接使用document.creatRange()来创建一个选区;默认是空的;使用selectNode(obj)来代替moveToElementText ... [详细]
  • 阿里p8用端午节3天假期整理出了Spring Cloud知识点大全,太全了
     前言:今天一觉起来,发现我们开工的日期又延迟了,虽然已经在家办公一个多礼拜了,但是由于家里的环境还是不能有很高的效率。于是干脆就对SpringCloud的一些知识点做了一些整理。 ... [详细]
  • DimcnAsNewADODB.ConnectionDimcmdAsNewADODB.CommandDimrstAsNewADODB.Recordsetcn.Mod ... [详细]
  • 利用原始socket简单实现FTP的客户端和服务器端程序
    1.设计目的本设计旨在利用原始socket简单实现FTP(FileTransferProtocol,文件传输协议)的客户端和服务器端程序,能够实现get、put、pwd、dir、cd等基 ... [详细]
  • 不常见的RAID,RAID2,RAID4,RAID7
    RAID2的技术RAID2是RAID0的改良版,以汉明码(HammingCode)的方式将数据进行编码后分割为独立的位元,并 ... [详细]
  • Windows下配置PHP5.6的方法及注意事项
    本文介绍了在Windows系统下配置PHP5.6的步骤及注意事项,包括下载PHP5.6、解压并配置IIS、添加模块映射、测试等。同时提供了一些常见问题的解决方法,如下载缺失的msvcr110.dll文件等。通过本文的指导,读者可以轻松地在Windows系统下配置PHP5.6,并解决一些常见的配置问题。 ... [详细]
  • 本文介绍了Android 7的学习笔记总结,包括最新的移动架构视频、大厂安卓面试真题和项目实战源码讲义。同时还分享了开源的完整内容,并提醒读者在使用FileProvider适配时要注意不同模块的AndroidManfiest.xml中配置的xml文件名必须不同,否则会出现问题。 ... [详细]
  • 单页面应用 VS 多页面应用的区别和适用场景
    本文主要介绍了单页面应用(SPA)和多页面应用(MPA)的区别和适用场景。单页面应用只有一个主页面,所有内容都包含在主页面中,页面切换快但需要做相关的调优;多页面应用有多个独立的页面,每个页面都要加载相关资源,页面切换慢但适用于对SEO要求较高的应用。文章还提到了两者在资源加载、过渡动画、路由模式和数据传递方面的差异。 ... [详细]
  • 本文介绍了关系型数据库和NoSQL数据库的概念和特点,列举了主流的关系型数据库和NoSQL数据库,同时描述了它们在新闻、电商抢购信息和微博热点信息等场景中的应用。此外,还提供了MySQL配置文件的相关内容。 ... [详细]
author-avatar
杜甜甜Athena15
这个家伙很懒,什么也没留下!
PHP1.CN | 中国最专业的PHP中文社区 | DevBox开发工具箱 | json解析格式化 |PHP资讯 | PHP教程 | 数据库技术 | 服务器技术 | 前端开发技术 | PHP框架 | 开发工具 | 在线工具
Copyright © 1998 - 2020 PHP1.CN. All Rights Reserved | 京公网安备 11010802041100号 | 京ICP备19059560号-4 | PHP1.CN 第一PHP社区 版权所有