我正在尝试在分布式设置中将orientdb版本从2.1.15升级到2.2.28:node1(MASTER)和node2(MASTER)。
Upgrade process: 1. Stop orientdb service on node1 and node 2. Upgrading node1 2.1 Copy the existing database in ~/tmp folder. 2.2 Download Orientdb v2.2.28 copy all the files in existing Orientdb folder. 2.3 Copy the existing database from ~/tmp to orientdb working dir. 2.4 Run node1 as standalone server (not in distributed mode) 2.5 Stop node1 2.6 Config node1 to run in distributed mode and run node 1 in distributed mode 3. Upgrade node2 following same steps as in node1
修改了文件以在分布式模式下运行
hazelcast.xml
<network>
<port auto-increment="false">3000</port>
<join>
<multicast enabled="false">
<multicast-group>235.1.1.1</multicast-group>
<multicast-port>2434</multicast-port>
</multicast>
<tcp-ip enabled="true">
<member>node1:3000</member>
<member>node2:3000</member>
</tcp-ip>
</join>
</network>
默认分布式-DB-config.json
{
"autoDeploy": true,
"readQuorum": 1,
"writeQuorum": "majority",
"executionMode": "undefined",
"readYourWrites": true,
"newNodeStrategy": "static",
"servers": {
"*": "master"
},
"clusters": {
"internal": {
},
"*": {
"servers": ["node1","node2"]
}
}
}
但是我得到一个错误node2,它在node1
之后加入了集群2017-11-29 10:57:10:140 INFO [node2] Servers in cluster: [node1, node2] [OHazelcastPlugin][node2] Error on starting distributed plugin
java.net.NoRouteToHostException: No route to host
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:339)
at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:200)
at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:182)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
at java.net.Socket.connect(Socket.java:579)
at com.orientechnologies.orient.client.binary.OChannelBinaryClientAbstract.<init>(OChannelBinaryClientAbstract.java:70)
at com.orientechnologies.orient.client.binary.OChannelBinarySynchClient.<init>(OChannelBinarySynchClient.java:32)
at com.orientechnologies.orient.server.distributed.ORemoteServerChannel.connect(ORemoteServerChannel.java:111)
at com.orientechnologies.orient.server.distributed.ORemoteServerChannel.<init>(ORemoteServerChannel.java:75)
at com.orientechnologies.orient.server.distributed.ORemoteServerController.<init>(ORemoteServerController.java:53)
at com.orientechnologies.orient.server.hazelcast.OHazelcastPlugin.getRemoteServer(OHazelcastPlugin.java:653)
at com.orientechnologies.orient.server.hazelcast.OHazelcastPlugin.startup(OHazelcastPlugin.java:250)
at com.orientechnologies.orient.server.OServer.registerPlugins(OServer.java:1257)
at com.orientechnologies.orient.server.OServer.activate(OServer.java:406)
at com.orientechnologies.orient.server.OServerMain$1.run(OServerMain.java:46)
com.orientechnologies.orient.server.distributed.ODistributedStartupException: Error on starting distributed plugin
at com.orientechnologies.orient.server.hazelcast.OHazelcastPlugin.startup(OHazelcastPlugin.java:311)
at com.orientechnologies.orient.server.OServer.registerPlugins(OServer.java:1257)
at com.orientechnologies.orient.server.OServer.activate(OServer.java:406)
at com.orientechnologies.orient.server.OServerMain$1.run(OServerMain.java:46)
Caused by: java.net.NoRouteToHostException: No route to host
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:339)
at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:200)
at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:182)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
at java.net.Socket.connect(Socket.java:579)
at com.orientechnologies.orient.client.binary.OChannelBinaryClientAbstract.<init>(OChannelBinaryClientAbstract.java:70)
at com.orientechnologies.orient.client.binary.OChannelBinarySynchClient.<init>(OChannelBinarySynchClient.java:32)
at com.orientechnologies.orient.server.distributed.ORemoteServerChannel.connect(ORemoteServerChannel.java:111)
at com.orientechnologies.orient.server.distributed.ORemoteServerChannel.<init>(ORemoteServerChannel.java:75)
at com.orientechnologies.orient.server.distributed.ORemoteServerController.<init>(ORemoteServerController.java:53)
at com.orientechnologies.orient.server.hazelcast.OHazelcastPlugin.getRemoteServer(OHazelcastPlugin.java:653)
at com.orientechnologies.orient.server.hazelcast.OHazelcastPlugin.startup(OHazelcastPlugin.java:250)
... 3 more
这是升级在分布式模式下运行的orientdb的正确方法吗?或者这与2.2.28版本有关(如果我使用相同的升级过程从2.2.28降级到2.2.15,它会再次开始工作)。
如果有人能指出我正确的方向,那就太好了。
答案 0 :(得分:0)
所以你需要先修复它。节点应该能够在配置的IP / DNS,端口等上看到彼此(或相互ping通)。如果3000无法访问,则尝试其他端口。