Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ERROR:Daemon:connection problem - is your daemon running? Retrying occasionally... #1

Closed
useramuser opened this issue Dec 9, 2017 · 7 comments

Comments

@useramuser
Copy link

useramuser commented Dec 9, 2017

Hi, I tried a lot of stuff now to get this running.

I have bitcoind installed, synced, reindexed and want to run electrumx on the same server.
Everytime I try to run the docker command it seems to spin up the server and then just forever say

ERROR:Daemon:connection problem - is your daemon running? Retrying occasionally...

So it can somehow not connect to bitcoind, right?

I have configured a rpc user and password there and included this in the docker commands variables.
I am running the docker command like this:

docker run -v /mnt/bitcoinserver2/electrumx:/data -e DAEMON_URL=http://coindancer:ucjcjgtnlrnchhtlnkbudvrjljckb+@127.0.0.1 -e COIN=BitcoinSegwit -p 50002:50002 elec:stream

(elec:stream are the name and tag of the image that I built. It also does not work with lukechilds/electrumx)

@lukechilds
Copy link
Owner

Have you tested http://coindancer:ucjcjgtnlrnchhtlnkbudvrjljckb+@46.101.242.237 separately to see if you can access it?

@useramuser
Copy link
Author

useramuser commented Dec 9, 2017

Bitcoind is running and I currently have 32 connections.

Here is the output from bitcoin-cli getblockchaininfo

{
  "chain": "main",
  "blocks": 498401,
  "headers": 498401,
  "bestblockhash": "0000000000000000008883eda4c7908ebb5d419703866ee14b6ab2e88658c65d",
  "difficulty": 1590896927258.079,
  "mediantime": 1512823607,
  "verificationprogress": 0.9999992581486629,
  "chainwork": "000000000000000000000000000000000000000000c49313e02d8635339e1cdc",
  "pruned": false,
  "softforks": [
    {
      "id": "bip34",
      "version": 2,
      "reject": {
        "status": true
      }
    },
    {
      "id": "bip66",
      "version": 3,
      "reject": {
        "status": true
      }
    },
    {
      "id": "bip65",
      "version": 4,
      "reject": {
        "status": true
      }
    }
  ],
  "bip9_softforks": {
    "csv": {
      "status": "active",
      "startTime": 1462060800,
      "timeout": 1493596800,
      "since": 419328
    },
    "segwit": {
      "status": "active",
      "startTime": 1479168000,
      "timeout": 1510704000,
      "since": 481824
    }
  }
}

@useramuser
Copy link
Author

useramuser commented Dec 9, 2017

So now:
curl --data-binary '{"jsonrpc":"1.0","id":"curltext","method":"getinfo","params":[]}' -H 'content-type:text/plain;' http://coindancer:ucjcjgtnlrnchhtlnkbudvrjljckb+@127.0.0.1:8332/

Gives the following reply:
{"result":{"deprecation-warning":"WARNING: getinfo is deprecated and will be fully removed in 0.16. Projects should transition to using getblockchaininfo, getnetworkinfo, and getwalletinfo before upgrading to 0.16","version":150100,"protocolversion":70015,"walletversion":139900,"balance":0.00000000,"blocks":498405,"timeoffset":-1,"connections":10,"proxy":"","difficulty":1590896927258.079,"testnet":false,"keypoololdest":1512353719,"keypoolsize":2000,"paytxfee":0.00000000,"relayfee":0.00001000,"errors":""},"error":null,"id":"curltext"}

That means connection works.

docker run -v /mnt/bitcoinserver2/electrumx:/data -e DAEMON_URL=http://coindancer:ucjcjgtnlrnchhtlnkbudvrjljckb+@127.0.0.1:8332/ -e COIN=BitcoinSegwit -p 50002:50002 elec:stream

gives still this reply:

INFO:root:ElectrumX server starting
INFO:Controller:event loop policy: None
INFO:Daemon:daemon #1 at 127.0.0.1:8332/ (current)
INFO:BlockProcessor:switching current directory to /data
INFO:BlockProcessor:using leveldb for DB backend
INFO:BlockProcessor:opened DB for serving
INFO:BlockProcessor:closing DB to re-open for sync
INFO:BlockProcessor:opened DB for sync
INFO:BlockProcessor:software version: ElectrumX 1.2.1
INFO:BlockProcessor:DB version: 6
INFO:BlockProcessor:coin: BitcoinSegwit
INFO:BlockProcessor:network: mainnet
INFO:BlockProcessor:height: -1
INFO:BlockProcessor:tip: 0000000000000000000000000000000000000000000000000000000000000000
INFO:BlockProcessor:tx count: 0
INFO:BlockProcessor:flush count: 0
INFO:BlockProcessor:sync time so far: 00s
INFO:BlockProcessor:reorg limit is 200 blocks
INFO:BlockProcessor:flushing DB cache at 1,200 MB
INFO:PeerManager:accepted new peer 1/13 btc.smsys.me from coins.py
INFO:PeerManager:accepted new peer 2/13 E-X.not.fyi from coins.py
INFO:PeerManager:accepted new peer 3/13 elec.luggs.co from coins.py
INFO:PeerManager:accepted new peer 4/13 electrum.vom-stausee.de from coins.py
INFO:PeerManager:accepted new peer 5/13 electrum3.hachre.de from coins.py
INFO:PeerManager:accepted new peer 6/13 electrum.hsmiths.com from coins.py
INFO:PeerManager:accepted new peer 7/13 erbium1.sytes.net from coins.py
INFO:PeerManager:accepted new peer 8/13 helicarrier.bauerj.eu from coins.py
INFO:PeerManager:accepted new peer 9/13 hsmiths4fyqlw5xw.onion from coins.py
INFO:PeerManager:accepted new peer 10/13 luggscoqbymhvnkp.onion from coins.py
INFO:PeerManager:accepted new peer 11/13 ozahtqwp25chjdjd.onion from coins.py
INFO:PeerManager:accepted new peer 12/13 us11.einfachmalnettsein.de from coins.py
INFO:PeerManager:accepted new peer 13/13 ELEX01.blackpole.online from coins.py
INFO:Controller:RPC server listening on localhost:8000
ERROR:Daemon:connection problem - is your daemon running?  Retrying occasionally...

@lukechilds
Copy link
Owner

You've edited your original comment so it now says you're connecting to 172.0.0.1. That's going to loop back to the container, not the host, which is probably not what you want to do.

@useramuser
Copy link
Author

useramuser commented Dec 10, 2017

Yes you where right.
I have to use the external IP adress.
Once I did that again, the reply changed to
ERROR:Daemon:HTTP error code 403: Forbidden Retrying occasionally...

So I checked the internal IP of my electrum container while it was running with
docker network ls and got the IP of the electrum container.
I edited the bitcoin.conf file to
rpcallowip=172.17.0.2/16
and now electrum finally connects!! :-)

Thanks!

@lukechilds
Copy link
Owner

No problem, glad you got it sorted. You may find it easier to manage if you dockerise bitcoind and manage access with docker-compose.

Vertcoin example: https://github.com/lukechilds/docker-electrum-vertcoin/blob/master/docker-compose.yml

@maxvint
Copy link

maxvint commented Dec 21, 2023

docker run add --network host
For docker-compose it is:

electrumx:
    image: lukechilds/electrumx
    network_mode: "host"

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

No branches or pull requests

3 participants