无法从其他节点启动geode服务器

时间:2017-10-09 10:58:16

标签: java caching gemfire geode

我在node1上运行了一个定位器和一个服务器。我想从node2启动另一个服务器。我能够从node1连接到定位器,但是当我尝试创建另一个服务器时,我遇到了一些错误。

节点1(172.20.22.52):

gfsh>list members
 Name   | Id
------- | ------------------------------------------------
locator | 172.20.22.52(locator:10094:locator)<ec><v0>:1024
server1 | 172.20.22.52(server1:10220)<v1>:1025

节点2(172.20.22.121)

gfsh>connect --locator=172.20.22.52[10334]
Already connected to: auto-crawler-tikv-1.cs1cloud.internal[1099]

现在,我尝试启动另一台服务器&#34; server2&#34;在node2上。

gfsh>start server --name=server2
Starting a Geode Server in /home/admin/apache-geode-1.2.1/bin/server2...
The Cache Server process terminated unexpectedly with exit status 1. Please refer to the log file in /home/admin/apache-geode-1.2.1/bin/server2 for full details.

Exception in thread "main" org.apache.geode.GemFireConfigException
    at org.apache.geode.distributed.internal.membership.gms.messenger.JGroupsMessenger.init(JGroupsMessenger.java:254)
    at org.apache.geode.distributed.internal.membership.gms.Services.init(Services.java:134)
    at org.apache.geode.distributed.internal.membership.gms.GMSMemberFactory.newMembershipManager(GMSMemberFactory.java:101)
    at org.apache.geode.distributed.internal.membership.MemberFactory.newMembershipManager(MemberFactory.java:89)
    at org.apache.geode.distributed.internal.DistributionManager.<init>(DistributionManager.java:1153)
    at org.apache.geode.distributed.internal.DistributionManager.<init>(DistributionManager.java:1201)
    at org.apache.geode.distributed.internal.DistributionManager.create(DistributionManager.java:572)
    at org.apache.geode.distributed.internal.InternalDistributedSystem.initialize(InternalDistributedSystem.java:697)
    at org.apache.geode.distributed.internal.InternalDistributedSystem.newInstance(InternalDistributedSystem.java:305)
    at org.apache.geode.distributed.DistributedSystem.connect(DistributedSystem.java:205)
    at org.apache.geode.cache.CacheFactory.create(CacheFactory.java:210)
    at org.apache.geode.distributed.internal.DefaultServerLauncherCacheProvider.createCache(DefaultServerLauncherCacheProvider.java:52)
    at org.apache.geode.distributed.ServerLauncher.createCache(ServerLauncher.java:860)
    at org.apache.geode.distributed.ServerLauncher.start(ServerLauncher.java:772)
    at org.apache.geode.distributed.ServerLauncher.run(ServerLauncher.java:699)
    at org.apache.geode.distributed.ServerLauncher.main(ServerLauncher.java:231)
Caused by: java.net.UnknownHostException
    at org.apache.geode.internal.net.SocketCreator.getLocalHost(SocketCreator.java:280)
    at org.apache.geode.distributed.internal.membership.gms.messenger.JGroupsMessenger.init(JGroupsMessenger.java:252)
    ... 15 more

我可以从一台服务器ping到另一台服务器。我

1 个答案:

答案 0 :(得分:1)

错误是:

  

引起:java.net.UnknownHostException       在org.apache.geode.internal.net.SocketCreator.getLocalHost(SocketCreator.java:280)

这是网络。你说你“可以从一个服务器ping到另一个服务器”,但是你可以通过主机名而不是IP来ping?它正在尝试解析主机名以获取IP,并且它不知道要连接到哪个IP。

auto-crawler-tikv-1.cs1cloud.internal是否有/ etc / hosts将localhost解析为172.20.22.121?你的node2 / etc / hosts是否知道auto-crawler-tikv-1.cs1cloud.internal解析为172.20.22.121?

另一个考虑因素是在服务器和定位器上设置--bind-address。见https://gemfire.docs.pivotal.io/gemfire/tools_modules/gfsh/command-pages/start.html