Dynamisches Hinzufügen eines neuen Peers zum Quorum

Ich habe ein Quorum-Setup mit drei Boxen, das auf AWS ausgeführt wird, und ich wollte diesem Setup dynamisch einen Knoten hinzufügen, also habe ich enode dieses Knotens zusammen mit ip in static-nodes.json aller Boxen hinzugefügt und den Knoten gestartet, aber er kann keine Verbindung herstellen ! Ist das der richtige Weg oder gibt es einen anderen Weg? Ich habe sogar versucht, die IP dieses neuen Knotens in der tm.conf-Datei aller Boxen hinzuzufügen. Dies ist, was ich in der geth.log des neuen Knotens bekomme

I0708 15:55:50.787364 ethdb/database.go:81] Allotted 128MB cache and 1024     file handles to /home/ubuntu/qdata/dd/geth/chaindata
I0708 15:55:50.797527 ethdb/database.go:174] closed db:/home/ubuntu/qdata/dd/geth/chaindata
I0708 15:55:50.797984 node/node.go:179] instance: Geth/v1.5.0-unstable-  647025ed/linux/go1.9.1
I0708 15:55:50.798004 ethdb/database.go:81] Allotted 128MB cache and 1024 file handles to /home/ubuntu/qdata/dd/geth/chaindata
I0708 15:55:50.819163 eth/backend.go:177] Protocol Versions: [63 62],      Network Id: 1
I0708 15:55:50.819964 core/blockchain.go:225] Last header: #0 [713e8588…] TD=0
I0708 15:55:50.819982 core/blockchain.go:226] Last block: #0 [713e8588…] TD=0
I0708 15:55:50.819991 core/blockchain.go:227] Fast block: #0 [713e8588…] TD=0
I0708 15:55:50.825067 p2p/server.go:328] Starting Server
I0708 15:55:50.825186 raft/handler.go:151] starting raft protocol handler
I0708 15:55:50.825190 p2p/server.go:582] Listening on [::]:30303
I0708 15:55:50.825222 raft/wal.go:43] replaying WAL
I0708 15:55:50.825273 raft/wal.go:32] loading WAL at term 1 and index 4
I0708 15:55:50.825622 raft/persistence.go:55] Persistent applied index write: 4
I0708 15:55:50.825659 raft/persistence.go:49] Persistent applied index load: 4
I0708 15:55:50.825666 raft/handler.go:286] local raft ID is 4
2018-07-08 15:55:50.825749 I | rafthttp: starting peer 1...
2018-07-08 15:55:50.825796 I | rafthttp: started HTTP pipelining with peer 1
2018-07-08 15:55:50.826944 I | rafthttp: started peer 1
2018-07-08 15:55:50.826960 I | rafthttp: added peer 1
2018-07-08 15:55:50.827000 I | rafthttp: starting peer 2...
2018-07-08 15:55:50.827022 I | rafthttp: started HTTP pipelining with peer 2
2018-07-08 15:55:50.827187 I | rafthttp: started streaming with peer 1 (stream Message reader)
2018-07-08 15:55:50.827296 I | rafthttp: started streaming with peer 1 (writer)
2018-07-08 15:55:50.827309 I | rafthttp: started streaming with peer 1 (writer)
2018-07-08 15:55:50.827331 I | rafthttp: started streaming with peer 1 (stream MsgApp v2 reader)
2018-07-08 15:55:50.828195 I | rafthttp: started peer 2
2018-07-08 15:55:50.828208 I | rafthttp: added peer 2
2018-07-08 15:55:50.828244 I | rafthttp: starting peer 3...
2018-07-08 15:55:50.828255 I | rafthttp: started HTTP pipelining with peer 3
2018-07-08 15:55:50.830164 I | rafthttp: started peer 3
2018-07-08 15:55:50.830190 I | rafthttp: added peer 3
raft2018/07/08 15:55:50 INFO: 4 became follower at term 1
raft2018/07/08 15:55:50 INFO: newRaft 4 [peers: [1,2,3,4], term: 1,  commit: 4, applied: 4, lastindex: 4, lastterm: 1]
I0708 15:55:50.832946 node/node.go:414] HTTP endpoint opened:   http://0.0.0.0:8545
2018-07-08 15:55:50.833650 I | rafthttp: started streaming with peer 3 (writer)
2018-07-08 15:55:50.833861 I | rafthttp: started streaming with peer 3 (stream MsgApp v2 reader)
I0708 15:55:50.837234 node/node.go:344] IPC endpoint opened: /home/ubuntu/qdata/dd/geth.ipc
2018-07-08 15:55:50.847909 I | rafthttp: started streaming with peer 2 (writer)
2018-07-08 15:55:50.848019 I | rafthttp: started streaming with peer 3 (stream Message reader)
2018-07-08 15:55:50.848130 I | rafthttp: started streaming with peer 2 (writer)
2018-07-08 15:55:50.848141 I | rafthttp: started streaming with peer 2 (stream MsgApp v2 reader)
2018-07-08 15:55:50.848212 I | rafthttp: started streaming with peer 2 (stream Message reader)
2018-07-08 15:55:50.848283 I | rafthttp: started streaming with peer 3 (writer)
I0708 15:55:51.755218 cmd/geth/accountcmd.go:189] Unlocked account 7cafa76acffadbeb7c6d5bfc7615323328dab40c
raft2018/07/08 15:55:52 INFO: 4 is starting a new election at term 1
raft2018/07/08 15:55:52 INFO: 4 became pre-candidate at term 1
raft2018/07/08 15:55:52 INFO: 4 received MsgPreVoteResp from 4 at term 1
raft2018/07/08 15:55:52 INFO: 4 [logterm: 1, index: 4] sent MsgPreVote req uest to 1 at term 1
raft2018/07/08 15:55:52 INFO: 4 [logterm: 1, index: 4] sent MsgPreVote request to 2 at term 1
raft2018/07/08 15:55:52 INFO: 4 [logterm: 1, index: 4] sent MsgPreVote request to 3 at term 1
2018-07-08 15:55:53.005201 I | rafthttp: peer 2 became active
2018-07-08 15:55:53.005256 I | rafthttp: peer 1 became active
2018-07-08 15:55:53.005303 I | rafthttp: peer 3 became active
2018-07-08 15:55:53.086817 E | rafthttp: failed to dial 1 on stream Message (peer 1 failed to find local node 4)
2018-07-08 15:55:53.086848 I | rafthttp: peer 1 became inactive
2018-07-08 15:55:53.089135 E | rafthttp: failed to dial 3 on stream MsgApp v2  (peer 3 failed to find local node 4)
2018-07-08 15:55:53.089153 I | rafthttp: peer 3 became inactive
2018-07-08 15:55:53.104596 E | rafthttp: failed to dial 2 on stream Message (peer 2 failed to find local node 4)
2018-07-08 15:55:53.104617 I | rafthttp: peer 2 became inactive
raft2018/07/08 15:55:54 INFO: 4 is starting a new election at term 1
raft2018/07/08 15:55:54 INFO: 4 became pre-candidate at term 1
raft2018/07/08 15:55:54 INFO: 4 received MsgPreVoteResp from 4 at term 1
raft2018/07/08 15:55:54 INFO: 4 [logterm: 1, index: 4] sent MsgPreVote request to 1 at term 1
raft2018/07/08 15:55:54 INFO: 4 [logterm: 1, index: 4] sent MsgPreVote request to 2 at term 1
raft2018/07/08 15:55:54 INFO: 4 [logterm: 1, index: 4] sent MsgPreVote   request    to 3 at term 1

Antworten (1)

Nachdem die Blockchain initialisiert wurde und über Block 1 hinausgegangen ist, müssen Sie den Anweisungen von raft.addPeer und admin.addPeer folgen, wie hier erklärt: https://github.com/jpmorganchase/quorum/blob/master/docs/raft.md #anfängliche-konfiguration-und-umsetzung-von-mitgliedschaftsänderungen