Does OS X have an equivalent to /dev/shm?

You can create and mount a ram based disk as follows: Create a disk hdiutil attach -nomount ram://$((2 * 1024 * SIZE_IN_MB)) hdiutil will return the name of the ramdisk. Format and mount the disk diskutil eraseVolume HFS+ RAMDisk NAME_OF_DISK Access the disk under /Volumes/<diskname> cd /Volumes/RAMDisk && touch testfile.txt && ls Creating a 100MB … Read more