Closed savyp closed 5 years ago
Was it working for you before? What was your old config? Perhaps something was using port 8000 by chance. If IPv6 is not supported in your system your network isn't setup right as localhost should not resolve to ::1 in that case.
Having domain names in SERVICES looks wrong....
I'm not home now, so I can't provide the previous setup, however everything had been working fine with RPC settings for months, thru the various electrumX releases. After the electrumx may 9th update, using the setup above (and updating the other new environment variables), I couldn't see port 8000 advertised, as a result of 'sudo netstat -plnt' command.
VPS server is on Contabo. With bitcoind and electrumX I use only IPv4 protocol.
By the way, I had sent you an email a couple of days ago because of a severe issue with the blacklist. I'm still struggling and looking for advices and explantions... with no success so far. https://www.reddit.com/r/btc/comments/bmkbt9/electrumx_server_blacklist_btc/
Thanks for your attention
I have not received an email and nothing is in spam. I have nothing to do with the blacklist though.
I think your current settings are wrong for the reasons I gave, please read those. It would help to know what worked before.
my old working configuration with electrumx 1.11.0 and aiorpcX 0.17.0 (before upgrading to aiorpcX 0.18.0 today early morning and using the new env variables) was as follows (pls note I prefer to use a run script):
export COIN=BitcoinSegwit
export DB_DIRECTORY=/home/my-LINUX-username/.electrumx/electrumx-leveldb-database/
export DAEMON_URL='coordinates-to-my-BTC-node'
export ELECTRUMX=/usr/local/bin/electrumx_server
export USERNAME=my-LINUX-username
export NET=mainnet
export DB_ENGINE=leveldb
export HOST=
export TCP_PORT=50001
export SSL_PORT=50006
export SSL_CERTFILE=/home/my-LINUX-username/.electrumx/server.keys/server.crt
export SSL_KEYFILE=/home/my-LINUX-username/.electrumx/server.keys/server.key
export RPC_HOST=127.0.0.1
export DONATION_ADDRESS='my-wallet-address'
export BANNER_FILE=/home/my-LINUX-username/.electrumx/banner
export TOR_BANNER_FILE=/home/my-LINUX-username/.electrumx/banner-tor.txt
export ANON_LOGS=NONE
export MAX_SESSIONS=2000
export PEER_DISCOVERY=ON
export TOR_PROXY_PORT=9050
export REPORT_HOST='my-domain-name (Dynamic DNS by No-IP.com)'
export REPORT_TCP_PORT=50001
export REPORT_SSL_PORT=50006
export REPORT_HOST_TOR='xxxxxxxxxxxxxxxx.onion'
export REPORT_TCP_PORT_TOR=50001
export REPORT_SSL_PORT_TOR=50006
export CACHE_MB=1500
For the time being, I reverted to tag 1.11.0 and aiorpcX 0.15.0 'sudo netstat -tulpn | grep LISTEN' now shows:
tcp 0 0 0.0.0.0:omitted 0.0.0.0:* LISTEN 581/sshd
tcp 0 0 127.0.0.1:8332 0.0.0.0:* LISTEN 642/bitcoind
tcp 0 0 0.0.0.0:8333 0.0.0.0:* LISTEN 642/bitcoind
tcp 0 0 0.0.0.0:50001 0.0.0.0:* LISTEN 19534/python3.7
tcp 0 0 127.0.0.53:53 0.0.0.0:* LISTEN 561/systemd-resolve
tcp 0 0 0.0.0.0:50006 0.0.0.0:* LISTEN 19534/python3.7
tcp 0 0 127.0.0.1:9050 0.0.0.0:* LISTEN 583/tor
tcp 0 0 127.0.0.1:9051 0.0.0.0:* LISTEN 583/tor
tcp 0 0 127.0.0.1:8000 0.0.0.0:* LISTEN 19534/python3.7
tcp6 0 0 :::omitted :::* LISTEN 581/sshd
tcp6 0 0 :::8333 :::* LISTEN 642/bitcoind
tcp6 0 0 :::50001 :::* LISTEN 19534/python3.7
tcp6 0 0 :::50006 :::* LISTEN 19534/python3.7
BTW, I was able to get in touch with the mantainer of blacklist (https://hodlister.co/electrum-server-blacklist.json) and my domain name has been delisted (thanks etmetm).
thanks again.
Please understand the difference between SERVICES and REPORT_SERVICES.
Note in your original config you have HOST=. This is part of the SERVICES now.
If the docs are unclear please state how to improve them. The examples were chosen for a reason; they are what most will want to use.
electrumx server is up and running using 04c409d, however RPC port 8000 on IPv4 is not listening. I've contacted Contabo VPS support to have IPv6 disabled, since I wont' use it (if disabling it would solve the issue).
current listening ports are:
tcp 0 0 0.0.0.0:omitted 0.0.0.0:* LISTEN 584/sshd
tcp 0 0 127.0.0.1:8332 0.0.0.0:* LISTEN 1745/bitcoind
tcp 0 0 0.0.0.0:8333 0.0.0.0:* LISTEN 1745/bitcoind
tcp 0 0 0.0.0.0:50001 0.0.0.0:* LISTEN 4496/python3.7
tcp 0 0 0.0.0.0:50004 0.0.0.0:* LISTEN 4496/python3.7
tcp 0 0 127.0.0.53:53 0.0.0.0:* LISTEN 542/systemd-resolve
tcp 0 0 0.0.0.0:50006 0.0.0.0:* LISTEN 4496/python3.7
tcp 0 0 127.0.0.1:9050 0.0.0.0:* LISTEN 585/tor
tcp 0 0 127.0.0.1:9051 0.0.0.0:* LISTEN 585/tor
tcp6 0 0 :::omitted :::* LISTEN 584/sshd
tcp6 0 0 :::8333 :::* LISTEN 1745/bitcoind
tcp6 0 0 :::50001 :::* LISTEN 4496/python3.7
tcp6 0 0 :::50004 :::* LISTEN 4496/python3.7
tcp6 0 0 :::50006 :::* LISTEN 4496/python3.7
other relevant settings:
export SERVICES=tcp://:50001,SSL://:50006,wss://:50004,rpC://
export REPORT_SERVICES=tcp://domain-name:50001,ssl://domain-name:50006,wss://myaddress.onion:50006
I'm waiting to fully have IPv6 disabled before reporting again on this issue
Have you looked if anything else is using port 8000? I assume the logs say it can't bind. I doubt this has anything to do with IPv6. Try
rpc://127.0.0.1
instead of rpc:// if you're convinced it's IPv6-related.
Your wss settings don't match port.
On Sat, 11 May 2019 at 10:54, Savy notifications@github.com wrote:
electrumx server is up and running using 04c409d https://github.com/kyuupichan/electrumx/commit/04c409ddacca313a9cc8519de8d6cb2af4721407, however RPC port 8000 on IPv4 is not listening. I've contacted Contabo VPS support to have IPv6 disabled, since I wont' use it (if disabling it would solve the issue).
current listening ports are:
tcp 0 0 0.0.0.0:omitted 0.0.0.0: LISTEN 584/sshd tcp 0 0 127.0.0.1:8332 0.0.0.0: LISTEN 1745/bitcoind tcp 0 0 0.0.0.0:8333 0.0.0.0: LISTEN 1745/bitcoind tcp 0 0 0.0.0.0:50001 0.0.0.0: LISTEN 4496/python3.7 tcp 0 0 0.0.0.0:50004 0.0.0.0: LISTEN 4496/python3.7 tcp 0 0 127.0.0.53:53 0.0.0.0: LISTEN 542/systemd-resolve tcp 0 0 0.0.0.0:50006 0.0.0.0: LISTEN 4496/python3.7 tcp 0 0 127.0.0.1:9050 0.0.0.0: LISTEN 585/tor tcp 0 0 127.0.0.1:9051 0.0.0.0: LISTEN 585/tor tcp6 0 0 :::omitted ::: LISTEN 584/sshd tcp6 0 0 :::8333 ::: LISTEN 1745/bitcoind tcp6 0 0 :::50001 ::: LISTEN 4496/python3.7 tcp6 0 0 :::50004 ::: LISTEN 4496/python3.7 tcp6 0 0 :::50006 ::: LISTEN 4496/python3.7
other relevant settings:
export SERVICES=tcp://:50001,SSL://:50006,wss://:50004,rpC:// export REPORT_SERVICES=tcp://domain-name:50001,ssl://domain-name:50006,wss://myaddress.onion:50006
I'm waiting to fully have IPv6 disabled before reporting again on this issue
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/kyuupichan/electrumx/issues/820#issuecomment-491497044, or mute the thread https://github.com/notifications/unsubscribe-auth/AAZKLCDKIJTAPEAG2HYLPF3PU2JT7ANCNFSM4HMAYO3Q .
I tried
export SERVICES=tcp://:50001,SSL://:50006,wss://:50004,rpc://127.0.0.1
but the result is this:
(meanwhile IPv6 has been disabled)
nothing else is using port 8000
...
INFO:BlockProcessor:caught up to height 575532
INFO:BlockProcessor:flushing to DB for a clean shutdown...
ERROR:root:task crashed: <Task finished coro=<Controller.serve() done, defined at /usr/local/lib/python3.7/dist-packages/electrumX-1.11.0-py3.7.egg/electrumx/server/controller.py:81> exception=TypeError("argument of type 'IPv4Address' is not iterable")>
Traceback (most recent call last):
File "/usr/local/lib/python3.7/dist-packages/aiorpcx/util.py", line 309, in check_task
task.result()
File "/usr/local/lib/python3.7/dist-packages/electrumX-1.11.0-py3.7.egg/electrumx/server/controller.py", line 134, in serve
await group.spawn(wait_for_catchup())
File "/usr/local/lib/python3.7/dist-packages/aiorpcx/curio.py", line 242, in __aexit__
await self.join()
File "/usr/local/lib/python3.7/dist-packages/aiorpcx/curio.py", line 211, in join
raise task.exception()
File "/usr/local/lib/python3.7/dist-packages/electrumX-1.11.0-py3.7.egg/electrumx/server/session.py", line 563, in serve
await self._start_servers(service for service in self.env.services
File "/usr/local/lib/python3.7/dist-packages/electrumX-1.11.0-py3.7.egg/electrumx/server/session.py", line 181, in _start_servers
service.port, ssl=sslc)
File "/usr/local/lib/python3.7/dist-packages/aiorpcx/rawsocket.py", line 178, in serve_rs
return await loop.create_server(protocol_factory, host, port, **kwargs)
File "/usr/lib/python3.7/asyncio/base_events.py", line 1331, in create_server
infos = await tasks.gather(*fs, loop=self)
File "/usr/lib/python3.7/asyncio/base_events.py", line 1273, in _create_server_getaddrinfo
flags=flags, loop=self)
File "/usr/lib/python3.7/asyncio/base_events.py", line 1262, in _ensure_resolved
info = _ipaddr_info(host, port, family, type, proto)
File "/usr/lib/python3.7/asyncio/base_events.py", line 138, in _ipaddr_info
if '%' in host:
TypeError: argument of type 'IPv4Address' is not iterable
Thanks, that's a bug, fixed in git HEAD. Can you try that again?
On Sat, 11 May 2019 at 12:56, Savy notifications@github.com wrote:
I tried export SERVICES=tcp://:50001,SSL://:50006,wss://:50004,rpc://127.0.0.1 but the result is this: (meanwhile IPv6 has been disabled)
... INFO:BlockProcessor:caught up to height 575532 INFO:BlockProcessor:flushing to DB for a clean shutdown... ERROR:root:task crashed: <Task finished coro=<Controller.serve() done, defined at /usr/local/lib/python3.7/dist-packages/electrumX-1.11.0-py3.7.egg/electrumx/server/controller.py:81> exception=TypeError("argument of type 'IPv4Address' is not iterable")> Traceback (most recent call last): File "/usr/local/lib/python3.7/dist-packages/aiorpcx/util.py", line 309, in check_task task.result() File "/usr/local/lib/python3.7/dist-packages/electrumX-1.11.0-py3.7.egg/electrumx/server/controller.py", line 134, in serve await group.spawn(wait_for_catchup()) File "/usr/local/lib/python3.7/dist-packages/aiorpcx/curio.py", line 242, in aexit await self.join() File "/usr/local/lib/python3.7/dist-packages/aiorpcx/curio.py", line 211, in join raise task.exception() File "/usr/local/lib/python3.7/dist-packages/electrumX-1.11.0-py3.7.egg/electrumx/server/session.py", line 563, in serve await self._start_servers(service for service in self.env.services File "/usr/local/lib/python3.7/dist-packages/electrumX-1.11.0-py3.7.egg/electrumx/server/session.py", line 181, in _start_servers service.port, ssl=sslc) File "/usr/local/lib/python3.7/dist-packages/aiorpcx/rawsocket.py", line 178, in serve_rs return await loop.create_server(protocol_factory, host, port, *kwargs) File "/usr/lib/python3.7/asyncio/base_events.py", line 1331, in create_server infos = await tasks.gather(fs, loop=self) File "/usr/lib/python3.7/asyncio/base_events.py", line 1273, in _create_server_getaddrinfo flags=flags, loop=self) File "/usr/lib/python3.7/asyncio/base_events.py", line 1262, in _ensure_resolved info = _ipaddr_info(host, port, family, type, proto) File "/usr/lib/python3.7/asyncio/base_events.py", line 138, in _ipaddr_info if '%' in host: TypeError: argument of type 'IPv4Address' is not iterable
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/kyuupichan/electrumx/issues/820#issuecomment-491504845, or mute the thread https://github.com/notifications/unsubscribe-auth/AAZKLCFCIMOGSWOJPRJWYYLPU2YARANCNFSM4HMAYO3Q .
I tried using variables below, RPC still does not listen on 8000 IPv4
export SERVICES=tcp://:50001,ssl://:50006,rpc://
export REPORT_SERVICES=tcp://my-domain-name:50001,ssl://my-domain-name:50006
production SW running on VPS server is: bitcoin core (Satoshi:0.18.0) and electrumx commit 7b16763
log
INFO:electrumx:ElectrumX server starting
INFO:electrumx:logging level: INFO
INFO:Controller:Python version: 3.7.1 (default, Oct 22 2018, 11:21:55) [GCC 8.2.0]
INFO:Controller:software version: ElectrumX 1.11.0
INFO:Controller:aiorpcX version: 0.18.0
INFO:Controller:supported protocol versions: 1.4-1.4.2
INFO:Controller:event loop policy: None
INFO:Controller:reorg limit is 200 blocks
INFO:Daemon:daemon #1 at localhost:8332/ (current)
INFO:DB:switching current directory to /home/bitcoin/.electrumx/electrumx-leveldb-database/
INFO:DB:using leveldb for DB backend
INFO:DB:opened UTXO DB (for sync: True)
INFO:DB:DB version: 6
INFO:DB:coin: BitcoinSegwit
INFO:DB:network: mainnet
INFO:DB:height: 575,550
INFO:DB:tip: 000000000000000000059f7f7cbe74f2b765bd66570733a5d9db7151d188fc33
INFO:DB:tx count: 412,151,465
INFO:DB:flushing DB cache at 1,500 MB
INFO:History:history DB version: 0
INFO:History:flush count: 427
ERROR:SessionManager:RPC server failed to listen on localhost:8000: [Errno 99] error while attempting to bind on address ('::1', 8000, 0, 0): cannot assign requested address
INFO:Prefetcher:catching up to daemon height 575,552 (2 blocks behind)
INFO:BlockProcessor:our height: 575,552 daemon: 575,552 UTXOs 3MB hist 4MB
INFO:BlockProcessor:processed 2 blocks size 2.60 MB in 82.9s
INFO:BlockProcessor:caught up to height 575552
INFO:DB:flushed filesystem data in 0.00s
INFO:History:flushed history in 0.1s for 20,745 addrs
INFO:DB:flushed 2 blocks with 5,994 txs, 13,974 UTXO adds, 9,663 spends in 0.1s, committing...
INFO:DB:flush #428 took 0.2s. Height 575,552 txs: 412,157,459 (+5,994)
INFO:DB:tx/sec since genesis: 35, since last flush: 72
INFO:DB:sync time: 134d 18h 40m ETA: 00s
INFO:DB:closing DBs to re-open for serving
INFO:DB:opened UTXO DB (for sync: False)
INFO:DB:DB version: 6
INFO:DB:coin: BitcoinSegwit
INFO:DB:network: mainnet
INFO:DB:height: 575,552
INFO:DB:tip: 0000000000000000000f3bb8274b936b3e8c7e1775cbc136993264861819ab7c
INFO:DB:tx count: 412,157,459
INFO:History:history DB version: 0
INFO:History:flush count: 428
INFO:DB:deleted 2 stale undo entries
INFO:DB:populating header merkle cache...
INFO:MemPool:beginning processing of daemon mempool. This can take some time...
INFO:DB:header merkle cache populated in 5.6s
INFO:Prefetcher:new block height 575,553 hash 00000000000000000023bdd89111df83d5a78eedf2a505f21a3d1c618a963f3f
INFO:DB:flush #429 took 0.8s. Height 575,553 txs: 412,160,321 (+2,862)
INFO:BlockProcessor:processed 1 block size 1.16 MB in 12.8s
ERROR:MemPool:268 txs dropped
INFO:SessionManager:max session count: 2,000
INFO:SessionManager:session timeout: 600 seconds
INFO:SessionManager:session cost hard limit 10,000
INFO:SessionManager:session cost soft limit 1,000
INFO:SessionManager:bandwidth unit cost 5,000
INFO:SessionManager:request sleep 2,500ms
INFO:SessionManager:request timeout 30s
INFO:SessionManager:initial concurrent 10
INFO:SessionManager:max response size 1,000,000 bytes
INFO:SessionManager:advertising service tcp://my-domain-name.org:50001
INFO:SessionManager:advertising service ssl://my-domain-name.org:50006
INFO:MemPool:synced in 524.86s
INFO:MemPool:30,634 txs 24.75 MB touching 132,388 addresses
INFO:MemPool:compact fee histogram: [(117, 106075), (111, 121553), (103, 122357), (98, 126134), (92, 145000), (89, 153868), (88, 207069), (87, 812089), (86, 34407), (85, 73203), (84, 41942), (79, 217540), (70, 315380), (63, 363595), (52, 351261), (50, 669263), (45, 209777), (40, 596973), (33, 467719), (25, 608496), (20, 1236118), (19, 402122), (14, 592048), (10, 3494316), (9, 313313), (8, 181553), (7, 778295), (5, 931616), (3, 1568965), (2, 2845235), (1, 6658353)]
INFO:SessionManager:TCP server listening on all_interfaces:50001
INFO:SessionManager:SSL server listening on all_interfaces:50006
INFO:PeerManager:peer discovery: ON
INFO:PeerManager:announce ourself: True
INFO:PeerManager:my clearnet self: my-domain-name.org
INFO:PeerManager:force use of proxy: False
INFO:PeerManager:beginning peer discovery...
INFO:PeerManager:trying to detect proxy on "127.0.0.1" ports [9050]
INFO:PeerManager:accepted new peer my-domain-name.org from env
INFO:PeerManager:accepted new peer btc.smsys.me from env
INFO:PeerManager:accepted new peer E-X.not.fyi from env
INFO:PeerManager:accepted new peer electrum.vom-stausee.de from env
INFO:PeerManager:accepted new peer electrum.hsmiths.com from env
INFO:PeerManager:accepted new peer helicarrier.bauerj.eu from env
INFO:PeerManager:accepted new peer node.arihanc.com from env
INFO:ElectrumX:[0] SSL 173.212.253.26:56527, 0 total
INFO:PeerManager:[my-domain-name.org:50006 SSL] verified in 0.0s
INFO:PeerManager:[btc.smsys.me:995 SSL] [Errno -5] No address associated with hostname
INFO:PeerManager:[E-X.not.fyi:50002 SSL] [Errno -5] No address associated with hostname
INFO:PeerManager:[E-X.not.fyi:50002 SSL] [Errno -2] Name or service not known
INFO:PeerManager:[E-X.not.fyi:50001 TCP] [Errno -5] No address associated with hostname
INFO:PeerManager:[E-X.not.fyi:50001 TCP] [Errno -2] Name or service not known
INFO:PeerManager:[btc.smsys.me:995 SSL] [Errno -5] No address associated with hostname
INFO:PeerManager:[electrum.hsmiths.com:50002 SSL] [Errno 111] Connect call failed ('51.15.106.98', 50002)
INFO:PeerManager:[electrum.hsmiths.com:50002 SSL] [Errno -5] No address associated with hostname
INFO:PeerManager:accepted new peer Bitkoins.nl from helicarrier.bauerj.eu
INFO:PeerManager:accepted new peer electrumx.kenrufe.com from helicarrier.bauerj.eu
INFO:PeerManager:registering ourself with helicarrier.bauerj.eu
INFO:ElectrumX:[1] TCP 217.112.13.56:21953, 0 total
INFO:ElectrumX:[1] attempting to crash old client with version 3.2.2
INFO:PeerManager:blacklist from https://electrum.org/blacklist.json has 531 entries
INFO:PeerManager:[electrum.hsmiths.com:50001 TCP] [Errno 111] Connect call failed ('51.15.106.98', 50001)
INFO:PeerManager:[electrum.hsmiths.com:50001 TCP] [Errno -5] No address associated with hostname
INFO:PeerManager:accepted new peer electrumx.ddns.net from electrum.vom-stausee.de
INFO:PeerManager:accepted new peer electrum.petrkr.net from electrum.vom-stausee.de
INFO:PeerManager:registering ourself with electrum.vom-stausee.de
INFO:PeerManager:[helicarrier.bauerj.eu:50002 SSL] verified in 0.3s
INFO:ElectrumX:[2] TCP 89.37.2.100:53602, 0 total
INFO:PeerManager:[electrum.vom-stausee.de:50002 SSL] verified in 0.4s
INFO:PeerManager:detected SOCKS5 proxy at 127.0.0.1:9050, auth: none
INFO:PeerManager:accepted new peer pink-gold.westeurope.cloudapp.azure.com from Bitkoins.nl
INFO:PeerManager:accepted new peer thanos.xskyx.net from Bitkoins.nl
INFO:PeerManager:[Bitkoins.nl:50502 SSL] verified in 0.3s
INFO:PeerManager:accepted new peer orannis.com from thanos.xskyx.net
INFO:PeerManager:accepted new peer electrum3.hodlister.co from thanos.xskyx.net
INFO:PeerManager:[thanos.xskyx.net:50002 SSL] verified in 0.1s
INFO:ElectrumX:[3] TCP 200.119.139.194:56463, 1 total
INFO:ElectrumX:[3] attempting to crash old client with version 3.2.2
INFO:PeerManager:accepted new peer electrum4.hodlister.co from electrum3.hodlister.co
INFO:PeerManager:accepted new peer e9.keff.org from electrum3.hodlister.co
INFO:PeerManager:[electrum3.hodlister.co:50002 SSL] verified in 0.3s
INFO:ElectrumX:[4] TCP 213.87.105.137:26839, 1 total
INFO:PeerManager:accepted new peer e10.keff.org from e9.keff.org
INFO:PeerManager:registering ourself with e9.keff.org
INFO:ElectrumX:[5] TCP 41.65.227.164:55589, 2 total
INFO:PeerManager:accepted new peer btc.theblains.org from electrum4.hodlister.co
INFO:PeerManager:accepted new peer btc.usebsv.com from electrum4.hodlister.co
INFO:PeerManager:registering ourself with electrum4.hodlister.co
ERROR:PeerManager:[electrumx.kenrufe.com:50002 SSL] marking bad: (bad height 575,545 (ours: 575,553))
INFO:PeerManager:[e9.keff.org:50002 SSL] verified in 0.3s
INFO:ElectrumX:[4] attempting to crash old client with version 3.2.2
INFO:ElectrumX:[6] TCP 188.158.53.125:52417, 2 total
INFO:PeerManager:accepted new peer electrum.xskyx.net from btc.usebsv.com
INFO:PeerManager:accepted new peer electrumx-core.1209k.com from btc.usebsv.com
INFO:PeerManager:registering ourself with btc.usebsv.com
INFO:PeerManager:[electrumx-core.1209k.com:50002 SSL] [Errno -5] No address associated with hostname
INFO:PeerManager:accepted new peer ndnd.selfhost.eu from electrum.xskyx.net
INFO:PeerManager:accepted new peer electrum.fedaykin.eu from electrum.xskyx.net
INFO:PeerManager:[electrum4.hodlister.co:50002 SSL] verified in 0.4s
INFO:PeerManager:[electrum.xskyx.net:50002 SSL] verified in 0.0s
INFO:PeerManager:[electrumx-core.1209k.com:50002 SSL] [Errno -5] No address associated with hostname
INFO:PeerManager:[electrumx-core.1209k.com:50001 TCP] [Errno -5] No address associated with hostname
INFO:PeerManager:[electrumx-core.1209k.com:50001 TCP] [Errno -5] No address associated with hostname
INFO:PeerManager:[btc.usebsv.com:52002 SSL] verified in 0.2s
INFO:PeerManager:accepted new peer e1.keff.org from e10.keff.org
INFO:PeerManager:accepted new peer e2.keff.org from e10.keff.org
INFO:PeerManager:registering ourself with e10.keff.org
INFO:PeerManager:[electrum.fedaykin.eu:50005 SSL] [Errno 111] Connect call failed ('109.192.226.254', 50005)
INFO:PeerManager:[electrum.fedaykin.eu:50005 SSL] [Errno -5] No address associated with hostname
INFO:PeerManager:[e10.keff.org:50002 SSL] verified in 0.3s
ERROR:PeerManager:[node.arihanc.com:50002 SSL] marking bad: (blacklisted)
INFO:PeerManager:accepted new peer electrum.nute.net from ndnd.selfhost.eu
INFO:PeerManager:accepted new peer ozahtqwp25chjdjd.onion from ndnd.selfhost.eu
INFO:PeerManager:registering ourself with ndnd.selfhost.eu
INFO:PeerManager:registering ourself with e2.keff.org
INFO:PeerManager:[e2.keff.org:50002 SSL] verified in 0.3s
INFO:PeerManager:accepted new peer electrum.jochen-hoenicke.de from electrumx.ddns.net
INFO:PeerManager:accepted new peer electrum.50x.com from electrumx.ddns.net
INFO:PeerManager:accepted new peer electrum.emzy.de from electrum.nute.net
INFO:PeerManager:accepted new peer tardis.bauerj.eu from electrum.nute.net
INFO:PeerManager:[electrum.nute.net:17315 SSL] verified in 0.2s
INFO:PeerManager:[electrum.emzy.de:50002 SSL] [Errno 104] Connection reset by peer
INFO:PeerManager:[electrum.emzy.de:50002 SSL] [Errno -5] No address associated with hostname
INFO:PeerManager:accepted new peer electrum2.hodlister.co from electrum.jochen-hoenicke.de
INFO:PeerManager:accepted new peer 77.20.219.157 from electrum.jochen-hoenicke.de
INFO:PeerManager:registering ourself with electrum.jochen-hoenicke.de
INFO:PeerManager:[ndnd.selfhost.eu:50002 SSL] verified in 0.6s
INFO:PeerManager:[electrum.jochen-hoenicke.de:50005 SSL] verified in 0.2s
INFO:PeerManager:accepted new peer ASSUREDLY.not.fyi from electrum.50x.com
INFO:PeerManager:accepted new peer btc.litepay.ch from electrum.50x.com
INFO:PeerManager:registering ourself with electrum.50x.com
INFO:PeerManager:[electrumx.ddns.net:53211 SSL] verified in 1.5s
INFO:PeerManager:[electrum.50x.com:50006 SSL] verified in 0.3s
INFO:ElectrumX:[7] TCP 195.201.74.162:46441, 2 total
INFO:PeerManager:accepted new peer electrumx.electricnewyear.net from 77.20.219.157
INFO:PeerManager:accepted new peer e5a8f0d103c23.not.fyi from 77.20.219.157
INFO:PeerManager:accepted new peer currentlane.lovebitco.in from btc.theblains.org
INFO:PeerManager:accepted new peer ndndword5lpb7eex.onion from btc.theblains.org
INFO:PeerManager:accepted new peer electrumx.schmoock.net from pink-gold.westeurope.cloudapp.azure.com
INFO:PeerManager:accepted new peer daedalus.bauerj.eu from pink-gold.westeurope.cloudapp.azure.com
INFO:PeerManager:registering ourself with pink-gold.westeurope.cloudapp.azure.com
...
electrumx is online serving clients right now, but does not anwers to electrumx_rpc call
ERROR:SessionManager:RPC server failed to listen on localhost:8000: [Errno 99] error while attempting to bind on address ('::1', 8000, 0, 0): cannot assign requested address
You need to figure out why that is. It is a problem with your system so I cannot help; it has nothing to do with ElectrumX. Ask your standard O/S tools what is listening on that port, and kill it. Or, determine why ::1 isn't working on your system.
I had the same issue with a Contabo VPS.
Something about binding ::1 (ipv6 localhost) is broken.
I got mine working by adding RPC_HOST=127.0.0.1
to my environment.
Correct Samuel,
I used the same in the past and it has always worked well through the various electrumx releases until the implementation of the new environment variables (SERVICES and REPORT_SERVICES) and latest aiorpcX (0.18.0).
Unfortunately the latest environment approach does not encompass someting like RPC_HOST=127.0.0.1
anylonger so, for the time being, I downgraded to electrumx 1.11.0 and aiorpcX 0.15.0.
Will see if I'm the only one with Contabo VPS suffering that issue. I'll try to open a ticket with Contabo Support meanwhile. Savy
INFO:electrumx:ElectrumX server starting
INFO:electrumx:logging level: INFO
INFO:Controller:Python version: 3.7.1 (default, Oct 22 2018, 11:21:55) [GCC 8.2.0]
INFO:Controller:software version: ElectrumX 1.11.0
INFO:Controller:aiorpcX version: 0.15.0
INFO:Controller:supported protocol versions: 1.4-1.4.2
INFO:Controller:event loop policy: None
INFO:Controller:reorg limit is 200 blocks
INFO:Daemon:daemon #1 at localhost:8332/ (current)
INFO:DB:switching current directory to /home/bitcoin/.electrumx/electrumx-leveldb-database/
INFO:DB:using leveldb for DB backend
INFO:DB:opened UTXO DB (for sync: True)
INFO:DB:DB version: 6
INFO:DB:coin: BitcoinSegwit
INFO:DB:network: mainnet
INFO:DB:height: 575,650
INFO:DB:tip: 0000000000000000001c8b7ab56ff85be64e7079a6611460ef444ae092d9de90
INFO:DB:tx count: 412,395,461
INFO:DB:flushing DB cache at 1,500 MB
INFO:History:history DB version: 0
INFO:History:flush count: 521
INFO:DB:deleted 3 stale undo entries
INFO:BlockProcessor:caught up to height 575650
INFO:SessionManager:RPC server listening on 127.0.0.1:8000
INFO:DB:closing DBs to re-open for serving
INFO:DB:opened UTXO DB (for sync: False)
INFO:DB:DB version: 6
INFO:DB:coin: BitcoinSegwit
INFO:DB:network: mainnet
INFO:DB:height: 575,650
INFO:DB:tip: 0000000000000000001c8b7ab56ff85be64e7079a6611460ef444ae092d9de90
INFO:DB:tx count: 412,395,461
INFO:History:history DB version: 0
INFO:History:flush count: 521
INFO:DB:populating header merkle cache...
I got the latest working by editing /etc/hosts.
#::1 localhost ip6-localhost ip6-loopback
::1 ip6-localhost ip6-loopback
This removes the broken ipv6 localhost.
"Unfortunately the latest environment approach does not encompass someting like RPC_HOST=127.0.0.1 anylonger "
Oh really? Why do you think that? It certainly does; let me know how to improve the docs please.
(there was a bug you pointed out where Python's APIs require a host as a string and don't accept their own IPv4 address objects; I fixed that).
Thank you both of you, @kyuupichan and @shsmith, for guidance and clarifications. Everything is up and running now, using commit 8b2918c (aiorpcX 0.18.0).
I saw environment.rst has been updated a few hours ago, I'll do my best to submit a proposal for further improvement if I can.
ref to: #rpc://:8000 # Default host, port given
In the Services section of my run script SERVICES are set like this: export SERVICES = tcp://2xxxxxxxx.hopto.org:50001,ssl://2xxxxxxxx.hopto.org:50006,rpc://localhost:8000
I do not use IPv6
in the log, I get this: ERROR:SessionManager:RPC server failed to listen on localhost:8000: [Errno 99] error while attempting to bind on address ('::1', 8000, 0, 0): cannot assign requested address
so RPCs do no go through via electrumx_rpc