Bitcoin Forum
November 15, 2024, 09:50:15 AM *
News: Latest Bitcoin Core release: 28.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1] 2 »  All
  Print  
Author Topic: RAM drive or SSD to hold blockchain.  (Read 3262 times)
Dabs (OP)
Legendary
*
Offline Offline

Activity: 3416
Merit: 1912


The Concierge of Crypto


View Profile
October 26, 2016, 01:55:55 PM
 #1

Serious Question, for those using Bitcoin Core or anything similar that stores the blockchain.

Aside from the very fast speeds, any other advantage to storing the entire blockchain in a RAM drive? I mean, if I have 96 GB of RAM, or 128 GB ...

Or are SSDs "more than enough" ? Can get a 128 GB or 256 / 240 GB SSD just to store the blockchain.

Use case: loading and rescanning different wallets. As in different wallet.dat files. So of course I'm not using pruning mode, I'm keeping the whole chain. If I had the RAM, yeah, it would be so much faster. SSDs, still faster than any mechanical HDD. I just don't know if anyone has tried it yet (maybe the big companies out there have tried it.)

Currently I'm using a slow hard drive, and when I rescan my wallet (which has addresses as far back as 2013) it takes at least 15 minutes before the GUI shows up. If I rescan a newer wallet (with addresses generated in 2016), it still takes about 5 minutes.

Maybe this would be just a "Waste" of RAM. It's just that I am finding a lot of older hardware selling for cheap, with DDR3 or even DDR2 RAM, those are still faster than SSDs.

achow101
Moderator
Legendary
*
expert
Offline Offline

Activity: 3542
Merit: 6886


Just writing some code


View Profile WWW
October 26, 2016, 02:00:38 PM
Merited by ABCbits (1)
 #2

Well a RAM drive would make shutting down the computer a major pain since the entire blockchain would have to be dumped to the disk, unless you want to resync the whole thing every time you start the computers.

An SSD is usually enough. I think one of the bigger bottlenecks is in the CPU.

Carlton Banks
Legendary
*
Offline Offline

Activity: 3430
Merit: 3080



View Profile
October 26, 2016, 03:10:52 PM
 #3

Yep, SSD is sufficient, especially if you get something that isn't impeded by SATA 3 speeds (~550MB/s), or the AHCI software interface. Most 2016 era BIOS'es support NVME and booting from PCI express SSDs. But even something older will benefit from SSD performance.

For the workloads you mentioned, I've been using SSDs for the longest time, I can't actually remember whether I ever tried it with mechanical disks. All I know is that it would mean far too much waiting around, 15 minutes to rescan wallets sounds tortuous. Ramdisk would probably only be practical or cost-effective for miners; you might have a spare PC with 128GB RAM today, but the blockchain can expand anything up to ~ 5 GB per month.

Vires in numeris
veleten
Legendary
*
Offline Offline

Activity: 2016
Merit: 1107



View Profile
November 01, 2016, 04:49:02 AM
 #4

I have my wallet on an old(2005) Toshiba laptop with 256mb RAM and originally 20gb hard drive
bought a very cheap SSD 128 gb for 78$ and now I have a hardware wallet that I only use for storing bitcoins
I connect it to internet once in a while to sync and only use it to check on my precious coins,nothing else

          ▄▄████▄▄
      ▄▄███▀    ▀███▄▄
   ▄████████▄▄▄▄████████▄
  ▀██████████████████████▀
▐█▄▄ ▀▀████▀    ▀████▀▀ ▄▄██
▐█████▄▄ ▀██▄▄▄▄██▀ ▄▄██▀  █
▐██ ▀████▄▄ ▀██▀ ▄▄████  ▄██
▐██  ███████▄  ▄████████████
▐██  █▌▐█ ▀██  ██████▀  ████
▐██  █▌▐█  ██  █████  ▄█████
 ███▄ ▌▐█  ██  ████████████▀
  ▀▀████▄ ▄██  ██▀  ████▀▀
      ▀▀█████  █  ▄██▀▀
         ▀▀██  ██▀▀
.WINDICE.████
██
██
██
██
██
██
██
██
██
██
██
██
████
      ▄████████▀
     ▄████████
    ▄███████▀
   ▄███████▀
  ▄█████████████
 ▄████████████▀
▄███████████▀
     █████▀
    ████▀
   ████
  ███▀
 ██▀
█▀

██
██
██
██
██
██
██
██
██
██
██
██
     ▄▄█████▄   ▄▄▄▄
    ██████████▄███████▄
  ▄████████████████████▌
 ████████████████████████
▐████████████████████████▌
 ▀██████████████████████▀
     ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
     ▄█     ▄█     ▄█
   ▄██▌   ▄██▌   ▄██▌
   ▀▀▀    ▀▀▀    ▀▀▀
       ▄█     ▄█
     ▄██▌   ▄██▌
     ▀▀▀    ▀▀▀

██
██
██
██
██
██
██
██
██
██
██
██
                   ▄█▄
                 ▄█████▄
                █████████▄
       ▄       ██ ████████▌
     ▄███▄    ▐█▌▐█████████
   ▄███████▄   ██ ▀███████▀
 ▄███████████▄  ▀██▄▄████▀
▐█ ▄███████████    ▀▀▀▀
█ █████████████▌      ▄
█▄▀████████████▌    ▄███▄
▐█▄▀███████████    ▐█▐███▌
 ▀██▄▄▀▀█████▀      ▀█▄█▀
   ▀▀▀███▀▀▀
████
  ██
  ██
  ██
  ██
  ██
  ██
  ██
  ██
  ██
  ██
  ██
  ██
████


▄▄████████▄▄
▄████████████████▄
▄████████████████████▄
███████████████▀▀  █████
████████████▀▀      ██████
▐████████▀▀   ▄▄     ██████▌
▐████▀▀    ▄█▀▀     ███████▌
▐████████ █▀        ███████▌
████████ █ ▄███▄   ███████
████████████████▄▄██████
▀████████████████████▀
▀████████████████▀
▀▀████████▀▀
iePlay NoweiI
I
I
I
[/t
Clement Kaliyar
Hero Member
*****
Offline Offline

Activity: 1302
Merit: 532


View Profile
November 01, 2016, 07:48:27 AM
 #5

you might have a spare PC with 128GB RAM today, but the blockchain can expand anything up to ~ 5 GB per month.

if I have 96 GB of RAM, or 128 GB ...

Are you guys talking about 128 GB of RAM  Huh i am using 16 GB of RAM which i thought is superior  Smiley SSD is faster than any mechanical drives but be careful about power outrages when you are using SSD
shorena
Copper Member
Legendary
*
Offline Offline

Activity: 1498
Merit: 1540


No I dont escrow anymore.


View Profile
November 01, 2016, 08:13:23 AM
 #6

you might have a spare PC with 128GB RAM today, but the blockchain can expand anything up to ~ 5 GB per month.

if I have 96 GB of RAM, or 128 GB ...

Are you guys talking about 128 GB of RAM  Huh i am using 16 GB of RAM which i thought is superior  Smiley SSD is faster than any mechanical drives but be careful about power outrages when you are using SSD

Probably on a server, RAM is pretty cheap atm.

Im not really here, its just your imagination.
Zz
Legendary
*
Offline Offline

Activity: 1820
Merit: 1077


View Profile
November 01, 2016, 08:44:25 AM
 #7

seriously? 128GB RAM Smiley

my Desktop system :
Intel Skylake Core i7 6700K 4.0GHz 8MB 1151p
Asus H110M-C DDR4 2133MHz VGA 1151p
Kingston Hyperx S 16GB (2x8) 3000MHz DDR4 HX430C15SB2K2/16
testining on Ubuntu 16.10 dd command.

test units
Seagate Barracuda 3.5 1TB 7200Rpm 64Mb Sata 3 ST1000DM003
Kingston 240GB V300 SSD Disk SV300S37A/240G
and
my ram disk : 8GB

all file systems ext4 (-i 4096MB)

my ram disk setup :
mkdir /ram
mount -t tmpfs -o size=8192M tmpfs /ram


my ram drive write speed :

root@kutaypc:/ram#  dd if=/dev/zero of=./largefile bs=1M count=1024
1024+0 kayıt girdi
1024+0 kayıt çıktı
1073741824 bytes (1,1 GB, 1,0 GiB) copied, 0,326958 s, 3,3 GB/s


my SSD drive write speed :

root@kutaypc:/home#  dd if=/dev/zero of=./largefile bs=1M count=1024
1024+0 kayıt girdi
1024+0 kayıt çıktı
1073741824 bytes (1,1 GB, 1,0 GiB) copied, 0,577785 s, 1,9 GB/s

my HDD drive write speed :

root@kutaypc:/disk2#  dd if=/dev/zero of=./largefile bs=1M count=1024
1024+0 kayıt girdi
1024+0 kayıt çıktı
1073741824 bytes (1,1 GB, 1,0 GiB) copied, 4,60376 s, 233 MB/s


WRITE test results : RAM > SSD > HDD

root@kutaypc:#sh -c "sync && echo 3 > /proc/sys/vm/drop_caches"


my ram drive read speed :
root@kutaypc:/ram# dd if=./largefile of=/dev/null bs=4k
262144+0 kayıt girdi
262144+0 kayıt çıktı
1073741824 bytes (1,1 GB, 1,0 GiB) copied, 0,20474 s, 5,2 GB/s

my SSD drive read speed :
root@kutaypc:/home# dd if=./largefile of=/dev/null bs=4k
262144+0 kayıt girdi
262144+0 kayıt çıktı
1073741824 bytes (1,1 GB, 1,0 GiB) copied, 2,21521 s, 485 MB/s

my HDD drive read speed :
root@kutaypc:/disk2# dd if=./largefile of=/dev/null bs=4k
262144+0 kayıt girdi
262144+0 kayıt çıktı
1073741824 bytes (1,1 GB, 1,0 GiB) copied, 9,81372 s, 109 MB/s

READ test results : RAM > SSD > HDD
shorena
Copper Member
Legendary
*
Offline Offline

Activity: 1498
Merit: 1540


No I dont escrow anymore.


View Profile
November 01, 2016, 02:02:40 PM
 #8

seriously? 128GB RAM Smiley

-snip-

There interesting test results would be:

#1 load blockchain from SSD to RAM-DISK
#2 load new wallet file
#3 let it resync
repeat #2, #3 as needed
(#4) safe updated blockchain from RAM-DISK to SSD for next session

vs.

#1 load new wallet file
#2 let it resync

As achow101 pointed out, the bottleneck might be elsewhere.

Im not really here, its just your imagination.
Dabs (OP)
Legendary
*
Offline Offline

Activity: 3416
Merit: 1912


The Concierge of Crypto


View Profile
November 01, 2016, 05:22:43 PM
Merited by ABCbits (1)
 #9

Yes, lots of RAM on old server hardware, usually off-lease units that are refurbished. Take a look at ebay, or servermonkey.

My test server is currently at 48 GB of RAM. It's only DDR3, so it's not the latest greatest DDR4. It cost me about $600 USD last year. I think RAM for these types of servers is priced at $300 US for every 128 GB. They are also ECC.

I guess I could just buy 2 or 4 SSDs instead, and run them in RAID0.

Grinder
Legendary
*
Offline Offline

Activity: 1284
Merit: 1001


View Profile
November 01, 2016, 05:54:40 PM
 #10

The price per GB is about 20 times higher for the cheapest RAM than it is for the cheapest SSDs. SSDs are much faster at random access than mechanical drives so you'll get a very significant speed up by moving the blockchain to an SSD, more than a simple sequential transfer test would indicate.
Dabs (OP)
Legendary
*
Offline Offline

Activity: 3416
Merit: 1912


The Concierge of Crypto


View Profile
November 01, 2016, 07:10:03 PM
 #11

The price per GB is about 20 times higher for the cheapest RAM than it is for the cheapest SSDs. SSDs are much faster at random access than mechanical drives so you'll get a very significant speed up by moving the blockchain to an SSD, more than a simple sequential transfer test would indicate.

True. But I wouldn't need more RAM than maybe double the size of the blockchain. 96 GB would be cutting it too close, but 128 GB should be fine for at least until next year, 2017.

For most people, (even me) I'd probably just get a 240 GB or larger SSD for "bitcoin purposes". I'm not too concerned about losing my copy, I have at least a few thousand backups online. Smiley

LoyceV
Legendary
*
Offline Offline

Activity: 3500
Merit: 17686


Thick-Skinned Gang Leader and Golden Feather 2021


View Profile WWW
November 03, 2016, 08:17:52 AM
 #12

I have tried it, but with a pruned chain. I can confirm it was faster to download the full blockchain compared to doing the same thing (also pruned) on my SSD. Test results: at the start, it was limited by my Wifi speed (2-3 MB/s), later on it was limited by my CPU (i3).

Obviously I don't have enough ram to do this without pruning, so I can't test a rescan. My HDD takes about 40 minutes to do a full rescan (for instance when I import a private key).
If you're now using a slow HDD, I'd say switching to a SSD is enough for a big improvement. If it reads 500 MB/s, it can read the entire blockchain in 3 minutes.

Personally I only use ram-drives for temporary files. I don't want to have to backup data, although you could argue you can always download it again.

▄▄███████████████████▄▄
▄█████████▀█████████████▄
███████████▄▐▀▄██████████
███████▀▀███████▀▀███████
██████▀███▄▄████████████
█████████▐█████████▐█████
█████████▐█████████▐█████
██████████▀███▀███▄██████
████████████████▄▄███████
███████████▄▄▄███████████
█████████████████████████
▀█████▄▄████████████████▀
▀▀███████████████████▀▀
Peach
BTC bitcoin
Buy and Sell
Bitcoin P2P
.
.
▄▄███████▄▄
▄████████
██████▄
▄██
█████████████████▄
▄███████
██████████████▄
███████████████████████
█████████████████████████
████████████████████████
█████████████████████████
▀███████████████████████▀
▀█████████████████████▀
▀██████████████████▀
▀███████████████▀
▀▀███████▀▀

▀▀▀▀███▀▀▀▀
EUROPE | AFRICA
LATIN AMERICA
▄▀▀▀











▀▄▄▄


███████▄█
███████▀
██▄▄▄▄▄░▄▄▄▄▄
████████████▀
▐███████████▌
▐███████████▌
████████████▄
██████████████
███▀███▀▀███▀
.
Download on the
App Store
▀▀▀▄











▄▄▄▀
▄▀▀▀











▀▄▄▄


▄██▄
██████▄
█████████▄
████████████▄
███████████████
████████████▀
█████████▀
██████▀
▀██▀
.
GET IT ON
Google Play
▀▀▀▄











▄▄▄▀
Grinder
Legendary
*
Offline Offline

Activity: 1284
Merit: 1001


View Profile
November 03, 2016, 10:59:39 AM
 #13

Seems this would be even more expensive than I thought. You need a socket 2011(-3) mainboard to get support for 128 GB or more RAM, which means that both the mainboard and CPU will be more expensive than normal consumer hardware.
Dabs (OP)
Legendary
*
Offline Offline

Activity: 3416
Merit: 1912


The Concierge of Crypto


View Profile
November 03, 2016, 02:27:57 PM
 #14

Seems this would be even more expensive than I thought. You need a socket 2011(-3) mainboard to get support for 128 GB or more RAM, which means that both the mainboard and CPU will be more expensive than normal consumer hardware.
Look at previous generation server hardware or workstations. Good prices for many CPUs and many cores and lots of RAM. (Yes, they will be refurbished or off-lease or old or used.)

calkob
Hero Member
*****
Offline Offline

Activity: 1106
Merit: 521


View Profile
November 03, 2016, 08:40:24 PM
 #15

96GB of ram,,,, wow

i am using 16GB ram and am running a full node on a standard HDD drive, it works fine and i have no problems at all.  Grin
Dabs (OP)
Legendary
*
Offline Offline

Activity: 3416
Merit: 1912


The Concierge of Crypto


View Profile
November 04, 2016, 03:32:02 AM
 #16

I'm currently on a laptop. 8 GB RAM, so you're double what I have. Also slow HDD drive.

Will be "upgrading" to an old refurbished workstation ... comes with 64 GB, should be a big improvement, and more browser tabs (and virtual machines).

shield132
Hero Member
*****
Online Online

Activity: 2408
Merit: 925


Metawin.com - Truly the best casino ever


View Profile
November 04, 2016, 06:45:00 AM
 #17

Well, I know that SSD Hard Drives are very fast and nowdays faster than any other hard drive but why do you need to store blockchain in a RAM drive? I amn't newbie but I can't understand how you can to store something on installed memory (RAM)
I can't understand what you say about RAM but I would say that store blockchain in your SSD, it's good and search time will be fast also with good CPU/RAM.

▄▄███████▄▄
▄██████████████▄
▄██████████████████▄
▄████▀▀▀▀███▀▀▀▀█████▄
▄█████████████▄█▀████▄
███████████▄███████████
██████████▄█▀███████████
██████████▀████████████
▀█████▄█▀█████████████▀
▀████▄▄▄▄███▄▄▄▄████▀
▀██████████████████▀
▀███████████████▀
▀▀███████▀▀
.
 MΞTAWIN  THE FIRST WEB3 CASINO   
.
.. PLAY NOW ..
Dabs (OP)
Legendary
*
Offline Offline

Activity: 3416
Merit: 1912


The Concierge of Crypto


View Profile
November 04, 2016, 01:02:02 PM
 #18

Well, I know that SSD Hard Drives are very fast and nowdays faster than any other hard drive but why do you need to store blockchain in a RAM drive? I amn't newbie but I can't understand how you can to store something on installed memory (RAM)
I can't understand what you say about RAM but I would say that store blockchain in your SSD, it's good and search time will be fast also with good CPU/RAM.
You just said it. RAM drive. Look it up if you don't know what that is. If you're using Windows, you have some app or something, and it eats a chunk of your memory, and you see a new drive letter, say R: or X:, Y:, Z:.

I don't need to answer the "why", ... if it's possible, someone will do it anyway.

Carlton Banks
Legendary
*
Offline Offline

Activity: 3430
Merit: 3080



View Profile
November 04, 2016, 05:15:31 PM
 #19

I don't need to answer the "why", ... if it's possible, someone will do it anyway.

There was definitely a p2pool miner on bitcointalk who ran a Ram drive for his mining rig for a while. It's in the p2pool thread somewhere.

Vires in numeris
shorena
Copper Member
Legendary
*
Offline Offline

Activity: 1498
Merit: 1540


No I dont escrow anymore.


View Profile
November 04, 2016, 07:14:25 PM
 #20

Well, I know that SSD Hard Drives are very fast and nowdays faster than any other hard drive but why do you need to store blockchain in a RAM drive? I amn't newbie but I can't understand how you can to store something on installed memory (RAM)
I can't understand what you say about RAM but I would say that store blockchain in your SSD, it's good and search time will be fast also with good CPU/RAM.
You just said it. RAM drive. Look it up if you don't know what that is. If you're using Windows, you have some app or something, and it eats a chunk of your memory, and you see a new drive letter, say R: or X:, Y:, Z:.

I don't need to answer the "why", ... if it's possible, someone will do it anyway.

I guess the answer to "why?" is "why not?" I have been holding back on this for a while, but I think I will just post how cheap this is. I dont think people understand this from a desktop/laptop perspective. If you have a place to put these loud and heavy boxes and can afford the running cost you can easily get one with enough RAM to support a blockchain.

Heading over to ebay (germany first)... searching for the rack mounted servers category and picking 128 GB(!) RAM gets me:

HP Proliant DL585 G6[1]
price: 429 EUR
CPU: 4*6 = 24 Core 2,6GHz AMD Opteron
RAM: 32*4 GB = 128GB DDR2 (no ECC?)
Just needs a few disks and is good to go

There is even one[2] with similar specs for 349 EUR.

If you are saying "booo, ddr2 sucks", get this[3] one for 774 EUR.

CPU: 2*6 = 12 Core, 2,66Ghz Xeon X5650
RAM: 16*8 = 128 GB DDR3
DISK: 2*300 GB SAS

Same in the UK[4], 8 Cores, 128 GB DDR3, 537 GBP.

and the US[5], 8 Cores, 128 GB DDR3, 569 USD.

[1] http://www.ebay.de/itm/HP-Proliant-DL585-G6-4x-Six-Core-2-6GHz-8435-128GB-RAM-Rackschienen-/401041664720
[2] http://www.ebay.de/itm/HP-ProLiant-DL580-G5-4x-QuadCore-Xeon-E7430-16x-2-13-GHz-128-GB-RAM-4x146-GB-HDD-/112193516338
[3] http://www.ebay.de/itm/IBM-X3550-M3-2x-Xeon-X5650-6-Core-2-66GHz-128GB-RAM-600GB-SAS-HDD-Raid-2x-PSU-/222264199184
[4] http://www.ebay.co.uk/itm/HP-PROLIANT-DL360-G7-SERVER-TWO-E5506-2-13GHZ-128GB-600GB-10K-SAS-P410I-/311732562256
[5] http://www.ebay.com/itm/HP-PROLIANT-DL360-G7-SERVER-TWO-E5506-2-13GHZ-128GB-2-X-146GB-10K-SAS-P410I-/192016881457

Im not really here, its just your imagination.
Pages: [1] 2 »  All
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!