Electrum Server Speed Test [combined summary]



Individual post summaries: Click here to read the original discussion on the bitcoin-dev mailing list

Published on: 2015-07-23T18:26:41+00:00


Summary:

In this email exchange, Eric Voskuil seeks clarification on the Electrum Server Speed Test. He wants to know if the time taken to process into the index includes transport and/or block validation by bitcoind or if it is exclusively the time taken by Electrum Server to index a validated block. ThomasV explains that validation in bitcoind occurs before the time on the wall for electrum-server.The conversation revolves around the performance of the Electrum server software. It is mentioned that the server requires a fully indexed Bitcoin Core daemon running and produces sizable external indexes to allow SPV clients to quickly retrieve their history. The logs from the electrum-server console show that it takes approximately 3.7 minutes per megabyte of block to process into the index on a modest-high end dedicated server. Based on the current inter-block time of 9.8 minutes, an electrum-server instance running on such a server can support up to 2.64 MB block sizes before permanently falling behind the chain.There is a debate about whether this data should be used to limit the block size or improve Electrum Server's database performance. One participant suggests focusing on performance improvements rather than limiting the block size. Slurms MacKenzie provides data points indicating the processing time for an electrum-server instance running on a modest-high end dedicated server. This information suggests that improving Electrum Server's database performance may be necessary instead of holding back Bitcoin.The Electrum server software has known performance issues, including loading data one block at a time and being single-threaded on transactions within the block. To address these concerns, an alternative implementation of the Electrum server has been created. It uses mongodb as a key-value store and bitcoinj for block and transaction parsing. This implementation is heavily multithreaded and interacts with all tested clients. The recent blocks imported and their import times are available in a pastebin link, showing the usage of 347G of mongodb storage and an 8-core Intel(R) Xeon(R) CPU E5430 @ 2.66GHz for processing.The alternative implementation aims to improve the performance and efficiency of the Electrum server. It tackles the loading issues by using mongodb as a key-value store and bitcoinj for parsing blocks and transactions. In contrast, the original Electrum server requires a fully indexed Bitcoin Core daemon and produces sizable external indexes for SPV clients to retrieve their history quickly. The logs from the electrum-server console indicate that it takes approximately 3.7 minutes per megabyte of block to process into the index. An instance running on a modest-high end dedicated server can handle up to 2.64 MB block sizes before permanently falling behind the chain. These findings provide insight into the resources required for operating an Electrum server.Overall, this article presents a quantitative analysis of the Electrum server software's performance under load. It highlights the reliance on distributed servers hosted by volunteers and the need for a fully indexed Bitcoin Core daemon. The data presented demonstrates the time taken to process blocks into the index, the potential block size limits, and the file sizes generated during the operation of an Electrum server.


Updated on: 2023-08-01T14:34:15.543142+00:00