Author

Topic: connect two bitcoin core nodes on different machine, using regtest (Read 191 times)

jr. member
Activity: 113
Merit: 5
You have two programs that are trying to use the same port. You can't do that. One of your bitcoind instances will need to use a different rpcport (-rpcport) and normal p2p port (-port)

Thank you. The setup of bitcoin core regtest network  on two nodes on two  different machine, is working now. Have to add rpcport entry. The machine A bitcoin.conf

`regtest=1
server=1
port=18332
rpcport = 18333
rpcuser=bitcoinrpc
rpcpassword=password
rpcallowip=0.0.0.0/0`

and machine B bitcoin.conf
`regtest = 1
server = 1
port=18443
rpcport = 18444
connect = 11.0.0.110:18332
rpcuser=bitcoinrpc
rpcpassword=password`
jr. member
Activity: 113
Merit: 5

You have two programs that are trying to use the same port. You can't do that. One of your bitcoind instances will need to use a different rpcport (-rpcport) and normal p2p port (-port)

The bitcoin.conf was setup already.  As below:

regtest = 1
server = 1
port=18443
connect = 12.0.0.111:18332
rpcuser=bitcoinrpc
rpcpassword=password

The port is set to 18443. Why is that bitcoind trying to bind to port 18332 ?

"2018-03-15 01:31:32 Binding RPC on address ::1 port 18332 failed.
2018-03-15 01:31:32 Binding RPC on address 127.0.0.1 port 18332 failed."
staff
Activity: 3458
Merit: 6793
Just writing some code
The bitcoind is still trying to connect to
`2018-03-15 01:31:32 Binding RPC on address ::1 port 18332 failed.
2018-03-15 01:31:32 Binding RPC on address 127.0.0.1 port 18332 failed.`

Anyone knows why ?
You have two programs that are trying to use the same port. You can't do that. One of your bitcoind instances will need to use a different rpcport (-rpcport) and normal p2p port (-port)
jr. member
Activity: 113
Merit: 5
I can connect regtest on two nodes on the same machine.

However, i cannot connect regtest on two nodes on different machine.

I use bitcoin v0.15.1 , setup the bitcoind to connect to remote host in bitcoin.conf 
`connect = 11.0.0.110:18332`
as well as command line
 `-connect=11.0.0.110:18332`

The bitcoind is still trying to connect to
`2018-03-15 01:31:32 Binding RPC on address ::1 port 18332 failed.
2018-03-15 01:31:32 Binding RPC on address 127.0.0.1 port 18332 failed.`

Anyone knows why ?
jr. member
Activity: 113
Merit: 5
I have setup one bitcoin core node on machine A, and one bitcoin core node on machine B. The two machines can ping each other.

On machine A (10.0.0.11):
bitcoind -regtest -port=18332 -rpcport=8331
Bitcoin server starting

On machine B (11.0.0.12):
bitcoind -regtest -port=18332 -rpcport=8331 -connect=10.0.0.11:18332
Bitcoin server starting

Then on machine B, i run the command:
"bitcoin-cli -regtest  -port=18332 -rpcport=8331 getconnectioncount"

It returns 0. Is there any mistakes in my steps ?
Jump to: