Thread: Cheap RAM disk?

Cheap RAM disk?

From
John A Meinel
Date:
I saw a review of a relatively inexpensive RAM disk over at
anandtech.com, the Gigabyte i-RAM
http://www.anandtech.com/storage/showdoc.aspx?i=2480

Basically, it is a PCI card, which takes standard DDR RAM, and has a
SATA port on it, so that to the system, it looks like a normal SATA drive.

The card costs about $100-150, and you fill it with your own ram, so for
a 4GB (max size) disk, it costs around $500. Looking for solid state
storage devices, the cheapest I found was around $5k for 2GB.

Gigabyte claims that the battery backup can last up to 16h, which seems
decent, if not really long (the $5k solution has a built-in harddrive so
that if the power goes out, it uses the battery power to copy the
ramdisk onto the harddrive for more permanent storage).

Anyway, would something like this be reasonable as a drive for storing
pg_xlog? With 4GB you could have as many as 256 checkpoint segments.

I'm a little leary as it is definitely a version 1.0 product (it is
still using an FPGA as the controller, so they were obviously pushing to
get the card into production).

But it seems like this might be a decent way to improve insert
performance, without setting fsync=false.

Probably it should see some serious testing (as in power spikes/pulled
plugs, etc). I know the article made some claim that if you actually
pull out the card it goes into "high consumption mode" which is somehow
greater than if you leave it in the slot with the power off. Which to me
seems like a lot of bull, and really means the 16h is only under
best-case circumstances. But even 1-2h is sufficient to handle a simple
power outage.

And if you had a UPS with detection of power failure, you could always
sync the ramdisk to a local partition before the power goes out. Though
you could do that with a normal in-memory ramdisk (tmpfs) without having
to buy the card. Though it does give you up-to an extra 4GB of ram, for
machines which have already maxed out their slots.

Anyway, I thought I would mention it to the list, to see if anyone else
has heard of it, or has any thoughts on the matter. I'm sure there are
some people who are using more expensive ram disks, maybe they have some
ideas about what this device is missing. (other than costing about
1/10th the price)

John
=:->


Attachment

Re: Cheap RAM disk?

From
Chris Browne
Date:
john@arbash-meinel.com (John A Meinel) writes:
> I saw a review of a relatively inexpensive RAM disk over at
> anandtech.com, the Gigabyte i-RAM
> http://www.anandtech.com/storage/showdoc.aspx?i=2480

And the review shows that it's not *all* that valuable for many of the
cases they looked at.

> Basically, it is a PCI card, which takes standard DDR RAM, and has a
> SATA port on it, so that to the system, it looks like a normal SATA
> drive.
>
> The card costs about $100-150, and you fill it with your own ram, so
> for a 4GB (max size) disk, it costs around $500. Looking for solid
> state storage devices, the cheapest I found was around $5k for 2GB.
>
> Gigabyte claims that the battery backup can last up to 16h, which
> seems decent, if not really long (the $5k solution has a built-in
> harddrive so that if the power goes out, it uses the battery power to
> copy the ramdisk onto the harddrive for more permanent storage).
>
> Anyway, would something like this be reasonable as a drive for storing
> pg_xlog? With 4GB you could have as many as 256 checkpoint segments.
>
> I'm a little leary as it is definitely a version 1.0 product (it is
> still using an FPGA as the controller, so they were obviously pushing
> to get the card into production).

What disappoints me is that nobody has tried the CF/RAM answer; rather
than putting a hard drive on the board, you put on some form of flash
device (CompactFlash or such), where if power fails, it pushes data
onto the CF.  That ought to be cheaper (both in terms of hardware cost
and power consumption) than using a hard disk.

> But it seems like this might be a decent way to improve insert
> performance, without setting fsync=false.

That's the case which might prove Ludicrously Quicker than any of the
sample cases in the review.

> Probably it should see some serious testing (as in power spikes/pulled
> plugs, etc). I know the article made some claim that if you actually
> pull out the card it goes into "high consumption mode" which is
> somehow greater than if you leave it in the slot with the power
> off. Which to me seems like a lot of bull, and really means the 16h is
> only under best-case circumstances. But even 1-2h is sufficient to
> handle a simple power outage.

Certainly.

> Anyway, I thought I would mention it to the list, to see if anyone
> else has heard of it, or has any thoughts on the matter. I'm sure
> there are some people who are using more expensive ram disks, maybe
> they have some ideas about what this device is missing. (other than
> costing about 1/10th the price)

Well, if it hits a "2.0" version, it may get interesting...
--
(format nil "~S@~S" "cbbrowne" "acm.org")
http://www.ntlug.org/~cbbrowne/sap.html
Rules of the Evil Overlord #78.  "I will not tell my Legions of Terror
"And he must  be taken alive!" The command will be:  ``And try to take
him alive if it is reasonably practical.''"
<http://www.eviloverlord.com/>

Re: Cheap RAM disk?

From
"Jeffrey W. Baker"
Date:
On Tue, 2005-07-26 at 11:34 -0500, John A Meinel wrote:
> I saw a review of a relatively inexpensive RAM disk over at
> anandtech.com, the Gigabyte i-RAM
> http://www.anandtech.com/storage/showdoc.aspx?i=2480
>
> Basically, it is a PCI card, which takes standard DDR RAM, and has a
> SATA port on it, so that to the system, it looks like a normal SATA drive.
>
> The card costs about $100-150, and you fill it with your own ram, so for
> a 4GB (max size) disk, it costs around $500. Looking for solid state
> storage devices, the cheapest I found was around $5k for 2GB.
>
> Gigabyte claims that the battery backup can last up to 16h, which seems
> decent, if not really long (the $5k solution has a built-in harddrive so
> that if the power goes out, it uses the battery power to copy the
> ramdisk onto the harddrive for more permanent storage).
>
> Anyway, would something like this be reasonable as a drive for storing
> pg_xlog? With 4GB you could have as many as 256 checkpoint segments.

I haven't tried this product, but the microbenchmarks seem truly slow.
I think you would get a similar benefit by simply sticking a 1GB or 2GB
DIMM -- battery-backed, of course -- in your RAID controller.

-jwb

Re: Cheap RAM disk?

From
Vivek Khera
Date:
On Jul 26, 2005, at 12:34 PM, John A Meinel wrote:

> Basically, it is a PCI card, which takes standard DDR RAM, and has
> a SATA port on it, so that to the system, it looks like a normal
> SATA drive.
>
> The card costs about $100-150, and you fill it with your own ram,
> so for a 4GB (max size) disk, it costs around $500. Looking for
> solid state storage devices, the cheapest I found was around $5k
> for 2GB.
>

gotta love /. don't ya?

This card doesn't accept ECC RAM therefore it is nothing more than a
toy.  I wouldn't trust it as far as I could throw it.

There are other vendors of SSD's out there.  Some even have *real*
power fail strategies such as dumping to a physical disk.  These are
not cheap, but you gets what ya pays for...

Vivek Khera, Ph.D.
+1-301-869-4449 x806



Attachment

Re: Cheap RAM disk?

From
PFC
Date:
> I'm a little leary as it is definitely a version 1.0 product (it is
> still using an FPGA as the controller, so they were obviously pushing to
> get the card into production).

    Not necessarily. FPGA's have become a sensible choice now. My RME studio
soundcard uses a big FPGA.

    The performance in the test doesn't look that good, though, but don't
forget it was run under windows. For instance they get 77s to copy the
Firefox source tree on their Athlon 64/raptor ; my Duron / 7200rpm ide
drive does it in 30 seconds, but not with windows of course.

    However it doesnt' use ECC so... That's a pity, because they could have
implemented ECC in "software" inside the chip, and have the benefits of
error correction with normal, cheap RAM.

    Well; wait and see...

Re: Cheap RAM disk?

From
"Luke Lonergan"
Date:
Yup - interesting and very niche product - it seems like it's only obvious
application is for the Postgresql WAL problem :-)

The real differentiator is the battery backup part.  Otherwise, the
filesystem caching is more effective, so put the RAM on the motherboard.

- Luke



Re: Cheap RAM disk?

