The --help
for rpcbind
suggests that the default behavior is to bind to all interfaces. However, in Core 0.13.1, I noticed that if rpcbind is left out of the config, the RPC server is either only bound to the loopback interface or only bound to the IPv6 port.
Yes. It fails differently, depending on whether or not you've supplied rpcallowip
Fails silently, only binds to loopback interface.
server=1
rpcuser=something
rpcpassword=somethingelse
Error message in log, only binds to all interfaces for IPv6.
server=1
rpcuser=something
rpcpassword=somethingelse
rpcallowip=0.0.0.0/0
rpcallowip=::/0
Binding RPC on address 0.0.0.0 port 8332 failed.
reported in _debug.log_.0.13.1
Are you sure this is really the case?
That message:
Binding RPC on address 0.0.0.0 port 8332 failed. reported in debug.log.
Means that it can't bind on 0.0.0.0 - which usually means that the IPv6 any address works as 'catchall' for both incoming IPv4 and IPv6 connections. This is the case on some OSes, making it unnecessary to have two binds.
Have you tried connecting to the port?
BTW: the default behavior is, and always has been, to bind on all interfaces if -rpcallowip
is set. If not bind on localhost only [both given no explicit binds]. This is a security feature.
I've just faced the same problem. Maybe it's worth noting this behavior in bitcoind help?
Because although the behavior has always been such, the option is unambiguously described that it binds to all interfaces by default:
-rpcbind=<addr>
Bind to given address to listen for JSON-RPC connections. Use
[host]:port notation for IPv6. This option can be specified
multiple times (default: bind to all interfaces)
I had to google some more time to find out an answer.
Most helpful comment
I've just faced the same problem. Maybe it's worth noting this behavior in bitcoind help?
Because although the behavior has always been such, the option is unambiguously described that it binds to all interfaces by default:
I had to google some more time to find out an answer.