Author

Topic: What is the minimum memory requirements for bitcoind? (Read 2948 times)

copper member
Activity: 1498
Merit: 1528
No I dont escrow anymore.
But if I use "disablewallet=1" the "dbcache=4" option won't reduce the needed amount of RAM, or am I wrong?

(By the way I've upgraded the RAM size to 1024 MB of my VPS and now bitcoind is more responsive, but still far from the perfect!)

I guess my post was too long, sorry Wink

disablewallet=1 disables the wallet cache, which is 1MiB. It won't save you much, but it doesn't hurt.

dbcache=4 decreases the other caches to 4 MiB, which by default total 100 MiB. Setting this too low might decrease performance, though... I don't know what a good number would be, but if DnT and shorena both say 4 is a good starting point, I'd trust them, and then maybe tweak it up a bit if you have any spare ram.

Its a bit unresponsive from time to time yes, but it holds 50 connections without any issues. Its just that the shells scripts I use to query data from bitcoind do not finish sometimes within 30 seconds. This will result in "unknown" values and as a consequence white lines in the pictures the node generates. E.g. last night at ~0050.

hero member
Activity: 672
Merit: 504
a.k.a. gurnec on GitHub
But if I use "disablewallet=1" the "dbcache=4" option won't reduce the needed amount of RAM, or am I wrong?

(By the way I've upgraded the RAM size to 1024 MB of my VPS and now bitcoind is more responsive, but still far from the perfect!)

I guess my post was too long, sorry Wink

disablewallet=1 disables the wallet cache, which is 1MiB. It won't save you much, but it doesn't hurt.

dbcache=4 decreases the other caches to 4 MiB, which by default total 100 MiB. Setting this too low might decrease performance, though... I don't know what a good number would be, but if DnT and shorena both say 4 is a good starting point, I'd trust them, and then maybe tweak it up a bit if you have any spare ram.
newbie
Activity: 50
Merit: 0
I'd imagine setting it down to 4 MiB would have a noticeable affect.


But if I use "disablewallet=1" the "dbcache=4" option won't reduce the needed amount of RAM, or am I wrong?

(By the way I've upgraded the RAM size to 1024 MB of my VPS and now bitcoind is more responsive, but still far from the perfect!)
member
Activity: 114
Merit: 10
PMs blocked, send answers to main.
-snip-

It used to be that Berkeley DB was used for the wallet, block indexes and tx indexes. -dbcache affected the in-memory cache for Berkeley DB. Version 0.8.0 moved the block and tx indexes to Google's LevelDB (it's faster), and kept the wallet in Berkeley DB format (presumably so that the wallet.dat format remained unchanged for backwards compatibility). In 0.8.0, -dbcache affected both the Berkeley DB and LevelDB caches.

The patch referenced above was introduced in 0.8.2, and it modified the -dbcache option so that it only affected the LevelDB caches (since the wallet is relatively small, there shouldn't be any need to adjust it's cache size, so it was hard-coded to 1 MiB). The default -dbache in 0.8.0 was 25 MiB.

Version 0.9.0 increased the default to 100 MiB. It has a hard-coded minimum of 4 MiB (and a maximum of 1 GiB on 32-bit machines, 4 GiB on 64-bit machines). I'd imagine setting it down to 4 MiB would have a noticeable affect.

Makes sense, thanks for the explanation. I was sure I did not imagine it reducing the memory impact, but its almost 6 months now so I wasnt entirely sure.
hero member
Activity: 672
Merit: 504
a.k.a. gurnec on GitHub

I dont know, gmaxwell DnT suggested it when I someone else had problems with memory and it worked like a charm. Let me dig that thread up. See the thread linked below[1]. I remember that it reduced the amount of RAM my node needs, while I had problems with 2 GB before.

It used to be that Berkeley DB was used for the wallet, block indexes and tx indexes. -dbcache affected the in-memory cache for Berkeley DB. Version 0.8.0 moved the block and tx indexes to Google's LevelDB (it's faster), and kept the wallet in Berkeley DB format (presumably so that the wallet.dat format remained unchanged for backwards compatibility). In 0.8.0, -dbcache affected both the Berkeley DB and LevelDB caches.

The patch referenced above was introduced in 0.8.2, and it modified the -dbcache option so that it only affected the LevelDB caches (since the wallet is relatively small, there shouldn't be any need to adjust it's cache size, so it was hard-coded to 1 MiB). The default -dbache in 0.8.0 was 25 MiB.

Version 0.9.0 increased the default to 100 MiB. It has a hard-coded minimum of 4 MiB (and a maximum of 1 GiB on 32-bit machines, 4 GiB on 64-bit machines). I'd imagine setting it down to 4 MiB would have a noticeable affect.
sr. member
Activity: 322
Merit: 250
Writing to dispel society's myths.
Bitcoin-Qt (a.k.a. Bitcoin Core), the reference implementation, is mostly written in C++. There are other clients written in different languages, Python and Java are both popular.

The c++ for a huge softwaer will need about at least 1.5 GB ram to run normally
copper member
Activity: 1498
Merit: 1528
No I dont escrow anymore.

I dont know, gmaxwell DnT suggested it when I someone else had problems with memory and it worked like a charm. Let me dig that thread up. See the thread linked below[1]. I remember that it reduced the amount of RAM my node needs, while I had problems with 2 GB before.

free -m:
Code:
             total       used       free     shared    buffers     cached
Mem:          2048       2018         29          5          0       1592
-/+ buffers/cache:        425       1622
Swap:            0          0          0

[1] https://bitcointalksearch.org/topic/bitcoin-core-uses-a-lot-of-ram-recommended-amount-659040
newbie
Activity: 50
Merit: 0

Code:
disablewallet=1
dbcache=4

Thanks, I'll try these settings.
copper member
Activity: 1498
Merit: 1528
No I dont escrow anymore.
I take it you have port 8333 open; how many connections do you get out of it?

Sure 8333 is open.
Between 20-40.

You could reduce the memory footprint via the confic file.

e.g.

Code:
disablewallet=1
dbcache=4
newbie
Activity: 50
Merit: 0
I take it you have port 8333 open; how many connections do you get out of it?

Sure 8333 is open.
Between 20-40.
legendary
Activity: 1358
Merit: 1001
https://gliph.me/hUF
[...] Do note that SDcard's lifespan will be reduced under heavy load of read and writes.

That's where a cheap external HDD comes in handy.  Wink
legendary
Activity: 3038
Merit: 4418
Crypto Swap Exchange
512mb would be the bare minimum to run Bitcoind. To run it with some connections, try using 1GB of ram. It is not possible to upgrade ram on this version of raspberry pi however. Do note that SDcard's lifespan will be reduced under heavy load of read and writes.
legendary
Activity: 1358
Merit: 1001
https://gliph.me/hUF

It runs, so it's enough.  Grin

I had it running until very recently on a RaspberryPi. Just don't expect to do much else with it.

I take it you have port 8333 open; how many connections do you get out of it?
newbie
Activity: 50
Merit: 0
I've installed bitcoind 0.9.4 on a VPS with 512MB memory (+1024MB swap) but the deamon isn't  too responsive. The full blockchain is already downloaded and it seems to be running stable but it responds to RPC calls very slow, if it all. 512 MB ram isn't enough for it?
Jump to: