BTCPayServer BTC chain not syncing after update

After the upgrade to BTCPay Server v2.2.1+790616d2a on umbrelOS Version 0.5.4, the pay server is not in sync.

I was checking various troubleshooting articles, which suggest this is an issue with the container, perhaps with hostname/port variables of the Docker config file.

Also, the status of the NBXplorer container is “Restarting”.

umbrel@umbrel:~/umbrel/app-data/btcpay-server $ docker container ls -a
2f915dc67bd9 nicolasdorier/nbxplorer:2.5.28 “dotnet NBXplorer.dll” 36 minutes ago Restarting (133) 6 seconds ago btcpay-server_nbxplorer_1


The BTCPay Server Docker file follows:

umbrel@umbrel:~/umbrel/app-data/btcpay-server $ cat docker-compose.yml
version: “3.7”

services:
app_proxy:
environment:
APP_HOST: btcpay-server_web_1
APP_PORT: 3003
PROXY_AUTH_ADD: “false”

nbxplorer:
image: nicolasdorier/nbxplorer:2.5.28@sha256:xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
user: “1000:1000”
restart: on-failure
stop_grace_period: 1m
depends_on: [postgres]
volumes:

  • ${APP_DATA_DIR}/data/nbxplorer:/data
    environment:
    NBXPLORER_DATADIR: “/data”
    NBXPLORER_NETWORK: “$APP_BITCOIN_NETWORK”
    NBXPLORER_BIND: 0.0.0.0:32838
    NBXPLORER_CHAINS: “btc”
    NBXPLORER_SIGNALFILEDIR: “/data”
    NBXPLORER_BTCRPCURL: “http://$APP_BITCOIN_NODE_IP:$APP_BITCOIN_RPC_PORT”
    NBXPLORER_BTCNODEENDPOINT: $APP_BITCOIN_NODE_IP:${APP_BITCOIN_P2P_WHITEBIND_PORT-${APP_BITCOIN_P2P_PORT}}
    NBXPLORER_BTCRPCUSER: $APP_BITCOIN_RPC_USER
    NBXPLORER_BTCRPCPASSWORD: $APP_BITCOIN_RPC_PASS
    NBXPLORER_POSTGRES: User ID=postgres;Host=btcpay-server_postgres_1;Port=5432;Application Name=nbxplorer;MaxPoolSize=20;Database=nbxplorer$APP_BITCOIN_NETWORK
    NBXPLORER_BTCHASTXINDEX: 1

web:
image: btcpayserver/btcpayserver:2.2.1@sha256:xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
user: “1000:1000”
restart: on-failure
stop_grace_period: 1m
depends_on: [nbxplorer, postgres]
entrypoint: [“dotnet”, “BTCPayServer.dll”]
volumes:

  • ${APP_DATA_DIR}/data/btcpay:/data
  • ${APP_DATA_DIR}/data/nbxplorer:/data/.nbxplorer
  • ${APP_LIGHTNING_NODE_DATA_DIR}:/lnd:ro
    environment:
    HOME: “/data”
    BTCPAY_DATADIR: “/data”
    BTCPAY_PLUGINDIR: “/data/plugins”
    BTCPAY_DOCKERDEPLOYMENT: “false”
    BTCPAY_POSTGRES: “User ID=postgres;Host=btcpay-server_postgres_1;Port=5432;Database=btcpayserver$APP_BITCOIN_NETWORK”
    BTCPAY_NETWORK: “$APP_BITCOIN_NETWORK”
    BTCPAY_BIND: 0.0.0.0:3003
    BTCPAY_CHAINS: “btc”
    BTCPAY_BTCEXPLORERURL: “http://btcpay-server_nbxplorer_1:32838”
    BTCPAY_BTCLIGHTNING: “type=lnd-rest;server=https://$APP_LIGHTNING_NODE_IP:$APP_LIGHTNING_NODE_REST_PORT/;macaroonfilepath=/lnd/data/chain/bitcoin/$APP_BITCOIN_NETWORK/admin.macaroon;allowinsecure=true”
    BTCPAY_SOCKSENDPOINT: $TOR_PROXY_IP:$TOR_PROXY_PORT
    BTCPAY_EXPLORERPOSTGRES: User ID=postgres;Host=btcpay-server_postgres_1;Port=5432;Application Name=nbxplorer;MaxPoolSize=20;Database=nbxplorer$APP_BITCOIN_NETWORK
    BTCPAY_TORSERVICES: “btcpayserver:$APP_HIDDEN_SERVICE”

postgres:
image: btcpayserver/postgres:13.13@sha256:xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

This needs to run as root for migrations to succeed

user: “1000:1000”

restart: on-failure

command: [“-c”, “random_page_cost=1.0”, “-c”, “shared_preload_libraries=pg_stat_statements”]
stop_grace_period: 1m
environment:
POSTGRES_HOST_AUTH_METHOD: trust
volumes:

  • ${APP_DATA_DIR}/data/postgres:/var/lib/postgresql/data

In /umbrel/app-data/btcpay-server/data/nbxplorer/Main/settings.configEverything is default/commented.


umbrel@umbrel:~/umbrel/app-data/btcpay-server $ ping http://btcpay-server_nbxplorer_1:32838
ping: http://btcpay-server_nbxplorer_1:32838: Name or service not known


I don’t know what else to check or where to fix this. I run local DNS (BIND) and NGINX reverse proxy, but no changes there.

Any ideas?

Just a small update to the troubleshooting. I have uninstalled BTCPayserver app and reinstalled it.

Symptoms are similar with the fresh installation this time, BTCPayserver won’t even complete start as NBXplorer container is hanged in restart status.

This is the error I am getting after reinstallation:

info: Configuration: NBXplorer version 2.5.28
info: Configuration: Data Directory: /data
info: Configuration: Configuration File: /data/Main/settings.config
info: Configuration: Network: Mainnet
Unhandled exception. System.FormatException: Invalid IP or DNS endpoint
at NBitcoin.Utils.ParseEndpoint(String hostPort, Int32 defaultPort)
at NBXplorer.Configuration.ExplorerConfiguration.LoadArgs(IConfiguration config) in /source/NBXplorer/Configuration/ExplorerConfiguration.cs:line 124
at NBXplorer.Program.Main(String args) in /source/NBXplorer/Program.cs:line 34

I notice you are running umbrelOS 0.5.4, one of the the first suggestions I can make that might help is to update to a more recent version of umbrelOS.

Otherwise could you try what this comment suggested fir a similar issue? BTCPAY won't start after install - #2 by usernameisJim

Failing that, could you post the full logs of BTCPayServer? I’m not sure how to get it on your version but on newer versions of umbrelOS it’s Settings > Troubleshoot > App > BTCPayServer

1 Like

Thank you very much for hints. I have tried usernameisJim solution, it did not make the service running, even script reported restart is completed.

umbrel@umbrel:~/umbrel/scripts $ ./app restart btcpay-server
Stopping app btcpay-server…
Stopping btcpay-server_nbxplorer_1 … done
Stopping btcpay-server_postgres_1 … done
Stopping btcpay-server_app_proxy_1 … done
Stopping btcpay-server_tor_server_1 … done
Going to remove btcpay-server_web_1, btcpay-server_nbxplorer_1, btcpay-server_postgres_1, btcpay-server_app_proxy_1, btcpay-server_tor_server_1
Removing btcpay-server_web_1 … done
Removing btcpay-server_nbxplorer_1 … done
Removing btcpay-server_postgres_1 … done
Removing btcpay-server_app_proxy_1 … done
Removing btcpay-server_tor_server_1 … done
Starting app btcpay-server…
Creating btcpay-server_postgres_1 … done
Creating btcpay-server_tor_server_1 … done
Creating btcpay-server_app_proxy_1 … done
Creating btcpay-server_nbxplorer_1 … done
Creating btcpay-server_web_1 … done

Attaching logs for further troubleshooting.

umbrel-1761073089558-debug.log (54.2 KB)