NuBits 2.1.1 Release

I just received my RaPi3; will install Raspbian, compile nud and sync blockchain from scratch - at least if I find out how to merge the pull requests…

Would it be possible to merge them into a branch that can just be checked out? That’d be great for not so skilled people like me.

But as it might take some time until I have my RaPi3 running, the reuqests might already have been pulled into the repo.
Will keep you updated!

when you’re in the nubits folder you can just run:

git fetch origin
git checkout 2.1.1-RC
git merge origin/fix_download_misbehaving
git merge origin/change_blockmap_cleanup

from there you can compile it as you normally would.

Thank you!
Bookmarked your post!

I know this has been a very tough nut to crack. I just wanted to say that I appreciate everything you guys are doing to figure it out. We should all celebrate once we have it solved! :smile:

Compiled with those two fixes and started from scratch.
Stuck at block 8,776:

2016-03-16 11:38:56 Nu version v2.1.1-RC1-4-g6919854-dirty-beta (2016-03-16 10:38:01 +0000)
2016-03-16 11:38:56 Using OpenSSL version OpenSSL 1.0.1k 8 Jan 2015
2016-03-16 11:38:56 Default data directory /home/pi/.nu
2016-03-16 11:38:56 Using data directory /home/pi/.nu
2016-03-16 11:38:56 Using at most 125 connections (65536 file descriptors available)
2016-03-16 11:38:56 Using 4 threads for script verification
2016-03-16 11:38:56 init message: Verifying wallet...
2016-03-16 11:38:56 dbenv.open LogDir=/home/pi/.nu/database ErrorFile=/home/pi/.nu/db.log
2016-03-16 11:38:56 Bound to [::]:9090
2016-03-16 11:38:56 Bound to 0.0.0.0:9090
2016-03-16 11:38:56 init message: Loading block index...
2016-03-16 11:38:56 Opening LevelDB in /home/pi/.nu/blocks/index
2016-03-16 11:38:56 Opened LevelDB successfully
2016-03-16 11:38:56 Opening LevelDB in /home/pi/.nu/chainstate
2016-03-16 11:38:56 Opened LevelDB successfully
2016-03-16 11:38:56 Nu Network: genesis=0x000003cc2da5a0a289ad nBitsLimit=0x1e0fffff nBitsInitial=0x1e00ffff nStakeMinAge=604800 nCoinbaseMaturity=100 nCoinstakeMaturity=5000 nModifierInterval=14400
2016-03-16 11:38:56 LoadBlockIndexDB(): last block file = 0
2016-03-16 11:38:56 LoadBlockIndexDB(): synchronized checkpoint not read
2016-03-16 11:38:56 LoadBlockIndexDB(): synchronized checkpoint 000003cc2da5a0a289ad0a590c20a8b975219ddc1204efd169e947dd4cbad73f
2016-03-16 11:38:56 LoadBlockIndexDB(): transaction index disabled
2016-03-16 11:38:56 Initializing databases...
2016-03-16 11:38:56 Nu Genesis Block Found:
2016-03-16 11:38:56 genesis hash=000003cc2da5a0a289ad0a590c20a8b975219ddc1204efd169e947dd4cbad73f
2016-03-16 11:38:56 merkle root=3e6c2608685f1d66d8fe9cb798400ec16aec1574b7ad9a7a92a65c7fcea2d32a
2016-03-16 11:38:56 CBlock(hash=000003cc2da5a0a289ad0a590c20a8b975219ddc1204efd169e947dd4cbad73f, ver=1, hashPrevBlock=0000000000000000000000000000000000000000000000000000000000000000, hashMerkleRoot=3e6c2608685f1d66d8fe9cb798400ec16aec1574b7ad9a7a92a65c7fcea2d32a, nTime=1407023435, nBits=1e0fffff, nNonce=1542387, vtx=1, vchBlockSig=)
2016-03-16 11:38:56   Coinbase(hash=3e6c2608685f1d66d8fe9cb798400ec16aec1574b7ad9a7a92a65c7fcea2d32a, unit=S, nTime=1407023435, ver=1, vin.size=1, vout.size=1, nLockTime=0)
    CTxIn(COutPoint(0000000000000000000000000000000000000000000000000000000000000000, 4294967295), coinbase 04ffff001d020f274c4c323031342d30382d30313a2057687920417267656e74696e6127732064656661756c74206665656c73206c696b6520416d65726963616e2062756c6c79696e673a20446f6e20506974746973)
    CTxOut(empty)
  vMerkleTree: 3e6c2608685f1d66d8fe9cb798400ec16aec1574b7ad9a7a92a65c7fcea2d32a
2016-03-16 11:38:56 End Nu Genesis Block
2016-03-16 11:38:56 000003cc2da5a0a289ad0a590c20a8b975219ddc1204efd169e947dd4cbad73f
2016-03-16 11:38:56 000003cc2da5a0a289ad0a590c20a8b975219ddc1204efd169e947dd4cbad73f
2016-03-16 11:38:56 3e6c2608685f1d66d8fe9cb798400ec16aec1574b7ad9a7a92a65c7fcea2d32a
2016-03-16 11:38:56 CBlock(hash=000003cc2da5a0a289ad0a590c20a8b975219ddc1204efd169e947dd4cbad73f, ver=1, hashPrevBlock=0000000000000000000000000000000000000000000000000000000000000000, hashMerkleRoot=3e6c2608685f1d66d8fe9cb798400ec16aec1574b7ad9a7a92a65c7fcea2d32a, nTime=1407023435, nBits=1e0fffff, nNonce=1542387, vtx=1, vchBlockSig=)
2016-03-16 11:38:56   Coinbase(hash=3e6c2608685f1d66d8fe9cb798400ec16aec1574b7ad9a7a92a65c7fcea2d32a, unit=S, nTime=1407023435, ver=1, vin.size=1, vout.size=1, nLockTime=0)
    CTxIn(COutPoint(0000000000000000000000000000000000000000000000000000000000000000, 4294967295), coinbase 04ffff001d020f274c4c323031342d30382d30313a2057687920417267656e74696e6127732064656661756c74206665656c73206c696b6520416d65726963616e2062756c6c79696e673a20446f6e20506974746973)
    CTxOut(empty)
  vMerkleTree: 3e6c2608685f1d66d8fe9cb798400ec16aec1574b7ad9a7a92a65c7fcea2d32a
2016-03-16 11:38:56 Pre-allocating up to position 0x1000000 in blk00000.dat
2016-03-16 11:38:56 SetBestChain: new best=000003cc2da5a0a289ad0a590c20a8b975219ddc1204efd169e947dd4cbad73f  height=0  log2_trust=0  moneysupply(S)=0.00  moneysupply(B)=0.00  tx=1  date=2014-08-02 23:50:35 progress=0.000000
2016-03-16 11:38:56 ResetSyncCheckpoint: pending for sync-checkpoint 11b331cb1e5ba525fdcd5915aa47ee9dc0ca79337e634beabc7be21b1e23b5b4
2016-03-16 11:38:56 ResetSyncCheckpoint: sync-checkpoint reset to 000003cc2da5a0a289ad0a590c20a8b975219ddc1204efd169e947dd4cbad73f
2016-03-16 11:38:56 init message: Verifying blocks...
2016-03-16 11:38:56  block index             151ms
2016-03-16 11:38:56 init message: Loading wallets...
2016-03-16 11:38:56 Loading wallet for unit S...
2016-03-16 11:38:58 nFileVersion = 2010100
2016-03-16 11:38:58  wallet                 2197ms
2016-03-16 11:38:58 Loading wallet for unit B...
2016-03-16 11:38:58 nFileVersion = 2010100
2016-03-16 11:38:58  wallet                   27ms
2016-03-16 11:38:58 init message: Loading addresses...
2016-03-16 11:38:58 ERROR: CAddrman::Read() : open failed
2016-03-16 11:38:58 Invalid or missing peers.dat; recreating
2016-03-16 11:38:58 Loaded 0 addresses from peers.dat  0ms
2016-03-16 11:38:58 mapBlockIndex.size() = 1
2016-03-16 11:38:58 nBestHeight = 0
2016-03-16 11:38:58 wallet S:
2016-03-16 11:38:58 setKeyPool.size() = 101
2016-03-16 11:38:58 mapWallet.size() = 0
2016-03-16 11:38:58 mapAddressBook.size() = 1
2016-03-16 11:38:58 wallet B:
2016-03-16 11:38:58 setKeyPool.size() = 101
2016-03-16 11:38:58 mapWallet.size() = 3
2016-03-16 11:38:58 mapAddressBook.size() = 4
2016-03-16 11:38:58 addcon thread start
2016-03-16 11:38:58 dnsseed thread start
2016-03-16 11:38:58 Loading addresses from DNS seeds (could take a while)
2016-03-16 11:38:58 0 addresses found from DNS seeds
2016-03-16 11:38:58 dnsseed thread exit
2016-03-16 11:38:58 net thread start
2016-03-16 11:38:58 dumpaddr thread start
2016-03-16 11:38:58 opencon thread start
2016-03-16 11:38:58 msghand thread start
2016-03-16 11:38:58 trying connection 104.156.247.229:7890 lastseen=377257.9hrs
2016-03-16 11:38:58 ThreadUpdateFromDataFeed started
2016-03-16 11:38:58 ThreadStakeMinter started
2016-03-16 11:38:58 PeerMiner started for proof-of-stake
2016-03-16 11:38:58 init message: Done loading
2016-03-16 11:38:58 ERROR: CTxMemPool::accept() : currency coinbase as individual tx
2016-03-16 11:38:58 ERROR: CTxMemPool::accept() : currency coinbase as individual tx
2016-03-16 11:38:58 AddToWallet d5a2ddf0d69de9f4a26577a9f4ad2cb3cd6e70421e2d9c7dc6568ffef581481f
2016-03-16 11:38:58 connected 104.156.247.229:7890
2016-03-16 11:38:58 send version message: version 2000000, blocks=0, us=0.0.0.0:0, them=104.156.247.229:7890, peer=104.156.247.229:7890
2016-03-16 11:38:59 Added 10 addresses from 127.0.0.1: 0 tried, 10 new
2016-03-16 11:38:59 trying connection 128.199.96.127:7890 lastseen=314.6hrs
2016-03-16 11:38:59 trying connection 104.238.165.61:7890 lastseen=377257.9hrs
2016-03-16 11:38:59 connected 104.238.165.61:7890
2016-03-16 11:38:59 send version message: version 2000000, blocks=0, us=0.0.0.0:0, them=104.238.165.61:7890, peer=104.238.165.61:7890
2016-03-16 11:38:59 connect() failed after select(): Connection refused
2016-03-16 11:38:59 trying connection 104.239.228.107:7890 lastseen=377257.9hrs
2016-03-16 11:38:59 trying connection 104.239.228.107:7890 lastseen=225.1hrs
2016-03-16 11:38:59 connect() failed after select(): No route to host
2016-03-16 11:39:00 connect() failed after select(): No route to host
2016-03-16 11:39:00 GetMyExternalIP() received [obfuscated] obfuscated:0
2016-03-16 11:39:00 GetMyExternalIP() returned obfuscated
2016-03-16 11:39:00 AddLocal(obfuscated:9090,4)
2016-03-16 11:39:00 trying connection 192.237.200.146:7890 lastseen=377257.9hrs
2016-03-16 11:39:00 trying connection 176.9.113.75:7890 lastseen=178.4hrs
2016-03-16 11:39:00 connect() failed after select(): Connection refused
2016-03-16 11:39:01 trying connection 212.129.19.120:7890 lastseen=203.5hrs
2016-03-16 11:39:01 connected 212.129.19.120:7890
2016-03-16 11:39:01 send version message: version 2000000, blocks=0, us=obfuscated:9090, them=212.129.19.120:7890, peer=212.129.19.120:7890
2016-03-16 11:39:01 Added time data, samples 2, offset -1 (+0 minutes)
2016-03-16 11:39:01 Moving 212.129.19.120:7890 to tried
2016-03-16 11:39:01 receive version message: /Siglee:2.0.3/Nu:2.0.3v2.0.3beta/: version 2000000, blocks=790591, us=obfuscated:45632, them=212.129.19.120:7890, peer=212.129.19.120:7890
2016-03-16 11:39:02 trying connection 104.239.228.107:7890 lastseen=225.1hrs
2016-03-16 11:39:02 received block 000000dd8d2f2c2945217064dbe4126278406c42b411c0cf072f9e6831ecaeb1
2016-03-16 11:39:02 connect() failed after select(): No route to host
2016-03-16 11:39:02 Pre-allocating up to position 0x100000 in rev00000.dat
2016-03-16 11:39:02 SetBestChain: new best=000000dd8d2f2c2945217064dbe4126278406c42b411c0cf072f9e6831ecaeb1  height=1  log2_trust=1  moneysupply(S)=2500000.00  moneysupply(B)=0.00  tx=2  date=2014-08-03 17:44:14 progress=0.000000
2016-03-16 11:39:02 ProcessBlock: ACCEPTED
2016-03-16 11:39:02 IsInitialBlockDownload 1, nBestHeight 1
2016-03-16 11:39:02 received block 00000055b07aca0c9ef5c401fd66ce01667f9f9a2bdbe3750ba497042dce0814
2016-03-16 11:39:02 SetBestChain: new best=00000055b07aca0c9ef5c401fd66ce01667f9f9a2bdbe3750ba497042dce0814  height=2  log2_trust=1.5849625  moneysupply(S)=5000000.00  moneysupply(B)=0.00  tx=3  date=2014-08-03 17:44:36 progress=0.000000
2016-03-16 11:39:02 ProcessBlock: ACCEPTED
2016-03-16 11:39:02 IsInitialBlockDownload 1, nBestHeight 2
2016-03-16 11:39:02 received block 0000001a9f348eb4c772137ec6047931692d9aa2bd15a2cc675c767a536d1ef0
2016-03-16 11:39:02 SetBestChain: new best=0000001a9f348eb4c772137ec6047931692d9aa2bd15a2cc675c767a536d1ef0  height=3  log2_trust=2  moneysupply(S)=7500000.00  moneysupply(B)=0.00  tx=4  date=2014-08-03 17:44:45 progress=0.000000
2016-03-16 11:39:02 ProcessBlock: ACCEPTED

[...]
2016-03-16 11:50:38 SetBestChain: new best=13175c28c1031022c93fb583ce7ee81769c904b56754a5bd51a7d605c14c1467  height=8757  log2_tru
st=33.028861  moneysupply(S)=1000328670.00  moneysupply(B)=0.00  tx=17326  date=2014-09-08 18:22:22 progress=0.000056
2016-03-16 11:50:38 SetBestChain: new best=919805596d08f3717843619db96504b60d6003492aa41e32087338d74979d152  height=8758  log2_tru
st=33.029034  moneysupply(S)=1000328710.00  moneysupply(B)=0.00  tx=17328  date=2014-09-08 18:24:27 progress=0.000056
2016-03-16 11:50:38 SetBestChain: new best=aff1fe88461b685ffdc14f73043b7427678a61e666f93aca3ac8154f835b49d6  height=8759  log2_tru
st=33.029206  moneysupply(S)=1000328750.00  moneysupply(B)=0.00  tx=17330  date=2014-09-08 18:24:59 progress=0.000056
2016-03-16 11:50:38 SetBestChain: new best=2c8e61dd171f8794a484fd039f73716322fb964086ae723162fd4dc95eed81e7  height=8760  log2_tru
st=33.029379  moneysupply(S)=1000328790.00  moneysupply(B)=0.00  tx=17332  date=2014-09-08 18:27:17 progress=0.000056
2016-03-16 11:50:38 SetBestChain: new best=6f597c3a163a99a8778526cf26e2a9fb9c68542b29fc78e2be3e5997e83a2745  height=8761  log2_tru
st=33.029551  moneysupply(S)=1000328830.00  moneysupply(B)=0.00  tx=17334  date=2014-09-08 18:37:06 progress=0.000056
2016-03-16 11:50:38 SetBestChain: new best=b6738774a663c4ceb660e2980a34f600bd6cb5e56031798cddb6f97a28280d43  height=8762  log2_tru
st=33.029724  moneysupply(S)=1000328870.00  moneysupply(B)=0.00  tx=17336  date=2014-09-08 18:40:29 progress=0.000056
2016-03-16 11:50:38 SetBestChain: new best=f65e17b779a76ce43b8b8462e161686b099d7d87fcbf6a3cac342311145bad2e  height=8763  log2_tru
st=33.029896  moneysupply(S)=1000328910.00  moneysupply(B)=0.00  tx=17338  date=2014-09-08 18:41:10 progress=0.000056
2016-03-16 11:50:38 SetBestChain: new best=9dd3c96c80795344bbda98eed51e008bed6f1e23f16543ee8cb060ed8cce89a9  height=8764  log2_tru
st=33.030069  moneysupply(S)=1000328950.00  moneysupply(B)=0.00  tx=17340  date=2014-09-08 18:41:03 progress=0.000056
2016-03-16 11:50:38 SetBestChain: new best=28a162cb8f2ec552bb8f60710c59d8f3c385a1e5aa6b0ae84a028e2df6476f00  height=8765  log2_tru
st=33.030241  moneysupply(S)=1000328990.00  moneysupply(B)=0.00  tx=17342  date=2014-09-08 18:41:38 progress=0.000056
2016-03-16 11:50:38 SetBestChain: new best=6baddb6094f2cda1398f646197ec9bf72bec57feae2f86d139ec7329dd0eabfe  height=8766  log2_tru
st=33.030414  moneysupply(S)=1000329030.00  moneysupply(B)=0.00  tx=17344  date=2014-09-08 18:42:05 progress=0.000056
2016-03-16 11:50:38 SetBestChain: new best=79923672543486069f40092c1ed2e70fc4cc11449bf7b8b5b660c5f22a5195c3  height=8767  log2_tru
st=33.030586  moneysupply(S)=1000329070.00  moneysupply(B)=0.00  tx=17346  date=2014-09-08 18:42:18 progress=0.000056
2016-03-16 11:50:39 SetBestChain: new best=4abe27a905815e6c32bb5d4656d1b58f44fa21e285ea298a84cf988c4a51560b  height=8768  log2_tru
st=33.030759  moneysupply(S)=1000329110.00  moneysupply(B)=0.00  tx=17348  date=2014-09-08 18:43:29 progress=0.000056
2016-03-16 11:50:39 SetBestChain: new best=6aeade35024342fbb7f6055433a09057c585fd7fc15eba51ba37162104779e34  height=8769  log2_tru
st=33.030931  moneysupply(S)=1000329150.00  moneysupply(B)=0.00  tx=17350  date=2014-09-08 18:45:13 progress=0.000056
2016-03-16 11:50:39 SetBestChain: new best=1ec4187c0ea80ca9edfd3bad107593dc56c86173cf8ee278dbf8dbb684be8cc9  height=8770  log2_tru
st=33.031104  moneysupply(S)=1000329190.00  moneysupply(B)=0.00  tx=17352  date=2014-09-08 18:50:26 progress=0.000056
2016-03-16 11:50:39 SetBestChain: new best=e603e2c542a7030f60507eb7440a4953237573e121ac8e165617ff4f86bb04c4  height=8771  log2_trust=33.031276  moneysupply(S)=1000329230.00  moneysupply(B)=0.00  tx=17354  date=2014-09-08 18:54:42 progress=0.000056
2016-03-16 11:50:39 SetBestChain: new best=68917053c35b6acc1dfe5bdee61ab84d0c5e671e317de2ab032968b87a338f6a  height=8772  log2_trust=33.031448  moneysupply(S)=1000329270.00  moneysupply(B)=0.00  tx=17356  date=2014-09-08 19:00:20 progress=0.000056
2016-03-16 11:50:39 SetBestChain: new best=326236c31145186b4a57ad8d53913c2999476b6b27103022c71dc801fa72596c  height=8773  log2_trust=33.031621  moneysupply(S)=1000329310.00  moneysupply(B)=0.00  tx=17358  date=2014-09-08 19:05:29 progress=0.000056
2016-03-16 11:50:39 SetBestChain: new best=1d720b9bafe6b24a1b612f2393f52ebd1b5b7bd7dc035ed878115f133e007d9e  height=8774  log2_trust=33.031793  moneysupply(S)=1000329350.00  moneysupply(B)=0.00  tx=17360  date=2014-09-08 19:08:41 progress=0.000056
2016-03-16 11:50:39 SetBestChain: new best=4636e873ee6972015421bcee666ab5b07a4432cffd0b3d02d6718908e8d692be  height=8775  log2_trust=33.031965  moneysupply(S)=1000329390.00  moneysupply(B)=0.00  tx=17362  date=2014-09-08 19:09:33 progress=0.000056
2016-03-16 11:50:39 SetBestChain: new best=9cbac54812a73402b92a2d60c735665a263934314b1e2495290a2506ba3a2754  height=8776  log2_trust=33.032138  moneysupply(S)=1000329430.00  moneysupply(B)=0.00  tx=17364  date=2014-09-08 19:09:56 progress=0.000056
2016-03-16 11:50:39 ProcessBlock: ACCEPTED
2016-03-16 11:50:39 IsInitialBlockDownload 1, nBestHeight 8776
2016-03-16 11:50:39 received block 293d11cf4e566d44baad4f22fc5a1c74925099461c30e93bad39646eea89023f
2016-03-16 11:50:39 ProcessBlock: ORPHAN BLOCK, prev=bdfda1a40987de3d77fe
2016-03-16 11:50:39 IsInitialBlockDownload 1, nBestHeight 8776
2016-03-16 11:50:39 received block dd5ee75551016aa53e8b5972d836bcbf7b154c86cb0ff5d7d56df691f5e62659
2016-03-16 11:50:39 ProcessBlock: ORPHAN BLOCK, prev=293d11cf4e566d44baad
2016-03-16 11:50:39 IsInitialBlockDownload 1, nBestHeight 8776
2016-03-16 11:50:39 received block 11e35055f154653cfa3482675bd4f3e5efa46d74261ffcad036a151fffafaa09
2016-03-16 11:50:39 ProcessBlock: ORPHAN BLOCK, prev=74b22a4263d02f469feb
2016-03-16 11:50:39 IsInitialBlockDownload 1, nBestHeight 8776
2016-03-16 11:50:39 received block 34b4ccdb82b8f0b110e80f81a432b76d8db22571ab0b5d59136f4041d9ce7dbd
2016-03-16 11:50:39 ProcessBlock: ORPHAN BLOCK, prev=dd5ee75551016aa53e8b
2016-03-16 11:50:39 IsInitialBlockDownload 1, nBestHeight 8776
2016-03-16 11:50:39 received block 4ea4dfa082fd4d07354a0d59c397bdec7ede0a2728dcf85c7ccaec2a3fbdd42e
2016-03-16 11:50:39 ProcessBlock: ORPHAN BLOCK, prev=34b4ccdb82b8f0b110e8
2016-03-16 11:50:39 IsInitialBlockDownload 1, nBestHeight 8776
2016-03-16 11:50:39 received block 9f93de576413c0908f84a56b42c34f548fb47395b6ef5f85a40de10f451d025f
2016-03-16 11:50:39 ProcessBlock: ORPHAN BLOCK, prev=4ea4dfa082fd4d07354a
2016-03-16 11:50:39 IsInitialBlockDownload 1, nBestHeight 8776
2016-03-16 11:50:39 received block ca626009e43c10b14e3d2d7193454deb19d359216c23745e3a72200420b2ce56
2016-03-16 11:50:39 ProcessBlock: ORPHAN BLOCK, prev=11e35055f154653cfa34
2016-03-16 11:50:39 IsInitialBlockDownload 1, nBestHeight 8776
2016-03-16 11:50:39 received block 2971436d338b3978a5c916e37d0f0d71c2f2ed9b7dcba86dde14d905356de734
2016-03-16 11:50:39 ProcessBlock: ORPHAN BLOCK, prev=ca626009e43c10b14e3d
2016-03-16 11:50:39 IsInitialBlockDownload 1, nBestHeight 8776
2016-03-16 11:50:39 received block 46e953591f5194efb0139c3622fd2ca3f9661d9938ebd53867d8bf19ebebbf50
2016-03-16 11:50:39 ProcessBlock: ORPHAN BLOCK, prev=2971436d338b3978a5c9
etc.

Really sorry. I was going to update you with this new information. There’s a branch that contains all of the proposed fixes.

can you reset your local repo

git reset --hard 2.1.1-RC

and then merge the branch above? Start the process over from that client.

sigh :stuck_out_tongue:
Compiling on my RaPi takes some time.
Will do it anyway :wink:

btw. restarting nud recovered the block download. Should I rather continue for now?

tail ~/.nu/debug.log
2016-03-16 13:11:37 ProcessBlock: ORPHAN BLOCK, prev=8229df0b4e64d4dd6341
2016-03-16 13:11:37 IsInitialBlockDownload 1, nBestHeight 20123
2016-03-16 13:11:37 received block a576932343a290f098b07f57efc7af8a37050cd39108ec09a927cf7d6309051e
2016-03-16 13:11:37 SetBestChain: new best=a576932343a290f098b07f57efc7af8a37050cd39108ec09a927cf7d6309051e  height=20124  log2_trust=34.269372  moneysupply(S)=1000782735.00  moneysupply(B)=2036449.84  tx=40096  date=2014-09-23 13:44:07 progress=0.000130
2016-03-16 13:11:37 ProcessBlock: ACCEPTED
2016-03-16 13:11:37 IsInitialBlockDownload 1, nBestHeight 20124
2016-03-16 13:11:37 received block b8f363677902c0d152a5e0d97e4d4f5dc473e9ebde42348c778d3a90484934ea
2016-03-16 13:11:37 ProcessBlock: ORPHAN BLOCK, prev=7066ef56e2e318f5c15a
2016-03-16 13:11:37 IsInitialBlockDownload 1, nBestHeight 20124
2016-03-16 13:11:37 received block 2ed6fe4ea776e107567b33e1831041f01520e6adac3b80bef26093f581b68134