From
John A Meinel
Date:
Luke Lonergan wrote:
> Yup - interesting and very niche product - it seems like it's only obvious
> application is for the Postgresql WAL problem :-)

Well, you could do it for any journaled system (XFS, JFS, ext3, reiserfs).

But yes, it seems specifically designed for a battery backed journal.
Though the article reviews it for very different purposes.

Though it was a Windows review, and I don't know of any way to make NTFS
use a separate device for a journal. (Though I expect it is possible
somehow).

John
=:->


>
> The real differentiator is the battery backup part.  Otherwise, the
> filesystem caching is more effective, so put the RAM on the motherboard.
>
> - Luke
>



Attachment

Re: Cheap RAM disk?

From
Alex Turner
Date:
Please see:

http://www.newegg.com/Product/Product.asp?Item=N82E16820145309
and
http://www.newegg.com/Product/Product.asp?Item=N82E16820145416

The price of Reg ECC is not significantly higher than regular ram at
this point.  Plus if you go with super fast 2-2-2-6 then it's actualy
more than good ol 2.5 Reg ECC.

Alex Turner
NetEconomist

On 7/26/05, PFC <lists@boutiquenumerique.com> wrote:
>
> > I'm a little leary as it is definitely a version 1.0 product (it is
> > still using an FPGA as the controller, so they were obviously pushing to
> > get the card into production).
>
>         Not necessarily. FPGA's have become a sensible choice now. My RME studio
> soundcard uses a big FPGA.
>
>         The performance in the test doesn't look that good, though, but don't
> forget it was run under windows. For instance they get 77s to copy the
> Firefox source tree on their Athlon 64/raptor ; my Duron / 7200rpm ide
> drive does it in 30 seconds, but not with windows of course.
>
>         However it doesnt' use ECC so... That's a pity, because they could have
> implemented ECC in "software" inside the chip, and have the benefits of
> error correction with normal, cheap RAM.
>
>         Well; wait and see...
>
> ---------------------------(end of broadcast)---------------------------
> TIP 6: explain analyze is your friend
>

Re: Cheap RAM disk?

From
Alex Turner
Date:
Also seems pretty silly to put it on a regular SATA connection, when
all that can manage is 150MB/sec.  If you made it connection directly
to 66/64-bit PCI then it could actualy _use_ the speed of the RAM, not
to mention PCI-X.

Alex Turner
NetEconomist

On 7/26/05, John A Meinel <john@arbash-meinel.com> wrote:
> I saw a review of a relatively inexpensive RAM disk over at
> anandtech.com, the Gigabyte i-RAM
> http://www.anandtech.com/storage/showdoc.aspx?i=2480
>
> Basically, it is a PCI card, which takes standard DDR RAM, and has a
> SATA port on it, so that to the system, it looks like a normal SATA drive.
>
> The card costs about $100-150, and you fill it with your own ram, so for
> a 4GB (max size) disk, it costs around $500. Looking for solid state
> storage devices, the cheapest I found was around $5k for 2GB.
>
> Gigabyte claims that the battery backup can last up to 16h, which seems
> decent, if not really long (the $5k solution has a built-in harddrive so
> that if the power goes out, it uses the battery power to copy the
> ramdisk onto the harddrive for more permanent storage).
>
> Anyway, would something like this be reasonable as a drive for storing
> pg_xlog? With 4GB you could have as many as 256 checkpoint segments.
>
> I'm a little leary as it is definitely a version 1.0 product (it is
> still using an FPGA as the controller, so they were obviously pushing to
> get the card into production).
>
> But it seems like this might be a decent way to improve insert
> performance, without setting fsync=false.
>
> Probably it should see some serious testing (as in power spikes/pulled
> plugs, etc). I know the article made some claim that if you actually
> pull out the card it goes into "high consumption mode" which is somehow
> greater than if you leave it in the slot with the power off. Which to me
> seems like a lot of bull, and really means the 16h is only under
> best-case circumstances. But even 1-2h is sufficient to handle a simple
> power outage.
>
> And if you had a UPS with detection of power failure, you could always
> sync the ramdisk to a local partition before the power goes out. Though
> you could do that with a normal in-memory ramdisk (tmpfs) without having
> to buy the card. Though it does give you up-to an extra 4GB of ram, for
> machines which have already maxed out their slots.
>
> Anyway, I thought I would mention it to the list, to see if anyone else
> has heard of it, or has any thoughts on the matter. I'm sure there are
> some people who are using more expensive ram disks, maybe they have some
> ideas about what this device is missing. (other than costing about
> 1/10th the price)
>
> John
> =:->
>
>
>
>

