Bitcoin Forum
December 11, 2017, 01:07:45 AM *
News: Latest stable version of Bitcoin Core: 0.15.1  [Torrent].
 
   Home   Help Search Donate Login Register  
Pages: [1]
  Print  
Author Topic: Dynamic IP change - incoming connections drop  (Read 1244 times)
loserkids
Member
**
Offline Offline

Activity: 67

Bitcoin = Freedom


View Profile WWW
February 16, 2017, 01:07:58 AM
 #1

I have a spare macbook pro which I dedicated to running full bitcoin node (along with other decentralized services).

I've opened 8333 on my router and got around 20 connections yesterday (I'm still syncing the chain) but after a dynamic IP change this morning, it dropped back to 8 with no incoming traffic whatsoever. The node also appeared offline on bitnodes.21.co.

I found a 2 yo thread describing the same issue so I'm wondering if it was fixed or there's nothing I can do about it (static IP is not a possibility in my case)?

// edit I run 0.13.2

░★░★░★░   freedomnode.com - BTCitcoin, Cryptography & Decentralization   ░★░★░★░
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
1512954465
Hero Member
*
Offline Offline

Posts: 1512954465

View Profile Personal Message (Offline)

Ignore
1512954465
Reply with quote  #2

1512954465
Report to moderator
1512954465
Hero Member
*
Offline Offline

Posts: 1512954465

View Profile Personal Message (Offline)

Ignore
1512954465
Reply with quote  #2

1512954465
Report to moderator
coinableS
Legendary
*
Offline Offline

Activity: 1064



View Profile WWW
February 16, 2017, 01:32:21 AM
 #2

Common issue for nodes or when running a web server from home. Take a look at NOIP dynamic DNS. http://www.noip.com/support/knowledgebase/getting-started-with-no-ip-com/

I have no affiliation with NOIP, but I have used them in the past which is why I'm recommending them as a solution. Good luck!

loserkids
Member
**
Offline Offline

Activity: 67

Bitcoin = Freedom


View Profile WWW
February 16, 2017, 02:07:29 AM
 #3

I already use noip for stats on bitnodes to be visible under a single host regardless of the IP. But how do you setup a node to get use of it?

Can you simply add bind=<my dyndns hostname> to bitcoin.conf?

░★░★░★░   freedomnode.com - BTCitcoin, Cryptography & Decentralization   ░★░★░★░
coinableS
Legendary
*
Offline Offline

Activity: 1064



View Profile WWW
February 16, 2017, 04:40:24 AM
 #4

Just run it on the same machine as your node. It will automatically update every time your router changes it's IP. Other peers will still just connect to the same static IP provided by noip. 

loserkids
Member
**
Offline Offline

Activity: 67

Bitcoin = Freedom


View Profile WWW
February 16, 2017, 11:17:42 AM
 #5

Just run it on the same machine as your node.
What do you mean by "it"? I run NOIP DUC (dynamic updater client) and it updates the IP for my hostname just fine. But I don't think my node is visible on the network as a hostname, but as an IP instead.

░★░★░★░   freedomnode.com - BTCitcoin, Cryptography & Decentralization   ░★░★░★░
piotr_n
Legendary
*
Offline Offline

Activity: 1778


aka tonikt


View Profile WWW
February 16, 2017, 01:54:45 PM
 #6

I don't think setting up dynamic DNS records for his node is going to help him anyhow with this issue.

I don't know much about bitcoin core, but it might have something to do with it being unable to notice your IP changes.
Maybe it's better to ask on the support forum.

Check out gocoin - my original project of full bitcoin node & cold wallet written in Go.
PGP fingerprint: AB9E A551 E262 A87A 13BB  9059 1BE7 B545 CDF3 FD0E
loserkids
Member
**
Offline Offline

Activity: 67

Bitcoin = Freedom


View Profile WWW
February 16, 2017, 01:58:32 PM
 #7

I don't think setting up dynamic DNS records for his node is going to help him anyhow with this issue.

I don't think so either.

I don't know much about bitcoin core, but it might have something to do with it being unable to notice your IP changes.
Maybe it's better to ask on the support forum.
Moved.

░★░★░★░   freedomnode.com - BTCitcoin, Cryptography & Decentralization   ░★░★░★░
0xfff
Full Member
***
Offline Offline

Activity: 224


View Profile
February 16, 2017, 04:02:41 PM
 #8

You could try running the node through a proxy that gives you a static ip address. You could pay a cloud provider like AWS for a very cheap VPS and use that as a proxy.
Real-Duke
Legendary
*
Offline Offline

Activity: 1036



View Profile
February 17, 2017, 01:14:22 PM
 #9

Have had the same issue with 0.13.1 and opened a ticket: https://github.com/bitcoin/bitcoin/issues/9056
Seems I was al alone with this problem so I decided to go back to 0.12.1 what works flawlessy so far.

But this sounds like a solution
Quote
You could try running the node through a proxy that gives you a static ip address. You could pay a cloud provider like AWS for a very cheap VPS and use that as a proxy.

Maybe I try it again this way, thanks!

         ▄███████████████▄
       ▄██▀             ▀██▄
    ▄▄██▀                 ▀██▄▄
