If I get page outs does it mean something is eating up all of my ram???

Discussion in 'Mac Pro' started by chrono1081, Sep 1, 2010.

  1. chrono1081 macrumors 604

    chrono1081

    Joined:
    Jan 26, 2008
    Location:
    Isla Nublar
    #1
    Hi guys,

    I was always under the impression that page outs are caused by the ram being used up. I have 24 gigs of ram, and these page outs mysteriously happen when I'm not by the computer so I cant catch them in Activity Monitor.

    The weird thing is is they happen when I have nothing in the background running. Programs (only a few like Maya, Unity and Photoshop) will be open, but they won't be doing anything. Even when doing heavy stuff, the most they have topped is 16 gigs.

    Is this just something writing to the disk for the heck of it? Or is something snarfing my ram?

    It doesn't really matter, Im more curious than anything.
     
  2. stridemat Moderator

    stridemat

    Staff Member

    Joined:
    Apr 2, 2008
    Location:
    UK
    #2
    I think thats more the problem. I wouldn't worry about it TBH. With 25gigs of ram you are not going to run out.
     
  3. mackenziemac macrumors newbie

    Joined:
    Aug 20, 2010
  4. sboerup macrumors 6502

    Joined:
    Mar 8, 2009
    #4
    What kind of apps do you use on a regular basis? 24GB is a LOT of RAM and I wouldn't worry about it, unless you are seeing 1GB+ in page outs.
     
  5. cnstoll macrumors 6502

    Joined:
    Aug 29, 2010
    #5
    It's probably just things that the OS wants to write to disk, and has no need to keep in RAM. Other programs could be doing it too. There's no reason to keep data in RAM if it doesn't need to be there.

    It's called pre-cleaning. The OS will write pages that change out to disk when possible, so it doesn't have to worry about doing so when it starts to run out of memory. If a page is "clean", i.e. the changes in memory have been written to disk, then that page can be easily discarded to make room for a new page coming in from disk. Otherwise the OS would have to write that page out to disk. So really these phantom page outs you're seeing are a feature, not a problem :)
     
  6. mattmower macrumors member

    mattmower

    Joined:
    Aug 12, 2010
    Location:
    Berkshire, UK
    #6
    In my experience some page-outs happen regardless of free memory. It's irksome because you feel like "How can this be?"

    The key thing seems to be the rate at which the page-outs happen, i.e. they shouldn't grow fast (e.g. as a % of pages-in). Well that and, is your system performing well?

    Matt
     
  7. mattmower macrumors member

    mattmower

    Joined:
    Aug 12, 2010
    Location:
    Berkshire, UK
    #7
    Isn't that "pages in" (as in pages into the swap)?

    Matt.
     
  8. Scottyk9 macrumors 6502a

    Joined:
    Jun 18, 2004
    Location:
    Canada
    #8
    My understanding was that it was not the absolute number of page outs, but the ratio of page in to page outs that was the useful metric to assess if you have sufficient RAM.
     
  9. cnstoll macrumors 6502

    Joined:
    Aug 29, 2010
    #9
    No. Page in is from disk to RAM.

    From http://en.wikipedia.org/wiki/Paging :

    "Page out is transferring a page from RAM to the disk"
     
  10. eponym macrumors 6502

    Joined:
    Jul 2, 2010
    #10
    How much paging are we talking here? Can you give us some actual numbers?
     
  11. Honumaui macrumors 6502a

    Joined:
    Apr 18, 2008
    #11
    I could be wrong ?

    I thought their was some that happens in a sleep mode when it makes a memory dump to disc to shut itself into sleep mode safely ?
    so it has a state to come back to ?

    again its morning my mocha is not gone and I am not awake yet :)

    but is your puter set to sleep ? this could be something to do with it ?

    set it not to sleep (if its set to) then come back and see what happens ?
     
  12. goMac macrumors 603

    Joined:
    Apr 15, 2004
    #12
    IIRC the OS will automatically page out memory that you haven't used in a while. No need to keep it in RAM if you're not using it.

    The more RAM you're using, the slower your computer can get as it looks for free blocks of memory, which can become rarer and rarer as memory fills. When you have 24 gigs of RAM, it can take the computer a while to look through all of it for free space. This is why it's a better idea to page out things you aren't using, even if you have enough RAM in theory for all of it.
     
  13. mulo macrumors 68020

    mulo

    Joined:
    Aug 22, 2010
    Location:
    Behind you
    #13
    that's what I said, but I guess these guys are pros! ;)
     
  14. cnstoll macrumors 6502

    Joined:
    Aug 29, 2010
    #14
    This is misleading. Searching for a free entry in physical memory does not slow down your computer. That's really not how things work. Memory Management in modern Operating Systems is pretty sophisticated.

    You can have 4KB, 2MB, or 4MB page sizes in x86 architecture. If you have 4MB pages then we're only talking about 6144 pages that could be "free" or not, based on 24GB of physical memory. That's a completely trivial calculation, even if it were a linear operation. If you have 4KB pages then that's 6,291,456 pages to address 24GB of physical memory.

    To find a free page to page into you can use a bitmask to map those pages to a value to determine if they are free or not. A bitmask for those 6 million pages would require less than 1 MB (786KB). The binary operation to perform the mask would take a completely trivial amount of time.

    I'm sure the optimizations used by all modern operating systems are even more complex than that, and even more optimized. But the point is that addressing more physical memory does not slow down your computer at all.
     
  15. chrono1081 thread starter macrumors 604

    chrono1081

    Joined:
    Jan 26, 2008
    Location:
    Isla Nublar
    #15
    I use Maya, ZBrush, Corel Painter, Photoshop CS5, and Unity the most. I'll also have iTunes open and every few days Aperture will be open too. The page outs are really small which is why don't think its a big problem. Usually 6 - 8 mb. I was more curious then anything.

    \

    It's performing excellent! I love it :) The percentage is very very small.

    Around 6 - 8 mb, the highest being around 20.

    I do notice it after sleep so it may be that this is what it is doing. It always happens when I am away from the machine. I've been trying to catch it for a few days now and it never happens when I am around.

    Lol ya I use a lot of stuff. The most I've ever got this thing to use at once was this morning at 22 gigs. Thats not normal, I was doing a lot extra this morning but usually I will hover around the 10 - 16 gig mark. A lot of it is when I am texturing in Maya since Maya and Photoshop are open at the same time, I then export those models into Unity (which also will link with Photoshop) and those three combined like to eat up lots of ram. ZBrush is also usually open and will link with Maya haha.
     
  16. smithrh macrumors 68020

    smithrh

    Joined:
    Feb 28, 2009
    #16
    This is the most cromulent explanation I've seen for this behavior that I've ever seen!

    Thanks, this is very helpful.
     

Share This Page