Recently I had to reinstall/compile Bitcoin Core in my freshly installed Debian Buster laptop. I followed instructions here for method 2 at the bottom of the site: https://en.bitcoin.it/wiki/Setting_up_a_Tor_hidden_service

But shortly after I started my node, I noticed that the command

bitcoin-cli getnetworkinfo

was reporting 2 onion addresses at the bottom of the returned JSON object, at section localaddresses.

      "address": "rs6srmllckfcveu2.onion",
      "port": 8333,
      "score": 6
      "address": "53hhdjgv4jailcee.onion",
      "port": 8334,
      "score": 4
  "warnings": ""

These are my settings related to Bitcoin Core and Tor

Bitcoin Core config file


and in /etc/tor/torrc

HiddenServiceDir /var/lib/tor/bitcoin-service
HiddenServiceVersion 2
HiddenServicePort 8334

I also added this to but these lines are for c-lightning node configuration, so I assume they play no role for Bitcoin Core configuration regarding method 2.

SocksPort 9050

CookieAuthentication 1
CookieAuthFileGroupReadable 1
CookieAuthFile /run/tor/control.authcookie

Inside /var/lib/tor/bitcoin-service/hostname I can see only one onion address which is the one in my Bitcoin Core config file.

I already tried to delete my bitcoin onion_private_key file and also deleted my /var/lib/tor/bitcoin-service folder, but still 2 onion addresses are showing up. So, where is it Bitcoin Core picking up the other onion address? Can anyone help me?

  • What happens if you remove the HiddenServiceDir HiddenServiceVersion and HiddenServicePort from /etc/tor/torrc ?
    – user103136
    Dec 10, 2020 at 12:50
  • I'll try today after work and will let you know @Prayank Dec 11, 2020 at 13:41
  • @Prayank if I remove those lines, the service won't be controlled by Tor any more, if I understand correctly. Which was the point of that config. However, I'm not using that config any more. If I get back to it, I'll come back to this thread. Thank you! Jan 24, 2021 at 16:10


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.