Pages:
Author

Topic: bitcoind for synology nas (ARM) (Read 21127 times)

newbie
Activity: 14
Merit: 0
June 25, 2017, 07:48:22 AM
#28
Hi, has anyone tried to compile with success bitcoind for nas synology DS211j (arm)?
I'm going crazy!


That looks quite promising. A bit techy, but seems like it can be pulled off.
Still, I'd have to put quite a few pieces together myself and I'm not really interested in downloading someone else's work as this would be a perfect place to implement a trojan horse to empty the wallet.
In my opinion the perfect scenario would be if the Bitcoin team officially offered this as a downloaded package I could trust, but that's probably pretty far down on their TODO list.
sr. member
Activity: 362
Merit: 262
June 21, 2017, 05:56:02 AM
#27
Assuming you are running another node who's output you trust you could use the assumevalid option to speed things up perhaps:

Quote
assumevalid=   If this block is in the chain assume that it and its ancestors are valid and potentially skip their script verification (0 to verify all, default: 00000000000000000013176bf8d7dfeab4e1db31dc93bc311b436e82ab226b90, testnet: 00000000000128796ee387cf110ccb9d2f36cffaf7f73079c995377c65ac0dcc)
You would specify a more recent block than the default of course.

Or also copy over an up to date blockchain directory from a node you trust.

newbie
Activity: 2
Merit: 0
June 17, 2017, 02:33:34 PM
#26
I still have a try on this moment although it's nothing worth trying at all  Tongue

I originally want to save the power/time from syncing data, which use my DS115j to get latest blickchain files 24/7 and docking my laptop with faster synchronization when needed.

so I didn't compile wallet and gui(qt) in my case.

here's my platform:
VMWare Ubuntu 64 bit 16.04 netboot only with openssh
Host CPU: 4 of 8 core intel xeon E3-1505M v5
MEM: 4GB

and here's the processes, and it's taking about 20 minutes
Code:

# unnecessary installation but useful
apt-get install sudo ssh vim ntpdate screen htop iftop nmap bzip2

# compiling tools
apt-get install make binutils xutils-dev libc6-i386

# cross compiling tools
apt-get install g++-arm-linux-gnueabihf curl

# bitcoin needed
apt-get install git-core autotools-dev automake pkg-config bsdmainutils build-essential autoconf libssl-dev libboost-dev libboost-chrono-dev libboost-filesystem-dev libboost-program-options-dev libboost-system-dev libboost-test-dev libboost-thread-dev libtool libevent-dev

# bitcoin optional
apt-get install miniupnpc libminiupnpc-dev libzmq3-dev

# create working dir
cd ~
mkdir ds115j
WDIR=/root/ds115j
DIST=$WDIR/dist

# prepare your toolchain file to working dir (says xvf armada370-gcc493_glibc220_hard-GPL.txz is for DS115j in my case)
cd $WDIR
tar xvf armada370-gcc493_glibc220_hard-GPL.txz

# setting the variables
cd $WDIR
export PATH="${WDIR}/arm-unknown-linux-gnueabi/bin:${PATH}"
export CC="${WDIR}/arm-unknown-linux-gnueabi/bin/arm-unknown-linux-gnueabi-gcc"
export CXX="${WDIR}/arm-unknown-linux-gnueabi/bin/arm-unknown-linux-gnueabi-g++"
export AR="${WDIR}/arm-unknown-linux-gnueabi/bin/arm-unknown-linux-gnueabi-ar"
export LD="${WDIR}/arm-unknown-linux-gnueabi/bin/arm-unknown-linux-gnueabi-ld"
export RANLIB="${WDIR}/arm-unknown-linux-gnueabi/bin/arm-unknown-linux-gnueabi-ranlib"
export CFLAGS="-I${WDIR}/arm-unknown-linux-gnueabi/arm-unknown-linux-gnueabi/include"
export LDFLAGS="-L${WDIR}/arm-unknown-linux-gnueabi/arm-unknown-linux-gnueabi/lib"
export LINK=$CXX

# specify your target version of bitcoin (says 0.14.1 in my case)
export ver=0.14.1

# cross compiling related tools
cd $WDIR
git clone -b v${ver} https://github.com/bitcoin/bitcoin
cd bitcoin/depends
make HOST=arm-linux-gnueabihf NO_QT=1 NO_WALLET=1 -j4

# cross compiling bitcoin
cd ..
./autogen.sh
LDFLAGS="-static-libstdc++" \
./configure \
--prefix=`pwd`/depends/arm-linux-gnueabihf \
--enable-upnp-default \
--enable-glibc-back-compat \
--enable-reduce-exports \
--disable-wallet \
--with-gui=no
make -j4
make install

# packing
cd depends
mv arm-linux-gnueabihf bitcoin-${ver}-arm-linux-gnueabihf
tar -c ./bitcoin-${ver}-arm-linux-gnueabihf/ | gzip -9 > ./bitcoin-${ver}-arm-linux-gnueabihf.tar.gz


