Skip to content
This repository has been archived by the owner on Jul 19, 2024. It is now read-only.

http-addrindexrs, counterparty unable to connect to addrindexrs #350

Open
joslee7410 opened this issue Jan 17, 2023 · 4 comments
Open

http-addrindexrs, counterparty unable to connect to addrindexrs #350

joslee7410 opened this issue Jan 17, 2023 · 4 comments

Comments

@joslee7410
Copy link

  • Bitcoind already synced.
  • addrindexrs already synced.

image

But service (http-addrindexrs and counterparty) unable to connect addrindexrs(8432 port). Already make sure the port 8432 is using by addrindexrs container.

Please help, thank you.

@pataegrillo
Copy link
Contributor

Hey, something seems wrong with addrindexrs container. Try this:

docker ps -a

That will display a list of docker containers (if you can attach a screenshot it may be handy). Find the container id for addrindexrs. Then do this:

docker inspect THAT_ID_YOU_FOUND

Now it will display details for that container. Find network details and look for the container's ip, try to see if it matches "172.18.0.5"

@droplister
Copy link

droplister commented Feb 20, 2023

I am also encountering this issue when syncing a fednode today. @joslee7410 did you resolve it?

The counterparty and http-addrindex config files reference a addrindexrs where is that set? The addrindexrs has no config file.

@jdogresorg
Copy link
Contributor

The config for addrindexr is taken directly from the environment section in docker-compose.tmpl.yml

https://github.com/CounterpartyXCP/federatednode/blob/master/docker-compose.tmpl.yml#L44-L82

@droplister
Copy link

Ok, I think there could be something happening here with the subnet ip addresses mismatching, but I don't know Docker well. I'm using Google Cloud to setup a fednode and here are tails of the different containers.

Everything looks more or less like it's doing what it should except http-addrindexrs, xcp-proxy, and counterparty appear to be trying to connect to other containers and failing maybe because they're available at different ips.

fednode tail bitcoin

bitcoin_1                   | 2023-02-23T17:34:49Z UpdateTip: new best=0000000000000000000683c258d84fed8d76fa98021e9c43fbcd662580f33e5c height=777988 version=0x317fc000 log2_work=94.021357 tx=808077235 date='2023-02-23T17:06:36Z' progress=0.999994 cache=330.4MiB(2487538txo)
bitcoin_1                   | 2023-02-23T17:34:50Z UpdateTip: new best=0000000000000000000698bbe12f63f37f70d2fb8cc2e83e4e5a7bcbd75b3c62 height=777989 version=0x20600000 log2_work=94.021369 tx=808080468 date='2023-02-23T17:23:12Z' progress=0.999997 cache=331.3MiB(2494104txo)
bitcoin_1                   | 2023-02-23T17:34:50Z UpdateTip: new best=00000000000000000002b3bd4b94a68c03f52601d88fd6adc7e3ee27c273ded1 height=777990 version=0x3fffe000 log2_work=94.021381 tx=808083000 date='2023-02-23T17:29:02Z' progress=0.999999 cache=331.7MiB(2497599txo)
bitcoin_1                   | 2023-02-23T17:34:50Z UpdateTip: new best=00000000000000000001c87dc5c003c60e647a4227eae8bbbb3b2d4bedebe36f height=777991 version=0x2e7f6000 log2_work=94.021393 tx=808083883 date='2023-02-23T17:31:00Z' progress=0.999999 cache=331.0MiB(2491944txo)

fednode tail armory-utxsvr

armory-utxsvr_1             | **** Starting up ...
armory-utxsvr_1             | BITCOIND_PATH: /root/.bitcoin/
armory-utxsvr_1             | ARMORY btcdir: /root/.bitcoin/
armory-utxsvr_1             | BITCOIND_URL: http://XXXXXXXX@bitcoin:8332
armory-utxsvr_1             | RPC_HOST: 0.0.0.0
armory-utxsvr_1             | **** Initializing armory ...

fednode tail addrindexrs

addrindexrs_1               | INFO - indexing block 00000000000000000006d7af07b9d9eb8d78947bda6277522e8b75e52d5ff237
addrindexrs_1               | INFO - indexing block 00000000000000000006d19dca49ba91ddb8695a6c405f442cc85eeb327ef534
addrindexrs_1               | INFO - indexing block 0000000000000000000228a17463f4fa9f1da97129f3a6e8f3440e5a8baf8f74
addrindexrs_1               | INFO - indexing block 0000000000000000000463a1034c59e6dc94c7e52855582af11882743b86e2a7

fednode tail http-addrindexrs

http-addrindexrs_1          | Connection to addrindexrs closed! Retrying in 10 seconds...
http-addrindexrs_1          | Error connecting to addrindexrs:  Error: connect ECONNREFUSED 172.18.0.14:8432
http-addrindexrs_1          |     at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1159:16) {
http-addrindexrs_1          |   errno: -111,
http-addrindexrs_1          |   code: 'ECONNREFUSED',
http-addrindexrs_1          |   syscall: 'connect',
http-addrindexrs_1          |   address: '172.18.0.14',
http-addrindexrs_1          |   port: 8432
http-addrindexrs_1          | }

fednode tail xcp-proxy

xcp-proxy_1                 | > [email protected] start /app
xcp-proxy_1                 | > node index.js server
xcp-proxy_1                 |
xcp-proxy_1                 | Thu, 23 Feb 2023 17:20:05 GMT express-session deprecated undefined saveUninitialized option; provide saveUninitialized option at index.js:209:5
xcp-proxy_1                 | Listening on port 8097
xcp-proxy_1                 | (node:24) UnhandledPromiseRejectionWarning: Error: connect ECONNREFUSED 172.18.0.6:4000
xcp-proxy_1                 |     at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1159:16)
xcp-proxy_1                 | (Use `node --trace-warnings ...` to show where the warning was created)
xcp-proxy_1                 | (node:24) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1)
xcp-proxy_1                 | (node:24) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
xcp-proxy_1                 | (node:24) UnhandledPromiseRejectionWarning: Error: connect ECONNREFUSED 172.18.0.6:4000
xcp-proxy_1                 |     at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1159:16)
xcp-proxy_1                 | (node:24) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 2)

fednode tail counterparty

counterparty_1              | [2023-02-23 17:23:30][INFO] AddrIndexRs connecting...
counterparty_1              | [2023-02-23 17:23:30][INFO] Error connecting to AddrIndexRs! Retrying in a few seconds
counterparty_1              | [2023-02-23 17:23:35][INFO] AddrIndexRs connecting...
counterparty_1              | [2023-02-23 17:23:35][INFO] Error connecting to AddrIndexRs! Retrying in a few seconds

fednode tail counterblock

counterblock_1              | WARNING:util: Got call_jsonrpc_api request error: result is None -- is the 'http://counterparty:4000/api/' endpoint operational? -- Waiting 3 seconds before trying again...
counterblock_1              | WARNING:util: Got call_jsonrpc_api request error: result is None -- is the 'http://counterparty:4000/api/' endpoint operational? -- Waiting 3 seconds before trying again...
counterblock_1              | WARNING:util: Got call_jsonrpc_api request error: result is None -- is the 'http://counterparty:4000/api/' endpoint operational? -- Waiting 3 seconds before trying again...
counterblock_1              | WARNING:util: Got call_jsonrpc_api request error: result is None -- is the 'http://counterparty:4000/api/' endpoint operational? -- Waiting 3 seconds before trying again...

fednode tail redis

redis_1                     | 1:M 23 Feb 17:20:02.324 # Server started, Redis version 3.2.12
redis_1                     | 1:M 23 Feb 17:20:02.324 # WARNING overcommit_memory is set to 0! Background save may fail under low memory condition. To fix this issue add 'vm.overcommit_memory = 1' to /etc/sysctl.conf and then reboot or run the command 'sysctl vm.overcommit_memory=1' for this to take effect.
redis_1                     | 1:M 23 Feb 17:20:02.324 # WARNING you have Transparent Huge Pages (THP) support enabled in your kernel. This will create latency and memory usage issues with Redis. To fix this issue run the command 'echo never > /sys/kernel/mm/transparent_hugepage/enabled' as root, and add it to your /etc/rc.local in order to retain the setting after a reboot. Redis must be restarted after THP is disabled.
redis_1                     | 1:M 23 Feb 17:20:02.324 * The server is now ready to accept connections on port 6379

fednode tail mongodb

mongodb_1                   | 2023-02-23T17:20:06.721+0000 I NETWORK  [initandlisten] connection accepted from 172.18.0.12:56544 #3 (3 connections now open)
mongodb_1                   | 2023-02-23T17:20:06.728+0000 I NETWORK  [initandlisten] connection accepted from 172.18.0.12:56548 #4 (4 connections now open)
mongodb_1                   | 2023-02-23T17:20:06.740+0000 I COMMAND  [conn4] CMD: dropIndexes counterblockd_testnet.balance_changes

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants