A RAM disk is a block of RAM (primary storage or volatile memory) that a computer’s software is treating as if the memory were a disk drive(secondary storage). It is sometimes referred to as a “virtual RAM drive” or “software RAM drive” to distinguish it from a “hardware RAM drive” that uses separate hardware containing RAM, which is a type of solid-state drive (Wiki). Please keep in mind that once the Computer is Turned Off or Loses Power all the Files that are on the RAM Disk will be lost.

Index:

Accreditation
Section 1: Configuration
Section 2: Creating The Ram Disk

Guide:

Accreditation:

Andrew Kern – Publisher
Nick Smith – Editor

Section 1: Configuration

1. Download RamDisk.command found here.

2. Open the Download Folder:

Screen Shot 2014-12-07 at 12.07.00 PM

3. Locate RamDisk.command:

screen-shot-2013-04-11-at-1-43-27-pm

4. Right click on RamDisk.command.

5. Select Open With:

screen-shot-2013-04-11-at-1-37-04-pm

6. Select TextEdit:

screen-shot-2013-04-11-at-1-36-35-pm

7. Locate 3906250 in the document:

screen-shot-2013-04-14-at-11-20-33-pm

8. Calculate how many Gigabytes of RAM that will be dedicated to the RAM Disk:

[(GB)(1000^3)]/512 = Sector Size

Example 2 GB = 3906250 Sectors

9. Replace 3906250 in the document with the calculated value.

10. Save and exit TextEdit.

11. Continue to Section 2.

Section 2: Creating The Ram Disk

1. Run RamDisk.command:

screen-shot-2013-04-11-at-1-43-27-pm

2. The RAM Disk is now mounted:

screen-shot-2013-04-11-at-1-44-29-pm

6 Comments on "Ram Disk"

  1. (Reposted from rampagdedev.wordpress.com)
    Hi. I tried this on a Mac Pro that we recently purchases (2 months ago), however I seem to be getting strange results: The RAM disk appears to be very slow. Running Blackmagic Disk Speed Test, I get results between 200-300MB/s. After 10 iterations of testing it is maybe 700MB/s. If I leave it running, it slowly creeps upwards going above 3000MB/s after 5 to 10 minutes, however if I stop and restart the test it again restarts being slow.
    Comparing that to the internal SSD which start up being over 800MB/s and on the 2nd or 3rd test iteration maxes out at 1300MB/s.
    I tried disabling memory compression (sudo nvram boot-args=”vm_compressor=1″) thinking that might be the cause of the slow response, however it seems to have no impact on this speed test result.
    One other benchmarking utility I found reports RAM speed as 10GB/s, however I seem to be getting 10 times slower speeds when using this RAM disk in practice.
    Any suggestions?

    Reply
    • What application are you using the RAM Disk with? Some applications have actual write limits hardcoded.

      Reply
      • I used the same benchmarking app (Blackmagic Disk Speed test) you guys used in your original article on rampagedev.wordpress.com. (i see the results section of the article has been removed in this version of the article). Your result showed 2300MB/s, thus atleast the old version of the app you used did not have limits that low.
        The fact is that my internal SSD and an external Lacie drive are both outperforming the RAM disk, based on the results reported by the benchmarking app.
        Other than the benchmarking app, my intended short term use is a custom developed simulator app, with is supposed to generate data at 3200MB/s into a ram disk (run/shm), which it manages on my 3 year old Dell laptop running Lunix. However on the Mac Pro it doesn’t seem to be able to write faster than about 1000MB/s to the RAM disk. Longer term, getting the data via 2x 10Gb ethernet or Thunderbolt or Infiniband to the Mac Pro to visualise using GPU preprocessing.
        However at this stage there seems to be some bottleneck on the Mac Pro limiting the RAM disk access. Activity monitor shows high CPU load from diskimage-helper, which I suspect might be causing the bottle neck. Any thoughts on its role when using the RAM disk?

        Reply
        • What format was the disk on Lunix as chances are I am formatting it diffent then what you had used in the past. Also please do not compare other OS Types as that is not a useful comparison since each OS Type functions differently.

        • 100% agreed the disk format is different from other OS’ disk.
          I only mention the other OS in order to indicate that my custom app doesn’t have write limits hardcoded. I believe disecting that solution further will not resolve the Mac issue.

          My point was I attempted to recreate your original instructions, using as similar tools as I could, however it doesn’t seem to give similar results. So has things changed with the never OS release? Do you still get such good results?

        • I get good results for what I use it for. I have not seen any issues with performance here. I get about 1.1 GPS on avg. when using it with real world programs.

Leave a Reply

Your email address will not be published. Required fields are marked *

Time limit is exhausted. Please reload the CAPTCHA.