after that, you can copy your bitcoin-${ver}-arm-linux-gnueabihf.tar.gz to the DS115j
legendary
Activity: 3430
Merit: 3080
January 29, 2015, 07:59:08 AM
#25
I am interested in continue this topic because I try to install a Bitcoin node in a Synology and it is the nearest information to do it that I have found.

If someone has new information about this I will feel happy if he/she shares with us.

I'll try to follow this guide step by step and I will tell here my progress.

I gave up on this idea.  My ARM-based synology has only 512 MB of RAM.  This is less than what bitcoind used to take on my desktop.  Maybe it is better now.

If you run the configure script with --disable-wallet, make will build a bitcoind executable that consumes only ~200 MB RAM.

The processor will still get tortured by the verification. Possibly the use of Intel low power chips with libsecp256k (the Bitcoin Core developed crypto library) verification code could make this sort of idea more practicable, but it'd be wise to wait until that code is being used in the main client (apparently the library is only used for signing txs in 0.10.0)
full member
Activity: 217
Merit: 259
January 29, 2015, 06:50:42 AM
#24
I am interested in continue this topic because I try to install a Bitcoin node in a Synology and it is the nearest information to do it that I have found.

If someone has new information about this I will feel happy if he/she shares with us.

I'll try to follow this guide step by step and I will tell here my progress.

I gave up on this idea.  My ARM-based synology has only 512 MB of RAM.  This is less than what bitcoind used to take on my desktop.  Maybe it is better now. Still the ARM processor is slow and it will take a long time to catch up with the block chain (if it will catch up at all).  Maybe one can "pre-index" the blockchain by copying the .bitcoin/blocks directory from another computer.  I'm not sure if the index can be ported over to a different architecture, though.

I thought about making a non-verifying bitcoind that just stores the blockchain without doing any checking at all (or at least avoid the most expensive ones, like signature and UTXO checking).  Then use an SPV client that connects to this bitcoind.  This avoids leaking any information about the transactions you are requesting and it still has the security of SPV.  I haven't started doing anything in this direction, though.

If you have a x86-based synology with 2 GB of RAM then you should be able to run bitcoind out of the box.
sr. member
Activity: 323
Merit: 250
January 28, 2015, 01:50:17 PM
#23
Hi.
I am interested in continue this topic because I try to install a Bitcoin node in a Synology and it is the nearest information to do it that I have found.

If someone has new information about this I will feel happy if he/she shares with us.

I'll try to follow this guide step by step and I will tell here my progress.

Thanks.
Doe
legendary
Activity: 1960
Merit: 1012
SELL bitcoinmarket.net | bitcoinitalia.com SELL
January 28, 2013, 11:22:53 AM
#22
Arrived at block 19967 !
it's hard!  Tongue
full member
Activity: 126
Merit: 100
January 28, 2013, 11:13:15 AM
#21
Any news? Is it working? Smiley
legendary
Activity: 1960
Merit: 1012
SELL bitcoinmarket.net | bitcoinitalia.com SELL
December 25, 2012, 03:19:36 AM
#20
use Plex.
I want to see if it will decrease the use, when bitcoind end of download ... we will see ..
donator
Activity: 1419
Merit: 1015
December 24, 2012, 07:39:09 PM
#19
When you say video streaming do you mean Plex or Video Station? That's too bad about RAM usage, but I'm actually thinking of upgrading my NAS. I can especially justify it if it can host the blockchain for me!
legendary
Activity: 1960
Merit: 1012
SELL bitcoinmarket.net | bitcoinitalia.com SELL
December 24, 2012, 05:41:16 PM
#18
Hello, I had to stop because, as you can see from the post above, the version I had compiled was the ultra-prune and was clobbered.
Now I have compiled 0.7.2 and began again to download the blockchain. At this time are the block number 15432. At the download has worked 100% cpu but now it is the ram that is consumed much.
My nas use it as a video straming and while doing this work, I just finished looking at the film "The Watch" without a hint of problems ..  Wink
donator
Activity: 1419
Merit: 1015
December 24, 2012, 11:49:04 AM
#17
Holy crap ziomik. That's awesome. How long did it run at 100% CPU before it finished verifying the blockchain? I'm tempted to give this a shot.
legendary
Activity: 1960
Merit: 1012
SELL bitcoinmarket.net | bitcoinitalia.com SELL
December 23, 2012, 11:52:34 AM
#16
solution is recompiled new build.  Cheesy
legendary
Activity: 1960
Merit: 1012
SELL bitcoinmarket.net | bitcoinitalia.com SELL
December 23, 2012, 08:28:11 AM
#15
Help.....  Cry

debug.log

Code:
Default data directory /root/.bitcoin                             
Used data directory /volume1/.bitcoin/                             
dbenv.open LogDir=/volume1/.bitcoin/database ErrorFile=/volume1/.bitcoin/db.log
Bound to [::]:8333                                                             
Bound to 0.0.0.0:8333                                                         
Loading block index...                                                         
Opening LevelDB in /volume1/.bitcoin/blktree                                   
Opened LevelDB successfully                                                   
Opening LevelDB in /volume1/.bitcoin/coins                                     
Opened LevelDB successfully                                                   
LoadBlockIndex(): last block file = 18                                         
LoadBlockIndex(): last block file: CBlockFileInfo(blocks=1051, size=90935905, heights=192137..193187, time=2012-08-03..2012-08-10)
LoadBlockIndex(): hashBestChain=000000000019d6689c08  height=0 date=01/03/09 18:15:05                                             
Verifying last 0 blocks at level 1                                                                                               
 block index           35045ms                                                                                                   
