Pages:
Author

Topic: Bitcoin with Raspberry Pi - page 4. (Read 17780 times)

full member
Activity: 121
Merit: 103
May 03, 2013, 07:35:52 PM
#7
Add more swap, run bitcoind from git.


good point in the other thread about faster arm SoCs.

Quote
A semi-ontopic aside:   If you were thinking about getting a rpi to run bitcoin you will be infinitely happier with a odroid u2: http://www.hardkernel.com/renewal_2011/products/prdt_info.php?g_code=G135341370451  it's much faster than an rpi, _far_ more than just the clockspeed and core count implies.  Failing that, a beaglebone: http://beagleboard.org/Products/BeagleBone%20Black is still close in price and should be more than twice the speed of an rpi while drawing a lot less power.  The rpi is a really handicapped arm, and Bitcoind/bitcoin-qt is designed to be a _full_ participant in the bitcoin network, it's not really meant for small systems. You don't really want to skimp on the cpu power if you don't have to.

due to the hw constraints, maybe try copying the db files, etc, to the rpi from a more powerful machine. that way your disk won't get beat up as badly.
hero member
Activity: 725
Merit: 503
May 03, 2013, 03:29:31 AM
#6
Add more swap, run bitcoind from git.


Doesen't swap wear the SD card?

How do you mean "run bitcoind from git"?

I just built picocoin https://bitcointalksearch.org/topic/m.2014606:

> sudo apt-get install libevent-dev libjansson-dev automake libglib2.0-dev
> wget https://github.com/jgarzik/picocoin/archive/master.zip
> unzip master.zip
> cd picocoin-master
> ./autogen.sh
> ./configure
> make

It doesn't have payment yet, so hold your horses but this could be what I'm looking for!
staff
Activity: 4284
Merit: 8808
May 03, 2013, 03:11:42 AM
#5
Add more swap, run bitcoind from git.
hero member
Activity: 725
Merit: 503
May 03, 2013, 01:10:44 AM
#4
Ok, so bitcoin is terminated after 5 hours by the raspberry OS because of memory:

