Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save bitkevin/f831afd413946d32e965 to your computer and use it in GitHub Desktop.
Save bitkevin/f831afd413946d32e965 to your computer and use it in GitHub Desktop.
# Install bitcoind
## build bitcoind
mkdir -p ~/source; cd ~/source
wget https://github.com/bitcoin/bitcoin/archive/v0.9.2.tar.gz
tar zxvf v0.9.2; cd bitcoin-0.9.2
## open-nodes.org_hub-v0.9.2.patch
wget https://gist.githubusercontent.com/bitkevin/a1b4a556fffce6fc527a/raw/ -O open-nodes.org_hub-v0.9.2.patch
patch -p1 < open-nodes.org_hub-v0.9.2.patch
## make
./autogen.sh
./configure --without-miniupnpc --disable-wallet
make -j4
strip src/bitcoind
cp src/bitcoind /usr/local/bin/bitcoind-0.9.2
cd /usr/local/bin
ln -s ./bitcoind-0.9.2 bitcoind
cd ~/source
## setup bitcoind
# `/d1/bitcoind` is the home dir for bitcoind.
mkdir -p /d1/bitcoind/
useradd bitcoind
chown bitcoind.bitcoind /d1/bitcoind
su - bitcoind
echo 'rpcuser=opennodesorg
rpcpassword=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
rpcthreads=32
rpcallowip=*
datadir=/d1/bitcoind
txindex=true
limitdownloadblocks=2016
maxconnections=4096
outboundconnections=3072
' > /d1/bitcoind/bitcoin.conf
### _Don't forget to change **rpcpassword**_. ###
## supervise for bitcoind
mkdir ~/supervise_bitcoind
cd ~/supervise_bitcoind
touch run
chmod +x run
echo '#! /bin/sh
SROOT=$(cd $(dirname "$0"); pwd)
cd $SROOT
bitcoind -conf=/d1/bitcoind/bitcoin.conf
' > run
## start bitcoind
# cd ~/
# nohup supervise supervise_bitcoind/ &
@yjzll
Copy link

yjzll commented Jul 24, 2014

请问是不是在树莓派下运行?我也在树莓派下成功编译了0.8.6和0.9版,但都出现运行问题,表现为bitcoind运行节点,出现ss命令下Recv-Q值不断升高,而bitcoind却sleep状态

@bitkevin
Copy link
Author

@yjzll 没在树莓派下测试,目前仅在CentOS下测试

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment