LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Hardware (https://www.linuxquestions.org/questions/linux-hardware-18/)
-   -   map hard disk to ram? (https://www.linuxquestions.org/questions/linux-hardware-18/map-hard-disk-to-ram-679368/)

santana 10-27-2008 12:54 PM

map hard disk to ram?
 
Hi, I have a system with 12 G of ram. Since typically I don't come close to needing this much ram, I was wondering if there was a way to create a drive partition on say 4G of it to improve hard disk io performance? Maybe map a small partition on one hard disk to memory and then run completely from RAM?

jailbait 10-27-2008 01:02 PM

You can do that with a ramdisk. Here is a howto on creating a ramdisk:

http://www.vanemery.com/Linux/Ramdisk/ramdisk.html

-----------------------
Steve Stites

estabroo 10-27-2008 01:53 PM

Linux will automatically cache files in ram and keep them there until the ram is needed for something else, it really isn't necessary to use a ramdisk in this instance.

onebuck 10-28-2008 12:41 AM

Hi,

There is a difference with cache of a file and creating a filesystem on a ramdisk. The filesystem will have better performance from a ramdisk vs a mechanical hdd where the files will be cached. The mechanical latency is the big problem with hdd that are based on physical storage with a moving head and platter. The ramdisk will have minute delay as compared to the mechanical hdd.

I think the newer silicon disks are twice the transfer rate typically. The density will be greater as the technology improves. The newer dynamic ramdisks will have more storage and out perform current hdd technology. As the density increases for the RAM then we will see even larger disks at lower cost. With new battery technology the backup is not a problem so you won't loose your data.

Electro 10-28-2008 04:53 AM

I recommend do not use RAM disk with that amount of RAM. I recommend use a high performance file system like XFS or JFS.


All times are GMT -5. The time now is 03:27 AM.