1

I am running a custom Python script to initiate network handshakes with other nodes. While testing the code I decided to initiate an handshake with my own node but I am getting a timeout error.

TimeoutError: [Errno 110] Connection timed out

I know the script works, because I have tried with other well known nodes in the network. Also the script is from Programming Bitcoin by Jimmy Song, so I am reasonably confident that it's tested.

This is related (I think) to my earlier problem where I was checking connectivity while setting up the node and https://bitnodes.earn.com/ can't reach my node. I didn't pay much attention because my node successfully established incoming connections.

  bitcoin@bitcoin_fullnode:~ $ bitcoin-cli getnetworkinfo
{
  "version": 180000,
  "subversion": "/Satoshi:0.18.0/",
  "protocolversion": 70015,
  "localservices": "000000000000040d",
  "localrelay": true,
  "timeoffset": 0,
  "networkactive": true,
  "connections": 18,
  "networks": [

So this means my node is reachable from other nodes somehow, yet I can't manually reach it.

My node's public IP:

bitcoin@bitcoin_fullnode:~ $ curl https://ipinfo.io/ip
103.24.86.29 

My ufw settings:

18333                      ALLOW       Anywhere                   # allow Bitcoin testnet
8333                       ALLOW       Anywhere                   # allow Bitcoin mainnet

I am getting a local ping reply from my server. But no response from its public IP.

rajarshi@linuxpc:~$ ping 192.168.1.185
PING 192.168.1.185 (192.168.1.185) 56(84) bytes of data.
64 bytes from 192.168.1.185: icmp_seq=1 ttl=64 time=5.25 ms
64 bytes from 192.168.1.185: icmp_seq=2 ttl=64 time=3.34 ms
64 bytes from 192.168.1.185: icmp_seq=3 ttl=64 time=4.65 ms
^C
--- 192.168.1.185 ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 2003ms
rtt min/avg/max/mdev = 3.347/4.418/5.250/0.797 ms

rajarshi@linuxpc:~$ ping 103.24.86.29
PING 103.24.86.29 (103.24.86.29) 56(84) bytes of data.
^C
--- 103.24.86.29 ping statistics ---
9 packets transmitted, 0 received, 100% packet loss, time 8197ms

Similar situation for 8333 port using telnet:

rajarshi@linuxpc:~$ telnet 192.168.1.185 8333
Trying 192.168.1.185...
Connected to 192.168.1.185.

rajarshi@linuxpc:~$ telnet 103.24.86.29 8333
Trying 103.24.86.29...
telnet: Unable to connect to remote host: Connection timed out

Somehow it seems that my public IP is not reachable. Can anyone suggest where should I look at? I am running Bitcoin Core 18.0 on a Raspberry 3 connected to a TPLink router. Router Firewall is disabled, UPNP is enabled, Port Forwarding done for 8333 and 18333. What else I should debug to figure out this problem? I am aware that it's not a Bitcoin specific problem, but any help is much appreciated.

Thank you. :)

PS: Also relevant part of my bitcoin.conf file, in case that's helpful.

upnp=1
listen=1
#testnet=1

#Along with clear ip also tell bitcoind that you are using tor
onion=127.0.0.1:9050 

#these are other Tor nodes that will help your node find peers
seednode=nkf5e6b7pl4jfd4a.onion
seednode=xqzfakpeuvrobvpj.onion
seednode=tsyvzsqwa2kkf6b2.onion

#these lines help limit potential DOS attacks over Tor
banscore=10000
bantime=11

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.