RAM usage is impressively low (percentages of 1 GB RAM):

  PID USER      PR  NI    VIRT    RES    SHR S  %CPU %MEM     TIME+ COMMAND
10529 pi        20   0  294512  72304   8492 S 100.1  7.3  28:40.35 nud
1 Like

You can if you like, I just think the branch has included some extra changes imported from bitcoins codebase. I don’t have time to verify at the moment. You should still notice a difference from the pull requests you merged though.

The download_optimizations_r2 patch includes the two aforementioned patches (dont-penalize-parent-nodes and revised-blockmap-cleanup) as well a few more optimizations – including another one that also tries to keep memory usage low.

In my tests, a full blockchain download on a computer with an SSD took under 12 hours, and the memory usage stayed under 1 GB, and was faster than 2.0.3. Much better, but there still look to be some memory leaks, since on a restart the memory usage goes back down even when managing the same dataset.

The orphans are an artifact of how the blockchain download works. And in response to an earlier post, yes this was improved in Bitcoin, but also brought with it a protocol change. The orphans are not ideal, but also not wasteful since they are held in queue and eventually melded into the known blockchain.

3 Likes

I stumbled upon a strange behaviour which renders using version 2.1.1 together with NuBot (I’ve tried 0.3.2a and 0.4.1) impossible.

