1

This is an odd one. I am running bitcoind 0.9.1 on Ubuntu 14.04 and have this behaviour:

Doesn't work:

$ bitcoind getinfo
error: couldn't connect to server

(timeout after 30s)

Works fine:

$ curl --data-binary '{"jsonrpc": "1.0", "id":"curltest", "method": "getinfo", "params": [] }' -H 'content-type: text/plain;' http://user:pass@localhost:8332/
{"result":{"version":90100,"protocolversion":70002,"walletversion":60000,"balance":0.00000000,"blocks":311140,"timeoffset":0,"connections":13,"proxy":"","difficulty":17336316978.50783157,"testnet":false,"keypoololdest":1402698503,"keypoolsize":102,"paytxfee":0.00000000,"errors":""},"error":null,"id":"curltest"}

Question:

Why does the bitcoind CLI not connect to the server, but curl does?

Driving me nuts. Something buggy in 0.9.1's JSON-RPC client implementation?

3
  • I ended up setting up a new Bitcoin node at a different provider. With the same system config and bitcoin.conf there "bitcoind getinfo" works fine. I assume it has to do with firewall or loopback interface settings at the old provider.
    – meinhard
    Commented Jul 27, 2014 at 22:33
  • I turn off firewall and still get the same, that's not the answear in my opinion :/ Commented Dec 15, 2014 at 20:54
  • same problem when I start via /etc/rc.local (raspberry pi)
    – tobi
    Commented Mar 20, 2017 at 20:46

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.