• About
  • FAQ
  • Earn Bitcoin while Surfing the net
  • Buy & Sell Crypto on Paxful
Newsletter
Approx Foundation
  • Home
    • Home – Layout 1
  • Bitcoin
  • Ethereum
  • Regulation
  • Market
  • Blockchain
  • Business
  • Guide
  • Contact Us
No Result
View All Result
  • Home
    • Home – Layout 1
  • Bitcoin
  • Ethereum
  • Regulation
  • Market
  • Blockchain
  • Business
  • Guide
  • Contact Us
No Result
View All Result
Approx Foundation
No Result
View All Result
Home Bitcoin

Why Are Electrs Address Balance Queries Slow (~900ms) on My Dockerized Bitcoin Full Node?

Moussa by Moussa
May 24, 2025
in Bitcoin
0
189
SHARES
1.5k
VIEWS
Share on FacebookShare on Twitter


I’m running a Bitcoin Core full node (bitcoind) and using romanz/electrs (via Docker) to provide Electrum server functionality for querying address balances and related wallet info. However, I’m experiencing unexpectedly high latency: querying the balance for a random address consistently takes around 600-900 ms via btc-rpc-explorer RPC interface. For addresses with an enormous number of transactions, the query can take some seconds instead of ms

Related articles

VanEck Highlights BNB Chain Usage To Differentiate VBNB ETF

Solana ETFs Record $925K In Daily Inflows As New Month Opens

September 3, 2026
PeaqOS and World ID Bring ZK Proofs to Autonomous Robots

World Adds Post-Quantum Security to New ZK Proving Toolkit

September 3, 2026

This is the docker compose yml file:

services:
  bitcoin_service:
    build:
      context: .
      dockerfile: Bitcoin.Dockerfile
      args:
        BITCOIN_VERSION: ${BTC_VERSION}
    image: bitcoin_full_node
    ports:
      - 8333:8333
      - 8332:8332
    volumes:
      - bitcoin_volume:/home/btc-user/.bitcoin
    networks:
      network:
        ipv4_address: 192.168.1.219
    healthcheck:
      test: [
        "CMD",
        "bitcoin-cli",
        "-rpccookiefile=/home/btc-user/.bitcoin/btc.cookie",
        "-rpcport=8332",
        "-rpcconnect=192.168.1.219",
        "getblockchaininfo"
      ]
      interval: 40s
      timeout: 60s
      retries: 45

  electrs:
    image: electrs:latest
    build:
      context: ./electrs/.
    container_name: electrs
    restart: always
    ports:
      - "50001:50001"    # Electrum TCP port exposed on host and container
    environment:
      - ELECTRS_NETWORK=bitcoin
      - ELECTRS_DAEMON_RPC_ADDR=192.168.1.219:8332
      - ELECTRS_DAEMON_P2P_ADDR=192.168.1.219:8333
      - ELECTRS_ELECTRUM_RPC_ADDR=192.168.1.223:50001
      - ELECTRS_LOG_FILTERS=INFO
      - ELECTRS_DB_DIR=/home/electrs/db
      - ELECTRS_VERBOSE_RPC_LOGS=true
      - ELECTRS_IGNORE_MEMPOOL=true
      - ELECTRS_TIMESTAMP_CACHE_CAPACITY=1000000  # Higher cache for faster lookups
      - ELECTRS_INDEX_LOOKUP_LIMIT=10000
      - ELECTRS_COOKIE_FILE=/home/btc-user/.bitcoin/btc.cookie
      - ELECTRS_THREADS=4
      - ELECTRS_DB_CACHE_SIZE=4096
    volumes:
      - electrs_db:/home/electrs/db
      - bitcoin_volume:/home/btc-user/.bitcoin:ro    # Mount same bitcoin data volume (read-only)
    networks:
      network:
        ipv4_address: 192.168.1.223 # new IP in the same subnet
    healthcheck:
      test: ["CMD-SHELL", "timeout 5 bash -c 'echo > /dev/tcp/192.168.1.223/50001'"]
      interval: 40s
      timeout: 60s
      retries: 45
    depends_on:
      bitcoin_service:
        condition: service_healthy

My Setup:

Bitcoin Core runs as a full node with default (non-pruned) settings.
Electrs runs in Docker with the following environment:
ELECTRS_NETWORK=bitcoin
ELECTRS_DAEMON_RPC_ADDR=192.168.1.219:8332
ELECTRS_DAEMON_P2P_ADDR=192.168.1.219:8333
ELECTRS_ELECTRUM_RPC_ADDR=192.168.1.223:50001
ELECTRS_DB_DIR=/home/electrs/db
ELECTRS_TIMESTAMP_CACHE_CAPACITY=1000000
ELECTRS_INDEX_LOOKUP_LIMIT=10000
ELECTRS_THREADS=4
ELECTRS_DB_CACHE_SIZE=4096
Volumes: bitcoin data (read-only) and electrs DB (persistent)
Docker container has 4 threads and 4GB cache configured

Electrs and bitcoind are on the same local network.
Problem:
Despite this setup, querying a single, random address balance via Electrs takes about 900ms. This seems slow compared to other Electrum servers and my expectations for local, SSD-backed infrastructure.

Hardware Specs:

  • CPU: AMD Ryzen 5 5600 3.5 GHz 6-Core Processor
  • RAM: 16 GB (2 x 8GB) DDR4-3200
  • Storage: Western Digital Blue SN580 2TB NVMe M.2 SSD (PCIe 4.0 x4)
  • Motherboard: Gigabyte A520M K V2 Micro ATX AM4
  • Network: 1GPS Download speed

Questions:

  • Is this latency typical for Electrs on a Dockerized full node?
  • Are there further optimizations I can make in my Docker or Electrs
    configuration to reduce balance query times?
  • Is there any known bottleneck, either in RocksDB, disk I/O, or Docker networking, that
    might cause this?
  • What are the typical response times others see for
    similar setups?

Any insights or tuning suggestions from the community
would be greatly appreciated!

Thank you!



Source link

Share76Tweet47

Related Posts

VanEck Highlights BNB Chain Usage To Differentiate VBNB ETF

Solana ETFs Record $925K In Daily Inflows As New Month Opens

by Moussa
September 3, 2026
0

U.S. spot Solana ETFs recorded $925,000 in net daily inflows as September trading opened, giving SOL markets a fresh regulated-demand...

PeaqOS and World ID Bring ZK Proofs to Autonomous Robots

World Adds Post-Quantum Security to New ZK Proving Toolkit

by Moussa
September 3, 2026
0

Key TakeawaysNIST guidance urges early adoption to prevent quantum computers from breaking current identity proofs.Hash-based post-quantum models mitigate forgery risks...

I have a transaction id i dont have previous emails or phone numbers a bitcoin amount was credited

by Moussa
September 3, 2026
0

I have a transaction id a bitcoin amount was credited or sent me I dont ha e .y previous emails...

Crypto Market News Today, December 17: Fidelity Says Bitcoin Is the Gold Standard as They Scoop The Bottom Price and Hal Finney–Satoshi Talk Returns

Bitcoin News Today: ETF Era Faces a Test From China’s Credit Slowdown

by Moussa
September 3, 2026
0

In Bitcoin news today, China’s credit impulse, a gauge of how quickly new borrowing is expanding relative to the size...

Sui’s USDsui Model Turns Stablecoin Yield Into Ecosystem Buybacks

Sui TVL Holds $1.2B As DeFi Activity Stays In View

by Moussa
September 3, 2026
0

Trusted Editorial content, reviewed by leading industry experts and seasoned editors. Ad Disclosure Sui Network’s total value locked is holding...

Load More

youssufi.com

sephina.com

[vc_row full_width="stretch_row" parallax="content-moving" vc_row_background="" background_repeat="no-repeat" background_position="center center" footer_scheme="dark" css=".vc_custom_1517813231908{padding-top: 60px !important;padding-bottom: 30px !important;background-color: #191818 !important;background-position: center;background-repeat: no-repeat !important;background-size: cover !important;}" footer_widget_title_color="#fcbf46" footer_button_bg="#fcb11e"][vc_column width="1/4"]

We bring you the latest in Crypto News

[/vc_column][vc_column width="1/4"][vc_wp_categories]
[/vc_column][vc_column width="1/4"][vc_wp_tagcloud taxonomy="post_tag"][/vc_column][vc_column width="1/4"]

Newsletter

[vc_raw_html]JTNDcCUzRSUzQ2RpdiUyMGNsYXNzJTNEJTIydG5wJTIwdG5wLXN1YnNjcmlwdGlvbiUyMiUzRSUwQSUzQ2Zvcm0lMjBtZXRob2QlM0QlMjJwb3N0JTIyJTIwYWN0aW9uJTNEJTIyaHR0cHMlM0ElMkYlMkZhcHByb3gub3JnJTJGJTNGbmElM0RzJTIyJTNFJTBBJTBBJTNDaW5wdXQlMjB0eXBlJTNEJTIyaGlkZGVuJTIyJTIwbmFtZSUzRCUyMm5sYW5nJTIyJTIwdmFsdWUlM0QlMjIlMjIlM0UlM0NkaXYlMjBjbGFzcyUzRCUyMnRucC1maWVsZCUyMHRucC1maWVsZC1maXJzdG5hbWUlMjIlM0UlM0NsYWJlbCUyMGZvciUzRCUyMnRucC0xJTIyJTNFRmlyc3QlMjBuYW1lJTIwb3IlMjBmdWxsJTIwbmFtZSUzQyUyRmxhYmVsJTNFJTBBJTNDaW5wdXQlMjBjbGFzcyUzRCUyMnRucC1uYW1lJTIyJTIwdHlwZSUzRCUyMnRleHQlMjIlMjBuYW1lJTNEJTIybm4lMjIlMjBpZCUzRCUyMnRucC0xJTIyJTIwdmFsdWUlM0QlMjIlMjIlM0UlM0MlMkZkaXYlM0UlMEElM0NkaXYlMjBjbGFzcyUzRCUyMnRucC1maWVsZCUyMHRucC1maWVsZC1lbWFpbCUyMiUzRSUzQ2xhYmVsJTIwZm9yJTNEJTIydG5wLTIlMjIlM0VFbWFpbCUzQyUyRmxhYmVsJTNFJTBBJTNDaW5wdXQlMjBjbGFzcyUzRCUyMnRucC1lbWFpbCUyMiUyMHR5cGUlM0QlMjJlbWFpbCUyMiUyMG5hbWUlM0QlMjJuZSUyMiUyMGlkJTNEJTIydG5wLTIlMjIlMjB2YWx1ZSUzRCUyMiUyMiUyMHJlcXVpcmVkJTNFJTNDJTJGZGl2JTNFJTBBJTNDZGl2JTIwY2xhc3MlM0QlMjJ0bnAtZmllbGQlMjB0bnAtcHJpdmFjeS1maWVsZCUyMiUzRSUzQ2xhYmVsJTNFJTNDaW5wdXQlMjB0eXBlJTNEJTIyY2hlY2tib3glMjIlMjBuYW1lJTNEJTIybnklMjIlMjByZXF1aXJlZCUyMGNsYXNzJTNEJTIydG5wLXByaXZhY3klMjIlM0UlQzIlQTBCeSUyMGNvbnRpbnVpbmclMkMlMjB5b3UlMjBhY2NlcHQlMjB0aGUlMjBwcml2YWN5JTIwcG9saWN5JTNDJTJGbGFiZWwlM0UlM0MlMkZkaXYlM0UlM0NkaXYlMjBjbGFzcyUzRCUyMnRucC1maWVsZCUyMHRucC1maWVsZC1idXR0b24lMjIlM0UlM0NpbnB1dCUyMGNsYXNzJTNEJTIydG5wLXN1Ym1pdCUyMiUyMHR5cGUlM0QlMjJzdWJtaXQlMjIlMjB2YWx1ZSUzRCUyMlN1YnNjcmliZSUyMiUyMCUzRSUwQSUzQyUyRmRpdiUzRSUwQSUzQyUyRmZvcm0lM0UlMEElM0MlMkZkaXYlM0UlM0NiciUyRiUzRSUzQyUyRnAlM0U=[/vc_raw_html][/vc_column][/vc_row]
No Result
View All Result
  • Contact Us
  • Homepages
  • Business
  • Guide

© 2024 APPROX FOUNDATION - The Crypto Currency News