Connect to bitcoind from a different device within the same local network

0

1

I have a full node running on a Linux device (A) with static IP 192.168.1.203 and I want to run bitcoin-cli commands or even eclair instances from a different device (B) within the same local network.

Device (A) has bitcoin.conf configured to accept RPC calls with this basic bitcoin.conf

server=1
daemon=1
txindex=1
rpcuser=<user_name>
rpcpassword=<password>

Actually I have an eclair running successfully on Device (A) and default RPC ports connect well. No typos on user_name and passwords.

When running the following command in device (B):

bitcoin-cli -rpcconnect=192.168.1.203 -rpcport=8332 -rpcuser=<user_name> -rpcpassword=<password> -getinfo


error: Could not connect to the server 192.168.1.203:8332 (error code 1 - "EOF reached")
Make sure the bitcoind server is running and that you are connecting to the correct RPC port.

Any ideas what can be wrong?

RaulRider

Posted 2019-02-05T23:01:24.423

Reputation: 1

Answers

2

If you're going to just use within the network and not outside of the LAN then as mention below, use rpcallowip=0.0.0.0/0 will work and also don't use rpcconnect as it may cause issues. If your planning future to use that option outside of the LAN (aka WAN) then there will be security issues so make sure to not use it outside of the LAN unless you can configure it correctly to not allow accept all ip.

zhiyan114

Posted 2019-02-05T23:01:24.423

Reputation: 528

Futher more, according to https://github.com/bitcoin/bitcoin/blob/master/share/examples/bitcoin.conf subnet address is also supported. Therefore you can use something like rpcallowip=192.168.0.0/24 to allow any devices with IPs from 192.168.0.1 to 192.168.0.255

Louis Loudog Trottier 2019-11-04T03:36:08.487

0

add rpcallowip=192.168.1.203 to your bitcoin.conf and restart your daemon. or may rpcallowip=0.0.0.0/0 is your option.

kinjia

Posted 2019-02-05T23:01:24.423

Reputation: 31