Re: Cheap RAM disk?

From
John A Meinel
Date:
Alex Turner wrote:
> Also seems pretty silly to put it on a regular SATA connection, when
> all that can manage is 150MB/sec.  If you made it connection directly
> to 66/64-bit PCI then it could actualy _use_ the speed of the RAM, not
> to mention PCI-X.
>
> Alex Turner
> NetEconomist
>

Well, the whole point is to have it look like a normal SATA drive, even
to the point that you can boot off of it, without having to load a
single driver.

Now, you could offer that you could recreate a SATA controller on the
card, with a SATA bios, etc. And then you could get the increased speed,
and still have bootable functionality.

But it is a version 1.0 of a product, and I'm sure they tried to make it
as cheap as possible (and within their own capabilities.)

John
=:->


Attachment

Re: Cheap RAM disk?

From
Michael Stone
Date:
On Tue, Jul 26, 2005 at 11:23:23AM -0700, Luke Lonergan wrote:
>Yup - interesting and very niche product - it seems like it's only obvious
>application is for the Postgresql WAL problem :-)

On the contrary--it's not obvious that it is an ideal fit for a WAL. A
ram disk like this is optimized for highly random access applications.
The WAL is a single sequential writer. If you're in the kind of market
that needs a really high performance WAL you'd be much better served by
putting a big NVRAM cache in front of a fast disk array than by buying a
toy like this.

Mike Stone

Re: Cheap RAM disk?

From
Richard_D_Levine@raytheon.com
Date:
> you'd be much better served by
> putting a big NVRAM cache in front of a fast disk array

I agree with the point below, but I think price was the issue of the
original discussion.  That said, it seems that a single high speed spindle
would give this a run for its money in both price and performance, and for
the same reasons Mike points out.  Maybe a SCSI 160 or 320 at 15k, or maybe
even something slower.

Rick

pgsql-performance-owner@postgresql.org wrote on 07/26/2005 01:33:43 PM:

> On Tue, Jul 26, 2005 at 11:23:23AM -0700, Luke Lonergan wrote:
> >Yup - interesting and very niche product - it seems like it's only
obvious
> >application is for the Postgresql WAL problem :-)
>
> On the contrary--it's not obvious that it is an ideal fit for a WAL. A
> ram disk like this is optimized for highly random access applications.
> The WAL is a single sequential writer. If you're in the kind of market
> that needs a really high performance WAL you'd be much better served by
> putting a big NVRAM cache in front of a fast disk array than by buying a
> toy like this.
>
> Mike Stone
>
> ---------------------------(end of broadcast)---------------------------
> TIP 2: Don't 'kill -9' the postmaster


Re: Cheap RAM disk?

From
Chris Browne
Date:
jwbaker@acm.org ("Jeffrey W. Baker") writes:
> I haven't tried this product, but the microbenchmarks seem truly
> slow.  I think you would get a similar benefit by simply sticking a
> 1GB or 2GB DIMM -- battery-backed, of course -- in your RAID
> controller.

Well, the microbenchmarks were pretty pre-sophomoric, essentially
trying to express how the device would be useful to a Windows user
that *might* play games...

I'm sure it's hurt by the fact that it's using a SATA ("version 1")
interface rather than something faster.

Mind you, I'd like to see the product succeed, because they might come
up with a "version 2" of it that is what I'd really like...
--
(format nil "~S@~S" "cbbrowne" "acm.org")
http://www.ntlug.org/~cbbrowne/sap.html
Rules of the Evil Overlord #78.  "I will not tell my Legions of Terror
"And he must  be taken alive!" The command will be:  ``And try to take
him alive if it is reasonably practical.''"
<http://www.eviloverlord.com/>