█████▀▀       ▄▀▀▀▀▀▀▀▄▄    ▀▀█████
██          ▄▀ ▄▄▄▀▀▀▀▄▀█▄▄      ██
▐█▌       ▄▀ ▄▀ ▄▄▄▀▀▀▄▀▀▀███   ▐█▌
 ██      ▄▀▄▀▄▀▀▄▄▄▀▀▀▀▀█ ▄█▀   ██
 ▐█▌    █▄▀▄▀▄█▀▀▀ ▀█▀ ▄▀▄▀█   ▐█▌
  ██    █▄▀▄▀▄▄█▀ ▄▀ ▄▀▄▀▄▀█   ██
  ▐█▌ ▀▄█████▀▄▄▀▀▄▄▀▄▀▄▀▄▀█  ▐█▌
   ██▌▀████▀██▄▄▀▀▄▄▀▄▀▄▀▄█▀ ▐██
    ██▌▀█▀▀█▄▀▀▄▀▀▄▄▀▄█▄▄█▀ ▐██
     ██▌ ▀  ▀███▄▄▄█████▀  ▐██
      ██▄      ▀▀▀▀▀      ▄██
       ▀██▄             ▄██▀
         ▀██▄         ▄██▀
           ▀██▄     ▄██▀
             ▀███▄███▀
               ▀███▀
.DeepOnion.
★ ★ ★ ★ ★  .❱❱❱ JOIN AIRDROP NOW!.
TOR INTEGRATED & SECURED
★  Your Anonymity Guaranteed
★  Your Assets Secured by TOR
★  Guard Your Privacy!
|Bitcointalk
Reddit
Telegram
|                        ▄▄▀▄▄▀▄▄▀▄▀▀
                    ▄▄██▀█▀▄▀▀▀
                  ▄██▄█▄██▀
                ▄██████▀
              ▄██████▀
  ▄█▄▄▄▄▄▄▄▄▄██████▀
██████▀▀▀▀▀██████▀
 ▀█████  ▄███████
  ████████████▀██
  ██▀███████▀  ██
  ██ ▀████▀    ██
  ██   ▀▀      ██
  ▀█████████████▀
2112
Legendary
*
Online Online

Activity: 1974



View Profile
February 19, 2017, 07:47:55 PM
 #10

The reliable solution to your problem is to periodically restart your Bitcoin Core client.

I'm assuming that you have one of those PPPoE or PPPoA services that force PPP session renegotiation every 24 hours if you not renegotiate earlier on your own. In that case the best solution is to write a script that periodically:

1) shuts down bitcoin{d,-qt} using bitcoin-cli
2) forces PPP session disconnect and reconnect
3) restarts bitcoin{d,-qt}

This has been working reliably for many users for years now, they get decent bandwidth and transaction propagation.

Depending on the specifics of your ISP this script has to be either:

a) run at fixed time of day with a short (e.g. 1 minute) pause between disconnect and reconnect
b) run on a rolling schedule every 22 (or so) hours
c) run twice daily on a fixed schedule (or better twice nightly)

The other possibility is to see if your ISP may be supporting mixed IPv4/IPv6 deployment (oftentimes it just needs appending something in your PPPoE login e.g. "you@yourisp.eu" changes to "you@yourisp.eu/ipv6". In that case the PPP session can stay up for weeks or months at a time and oftentimes reconnecting your PPP session doesn't change the assigned IPv4 & IPv6 addresses. The usual consumer-level dual-stack deployments have limitations on IPv4 connectivity but will give you nearly permanent /64 (or /56) of IPv6 address space. Your incoming Bitcoin connection will be then over IPv6.

Please comment, critique, criticize or ridicule BIP 2112: https://bitcointalk.org/index.php?topic=54382.0
Long-term mining prognosis: https://bitcointalk.org/index.php?topic=91101.0
loserkids
Member
**
Offline Offline

Activity: 67

Bitcoin = Freedom


View Profile WWW
February 22, 2017, 03:09:47 AM
 #11

The reliable solution to your problem is to periodically restart your Bitcoin Core client.
That's what I do with OpenBazaar because they store IPs instead of hostnames in the DHT and I have the exact same problem when my IP changes.

I made this little script for it (in case someone wants to modify it for their bitcoin client):

Code:
#!/bin/sh

# Create log file
LOG="/tmp/ip-check.log"
touch $LOG

IP="$(dig +short myip.opendns.com @resolver1.opendns.com)"
LAST_IP="$(cat $LOG)"

if [ "$IP" != "$LAST_IP" ]; then
    # Save the new IP
    echo "test"
    echo $IP > $LOG

    # Restart OB
    sudo service openbazaar restart
fi

I check for the change every 5 minutes via crontab:

Code:
*/5 * * * * sh /home/user/bin/check.sh >/dev/null 2>&1

The other possibility is to see if your ISP may be supporting mixed IPv4/IPv6 deployment
I checked and my ISP doesn't support IPv6 AFAIK. I'll be restarting my client then.

Thanks!

░★░★░★░   freedomnode.com - BTCitcoin, Cryptography & Decentralization   ░★░★░★░
Pages: [1]
  Print  
 
Jump to:  

Sponsored by , a Bitcoin-accepting VPN.
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!