Virtual Memory (paging) Files in OS X?

Discussion in 'macOS' started by GilGrissom, Oct 9, 2006.

  1. GilGrissom macrumors 65816


    Mar 13, 2005

    I have suddenly ran out of hard drive space on my 100Gb PB hard drive. There hasn't been any more large files added to my PB, but all of a sudden my space has vanished.

    I'm missing around 10-20Gb of space. I know that the virtual memory files (or paging files?) can sometimes do this, but you cannot just delete them as OS X is supposed to handle them on its own.

    It doesn't seem to be doing this so does anyone know how to manually and safely delete these files and free up my space? I on the right lines with the virtual memory??

    It is a heavily used machine for work and uni use, but did have around 20Gb free not long ago and I have not put that much stuff on it!

    I've gone through everything to try and delete stuff I don't need but I'm pretty streamlined, but still have no drive space left!

    Thanks for any insight and advice!
  2. rdowns macrumors Penryn


    Jul 11, 2003
    Sometimes OS X alows log files to get huge. Check you Library->Log folder to see if anything is huge. If so, delete it.

    A restart might also help.
  3. mad jew Moderator emeritus

    mad jew

    Apr 3, 2004
    Adelaide, Australia
    These Virtual Memory files should be deleted on shut down but they'll accumulate quite quickly afterwards so removing them is slightly pointless. rdowns, for once in his small and petty life, mentioned something worthwhile. There is a known bug in OSX that results in log files growing to the extent of your hard drive. Simply removing these will fix the problem until it happens again (although that's quite rare).

    If that's not the problem, then use an app like OmniDiskSweeper in an administrator account to see where the space is being used up. :)

    Just kidding about rdown's life. It's not really that small.
  4. GilGrissom thread starter macrumors 65816


    Mar 13, 2005
    Ta guys

    I have rebooted, ran macjanitor, ran repair permissions from master CD, to no avail.

    There are no large log files, nothing over 20Mb in any of my log folders I can find!

    Am currently running disk sweeper...waiting for it to finish!

    Anything else? There must be something!

    A friend of mine said he had trouble with the VM files on his eMac where OS X created a new VM section without deleting the old one etc etc...any help?
  5. crees! macrumors 68000


    Jun 14, 2003
    Repair permissions has nothing to do with lost disk space.
  6. SimonTheSoundMa macrumors 6502a

    Aug 6, 2006
    Birmingham, UK
    And never run from the CD/DVD, only do this if you receipts folder is damaged/deleted.

    And if you want to know where it has gone, use WhatSize.
  7. beatsme macrumors 65816


    Oct 6, 2005
    it's not too hard. OSX has an auto-delete feature, but the scheduled runtime is set at something like 3am (I don't know for sure when), so the practical upshot is if you're computer is off during that time, they don't get deleted.

    Anyway, do this:
    1) open Terminal
    2) type in sudo periodic daily, and hit enter
    3) it'll ask for your admin password, so type that in and hit enter
    4) when the cursor returns (it'll be a minute or two), type in sudo periodic weekly, and hit enter
    5) when the cursor returns, type in sudo periodic monthly and hit enter

    after the cursor returns, go ahead and reboot the machine

    hopefully, this will take care of your problem. What you might want to do (for future reference) is make a partition on your HD that your apps can use as a scratch disk. Illustrator and Photoshop let you choose which volume you want to use as a scratch disk, so all you have to do is point to the specific volume in the application preferences. I believe the rule for creating a scratch disk partition is to make it 1.5 times the amount of memory. In other words, if you have 500MB of memory, make the scratch disk 750MB.

    Personally, my scratch disk is 1.5GB...but that's just me.

    hope this helps :)
  8. SimonTheSoundMa macrumors 6502a

    Aug 6, 2006
    Birmingham, UK
    Or to run all at once,

    sudo periodic daily weekly monthly

    Tiger will always run these scripts if your system is switched off, it will simply run them at the next time the machine is on.
  9. Vlade macrumors 6502a


    Feb 2, 2003
    Meadville, PA
    Omni Disk Sweeper is very good for finding large files and getting extra space off a drive.
  10. SC68Cal macrumors 68000

    Feb 23, 2006
    Disk Inventory X might help, creates a visual representation of your hard drive
  11. IJ Reilly macrumors P6

    IJ Reilly

    Jul 16, 2002
    Not so quickly as all that. I keep an alias to the vm directory in my Sidebar for purposes of monitoring the swap files (an obsessive-compusive disorder, I know). At worst I get three of them amounting to less than a Gb. Reboot and they go back to the default, one file of 64 Mb. Obviously, the OP has a different issue.
  12. GilGrissom thread starter macrumors 65816


    Mar 13, 2005
    Isn't that what macjanitor does with a nice GUI?
    Ah...I normally run disk utility from normal OS X but have always been told its best to do it from the CD for a more thorough effect! Confusing!

    I know it probably had nothing to do with my problem, but it was always worth a shot as course of action!
    How do you find where these files are stored to create an alias?

    [UPDATE!!] DiskSweeper says there is an area called "volume" on my drive, which contains some iDisk stuff, iPod stuff, my USB memory stick references and folders named after my external USB drive. When I ran DiskSweeper none of these external devices were plugged in but it still says it is taking up room. The references to my external drive are taking up a large amount of memory (almost 10Gb) according to Disk Sweeper. Being as my drive is not currently plugged in has OS X for some reason created another instance of it on the hard drive? (i.e.:...what the hell is this?! I don't want to guess to much and look stupid!)...also, is it safe for me to delete the folders named after my external drive?
  13. mad jew Moderator emeritus

    mad jew

    Apr 3, 2004
    Adelaide, Australia

    Okay, you're right. Virtual Memory isn't entirely deleted but it is reset and most of it (the majority) is deleted. Better? :p

    Pretty much. Running these scripts manually is usually a waste of time in Tiger unless the computer is shut down each night (which most are not). :cool:

    There are two things that get repaired/verified. The permissions should be repaired from the internal drive.

    Picture 1.png

    If there's something actually wrong with the file system, then the disk should be repaired from the OSX disc. In fact, you can't repair the disk from the boot drive (that's why the option is grey), unless you use Single User Mode + fsck.

    Picture 2.png

    Of these things, which are taking up the most space and how much is it? :)
  14. knome macrumors 6502


    Sep 7, 2006
    I am having a problem like this too. I recently started looking at my hard drive trying to clean some stuff out for my new computer and i looked and the numbers don't add up. I have 40 gigs in documents, 15 in applications. 5 for system. 12 for my library and another 6 gigs for miscellaneous stuff. I added the numbers up and it didn't match the amount of drive space i had left over, (yes i accounted for the original format space loss) migration assistant said i had 90 gigs of files it needed to transfer. Ok all the stuff i added up equaled 78..... What happened to my other 12 gigs???????
  15. GilGrissom thread starter macrumors 65816


    Mar 13, 2005
    Thanks Madjew.

    The largest one was 9.9Gb, with the others about a few more gig. I've deleted them and all seems fine now!!...i have space an nothng seems broken!
  16. mad jew Moderator emeritus

    mad jew

    Apr 3, 2004
    Adelaide, Australia

    From your post it's not terribly easy to see what's happening. Are you missing 12GB of data or 12GB of free space? :eek:

    No worries mate. Good to hear things are back on track. :)
  17. 2nyRiggz macrumors 603


    Aug 20, 2005
    Thank you Jah...I'm so Blessed
    Check in your user/lib folder and see whats going on in there. Anything that seems "out there" to you just post it here and we will run through it with you.


Share This Page