Although I compiled nud with “IPv4 only” (in makefile.unix:):

# :=1 --> Enable IPv6 support
# :=0 --> Disable IPv6 support
USE_IPV6:=0

it looks like nud opens sockets at both IPv4 and IPv6:
(when starting the compiled application):

2016-03-17 16:42:14 init message: Verifying wallet...
2016-03-17 16:42:14 dbenv.open LogDir=/home/pi/.nu/database ErrorFile=/home/pi/.nu/db.log
2016-03-17 16:42:14 Bound to [::]:9090
2016-03-17 16:42:14 Bound to 0.0.0.0:9090

There’s more evidence for that:

netstat -l
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address           Foreign Address         State
tcp        0      0 *:9090                  *:*                     LISTEN
tcp        0      0 *:ssh                   *:*                     LISTEN
tcp6       0      0 [::]:9090               [::]:*                  LISTEN
tcp6       0      0 [::]:9091               [::]:*                  LISTEN
tcp6       0      0 [::]:9092               [::]:*                  LISTEN
tcp6       0      0 [::]:ssh                [::]:*                  LISTEN
[...]

Unfortunately the RPC port (9091) seems to be open only on IPv6.

This leads to this error message when trying to connect NuBot to nud via RPC:

[...]
16:51:13.313 [main] INFO  - Setting up RPC client on 127.0.0.1:9091 [com.nubits.nubot.tasks.TaskManager:64]
16:51:13.327 [main] INFO  - Starting task : Check connection with Nud [com.nubits.nubot.tasks.TaskManager:75]
16:51:13.331 [main] INFO  - Started BotTask checkNud [com.nubits.nubot.tasks.BotTask:57]
16:51:13.331 [checkNud] INFO  - Executing class com.nubits.nubot.tasks.CheckNudTask [com.nubits.nubot.tasks.CheckNudTask:37]
16:51:13.827 [main] INFO  - BotTask [sendLiquidity] will start in 40s, and run it every 130s [com.nubits.nubot.tasks.BotTask:63]
16:51:13.832 [main] ERROR - can't connect to Nu com.nubits.nubot.bot.NuBotConnectionException: Problem with nud connectivity [c.n.n.l.MainLaunch:173]

