Bitcoin Forum
December 09, 2016, 07:33:30 PM *
News: Latest stable version of Bitcoin Core: 0.13.1  [Torrent].
 
   Home   Help Search Donate Login Register  
Pages: [1]
  Print  
Author Topic: bash-script for users with dynamic IP to restart bitcoin  (Read 1460 times)
molecular
Donator
Legendary
*
Offline Offline

Activity: 2142



View Profile
March 07, 2011, 01:50:51 PM
 #1

I wrote a little bash a while back, because I'm on a dynamic ip connection and bitcoin doesn't behave so nicely with changing IPs. (see https://github.com/bitcoin/bitcoin/issues#issue/48 for more info (while the gui still displays connections, the node may in fact be disconnected)).
Since I still wanted to mine solo, I wrote this script.

I've been using it for 6 weeks now, have been mining solo using it for 2 weeks now without problem and I thought it's ripe for sharing:

http://pastebin.com/tFJwFwns

It works by comparing an "official blockcount" (e.g. from blockexplorer.com) with the local one from rpc interface.

To use it, you should check/edit some variables at the beginning of the script: BITCOIN_BIN, PING_HOST and OFFICIAL_URL
Then just go ahead and run it.
If you want, you can also adjust some timing variables.

Feedback is welcome, also symbolic (0.01 BTC or so) donations to the address in my signature are of course appreciated and also good for your karma Wink

PGP key molecular F9B70769 fingerprint 9CDD C0D3 20F8 279F 6BE0  3F39 FC49 2362 F9B7 0769
1481312010
Hero Member
*
Offline Offline

Posts: 1481312010

View Profile Personal Message (Offline)

Ignore
1481312010
Reply with quote  #2

1481312010
Report to moderator
1481312010
Hero Member
*
Offline Offline

Posts: 1481312010

View Profile Personal Message (Offline)

Ignore
1481312010
Reply with quote  #2

1481312010
Report to moderator
1481312010
Hero Member
*
Offline Offline

Posts: 1481312010

View Profile Personal Message (Offline)

Ignore
1481312010
Reply with quote  #2

1481312010
Report to moderator
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
1481312010
Hero Member
*
Offline Offline

Posts: 1481312010

View Profile Personal Message (Offline)

Ignore
1481312010
Reply with quote  #2

1481312010
Report to moderator
1481312010
Hero Member
*
Offline Offline

Posts: 1481312010

View Profile Personal Message (Offline)

Ignore
1481312010
Reply with quote  #2

1481312010
Report to moderator
1481312010
Hero Member
*
Offline Offline

Posts: 1481312010

View Profile Personal Message (Offline)

Ignore
1481312010
Reply with quote  #2

1481312010
Report to moderator
DarkMatter
Member
**
Offline Offline

Activity: 86


Stop breeding! Save the Earth! www.vhemt.org


View Profile WWW
March 09, 2011, 01:36:24 PM
 #2

The post is old, and I've not seen this issue since a quite long time.
Guess it has been fixed in most recent client releases.

Feed The Troll!! | 1JKdTyUjxo5VJoaQKjp4oUnXqdSSErC1mp
Lardie
Newbie
*
Offline Offline

Activity: 18


View Profile
March 11, 2011, 07:28:09 PM
 #3

Yesterday I was disconnected from the internet for a couple of hours and the Bitcoin gui still showed 15 connections and my miner was still buzzing away.  Huh
DarkMatter
Member
**
Offline Offline

Activity: 86


Stop breeding! Save the Earth! www.vhemt.org


View Profile WWW
March 14, 2011, 06:16:53 PM
 #4

The post is old, and I've not seen this issue since a quite long time.
Guess it has been fixed in most recent client releases.

Ehm, I forgot to give you the deserved credit for the script, looks very nice Smiley

Feed The Troll!! | 1JKdTyUjxo5VJoaQKjp4oUnXqdSSErC1mp
snedie
Member
**
Offline Offline

Activity: 112


View Profile
March 14, 2011, 11:59:43 PM
 #5

Yesterday I was disconnected from the internet for a couple of hours and the Bitcoin gui still showed 15 connections and my miner was still buzzing away.  Huh

Well the miner will simply continue to process the current work it has been given until it either finishes it or is told to stop.
molecular
Donator
Legendary
*
Offline Offline

Activity: 2142



View Profile
March 16, 2011, 01:10:01 PM
 #6

The post is old, and I've not seen this issue since a quite long time.
Guess it has been fixed in most recent client releases.

Ehm, I forgot to give you the deserved credit for the script, looks very nice Smiley

Thanks!

And: the issue (https://github.com/bitcoin/bitcoin/issues#issue/48) is not solved. There's new comments now.

BlueMatt looked into it and we chatted a bit yesterday on #bitcoin-dev. It seems it will need some serious debugging. I'm trying to help him as much as I can (testing).

PGP key molecular F9B70769 fingerprint 9CDD C0D3 20F8 279F 6BE0  3F39 FC49 2362 F9B7 0769
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!