I have puzzling question: 1gb of inactive RAM, little free RAM, and mucho page outs..

Discussion in 'MacBook Pro' started by Miss Terri, Apr 10, 2011.

  1. Miss Terri macrumors 6502

    Joined:
    Nov 11, 2010
    Location:
    US East Coast
    #1
    Hi all,

    I have a question about something that is puzzling me with my system, and I wonder if any of you can help me with it. I have searched out and read a number of older threads but they didn't really help me (I did try though).

    Also, sorry to be so wordy, but I can't see holding back information and then we just have to go back and forth while you pry it out of me bit by bit :)

    This is my 4-month old MBP 13", with 2.4ghz C2D, 4GB RAM, and 250gb HD. I'm running 10.6.4.

    I'm a pretty light user EXCEPT I'm a major "tab hog" in Firefox :eek: I just love tabs!

    So, I notice that as I build up my tabs, my "Memory pie" starts to look a bit odd. I'll have almost no free RAM (say 30mb), about 2GB of active RAM, and then over 1 GB of "inactive RAM." But when the free RAM gets down that low, FF gets really unresponsive and starts beachballing.

    From my reading, it seemed that the system would "know" to just make use of that "inactive" RAM if it needed it, but this almost makes it seem like it's not doing that.

    Another thing is that, for example, right now I have 2.8 GB of Page Ins, but relatively whopping almost 7 GB of Page Outs. Again, from my reading it sounds like having a lot more page outs than page ins means you need more RAM. But that seems odd with 25% of my total RAM "inactive."

    Here is a shot of my Activity Monitor now; this is the behavior I mean:

    am.jpg

    FF is using around 40-50% of my CPU, and everything else is at like .8% or less, so although FF is using a lot, everything else is nearly nothing.

    Also, I use FlashBlocker on FF, so even though I have a lot of tabs open, there is not rampant flash usage on them.

    Okay, now I also read that "inactive" RAM comes from programs you recently closed, in case you open them again. Okay, that makes sense. Except, to experiment, after I read about that, I closed all my programs except FF and Mail for a long time, and still I had the extremely small amount of free RAM, and the huge amount of inactive RAM, at which point FF would start to beachball. At the same time the computer begins to get much hotter. Not that it's too hot, but just this seems to go along with the overall behavior. It will go from its usual 45ºC up to 60ºC or so. Again, not a worry in and of itself, but it coincides with the "no" free RAM and the beachballing FF.

    If anyone can shed any light on this, I would much appreciate it. I did read Apple's page on memory and how it works, but they were a bit vague on a few things.

    Thank you!

    Miss Terri

    PS: I do have 8GB of RAM ready to install, but I still want to understand this, because.... am I then going to have the same thing but just with MORE inactive RAM? I want to understand it.
     
  2. mobilehavoc macrumors 6502

    mobilehavoc

    Joined:
    Jun 30, 2007
    #2
    At a high level Firefox is allocated a maximum amount of virtual memory and once it uses all of it it will swap out for more. How much virtual memory is Firefox using?
     
  3. Neil1138 macrumors regular

    Joined:
    Jan 21, 2008
    #3
    Learn to use the 'purge' command in terminal and your inactive ram will be free young padawan.

    Just type 'purge' in terminal and hit enter. It will free your inactive ram. You need to have xcode installed for this to work
     
  4. Miss Terri, Apr 10, 2011
    Last edited: Apr 10, 2011

    Miss Terri thread starter macrumors 6502

    Joined:
    Nov 11, 2010
    Location:
    US East Coast
    #4
    Ah! Okay, that was not displayed in my Activity Monitor, but I went to View and there was only one possible column to add with the word Virtual in it, which was Virtual Private Memory. Is that the one?

    So right now FF is using the following:
    CPU --- 20%
    Real Memory --- 663MB
    Virtual Memory -758MB

    Pie is still similar:
    am2.jpg


    Can you help me to understand what that means now? :eek:

    And, if/when I put in the 8GB of RAM vs. the 4GB I have now, will that change the ratios?

    Okay, a question then, if you have a moment:

    I like being able to do things for myself, but OTOH it seems odd that I would need to (?). What I mean is... is this Free/Inactive RAM ratio a symptom I should be using to figure out and cure an underlying problem vs. just eliminating the symptom?

    Or is there a "flaw" in the way the system allocates memory wherein I need to download something to fix it? (xcode) (I want to believe there would not be, but I'm open to your thoughts :))


    Thanks,
    Miss Terri
     
  5. mobilehavoc macrumors 6502

    mobilehavoc

    Joined:
    Jun 30, 2007
    #5
    Right what this is saying is Firefox is only allowed to use 758 virtual memory Max and once it reaches that threshold it will need to swap out pages to free up memory. This is the way modern systems are designed and I'm not sure adding more memory will help with this particular situation. Don't worry about free memory, inactive is not really free. Try just using one tab in Firefox for a day after a reboot and see hat results you get.

     
  6. Miss Terri thread starter macrumors 6502

    Joined:
    Nov 11, 2010
    Location:
    US East Coast
    #6
    mobilehavoc,

    If I only use one tab in Firefox, I already know what will happen: There will be more free RAM.

    But.... it just seems like with 4 GB of RAM (and 8GB once I shut down and tinker with it :)) that I should be able to browse more tabs. I mean, that's ALL I'm doing, basically (in terms of resource-using things).

    Is there a way to allocate more Virtual Memory to FF (especially if I go up to twice as much RAM)? Or will that amount double automatically when I double my RAM?

    One reason I got more RAM was because people mentioned that tabbed browsing was RAM hungry, and I know I do a lot of that.

    I don't mean to complain at you, because I know you didn't design the system and are just trying to help :) It just seems like a Macbook Pro with four (or eight!) GB of RAM ought to be able to support a big chunka tabs - especially if that's all I'm doing. Or is that wrong?

    If I could allocate more Virtual Memory to FF (or if it will automatically double when I double my RAM), that seems like it might be helpful.

    Okay, so just to make sure I understand one thing correctly: So the reason my Inactive RAM is not being "called upon" is because FF can only use 7xx mb of memory no matter what, and it already IS using that, so the Inactive RAM is not "seeing" a need to be used?

    Okay, so if I open, say, iPhoto, and start doing stuff, then the "free" pie wedge should "recover' some of the inactive memory, right? Because the inactive memory is there to be used if/when needed? And iPhoto will have used none of it's allocated amount (so it's not maxed like FF is). Okay, let me try that....

    Okay, so I opened iPhoto (sloooow) scrolled around a bit, putting it to use. Then I looked at my activity "pie" again. It was down to 5mb of "free" RAM :eek: with still over a gigabyte of "inactive" RAM. Here it had recovered to 10mb of free RAM:
    am3.jpg

    So does this make sense? I can sort of get what you are saying about FF having a set limit (although I sure hope that can be increased if I double my RAM); but then iPhoto should have another whole chunk of memory limit, no?

    Thanks for helping me out here - this is really vexing!

    Miss Terri
     
  7. mobilehavoc macrumors 6502

    mobilehavoc

    Joined:
    Jun 30, 2007
    #7
    I'm not sure how Firefox sets its virtual memory limit so it may go up with more ram if its based off a percentage of total real memory for example. At the end of the day though you shouldn't be looking at this stuff and worrying. It'll drive you crazy. Inactive memory is free in that its assigned to something so its not free but if another app needs it, it will be released and used for that. Ideally a good memory management system would have little to no free memory. Memory that is not being used for something is just wasted.

    Another option is to try out Chrome. :D
     
  8. Miss Terri thread starter macrumors 6502

    Joined:
    Nov 11, 2010
    Location:
    US East Coast
    #8
    That would be nice, as otherwise it seems like I will have a whole lot more RAM that I "can't" use for my computer usage.

    Well you know, I *wasn't* :p I have very little desire to "look under the hood" on my computer ;) In fact, I don't think I ever looked at Activity Monitor on any of my other Macs. But on this MBP, I couldn't help noticing how my normally wonderfully zippy computer would just start beachballing and lagging like crazy. And that would correspond to when there was very little to no free RAM (say 50mb or less).

    If I restart the computer, it seems like it goes back to having a lot of free RAM, which then slowly gets the life sucked out of it (with me basically only using FF with any load).

    On my older, slower computers, I would go months without re-starting (I would just sleep them). Granted they were never this zippy, but they didn't seem to "deteriorate" just by virtue of being "on" (okay for months, yes, but not days or a week). Now, it seems I would have to re-start every couple of days, which just seems so "un-Mac-Like" to me :(

    So, as long as things stay zippy and I don't suddenly get a bunch of beach balls, then I'm not going to be worrying. I just want to figure out how to get back to that state!

    Miss Terri
     
  9. Macsavvytech macrumors 6502a

    Macsavvytech

    Joined:
    May 25, 2010
    #9
    Technically it's not lagging, it's freezing.
    But anyway, maybe try using chrome or safari for abit and see if it fixes the problem, I have been reading quite a few threads blaming FF4 on issues.
    Luckily though I just remembered as I was typing this that there was a version of flash player release not so long ago that hogged RAM, maybe you have this version; try updating Flash
     
  10. Miss Terri, Apr 11, 2011
    Last edited: Apr 11, 2011

    Miss Terri thread starter macrumors 6502

    Joined:
    Nov 11, 2010
    Location:
    US East Coast
    #10
    Ah, okay, freezing, thanks for the clarification.

    So....

    1) I'm using Firefox 3.6.15

    2) I'm running Flash version 10.0.42.34 (Adobe says I can now run 10.2.153.1 as the newest version).

    3) I use Flashblock (version 1.5.14.2), so if it makes a difference, Flash is not just running amok on my unviewed tabs - I just click when I want to play something.

    Eww, I wouldn't want that! I wonder which one is the supposed ram-hogging one?

    Oh, and I'm still curious why iPhoto would not "get" some of that "inactive" RAM? (If I understand this correctly?) I'm not sure that's as much of a problem, but it seems to somewhat counter of the idea of Firefox just not getting any more RAM because it's at its limit (at least as far as I'm understanding this).

    Again, I don't really care about all this, per se, as long as my computer is not freezing and beachballing when I'm not really loading it down all that much (I mean, I read about people doing so much more than I do on their MBPs). Of course now that it is doing this, I do care :D

    MT
     
  11. Macsavvytech macrumors 6502a

    Macsavvytech

    Joined:
    May 25, 2010
    #11
    Maybe you should try FF4, seems that most of it's "problems" were actually just flash. Which has been updated. People confuse me sometimes hopefully you understand why I have turned on what I said earlier.
     
  12. Miss Terri thread starter macrumors 6502

    Joined:
    Nov 11, 2010
    Location:
    US East Coast
    #12
    I'm sorry if I'm confusing you; can I clarify something?

    Since I'm the type who just wants my computer to work, I usually don't adopt new things right away, but instead let others work out the bugs (IOW, I'm not the "early adopter" type).

    BUT, that said.... is FF4 already known for being less of a system hog? If so, I might switch, but if not.... I think I'll wait. Since my version of FF3 should be a long-used and "stable" one.... right?

    Again, not saying I won't change if that is the problem; I just don't really feel like I have a handle on what's going on, and I'm a bit leery about moving to a "brand new" FF yet, unless I'm pretty sure that's going to fix my problem (and maybe you know enough about FF4 to know that it will :))

    I guess what's making me think.. hmmm??? is that... I still don't have my mind around the original problem, and I would like to figure that out before I move on. And even if FF3 is the problem, why doesn't iPhoto use some of the supposedly available inactive RAM (over a GB!), instead of just slowing down and sucking Free ram down to 5mb?

    If the only way to run my MBP is to shut it down every day, something seems wrong, doesn't it?

    I just want to learn something here, and make sure I get the basics sorted.

    Thanks for your help,

    MT
     
  13. Krevnik macrumors 68040

    Krevnik

    Joined:
    Sep 8, 2003
    #13
    The 756 MB you mentioned isn't a limit, it is what is in use by FF. Every process maps in more than just the app. It includes the kernel and libraries as well. But I can use tricks to not duplicate RAM in this situation by mapping code pages into multiple processes and so on. Also, if I have memory swapped out to disk, it appears in this category as well. The real limit for any 32-bit process in OS X is around 3GB, as the kernel eats 1GB if my memory serves me correctly. 64-bit apps get more room with a larger address space.

    That said, I still agree with the advice. Try FF4, Chrome or more RAM. It seems odd that Firefox is helping you hit the limit so easily, but then again, I don't know how many tabs are open, or what other processes are open. But 600+ MB of RAM is nothing to sneeze at.
     
  14. Miss Terri thread starter macrumors 6502

    Joined:
    Nov 11, 2010
    Location:
    US East Coast
    #14
    Hi Krevnik,

    First of all, thank you very much for taking the time to read through my posts and give me your thoughts. It sounds like you are pretty familiar with the inner workings.

    I guess I'll start by putting in the 8GB of RAM, since I already have it right here in front of me. I just.... well, it was/is bugging me why I have so much inactive RAM that seemingly can't be called into use even by another program! i.e. when I also opened iPhoto, it sucked my free ram down to 5mb and didn't change the over 1GB "slice" of inactive RAM "pie" that I thought I understood was available when necessary. Do I have that wrong?

    If the 8GB of RAM helps.... great, but I hate to just mask a problem, if there is one. And I thought it might actually be easier to figure it out with only 4GB of RAM in place (vs. I put in the 8GB, it works fine now, but some underlying issue remains and then just re-surfaces when the problem recurs and then I have to figure it out all over again).

    Miss Terri

    Oh, PS: I have no other processes of any significance going on while this problem is happening. I have "all processes" by size showing in Activity Monitor, so I can see that all the other things are just miniscule.

    So yeah, this is still bugging me. How does FF - even if it is using 1GB of RAM, bring my 4GB of RAM to its knees? Why doesn't the 1GB of "inactive" RAM get used? I know it's there in case I re-open something, but if I haven't opened or re-opened anything in days, and I'm down to 5mb of Free RAM, I thought then the inactive RAM was supposed to be able to be brought back into use? I think that's the crux of my question, really.
     
  15. Krevnik macrumors 68040

    Krevnik

    Joined:
    Sep 8, 2003
    #15
    It really depends on how all the RAM got tied up in the first place. There are certainly tests that can be done (by the person) to check to see where all the RAM is going. It's possible Inactive counts both cached RAM pages, as well as pages that are aged to the point where the system has dumped it out to disk in the expectation that some process will need more RAM when there isn't enough.

    And the RAM shown by 'All Processes', unless it includes the system processes isn't a complete picture. But including the system processes, there's a lot to add up. A few things to look at are the following:

    1) What does the 4GB look like after a reboot? Take note of it.
    2) When the machine gets into this state where it is just spewing pages out into swap space (11GB of swap is impressive)... watch Activity Monitor while you close down apps like Firefox. How much gets freed when it exits? What happens when it re-opens again?

    It's possible there is a leak in some app you are using which is generating tons of pages that then sit there eating up memory.

    I agree the answer shouldn't have to be "get more RAM". I do a bit of avid browsing, some gaming, software development and even run VMWare on a 4GB MBP and I don't swap pages out to disk all that much. Not nearly as badly as you seem to be doing.

    I'd run those couple of experiments above before adding the RAM, seeing if you can nail it down to a Firefox memory leak, and see if the latest FF does any better in the same situation. Try opening that number of tabs on competing browsers as well (Safari or Chrome) to see how they handle it.

    If you can't figure out how to make it work for you at that point, then throw the RAM in.
     
  16. brentsg macrumors 68030

    Joined:
    Oct 15, 2008
    #16
    Also, never underestimate masking a problem if the mask is painless and (effectively) eliminates said problem.

    I mean if you enjoy messing with it fine, but if $85 can make a problem go away so I can focus on important things.. $85 it is.
     
  17. Miss Terri thread starter macrumors 6502

    Joined:
    Nov 11, 2010
    Location:
    US East Coast
    #17
    brentsg

    I completely take your point on that. In fact, I already bought the RAM and have it here on my desk, ready to install. But I'm not super confident that it will solve the problem, so I figured it was worth trying to figure it out first, if possible. After all, if a program seemingly using 750mb of RAM can bring my 4GB computer to its knees, then who's to say it won't do the same thing with 8GB?

    Granted, if I cannot figure it out I will absolutely throw the 8GB in. But now seems like a good time to at least try.

    Krevnik,

    I appreciate your thoughts and analysis, thank you :)

    Just before I came back and saw your most recent reply, I decided to shut down the computer and see what happened. But before I did that, I shut down Firefox (knowing otherwise it would pop up asking me about closing tabs anyway). Then I noticed that "Voila!" instantly I had plenty of free RAM. Well of course that makes sense, it's the RAM that FF was just using. But since the "inactive" RAM is supposed to be comprised of RAM used by things you just closed (in case you want to open them again), funny thing is, that slice of the pie stayed just the same :confused: Not that it's a problem, just a curiosity, given how I understand it's supposed to work. Here is how it looked just after I closed FF:

    am4.jpg

    And now after re-opening FF (I did not shut down computer at this time after all):

    am5.jpg

    On the "All processes": I think it really is all. I say that because look at the options. The checked one is the one I have had selected - doesn't it seem like it really is all? Or is there something else I need to select or change? I'm trying to give you good data since you are going to the trouble to take an interest and help me :)
    am6.jpg

    I'm leaning toward just installing the 8GB, but that part of me that does like to understand things, and solve problems.... that part still wants to know, since this seems a bit wacky!

    Miss Terri
     
  18. Macsavvytech macrumors 6502a

    Macsavvytech

    Joined:
    May 25, 2010
    #18
    Ok, just to note on my computer it only as 4GB of RAM (I am upgrading soon), I don't use firefox but my experience in chrome is I can easily have 30+ tabs open with no slow down (this is not on the computer in my sig that has SSDs). Maybe you should try chrome?
     
  19. jwksmith macrumors member

    Joined:
    Apr 27, 2008
    Location:
    Calgary
    #19
    Miss Terri

    Your Flash is WAY out of date. You really should update it. Flash is the buggiest piece of software out there.
     
  20. gullySn0wCat macrumors 6502

    Joined:
    Dec 7, 2010
    #20
    OP

    GET FF4! Stat! 3.5 was so much of a RAM hog I ditched it for Chrome. As soon as FF4 betas started coming out, I tried it, and BOOM! SPEED!

    I'm back on the Mozilla boat now. FF4 keeps Flash on a tight leash, and has a cool multi-tab view (something you might like?)
     
  21. Miss Terri thread starter macrumors 6502

    Joined:
    Nov 11, 2010
    Location:
    US East Coast
    #21
    Thanks for the additional responses :)

    Okay, I'll take a deep breath and update Flash (not an early adopter; maybe I took that too far).

    So FF 3.6 is a known RAM hog? That is good to know. I tend to not like "new and improved" browsers, and when I looked at the early demos of FF4 I wasn't really "wowed" by the new features. BUT, if it will keep my RAM from being sucked dry, that is probably a good reason to try it. I'm not a big fan of Google products in general, so I would like to stay with FF.

    Right now I have 15 tabs open, none with active Flash playing and my free RAM is 24 mb. Sad! (I have no other programs doing anything to speak of, which Activity Monitor reflects.)

    So....no horror stories with the newest Flash version or FF4? :eek:

    Miss Terri
     
  22. Mactrillionaire macrumors regular

    Joined:
    Oct 16, 2010
    #22
    The culprit is most likely Adobe Flash Player. Most plugins are more responsible with memory than that. It doesn't matter what computer I use, if I visit too many sites with Flash on them, eventually I have to do something manual about its memory usage. So, the solution is I have another program run which automatically returns inactive memory to free memory after the inactive memory becomes too large. The other solution would be to disable Adobe Flash Player unless you really need it.
     
  23. theSeb macrumors 604

    theSeb

    Joined:
    Aug 10, 2010
    Location:
    Poole, England
    #23
    FF 3.whatever is a known resource hog with poor memory management. In fact, it usually cannot even release the memory if you close the tabs and needs a full restart. I would strongly recommend that you use Chrome. It is just so much better.

    Your page outs in the screenshots are HUGE (7.13 GB). I've upgraded my MBP to 8GB and currently my page outs are 1.8 MB and my pages Ins are 4.8 GB. My usage tonight has been similar to yours (lots of tabs open in Chrome) .

    I am too lazy to type out what page outs are and this guy gives a great explanation:

    http://macosx.com/forums/mac-os-x-s...somebody-please-explain-me-idiot-fashion.html

     
  24. Miss Terri thread starter macrumors 6502

    Joined:
    Nov 11, 2010
    Location:
    US East Coast
    #24
    I do run Flashblock, as I mentioned above. So any flash things in a website just show up as static icons, unless and until I click on them. So with that, does Adobe Flash still run amok with my memory? I was thinking that was "disabling it"?

    Real world-example of my usage: 16 tabs open, and on one of the tabs I click on a video and watch it. After that I close that tab. The other 15 tabs are under the influence of Flashblock and (as I understand it) don't have flash running.
     
  25. Miss Terri thread starter macrumors 6502

    Joined:
    Nov 11, 2010
    Location:
    US East Coast
    #25
    Okay, I follow you on the FF3 - it sounds problematical. I think I will try FF4 though, as I just don't want to use any Google products I don't have to (and I do like FF in terms of user interface, etc.).

    I KNOW, isn't that ridiculous? The weird thing is, I used to have few to no page outs, even after a week or two of non-restarting. And I haven't changed anything I can think of - definitely not Flash or FF.

    That's what I understood too, from my researching before posting. But I just thought it was weird that 4GB of RAM would not be enough to run a browser and 25 tabs. And that said usage would quickly suck my free RAM down to nothing while 1GB stayed "inactive" long after I had closed any other programs it was saving itself for. That's what made me post.

    Well, I have 8GB of RAM, and I will put it in. I'll also check out FF4 and the updated Flash. I just wanted to find out what was going on. The weird thing is I would have no problem running FF and 25 tabs on my old Macbook with half the RAM (or was it 1/4 - can't remember if it had 1GB or 2GB now). Seems crazy that now I would need EIGHT to do the same thing.

    Like I say, it just seemed odd. I don't see hordes of other people complaining that they can't run FF with 25 tabs on their 4-month-old MBPs, and if it were a common problem I thought I would have seen it.

    Okay, off to play with #00 screwdrivers and sticks of RAM...

    MT
     

Share This Page