18 comments

[ 5.2 ms ] story [ 40.3 ms ] thread
For several months I have a 500MB tmpfs ramdisk (which I will probably turn into a ramfs one after reading that article).

I put my browser cache, several logging files and other volatile things there. Whenever I download something just to dispose it later, it goes in there. If I try something stupid with a lot files or some big ones, it goes in there.

It feels much nicer than to fragment the harddisk for such things; maybe it is just a placebo but it makes me happy. And of course access and usage of those files is blazing fast.

PS: Having Opera's temporary download directory automatically wiped away alone is worth it... :)

(comment deleted)
I do this too. But tmpfs (why do you want to use ramfs?)

I call it /tmp-ram and I give it the same drwxrwxrwt permissions as /tmp.

I use it as the default place for all downloads.

Another example, I listen to streaming radio, and I rip it to disk (so I don't have to deal with buffering, and so I can skip songs). I put it in /tmp-ram, it rips from one end, and I play and then delete from the other.

On Acard's page that CD-ROM sized module supporting up to 64GB without memory included costs $550. The memory for it would cost about $900 more. Maybe Joel could get this for all employees after they get tired of their new X25s.
(comment deleted)
Does anybody here use ramback? If so, please report your experiences.

Also, what other RAM-to-HD backup mechanisms are out there?

Can I ask a question?

Does anyone know how to signal to the Operating System NOT TO CACHE these filesystems? This would be ram caching a ram cache which wouldn't make performance sense.

I cannot work out if that is part of the tmpfs/ramdisk driver itself, or if people who write these sort of articles don't know about normal read/write caching that occurs in all operating systems.

Both ramfs and tmpfs on Linux cause writes directly to the page cache, just like a normal write but without a backing store (though in tmpfs' case, the backing store is swap). So there is no double RAM usage.

This is confirmed in these docs:

Documentation/filesystems/ramfs-rootfs-initramfs.txt

Documentation/filesystems/tmpfs.txt

A thing you can do with these is use an "at boot time, prime the ramfs" technique on file/web servers to pin important static files in memory if your normal serving patterns will push certain things in and out of the page cache more than you like.
This article exemplifies one problem with the Linux/tech crowd. All that text and command line output - and not a single damn graph on the page! One graph showing speed differences would eliminate the need for tons of text on that page.

  Hard disk: _                     100 MB/s
  Ram disk : ____________________ 2000 MB/s
'K?
No, but that's not the point: anyone can be cajoled into making a graph (and I love ASCII art as much as anyone), but the fact that there wasn't the culture of putting a pretty ribbon on nice results, that's the problem.
Real life is not that simple. Many times, graphs and charts (especially when they replace actual numbers) can be misleading, even unintentionally. In this article, you could focus on IOPS, if your target workload is sensitive to that. Or you could think about maximum bandwidth, or number of rack units required, or the fact that one of the options requires special drivers and multiple PCI-e channels, and so on. Just throwing a graph up would hide a lot of useful information, and encourage knee-jerk reactions to the article. We all know from the Megahertz Wars that this isn't good for anybody. Pretty graphs have their place in pop-tech pieces, but this article was more useful in just two pages than most of those articles are in ten pages of graphs.
Additionally, there is not-universal-but-fairly-widespread culture of contempt for folks who make suggestions like that. "Bah, typical Excel user with your useless eye-candy and summaries and obsession with ease of use."

I wrote an article some months back about competing with OSS, which included some very basic advice like "If you offer software for download, you should have a prominent button which lets people download your software". I did not anticipate this recommendation would be controversial. I got some absolutely priceless comments about it. My two favorites: users who can't find the software without a big ugly button don't deserve to have it, and technically disinclined users who are attempting to install software from the Internet are already doing something wrong, they should be getting it from their distro's repo instead.

I'd rather have content than a graph. Comfortably I'd like both.

Graphs without much content, which is the leading combination these days - especially around "tech", business, economics sites/"content", is pretty damn annoying and it makes it feel a lot more cheap.

I do agree that a graph would be a nice complement. Even if the "problem with Linux/tech crowd" was pretty unnecessary.

Any alternative for Windows?