Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

So I just installed an SSD in my MBP and have been a bit concerned about running out of disk space. I noticed that /private/var/vm holds an 8.6 gb sleepimage file as well as swap files. I'd be much happier if they existed on my old (regular) HDD which is also still inside my machine as well.

I can't think of anything that would really go wrong with this, but can someone tell me whether or not I'll totally screw up my computer by symlinking /private/var/vm -> /Volumes/OldDrive/private/var/vm?

I read in this superuser post that if the target disk isn't mounted at the time that the swap files are being created, then it could "fake it" (so to speak) and create a directory "/Volumes/OldDrive", forcing my actual drive to be mounted at "/Volumes/OldDrive 1".

share|improve this question

2 Answers 2

It looks like an app called Xupport from Applicorn should set this up in the correct way (trusting the developer to have worked this out - you could always ask them): http://www.applicorn.com/xupport/help/Manuals/English/pgs/optimization.html . However, the rest of their site, including the download, appears to be down now. You'd also want to check it'll work for Lion, though it seems unlikely the swap setup would have changed much.

PS: Your SSD will last longer if you move swap off it too.

share|improve this answer
    
Intriguing... Though the site being down (still) is not particularly reassuring. –  steve Dec 5 '11 at 22:41
    
Yeah.. if you ever do work it out, or want to discuss the swap issue, let me know via my (still standing) question superuser.com/questions/364204/… –  tog22 Dec 6 '11 at 12:04

Multiple aspects to this one question …

A separate volume for external page files

You should not prefer a symbolic link.

… whether or not I'll totally screw up my computer …

Not totally, but if dynamic_pager can not write when required to your chosen volume, then sooner or later the operating system will almost certainly misbehave in ways that will be disruptive to your use of the Mac.

Instead of an unmanaged symbolic link with the risk of misbehaviour:

  • prefer to manage the behaviour of dynamic_pager

Links

dynamic_pager_wrapper source from dynamicpagerwrapper – performance wrapper for /sbin/dynamic_pager on OSX

In Ask Different: How can I move virtual memory swap files to a different drive or partition? (2010-09-12) – that's a more recent version (from the same person) of the question that's linked from your opening post.

A separate volume for sleepimage

Aim to not use the same separate volume that you use for external page files.

Manageability

Whilst there are accepted approaches to managing the behaviour of dynamic_pager (wait for a path), the timing of creation of sleepimage may be less easy to manage.

Impact

If force is applied to a restart or shut down, or if the kernel panics, and if then sleepimage is not written to your chosen volume, and if that volume was also intended for external swap files:

  • misbehaviour of the operating system may be not immediately easy to predict or detect
  • cleaning up may be unexpectedly time consuming.
share|improve this answer
    
so considering I have exactly 2 physical volumes, (1 ssd, 1 old spinning rust), what exactly would you recommend WRT sleepimage & paging? Just leave everything on the new SSD? Or perhaps I should symlink my home dir to the old drive and leave? –  steve May 3 '13 at 23:27
    
You might benefit from a separate volume for external swap files, but I should not prefer to use a symbolic link. Prefer the approach given in the linked question. –  Graham Perrin May 4 '13 at 8:34

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.