zookeeper 安装集群,配置文件和data和其它都没有问题。

则需要在data里面下添加一个myid 文件

myid里面的数据个service一致

比如.cnf里面配置是

dataDir=/usr/local/src/zookeeper/apache-zookeeper-3.6.3-bin/data
dataLogDir=/usr/local/src/zookeeper/apache-zookeeper-3.6.3-bin/logs
# 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
###集群信息
server.1=192.168.0.79:3188:3288
server.2=192.168.0.118:3188:3288
server.3=192.168.0.81:3188:3288

对应service.1 service.2 service.3 上分别创建文件
比如192.168.0.79
echo "1" >/usr/local/src/zookeeper/apache-zookeeper-3.6.3-bin/data/myid 192.168.0.118 上
echo "2" > /usr/local/src/zookeeper/apache-zookeeper-3.6.3-bin/data/myid
192.168.0.81上
echo "3" > /usr/local/src/zookeeper/apache-zookeeper-3.6.3-bin/data/myid

启动zookeeper

/usr/local/src/zookeeper/apache-zookeeper-3.6.3-bin/bin/zkServer.sh start

ps -ef | grep zookeeper

dataDir=/usr/local/src/zookeeper/apache-zookeeper-3.6.3-bin/data

dataLogDir=/usr/local/src/zookeeper/apache-zookeeper-3.6.3-bin/logs

# 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

###集群信息

server.1=192.168.0.79:3188:3288

server.2=192.168.0.118:3188:3288

server.3=192.168.0.81:3188:3288

zookeeper Caused by: java.lang.IllegalArgumentException: myid file is missing的更多相关文章

  1. Caused by: java.lang.IllegalArgumentException: Could not resolve placeholder 'jdbc.username' in string value "${jdbc.username}"

    1.启动dubbo的引用dubbo服务时候报下面这个错误,这是由于去找dubbo的发布服务未找到报的错误,所以先启动dubbo的发布服务即可. [INFO] Scanning for projects ...

  2. kettle添加hadoop cluster时报错Caused by: java.lang.IllegalArgumentException: Does not contain a valid host:port authority: hadoop:password@node56:9000

    完整报错是: Caused by: java.lang.IllegalArgumentException: Does not contain a valid host:port authority: ...

  3. Caused by: java.lang.IllegalArgumentException: Property 'sqlSessionFactory' or 'sqlSessionTemplate' are required [ IDEA mybatis项目报错 ]

    今天笔者用Springboot框架整合Mybatis做一个小小的项目: 代码写完,在运行项目时,IDEA给我报了3处错误: org.springframework.beans.factory.Unsa ...

  4. springboot整合mybatis的时候报错Caused by: java.lang.IllegalArgumentException: Property 'sqlSessionFactory' or 'sqlSessionTemplate' are required

    今天闲来无事,学习springboot整合mybatis,在bilibili看视频学的,视频中在dao层的interface上面加上org.apache.ibatis.annotations.Mapp ...

  5. 使用 Jenkins 打包成功后 运行 出现 Caused by: java.lang.IllegalArgumentException: Property 'sqlSessionFactory' or 'sqlSessionTemplate' are required

    linux 运行时 错误日志 Error starting ApplicationContext. To display the conditions report re-run your appli ...

  6. mybatis报错:Caused by: java.lang.IllegalArgumentException: Caches collection already contains value for com.crm.dao.PaperUserMapper

    一.问题 eclipse启动时报下面的错误: Caused by: java.lang.IllegalArgumentException: Caches collection already cont ...

  7. 解决Caused by: java.lang.IllegalArgumentException: Result Maps collection does not contain value for com.geek.dao.ContentDao.Integer

    mybatis报错:Caused by: java.lang.IllegalArgumentException: Result Maps collection does not contain val ...

  8. 解决Caused by: java.lang.IllegalArgumentException: A universal match pattern ('/**') is defined before other patterns in the filter chain, causing them to be ignored. Please check the ordering in your

    写项目时应用了SpringSecurity框架来进行登陆验证,之前单独的写简单的SpringSecrity的Demo时并没有报错,但是当和SpringMVC一起整合时却发生了报错 报错如下: Caus ...

  9. Caused by: java.lang.IllegalArgumentException: argument type mismatch

    下面是我的报错信息 at org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java: ...

随机推荐

  1. 四月总结&五月计划

    四月总结 1. 主要任务 <Effective C++>书 ① 进展: 看完了30讲(共55讲),从4月20号开始居家办公,书落在公司了,一直到昨天29号才去园区上班,耽搁了.30讲之前的 ...

  2. 一行代码如何隐藏 Linux 进程?

    开源Linux 长按二维码加关注~ 上一篇:IPv6技术白皮书(附PDF下载) 总有朋友问隐藏Linux进程的方法,我说你想隐藏到什么程度,是大隐于内核,还是小隐于用户.网上通篇论述的无外乎 hook ...

  3. 微信小程序云开发如何实现微信支付,业务逻辑又怎样才算可靠

    今天打了几把永劫无间后,咱们来聊一聊用云开发来开发微信小程序时,如何实现微信支付,并且保证业务逻辑可靠. @ 目录 注册微信支付商户号 小程序关联商户号 业务逻辑 代码实现 注册微信支付商户号 点击& ...

  4. Redis设计与实现3.3:集群

    集群 这是<Redis设计与实现>系列的文章,系列导航:Redis设计与实现笔记 集群中的节点 创建集群 通过 CLUSTER NODE 命令可以查看当前集群中的节点.刚启动时,默认每一台 ...

  5. Nginx分片限流

    一.全局限流 在http节点中添加 # 创建限流规则 limit_req_zone $binary_remote_addr zone=addr:10m rate=1r/s;# 客户端进行限流 # li ...

  6. JAVA数组案例!

    数组的用例 一.案例需求: 有这样的一个数组,元素是{68,27,95,88,171,996,51,210}.求出该数组中满足要求的元素和, 要求是:求和的元素个位和十位都不能是7,并且只能是偶数如何 ...

  7. MongoDB 主节点的选举原则

    每日一句 Life is like a shower. One wrong turn and you're in hot water. 生活就像淋浴,方向转错,水深火热. 概述 MongoDB在副本集 ...

  8. js 定时器 Timer

    1 /* Timer 定时器 2 3 parameter: 4 func: Function; //定时器运行时的回调; 默认 null 5 speed: Number; //延迟多少毫秒执行一次 f ...

  9. Android 实现开机自启APP

    原文地址:Android 实现开机自启APP - Stars-One的杂货小窝 公司有个项目,需要实现自启动的功能,本来想着是设置桌面启动器的方式去实现,但是设备是华为平板(EMUI系统),不允许设置 ...

  10. select into 与 insert into 的区别

    1.select * into table_A  from table_B table_A是个新创建表,table_B是个已经存在的表. 2.insert into table_A from tabl ...