Random 'The operation has timed out' errors in JSON-RPC

1

I run Bitcoin Core QT and ASP.NET website on the same webserver. My website communicates with Bitcoin Core QT via JSON-RPC. There are hundreds of requests behind the scenes. Sometimes a request finishes with The operation has timed out exception. What is wrong with it? This unstable behavior is really annoys me.

My bitcoin.conf is:

rpcuser = XXXXXXXX
rpcpassword = XXXXXXXX
server=1
rpcallowip=xx.xx.xx.xx
rpcallowip=127.0.0.1
rpcport=xxxx
rpcthreads=1200

UPDATE: I use heavily edited https://github.com/GeorgeKimionis/BitcoinLib, which in its turn internally is based on HttpWebRequest. RpcRequestTimeoutInSeconds is set to 60 seconds. Is it not enough to get balance and account list?

Denis

Posted 2016-06-07T10:30:04.960

Reputation: 141

What kind of RPC calls are you issuing?Pieter Wuille 2016-06-07T10:53:20.750

@PieterWuille, I updated my question.Denis 2016-06-07T11:16:58.180

Answers

1

Some operation might take longer then your RPC clients timeout is set to. This could be either due to system workload or due to loading bigger sets of data over RPC (example: a wallet with 100'000 wallet transactions).

Try to debug which commands take long/longer and consider checking your RPC clients http timeout.

Jonas Schnelli

Posted 2016-06-07T10:30:04.960

Reputation: 5 465

As I see timeout can occur literally in any RPC call. More often in 'ListAccounts', then in 'GetAccountAddress', sometimes even in 'Move' and 'SendRawTransaction'.Denis 2016-06-07T11:20:04.680