Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the 'From an anonymous commenter...' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
From an anonymous commenter...
Authored by: robg on Sep 04, '04 09:16:23AM
This was sent to me via email; I make no promises about it, and I haven't tested it...

-rob.

---------------

I have a ram disk set up to run seti@home. While I just move the files manually, I'm sure a script could be written to safely move them on reboot. You can create your own ram disk using the hdid unix command ... Check out the man page! // single line for ram disk creation...
hdid -nomount ram://<sectors>
// ram disk creation script...
#!/bin/sh
NUMSECTORS=10240
mydev=`hdid -nomount ram://$NUMSECTORS`
newfs_hfs $mydev
mkdir /RamDisk
mount -t hfs $mydev /RamDisk
// you can even add it to your start up items like so... File Name 'RamDisk'
#!/bin/sh

##
# Start RamDisk daemon
##

. /etc/rc.common

ConsoleMessage "Starting RamDisk"

NUMSECTORS=30720
mydev=`hdid -nomount ram://$NUMSECTORS`
newfs_hfs $mydev
mkdir /RamDisk
mount -t hfs $mydev /RamDisk
// and the plist to go along with the start up file... File Name 'StartupParameters.plist'
{
  Description     = "RamDisk daemon";
  Provides        = ("RamDisk");
  Requires        = ("Multiuser Login Prompt");
  OrderPreference = "Last";
  Messages =
  {
    start = "Starting RamDisk";
    stop  = "Stopping RamDisk";
  };
}


[ Reply to This | # ]