前言

经历:

最近在搭建zookeeper集群,基础是3台机器(尝试过ubuntu 17 和 Centos 7)。

一开始选择的是3台腾讯云服务器,每台机器在java环境配置正确的情况下,单机的情况都运行正常。

(java环境配置教程:http://www.cnblogs.com/toulanboy/p/8681204.html

但是一旦尝试建立集群(也就是zoo.cfg包含3条服务器条目时),则相互连接失败。

报的第一个异常是:

BindException: Cannot assign requested address

尝试过的方案:

1. 关闭防火墙(解决失败)

2. 将外网IP换成内网IP(腾讯云提供的内网ip互相Ping不通)

本文博客地址:http://www.cnblogs.com/toulanboy/

最终解决方案:用物理机,且必须在同一局域网下

总结故障原因可能有2:

1. 腾讯云服务器底层有其他限制,导致zookeeper集群无法成功互相连接。

2. 集群的机器需要在同一局域网下。

以上是我这一周来的头疼总结。希望对你有帮助。

Zookeeper 集群 BindException: Cannot assign requested address 解决方案的更多相关文章

  1. com.sun.xml.internal.ws.server.ServerRtException: Server Runtime Error: java.net.BindException: Cannot assign requested address: bind

    在发布 web service 时报错: Endpoint.publish(publishAddress, hl7MessageReveiver); com.sun.xml.internal.ws.s ...

  2. tomcat java.net.BindException: Cannot assign requested address 解决方法

    今天线上TOMCAT启动时遇到了下比较麻烦的问题,错误如下: 21-Apr-2016 15:14:19.077 SEVERE [main] org.apache.catalina.core.Stand ...

  3. Tomcat启动报错:严重: StandardServer.await: create[8005] java.net.BindException: Cannot assign requested address

    org.apache.catalina.core.StandardServer await        SEVERE: StandardServer.await: create[8005]:    ...

  4. java.net.BindException: Cannot assign requested address: bind

    异常信息 时间:2017-03-16 10:21:05,644 - 级别:[ERROR] - 消息: [other] Failed to start end point associated with ...

  5. tomcat启动端口号报错java.net.BindException: Cannot assign requested address

    异常信息 时间:2017-02-09 15:09:59,829 - 级别:[ERROR] - 消息: [other] Failed to start end point associated with ...

  6. 服务器启动socket服务报错 java.net.BindException:Cannot assign requested address

    错误信息:  2017-06-13 11:18:00,865 [GateServer.java:82][ERROR]:启动服务出错了java.net.BindException: Cannot ass ...

  7. Tomcat启动异常 java.net.BindException: Cannot assign requested address: JVM_Bind

    从Apache官网下载的tomcat7,在MyEclipse中启动时抛出如下异常: 严重: StandardServer.await: create[localhost:8005]: java.net ...

  8. Tomcat启动报错:StandardServer.await: create[8005] java.net.BindException: Cannot assign requested address

    Tomcat启动报错:StandardServer.await: create[8005] java.net.BindException: Cannot assign requested addres ...

  9. Tomcat启动报错:java.net.BindException: Cannot assign requested address: JVM_Bind

    Tomcat启动报错:java.net.BindException: Cannot assign requested address: JVM_Bind Tomcat Cannot assign re ...

随机推荐

  1. 图片美化增强AI接口调用手册

    在调合合AI平台提供的图片美化增强API接口,API平台链接:https://ai.ccint.com/doc/api/crop_enhance_image, 因为有遇到一些问题,写篇博客记录一下 A ...

  2. luoguP4242树上的毒瘤

    传送门 模板集合吧,除了码农,没啥难的... 和bzoj2243:[SDOI2011]染色十分相像,但是多了点集和查询的区别 然后点集显然可以看出是虚树问题,查询可以用点分治\(O(nlogn)\), ...

  3. swift SqliteDB使用

    操作步骤: 1,在 Build Phases -> Link Binary With Libraries 中点击加号,添加 libsqlite3.0.tbd 到项目中来   2,创建连接头文件B ...

  4. [题解](组合数/二位前缀和)luogu_P2822组合数问题

    首先要知道C(n,m)=C(n-1,m)+C(n-1,m-1),这样显然是一个杨辉三角,这样大部分的问题就解决了, 那么判能否整除只需要杨辉三角对k取模即可, 而对于多组数据的k都是一样的,所以用前缀 ...

  5. ZROI 部分题目题解

    ZROI 部分题目题解 335 首先发现一个性质: 对于最短的边而言,所有点的路径如果经过了这条边,那么路径的权值就是这条边的边权(废话) 那么我们把最短的边拎出来,可以发现,博物馆确定时,每个点按照 ...

  6. php—cURL库基本用法总结

    作用 用来连接客户端和服务器端,实从互联网上获取资源 常用接口 curl_init(): 初始化curl curl_close: 结束curl,释放资源 curl_setopt: 设置curl的属性 ...

  7. Connected Components? Codeforces - 920E || 洛谷 P3452 &&bzoj1098 [POI2007]BIU-Offices

    https://codeforces.com/contest/920/problem/E https://www.luogu.org/problemnew/show/P3452 https://www ...

  8. Jenkins之发布报错“error: RPC failed; curl 18 transfer closed with outstanding read data remaining”

    报错信息: error: RPC failed; curl transfer closed with outstanding read data remaining fatal: The remote ...

  9. 运行nodejs项目报Process finished with exit code 1 错误

    在项目中,明明在别人的机子上项目可以运行,但是复制到自己的电脑就无法就无法启动.报Process finished with exit code 1错误,也没提示错误地方.自己倒腾了很久总结了几个解决 ...

  10. .Net 第一章笔记

    1.深入.NET框架 对象数组 登录和注册 内存级别数据的拎取 1..NET 战略 Java领域:::::SQL Server不会用到 浏览器IE 口号:任何人 在任何地方 使用任何终端,,都可以使用 ...