I have a question about rpc cmd 'getpeerinfo'

+3 votes
Hi

I have a question about rpc cmd 'getpeerinfo'

I composed blockchain network from 3 nodes A, B, C

A is mining node and other 2 nodes B, C connect to A.
like B --> A <-- C.

then, i execute cmd 'getpeerinfo' on A node, it show other node B, C info.

but when i execute cmd it on B or C, it shows only A info.

is that right? i think because all 3 nodes consisted network, so all cmd response has to same on every node like response of A.

can you explain what is right?
asked Nov 21, 2019 by 0080khs

1 Answer

+1 vote

The getpeerinfo command shows with other node this node is actually connected to. In an ideal situation this will be all other nodes on the network, since nodes automatically tell each other about their connections. But if there is a firewall or NAT router or other network barrier in the way, B and C cannot connect to each other directly.

answered Nov 21, 2019 by MultiChain
...