Loading wallet...                                                                                                                 
nFileVersion = 79900                                                                                                             
 wallet                16219ms                                                                                                   
ERROR: CheckProofOfWork() : nBits below minimum work                                                                             
ERROR: CBlock::ReadFromDisk() : errors in block header                                                                           
ERROR: SetBestBlock() : ReadFromDisk for connect failed                                                                           
Loading addresses...                                                                                                             
Loaded 118 addresses from peers.dat  22ms                                                                                         
mapBlockIndex.size() = 193188                                                                                                     
nBestHeight = 0                                                                                                                   
setKeyPool.size() = 101                                                                                                           
mapWallet.size() = 0                                                                                                             
mapAddressBook.size() = 4                                                                                                         
Done loading                                                                                                                     
Bitcoin: Failed to connect best block                                                                                             
Flush(false)                                                                                                                     
wallet.dat refcount=0                                                                                                             
wallet.dat checkpoint                                                                                                             
ThreadRPCServer started                                                                                                           
send version message: version 60002, blocks=0, us=0.0.0.0:0, them=0.0.0.0:0, peer=127.0.0.1:0                                     
ThreadIRCSeed exited                                                                         
ThreadSocketHandler started                                                                 
ThreadOpenAddedConnections started                                                           
ThreadOpenAddedConnections exited                                                           
ThreadOpenConnections started                                                               
ThreadMessageHandler started                                                                 
ThreadMessageHandler exited                                                                 
ThreadDumpAddress exited                                                                     
ThreadDNSAddressSeed started                                                                 
Loading addresses from DNS seeds (could take a while)                                       
ThreadRPCServer exited                                                                       
wallet.dat detach                                                                           
ThreadSocketHandler exited                                                                   
wallet.dat closed                                                                           
DBFlush(false) ended              77ms                                                       
StopNode()                                                                                   
GetMyExternalIP() received [xxx.xxx.xxx.xxx] xxx.xxx.xxx.xxx:0                                   
GetMyExternalIP() returned xxx.xxx.xxx.xxx                                                     
AddLocal(95.228.138.78:8333,5)                                                               
ThreadOpenConnections exited                                                                 
Added 31 addresses from 178.18.90.41: 0 tried, 149 new                                       
Added 24 addresses from 173.242.112.53: 0 tried, 173 new                                     
120 addresses found from DNS seeds                                                           
ThreadDNSAddressSeed exited                               
Flushed 173 addresses to peers.dat  123ms                 
Committing 0 changed transactions to coin database...     
Flush(true)                                               
DBFlush(true) ended               0ms                     
Bitcoin exited     
legendary
Activity: 1960
Merit: 1012
SELL bitcoinmarket.net | bitcoinitalia.com SELL
November 10, 2012, 07:16:53 AM
#14
I have a strange answer bitcoind running. I have not found solutions. Aid?
Code:
./bitcoind -datadir=/volume1/.bitcoin/
Bitcoin: Failed to connect best block
legendary
Activity: 1960
Merit: 1012
SELL bitcoinmarket.net | bitcoinitalia.com SELL
October 24, 2012, 01:02:31 AM
#13
The purpose is not to generate bitcoin, but having a personal wallet I'll put on the network and will manage through the web wherever I am.
full member
Activity: 196
Merit: 100
October 23, 2012, 09:48:47 PM
#12
Why bother, all you would do is increase the CPU temp of the synology , causing it to NOT enter the sleep mode, thereby using MORE electricity than you can earn from generating bitcoins.

HC
legendary
Activity: 980
Merit: 1008
October 23, 2012, 04:21:56 PM
#11
Yes, you are running the ultra-prune version.

I was just letting you know that there have been reports of this version corrupting wallets, and that it's a fairly big code change, so it might not be as stable as the official releases. So if you want to run bleeding edge, this is the version to get. If you want stable, it might be better to grab an official release like 0.7.1 and building that.
legendary
Activity: 1960
Merit: 1012
SELL bitcoinmarket.net | bitcoinitalia.com SELL
October 23, 2012, 02:32:45 PM
#10
Isn't the  ultra-prune in action. I downloaded the sources from the official github..
Code:
git clone https://github.com/bitcoin/bitcoin.git
Maybe I misunderstood, what you want to tell me?   Undecided
legendary
Activity: 980
Merit: 1008
October 23, 2012, 01:53:23 PM
#9
Looks like it downloaded 640 MB in 24 hours. But I don't think it verifies any transactions until block 190,000 (the latest check point). After that it will probably slow down significantly.

Also, note that you seem to be running the ultra-prune version (which you should, since it has been merged to main), which has been known to corrupt wallets. Just a heads up.
Pages:
Jump to: