0

I just trying to build a private network with two nodes(two different physical hosts) and all of two nodes are validator nodes, but I just stuck in the "Joining SCP" state when I run stellar-core run --conf my-own-network.cfg, the output I got from stellar-core http-command 'info' --conf my-own-network.cfg is like below:

2019-08-24T17:51:57.461 <startup> [default INFO] Using QUORUM_SET: {
   "t" : 2,
   "v" : [ "self", "node2" ]
}

Content-Length: 1012
Content-Type: application/json

2019-08-24T17:51:57.463 GAWSD [default INFO] {
   "info" : {
      "build" : "v11.2.0-16-g22d03b8c",
      "history_failure_rate" : "0",
      "ledger" : {
         "age" : 75686,
         "baseFee" : 100,
         "baseReserve" : 100000000,
         "closeTime" : 1566564631,
         "hash" : "e5f0a34efb01a519f767b54b68fc4bb486497541239c1157e58f596d4f615969",
         "maxTxSetSize" : 100,
         "num" : 613418,
         "version" : 0
      },
      "network" : "Test Private Network ; Jul 2019",
      "peers" : {
         "authenticated_count" : 3,
         "pending_count" : 0
      },
      "protocol_version" : 11,
      "quorum" : {
         "node" : "self",
         "qset" : {
            "agree" : 1,
            "delayed" : 0,
            "disagree" : 0,
            "fail_at" : 0,
            "hash" : "1022b7",
            "ledger" : 613418,
            "missing" : 0,
            "phase" : "EXTERNALIZE",
            "validated" : true
         }
      },
      "startedOn" : "2019-08-24T09:49:38Z",
      "state" : "Joining SCP"
   }
}

I checked the log files of stellar-core's output and didn't find "error" info but only found this:

2019-08-24T17:24:06.805 GBZCP [Overlay TRACE] TCPPeer::startRead to 10.0.8.27:11625 [TCPPeer.cpp:330]
2019-08-24T17:24:06.805 GBZCP [Overlay TRACE] TCPPeer::startRead calledback system:0 length:4 [TCPPeer.cpp:337]
2019-08-24T17:24:06.805 GBZCP [Overlay TRACE] Debiting peer node1 time:1us send:0 recv:4B query:0 [LoadManager.cpp:199]
2019-08-24T17:24:06.805 GBZCP [Overlay TRACE] Debiting peer node1 time:2us send:0 recv:308B query:0 [LoadManager.cpp:199]
2019-08-24T17:24:06.805 GBZCP [Overlay TRACE] (self) recv: SCP::NOMINATE from:node1 [Peer.cpp:504]
2019-08-24T17:24:06.805 GBZCP [Overlay TRACE] recvSCPMessage node: node1 [Peer.cpp:707]
2019-08-24T17:24:06.805 GBZCP [Herder DEBUG] recvSCPEnvelope from: node1 s:3 i:633364 a:Joining SCP
2019-08-24T17:24:06.805 GBZCP [Herder DEBUG] Ignoring SCPEnvelope outside of range: 633364( 619156,619269)
2019-08-24T17:24:06.805 GBZCP [Overlay TRACE] TCPPeer::startRead to 10.0.8.27:11625 [TCPPeer.cpp:330]
2019-08-24T17:24:07.012 GBZCP [Herder DEBUG] broadcast  s:3 i:619169
2019-08-24T17:24:07.012 GBZCP [Overlay TRACE] broadcast 189289 [Floodgate.cpp:88]
2019-08-24T17:24:07.015 GBZCP [Overlay TRACE] broadcast 189289 told 3 [Floodgate.cpp:114]
2019-08-24T17:24:07.451 GBZCP [Overlay TRACE] OverlayManagerImpl tick [OverlayManagerImpl.cpp:461]
2019-08-24T17:24:07.451 GBZCP [default DEBUG] Estimated clock loop idle: 86% (512/590)
2019-08-24T17:24:07.451 GBZCP [Database DEBUG] Estimated DB idle: 100% (query=140572ns, total=3001241924ns)
2019-08-24T17:24:07.451 GBZCP [Overlay DEBUG] Peer 10.0.8.27:11625 is preferred
2019-08-24T17:24:07.451 GBZCP [Overlay DEBUG] Peer 10.0.8.26:11625 is preferred
2019-08-24T17:24:09.015 GBZCP [Herder DEBUG] broadcast  s:3 i:619169
2019-08-24T17:24:09.015 GBZCP [Overlay TRACE] broadcast 189289 [Floodgate.cpp:88]
2019-08-24T17:24:09.016 GBZCP [Overlay TRACE] broadcast 189289 told 3 [Floodgate.cpp:114]
2019-08-24T17:24:10.402 GBZCP [Herder WARNING] Lost track of consensus
2019-08-24T17:24:10.403 GBZCP [Herder WARNING] Out of sync context: {
   "queue" : null,
   "scp" : {
      "619157" : {
         "ballotProtocol" : {
            "ballot" : "(4294967295,[ txH: 30e810, ct: 1566564061, upgrades: [ ] ])",
            "heard" : false,
            "phase" : "EXTERNALIZE",
            "state" : "i: 619157 | EXTERNALIZE | b: (4294967295,[ txH: 30e810, ct: 1566564061, upgrades: [ ] ]) | p: (4294967295,[ txH: 30e810, ct: 1566564061, upgrades: [ ] ]) | p': (<null_ballot>) | h: (1,[ txH: 30e810, ct: 1566564061, upgrades: [ ] ]) | c: (1,[ txH: 30e810, ct: 1566564061, upgrades: [ ] ]) | M: 1"
         },
         "nomination" : {
            "X" : [ "[ txH: 30e810, ct: 1566564061, upgrades: [ ] ]" ],
            "Y" : [ "[ txH: 30e810, ct: 1566564061, upgrades: [ ] ]" ],
            "roundnumber" : 0,
            "started" : false
         },
         "quorum_sets" : {
            "9831fc" : {
               "t" : 1,
               "v" : [ "self" ]
            }
         },
         "statements" : [
            [
               1566638615,
               "{ENV@self |  i: 619157 | NOMINATE | D: 9831fc | X: {'[ txH: 30e810, ct: 1566564061, upgrades: [ ] ]'} | Y: {'[ txH: 30e810, ct: 1566564061, upgrades: [ ] ]'} }",
               true
            ],
            [
               1566638615,
               "{ENV@self |  i: 619157 | EXTERNALIZE | c: (1,[ txH: 30e810, ct: 1566564061, upgrades: [ ] ]) | h.n: 1 | (lastD): 9831fc }",
               true
            ]
         ],
         "validated" : true
      },
      "619158" : {
         "ballotProtocol" : {
            "ballot" : "(4294967295,[ txH: b7f615, ct: 1566564066, upgrades: [ ] ])",
            "heard" : false,
            "phase" : "EXTERNALIZE",
            "state" : "i: 619158 | EXTERNALIZE | b: (4294967295,[ txH: b7f615, ct: 1566564066, upgrades: [ ] ]) | p: (4294967295,[ txH: b7f615, ct: 1566564066, upgrades: [ ] ]) | p': (<null_ballot>) | h: (1,[ txH: b7f615, ct: 1566564066, upgrades: [ ] ]) | c: (1,[ txH: b7f615, ct: 1566564066, upgrades: [ ] ]) | M: 1"
         },
         "nomination" : {
            "X" : [ "[ txH: b7f615, ct: 1566564066, upgrades: [ ] ]" ],
            "Y" : [ "[ txH: b7f615, ct: 1566564066, upgrades: [ ] ]" ],
            "roundnumber" : 0,
            "started" : false
         },
         "quorum_sets" : {
            "9831fc" : {
               "t" : 1,
               "v" : [ "self" ]
            }
         },
         "statements" : [
            [
               1566638615,
               "{ENV@self |  i: 619158 | NOMINATE | D: 9831fc | X: {'[ txH: b7f615, ct: 1566564066, upgrades: [ ] ]'} | Y: {'[ txH: b7f615, ct: 1566564066, upgrades: [ ] ]'} }",
               true
            ],
            [
               1566638615,
               "{ENV@self |  i: 619158 | EXTERNALIZE | c: (1,[ txH: b7f615, ct: 1566564066, upgrades: [ ] ]) | h.n: 1 | (lastD): 9831fc }",
               true
            ]
         ],
         "validated" : true
      },
      "619159" : {
         "ballotProtocol" : {
            "ballot" : "(4294967295,[ txH: 34ec67, ct: 1566564071, upgrades: [ ] ])",
            "heard" : false,
            "phase" : "EXTERNALIZE",
            "state" : "i: 619159 | EXTERNALIZE | b: (4294967295,[ txH: 34ec67, ct: 1566564071, upgrades: [ ] ]) | p: (4294967295,[ txH: 34ec67, ct: 1566564071, upgrades: [ ] ]) | p': (<null_ballot>) | h: (1,[ txH: 34ec67, ct: 1566564071, upgrades: [ ] ]) | c: (1,[ txH: 34ec67, ct: 1566564071, upgrades: [ ] ]) | M: 1"
         },
         "nomination" : {
            "X" : [ "[ txH: 34ec67, ct: 1566564071, upgrades: [ ] ]" ],
            "Y" : [ "[ txH: 34ec67, ct: 1566564071, upgrades: [ ] ]" ],
            "roundnumber" : 0,
            "started" : false
         },
         "quorum_sets" : {
            "9831fc" : {
               "t" : 1,
               "v" : [ "self" ]
            }
         },
         "statements" : [
            [
               1566638615,
               "{ENV@self |  i: 619159 | NOMINATE | D: 9831fc | X: {'[ txH: 34ec67, ct: 1566564071, upgrades: [ ] ]'} | Y: {'[ txH: 34ec67, ct: 1566564071, upgrades: [ ] ]'} }",
               true
            ],
            [
               1566638615,
               "{ENV@self |  i: 619159 | EXTERNALIZE | c: (1,[ txH: 34ec67, ct: 1566564071, upgrades: [ ] ]) | h.n: 1 | (lastD): 9831fc }",
               true
            ]
         ],
         "validated" : true
      },
...

my configure file on one of two nodes is like below:

HTTP_PORT=11626

PUBLIC_HTTP_PORT=true

RUN_STANDALONE=false

NETWORK_PASSPHRASE="Test Private Network ; Jul 2019"

NODE_SEED="SC2Y****GTYE self"


NODE_IS_VALIDATOR=true

KNOWN_PEERS=["ip_1:11625","ip_2:11625","ip_4:11625"]

NODE_NAMES=[
    "GASA****R4C6 node1",
    "GDPO****TV3V node2",
    "GAWS****NK2T node4"
]

PREFERRED_PEERS=[
    "ip_1:11625",
    "ip_2:11625",
    "ip_4:11625"
]

DATABASE="postgresql://dbname=stellar_node4_db host=ip_4 user=stellar password=***"

PEER_PORT=11625

COMMANDS=["ll?level=trace"]

FAILURE_SAFETY=0
UNSAFE_QUORUM=true

[QUORUM_SET]
THRESHOLD_PERCENT=51

VALIDATORS=["$self"]

[HISTORY.vs]
get="cp /tmp/stellar-core/history/vs/{0} {1}"
put="cp {0} /tmp/stellar-core/history/vs/{1}"
mkdir="mkdir -p /tmp/stellar-core/history/vs/{0}"

P.S. if I want to try to use nginx to balance the load on horizon server by "install horizon on every stellar-core node and use nginx to connect them", when I visit ip:8000/accounts/ on different node, should I get completely same info including the sequence and last_modified_ledger? like below:

"id": "GDAM****C3SG",
  "account_id": "GDAM****C3SG",
  "sequence": "2351228306587648",
  "subentry_count": 0,
  "last_modified_ledger": 547438,
  "thresholds": {
    "low_threshold": 0,
    "med_threshold": 0,
    "high_threshold": 0
  },
1

If you’re trying to build a 2 nodes setup it’s unlikely to work: the only safe way to run such a setup would be to have nodes that depend on each other (ie neither can go down) as otherwise you would allow each node to diverge from each other.

For testing purpose you should use 1 node or more generally2*f+1 where f is the number of failures you want to tolerate.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.