Skip to content

Instantly share code, notes, and snippets.

@wakiyamap
Created November 8, 2017 12:52
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save wakiyamap/c846c3c26284a18eea903babf6f57086 to your computer and use it in GitHub Desktop.
Save wakiyamap/c846c3c26284a18eea903babf6f57086 to your computer and use it in GitHub Desktop.
DB_DIRECTORY = /var/electrumx
USERNAME = electrumx
ELECTRUMX = /usr/local/bin/electrumx_server.py
#Bitcoin Node RPC Credentials
DAEMON_URL = http://user:pass@IPaddress:port/
#port is optional, defaults to COIN RPC default
#
#REQUIRED FOR PUBLIC VISIBILITY
#
HOST = 0.0.0.0
#listen on interface, (0.0.0.0 is any, localhostは不可)
TCP_PORT = 50001
SSL_PORT = 50002
#Requires
SSL_CERTFILE = /etc/server.crt
SSL_KEYFILE = /etc/server.key
#
#OPTIONAL VISIBILITY
#
BANNER_FILE = /etc/electrumx.banner
DONATION_ADDRESS = MEmGfo7cgRNM3kAHqVkcbesWVrBo7DoEbU
IRC = yes
IRC_NICK = nick
REPORT_HOST = URL
REPORT_TCP_PORT = 50001
REPORT_SSL_PORT = 50002
RPC_PORT = 8000
#REPORT_HOST_TOR = mwd2hbro2svhr4l6.onion
#REPORT_TCP_PORT_TOR = 51001
#REPORT_SSL_PORT_TOR = 51002
LOG_SESSIONS = 0
#
#MISC
#
COIN = Monacoin
NET = mainnet
#DB_ENGINE = leveldb
#leveldb, rocksdb, lmdb (You'll need to install appropriate python packages)
#REORG_LIMIT = 200
#maximum number of blocks to be able to handle in a chain
#reorganisation. ElectrumX retains some fairly compact
#undo information for this many blocks in levelDB.
#ANON_LOGS =
#Set to anything non-empty to remove IP addresses from logs.
#These following environment variables are to help limit server
#resource consumption and to prevent simple DoS. Address subscriptions
#in ElectrumX are very cheap - they consume about 100 bytes of memory
#each and are processed efficiently. I feel the defaults are low and
#encourage you to raise them.
MAX_SUBS = 250000
#Maximum number of address subscriptions across all sessions
MAX_SESSION_SUBS = 50000
#Maximum number of address subscriptions permitted to a single session.
MAX_SEND = 5000000
BANDWIDTH_LIMIT = 100000000
SESSION_TIMEOUT = 1800
MAX_SESSIONS = 2000
#If synchronizing from the Genesis block your performance might change
#by tweaking the following cache variables. Cache size is only checked
#roughly every minute, so the caches can grow beyond the specified
#size. Also the Python process is often quite a bit fatter than the
#combined cache size, because of Python overhead and also because
#leveldb consumes a lot of memory during UTXO flushing. So I recommend
#you set the sum of these to nothing over half your available physical
#RAM:
#HIST_MB = 300
#amount of history cache, in MB, to retain before flushing to
#disk. Default is 300; probably no benefit being much larger
#as history is append-only and not searched.
#UTXO_MB = 1000
#amount of UTXO and history cache, in MB, to retain before
#flushing to disk. Default is 1000. This may be too large
#for small boxes or too small for machines with lots of RAM.
#Larger caches generally perform better as there is
#significant searching of the UTXO cache during indexing.
#However, I don't see much benefit in my tests pushing this
#too high, and in fact performance begins to fall. My
#machine has 24GB RAM; the slow down is probably because of
#leveldb caching and Python GC effects. However this may be
#very dependent on hardware and you may have different
#results.
######
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment