Bitcoin Forum

Bitcoin => Bitcoin Technical Support => Topic started by: DeathAndTaxes on May 26, 2014, 04:38:03 PM



Title: What does "keypool reserve" & "keypool return" in the debug log indicate?
Post by: DeathAndTaxes on May 26, 2014, 04:38:03 PM
What does "keypool reserve" & "keypool return" in the debug log indicate?
Quote
2014-05-26 16:34:01 keypool reserve 9028
2014-05-26 16:34:01 keypool return 9028
2014-05-26 16:34:01 keypool reserve 9028
2014-05-26 16:34:01 keypool return 9028


Title: Re: What does "keypool reserve" & "keypool return" in the debug log indicate?
Post by: telepatheic on May 26, 2014, 08:53:09 PM
They indicate that a key has been temporarily removed from the pool and then returned to the pool while an operation involving it is taking place. See the wallet.cpp (https://github.com/bitcoin/bitcoin/blob/master/src/wallet.cpp) file.

These functions allow multi-threading (two threads can't be using the same key at the same time).


Title: Re: What does "keypool reserve" & "keypool return" in the debug log indicate?
Post by: DeathAndTaxes on May 26, 2014, 08:55:07 PM
Thanks and that opens up even more questions.  Not sure why a key would be removed from the keypool and returned.  Will need to dig into the code.