Any ideas how to fix that?
For the time being I can continue to use 2.0.3 (although I’d prefer 2.1.1 because of the lesser RAM consumption).
I’d like to get it fixed anyway.

edit:
I should add that I defined port and rpcport settings in nu.conf (9090, 9091).
Without these settings, port 7890 gets selected as default by nud; the rpcport should be 7891 then, right?
From the debug.log (without specified port and rpcport):

2016-03-18 08:46:50 init message: Verifying wallet...
2016-03-18 08:46:50 dbenv.open LogDir=/home/pi/.nu/database ErrorFile=/home/pi/.nu/db.log
2016-03-18 08:46:50 Bound to [::]:7890
2016-03-18 08:46:50 Bound to 0.0.0.0:7890
2016-03-18 08:46:50 init message: Loading block index...

I realized that it’s not only the nud version, that is differently (2.0.3 <-> 2.1.1), but the Raspbian version as well (wheezy <-> jessie). Could it be related to that as well?

In fact I don’t care that nud opens ports on IPv6 (despite having compiled with USE_IPV6:=0, of course!).
What troubles me is that there’s no RPC port open on IPv4.
How to make nud open RPC port on IPv4?

3 Likes

I’m looking for some community members that would like to help test some changes going into 2.1.1. You would need to have a linux box and experience in compiling the client from source code. If anyone has a bit of time to help please let me know here.

I’m not in the position to do that now, but if you provide me with a test plan and the branch that shall be compiled, I’ll try as soon as I can.

I might have the time after 12 hrs or so. Please post what’s needed to be done.

Checkout the 2.1.1-RC branch. Merge this branch into it. Compile the QT and try to sync from scratch.

I’m looking to get feedback on the stability of the client while syncing from scratch. Note if it crashes, .and if there are any mentions of “error” in the debug.log. Any feedback would be appreciated.

Is QT really necessary? I think so, because you write it.
It’s just that I operate my RaspberryPis headless and have no experience with compiling QT…

You can try it headless.The code changes aren’t QT specific. I wanted to compare my experiences with others using the QT but go ahead and try with the daemon.

can you provide the exact commands that i can copy and paste on a linux box?
btw I don’t know how to get qt to compile.

I highly recommend to use an Ubuntu virtual machine with VirtualBox and do this inside the VM. It makes sure you’re using a clean environment and installed dependencies will not impact your personal setup.

Dependencies:

sudo apt-add-repository ppa:bitcoin/bitcoin -y

sudo apt-get update
sudo apt-get install git build-essential g++ libssl-dev libboost-all-dev libdb4.8++-dev libqrencode-dev qt4-qmake libqt4-dev libcurl4-openssl-dev -y

Clone NuBits repo, checkout branch, compile

git clone https://bitbucket.org/JordanLeePeershares/nubit.git

cd nubit

git checkout 2.1.1-RC

git merge origin/download_optimizations_r2

qmake USE_UPNP=-

make

Should take a bit, but in the nubit directory you’ll have a fresh nu binary. Run it and let it sync.

2 Likes

$ git merge download_optimizations_r2
fatal: ‘download_optimizations_r2’ does not point to a commit

try

git merge origin/download_optimizations_r2