How do I make bitcoind listen on 0.0.0.0:8332? [closed]
-
14-11-2019 - |
Question
I'm running bitcoind
on one machine and would like to control it from another (using python and the JSON RPC interface).
~/.bitcoin/bitcoin.config
on the bitcoind host (192.168.2.4):
rpcuser=xxx
rpcpassword=xxx
gen=1
rcpallowip=127.0.0.1
rcpallowip=192.168.2.6 # This is the other machine
paytxfee=0.01
Now, I start bitcoind -daemon
, but my python program fails with
IOError: [Errno socket error] [Errno 111] Connection refused
On the bitcoind host, ps -nlp shows bitcoind listening on 127.0.0.1:8332, and not 0.0.0.0:8332 (which is what I would have expected). Wireshark shows a response of RST,ACK to the TCP connection attempt, which appears to be logical.
What am I missing?
Solution
Try rpcallowip, instead of rcpallowip :)
OTHER TIPS
Just had same problem.
Solved by setting
rpcallowip=*
in bitcoin.conf
have a look at https://en.bitcoin.it/wiki/Enabling_SSL_on_original_client_daemon
Are you certain bitcoind
is not listening on 0.0.0.0 as well? On a fresh install here it's listening on 0.0.0.0:8333
$ sudo netstat --ip -lpa|grep bitcoin
tcp 0 0 localhost:8332 *:* LISTEN 2909/bitcoind
tcp 0 0 *:8333 *:* LISTEN 2909/bitcoind
Also, what does nmap
from 192.168.2.6 say?
Please use the following settings.
As for http/https rpc request.
rpcport=8332 #8331 will be nice.
As for process.
port=8332
Remind:
1st: These two setting should not be the same.
2nd: You should restart the bitcoind process since you change the conf file.
Just Update ur bitcoin.conf file
- use rpcport = 8332 rpcconnect = 127.0.0.1
rpcallowip=*
It is not a good idea because it open for every one . So if you want to specific IP and Port then edit your coin.conf file
rpcallowip = yourip; // (Default = 127.0.0.1
rpcport = your port; // (Default =8332)
Solved by setting
rpcallowip=0.0.0.0/0
in bitcoin.conf