Code:
May  2 22:19:17 raspberrypi kernel: [46311.694148] net_ratelimit: 422920 callbacks suppressed
May  2 22:19:19 raspberrypi kernel: [46312.180357] kworker/0:0 invoked oom-killer: gfp_mask=0x102d0, order=3, oom_adj=0, oom_score_adj=0
May  2 22:19:19 raspberrypi kernel: [46312.180439] [] (unwind_backtrace+0x0/0xf0) from [] (dump_header.isra.15+0x74/0x1a0)
May  2 22:19:19 raspberrypi kernel: [46312.180490] [] (dump_header.isra.15+0x74/0x1a0) from [] (oom_kill_process+0x294/0x418)
May  2 22:19:19 raspberrypi kernel: [46312.180520] [] (oom_kill_process+0x294/0x418) from [] (out_of_memory+0x1cc/0x29c)
May  2 22:19:19 raspberrypi kernel: [46312.180547] [] (out_of_memory+0x1cc/0x29c) from [] (__alloc_pages_nodemask+0x608/0x63c)
May  2 22:19:19 raspberrypi kernel: [46312.180581] [] (__alloc_pages_nodemask+0x608/0x63c) from [] (cache_alloc_refill+0x338/0x6a0)
May  2 22:19:19 raspberrypi kernel: [46312.180605] [] (cache_alloc_refill+0x338/0x6a0) from [] (__kmalloc+0xc4/0x11c)
May  2 22:19:19 raspberrypi kernel: [46312.180636] [] (__kmalloc+0xc4/0x11c) from [] (__kmalloc_reserve+0x1c/0x64)
May  2 22:19:19 raspberrypi kernel: [46312.180661] [] (__kmalloc_reserve+0x1c/0x64) from [] (__alloc_skb+0x74/0x158)
May  2 22:19:19 raspberrypi kernel: [46312.180683] [] (__alloc_skb+0x74/0x158) from [] (__netdev_alloc_skb+0x98/0xd0)
May  2 22:19:20 raspberrypi kernel: [46312.180712] [] (__netdev_alloc_skb+0x98/0xd0) from [] (rx_submit+0x1c/0x1f8)
May  2 22:19:20 raspberrypi kernel: [46312.180736] [] (rx_submit+0x1c/0x1f8) from [] (kevent+0x210/0x27c)
May  2 22:19:20 raspberrypi kernel: [46312.180761] [] (kevent+0x210/0x27c) from [] (process_one_work+0x150/0x40c)
May  2 22:19:20 raspberrypi kernel: [46312.180784] [] (process_one_work+0x150/0x40c) from [] (worker_thread+0x150/0x498)
May  2 22:19:20 raspberrypi kernel: [46312.180815] [] (worker_thread+0x150/0x498) from [] (kthread+0x88/0x94)
May  2 22:19:20 raspberrypi kernel: [46312.180850] [] (kthread+0x88/0x94) from [] (kernel_thread_exit+0x0/0x8)
May  2 22:19:20 raspberrypi kernel: [46312.180861] Mem-info:
May  2 22:19:20 raspberrypi kernel: [46312.180869] Normal per-cpu:
May  2 22:19:20 raspberrypi kernel: [46312.180879] CPU    0: hi:  186, btch:  31 usd:   0
May  2 22:19:20 raspberrypi kernel: [46312.180903] active_anon:41475 inactive_anon:41483 isolated_anon:0
May  2 22:19:20 raspberrypi kernel: [46312.180903]  active_file:112 inactive_file:181 isolated_file:0
May  2 22:19:20 raspberrypi kernel: [46312.180903]  unevictable:12 dirty:0 writeback:7317 unstable:0
May  2 22:19:20 raspberrypi kernel: [46312.180903]  free:30314 slab_reclaimable:457 slab_unreclaimable:4189
May  2 22:19:20 raspberrypi kernel: [46312.180903]  mapped:100 shmem:0 pagetables:415 bounce:0
May  2 22:19:20 raspberrypi kernel: [46312.180954] Normal free:121256kB min:8192kB low:10240kB high:12288kB active_anon:165900kB inactive_anon:165932kB active_file:448kB inactive_file:724kB unevictable:48kB isolated(anon):0kB isolated(file):0kB present:487680kB mlocked:48kB dirty:0kB writeback:29268kB mapped:400kB shmem:0kB slab_reclaimable:1828kB slab_unreclaimable:16756kB kernel_stack:1288kB pagetables:1660kB unstable:0kB bounce:0kB writeback_tmp:0kB pages_scanned:8387 all_unreclaimable? yes
May  2 22:19:20 raspberrypi kernel: [46312.180968] lowmem_reserve[]: 0 0
May  2 22:19:20 raspberrypi kernel: [46312.180985] Normal: 11514*4kB 6410*8kB 1461*16kB 1*32kB 0*64kB 0*128kB 0*256kB 1*512kB 0*1024kB 0*2048kB 0*4096kB = 121256kB
May  2 22:19:20 raspberrypi kernel: [46312.181029] 7639 total pagecache pages
May  2 22:19:20 raspberrypi kernel: [46312.181037] 7346 pages in swap cache
May  2 22:19:20 raspberrypi kernel: [46312.181046] Swap cache stats: add 43265, delete 35919, find 2742/2832
May  2 22:19:20 raspberrypi kernel: [46312.181052] Free swap  = 0kB
May  2 22:19:20 raspberrypi kernel: [46312.181059] Total swap = 102396kB
May  2 22:19:20 raspberrypi kernel: [46312.208849] 122880 pages of RAM
May  2 22:19:20 raspberrypi kernel: [46312.208874] 30560 free pages
May  2 22:19:20 raspberrypi kernel: [46312.208882] 2558 reserved pages
May  2 22:19:20 raspberrypi kernel: [46312.208888] 4654 slab pages
May  2 22:19:20 raspberrypi kernel: [46312.208894] 221 pages shared
May  2 22:19:20 raspberrypi kernel: [46312.208900] 7346 pages swap cached
May  2 22:19:20 raspberrypi kernel: [46312.208909] [ pid ]   uid  tgid total_vm      rss nr_ptes swapents oom_score_adj name
May  2 22:19:20 raspberrypi kernel: [46312.208963] [  142]     0   142      720        2       5      133         -1000 udevd
May  2 22:19:20 raspberrypi kernel: [46312.208983] [  248]     0   248      719        2       5      137         -1000 udevd
May  2 22:19:20 raspberrypi kernel: [46312.209003] [  270]     0   270      719        2       5      135         -1000 udevd
May  2 22:19:20 raspberrypi kernel: [46312.209020] [ 1411]     0  1411      436       12       4       16         -1000 ifplugd
May  2 22:19:20 raspberrypi kernel: [46312.209037] [ 1440]     0  1440      436       12       5       16         -1000 ifplugd
May  2 22:19:20 raspberrypi kernel: [46312.209055] [ 1684]     0  1684     6992       64       7       49             0 rsyslogd
May  2 22:19:20 raspberrypi kernel: [46312.209071] [ 1716]     0  1716     1223       39       7      391         -1000 dhclient
May  2 22:19:20 raspberrypi kernel: [46312.209088] [ 1764]     0  1764      948       11       5       31             0 cron
May  2 22:19:20 raspberrypi kernel: [46312.209105] [ 1806]   104  1806      794       39       5       34             0 dbus-daemon
May  2 22:19:20 raspberrypi kernel: [46312.209123] [ 1843]   102  1843     1377       29       6       70             0 ntpd
May  2 22:19:20 raspberrypi kernel: [46312.209140] [ 1872]     0  1872     1552       20       6       88         -1000 sshd
May  2 22:19:20 raspberrypi kernel: [46312.209157] [ 1900] 65534  1900      503        6       6       26             0 thd
May  2 22:19:20 raspberrypi kernel: [46312.209173] [ 1911]     0  1911      935        1       6       32             0 getty
May  2 22:19:20 raspberrypi kernel: [46312.209190] [ 1912]     0  1912      935        1       6       32             0 getty
May  2 22:19:20 raspberrypi kernel: [46312.209207] [ 1913]     0  1913      935        1       5       32             0 getty
May  2 22:19:20 raspberrypi kernel: [46312.209223] [ 1914]     0  1914      935        1       5       32             0 getty
May  2 22:19:20 raspberrypi kernel: [46312.209240] [ 1915]     0  1915      935        1       6       32             0 getty
May  2 22:19:20 raspberrypi kernel: [46312.209257] [ 1916]     0  1916      935        1       5       32             0 getty
May  2 22:19:20 raspberrypi kernel: [46312.209286] [ 1917]     0  1917      515        1       4       31             0 getty
May  2 22:19:20 raspberrypi kernel: [46312.209306] [ 1923]     0  1923     6886       80      11      199             0 console-kit-dae
May  2 22:19:20 raspberrypi kernel: [46312.209323] [ 1990]     0  1990     5836       82       9       44             0 polkitd
May  2 22:19:20 raspberrypi kernel: [46312.209342] [ 7086]     0  7086      438        1       6       25             0 mysqld_safe
May  2 22:19:20 raspberrypi kernel: [46312.209359] [ 7437]   107  7437    81073      245      42     6951             0 mysqld
May  2 22:19:20 raspberrypi kernel: [46312.209377] [ 7438]     0  7438      836        1       5       20             0 logger
May  2 22:19:20 raspberrypi kernel: [46312.209394] [ 7810]     0  7810     2451       43       8      118             0 sshd
May  2 22:19:20 raspberrypi kernel: [46312.209410] [ 7817]  1000  7817     2451       75       8      106             0 sshd
May  2 22:19:20 raspberrypi kernel: [46312.209427] [ 7818]  1000  7818     1421      190       6      139             0 bash
May  2 22:19:20 raspberrypi kernel: [46312.209456] [13583]     0 13583      420       18       4        3             0 minissdpd
May  2 22:19:20 raspberrypi kernel: [46312.209476] [14084]  1000 14084   124336    74874     209    16776             0 bitcoind

Is there something one can do to work around this?
hero member
Activity: 725
Merit: 503
May 02, 2013, 07:00:32 AM
#3
Howto compile bitcoind on raspberry pi:

> sudo apt-get install libboost1.50-dev libboost-filesystem1.50-dev libboost-system1.50-dev libboost-program-options1.50-dev libboost-thread1.50-dev libcurl4-openssl-dev libdb5.3++-dev libminiupnpc-dev
> wget https://github.com/bitcoin/bitcoin/archive/master.zip
> unzip master.zip
> cd bitcoin-master/src
> make -f makefile.unix bitcoind

Compilation takes about 1 hour, downloading the blockchain about 20 hours and the bitcoind executable is 43MB!

Other than that it runs really well compared to AWS micro instance, and since RPi colocation is free and AWS micro would be atleast 20$/month with horrible CPU IO wait; this is a nobrainer!

Goodbye AWS!
legendary
Activity: 2058
Merit: 1452
hero member
Activity: 725
Merit: 503
April 30, 2013, 09:11:11 AM
#1
Has anyone compiled bitcoind on the RPi already? Does it work well?
Pages:
Jump to: