PDA

View Full Version : OT: Mac Virtual Memory



jeremyhardin
11-15-2006, 05:04 AM
Using my 2ish year old Powerbook is beginning to force me to learn how to optimize my Mac usage since I'm still using it in production, and increasingly with every project.

Right now I'm painting animated texture maps in Shake (because I need to animate strokes) at 4k.

And I have about 2 gigs of HD space left and my external HD in another country. Brilliant.

So aside from the fact that I've already used Spotlight to kill every unneccessary TGA, MDD, PFX, MPG, and MOV file, as well as delete every podcast that has been listened to, I still have about 2 gigs left.

I go to render the Shake script, and Hard Drive errors pop up saying the disk is full. I go to the /var/tmp/Shake folder and delete any unneccessary caches. Still 0 space.

Well, a quick trip to my activity monitor reminds me of a little thing called virtual memory. And lets me know that each of my running widgets is taking up a fair amount of hard drive space in virtual memory.

So I used the activity monitor to kill iCal Alarm Scheduler, iTunesHelper, some HP printer stuff (for a printer I no longer own), and then use dashboard to close all my widgets.

Lots of space comes back. So if you're every pusing the limits of your disk space, don't forget virtual memory. And kill any unneccessary widgets! :thumbsup:

Tartiflette
11-15-2006, 06:21 AM
Yeah, i know what you mean ! :agree:

Even if i own a MacBookPro loaded with 1,5GB of RAM and a fast 7200rpm 100GB Hard Drive, i've ended up killing all the unnecessary stuff in my OS...

There was a time when i had a launcher (QuickSilver), a lot of Unsanity haxies (Fruitmenu, WindowShade, LabelsX, and Shapeshifter...) and a bunch of other menubar tools, such as MenuCalendarClock, Menutunes, Menumeter, etc, etc...

Then i discovered that each of this little app was lying on my system with at least 200MB of virtual memory !! Then i decided to throw all those app to the trash and do the things differently...

I know use Spotlight to launch applications or search the drive, Dashboard has been deactivated from my machine, i only use windowshade (i just can't do without it, never been "familiar" with Exposť...) and the ony menubar tool remaining is Menutunes, since i use it to control iTunes without bringing this one to the front...

And i must say that i feel my machine is more responsive in this "light" configuration... :thumbsup:


Sorry for the long post, just wanted to share my experience as a "Mac maniac" !! :D

Regards,
Laurent aka Tartiflette :)

jeremyhardin
11-15-2006, 07:32 AM
There was a time when i had a launcher (QuickSilver), a lot of Unsanity haxies (Fruitmenu, WindowShade, LabelsX, and Shapeshifter...) and a bunch of other menubar tools, such as MenuCalendarClock, Menutunes, Menumeter, etc, etc...

...Dashboard has been deactivated from my machine...



Very similiar experiences here. I watch MacBreak (http://www.twit.tv/MB/) and get lot's of nice tips and such for these programs, but now I pretty much use Spotlight for everything and Menushade (http://www.nullriver.com/index/products) when I'm not doing anything system intensive.

How did you disable Dashboard? I wouldn't mind doing that as well.

Tartiflette
11-15-2006, 08:33 AM
How did you disable Dashboard? I wouldn't mind doing that as well.

I'm using one of this utility :

TinkerTool (http://www.bresink.de/osx/TinkerTool.html)
or
Onyx (http://www.titanium.free.fr/pgs2/english/onyx.html)

Those are utilities that enable some "hidden" features of mac OSX... No additionnal software or background running app, only "preferences" that you could enable via the Terminal...

Hope it helps ! :)


Regards,
Laurent aka Tartiflette :)

jeremyhardin
11-15-2006, 08:38 AM
I'm using one of this utility :

TinkerTool (http://www.bresink.de/osx/TinkerTool.html)
or
Onyx (http://www.titanium.free.fr/pgs2/english/onyx.html)

Those are utilities that enable some "hidden" features of mac OSX... No additionnal software or background running app, only "preferences" that you could enable via the Terminal...

Hope it helps ! :)


Regards,
Laurent aka Tartiflette :)

Nice! I have TinkerTool, but it was pre-dashboard. I'll download the latest. Thanks mate. :thumbsup:

Tartiflette
11-15-2006, 08:44 AM
Nice! I have TinkerTool, but it was pre-dashboard. I'll download the latest. Thanks mate. :thumbsup:
:D

No problem, you're welcome !

Regards,
Laurent aka Tartiflette :)

dglidden
11-16-2006, 07:27 PM
Then i discovered that each of this little app was lying on my system with at least 200MB of virtual memory !!

The numbers you were seeing were probably a little misleading if it looked like each app was using 200MB. Because OS X is UNIX-based, a lot of that "virtual" memory is actually shared between ALL apps on your system for things like the standard C library and linked frameworks and stuff. Not only that but that memory may be referencing pages that haven't even been loaded from the libraries on disk yet. Since ANY app that you have running that loads these libraries and frameworks is going to cause OS X to keep a reference to them for "virtual" memory, even if that memory isn't actually being used by that application.

For example right now Quicksilver is using 380MB of "virtual" memory because of the various dynamic libraries and frameworks it's linked against, but it's really only using 18MB of actual system RAM itself.

There are some pretty good white papers on OS X memory management in apple's knowledge base if you want to get more technical information about what all those numbers mean. So don't stop using those handy utilities because of what shows up on your "virtual" memory use! I don't know what I'd do without Quicksilver.

jeremyhardin
11-17-2006, 01:57 AM
The numbers you were seeing were probably a little misleading if it looked like each app was using 200MB. Because OS X is UNIX-based, a lot of that "virtual" memory is actually shared between ALL apps on your system for things like the standard C library and linked frameworks and stuff. Not only that but that memory may be referencing pages that haven't even been loaded from the libraries on disk yet. Since ANY app that you have running that loads these libraries and frameworks is going to cause OS X to keep a reference to them for "virtual" memory, even if that memory isn't actually being used by that application.

For example right now Quicksilver is using 380MB of "virtual" memory because of the various dynamic libraries and frameworks it's linked against, but it's really only using 18MB of actual system RAM itself.

There are some pretty good white papers on OS X memory management in apple's knowledge base if you want to get more technical information about what all those numbers mean. So don't stop using those handy utilities because of what shows up on your "virtual" memory use! I don't know what I'd do without Quicksilver.

good to know. :thumbsup:

but when Shake is taking up 2GB of virtual memory, i can actually switch over and watch my disk's available space drop. and each of those handy little apps I close helps keep me from hitting the zero mark. :D

Tartiflette
11-17-2006, 02:47 AM
good to know. :thumbsup:

but when Shake is taking up 2GB of virtual memory, i can actually switch over and watch my disk's available space drop. and each of those handy little apps I close helps keep me from hitting the zero mark. :D

Ditto ! :)

By the way, thanks for the explanation ! :thumbsup: You learn everyday...

However, even if it's not taken on the physical memory, it's taking up a lot of space on the HD, and i must say that i hate when my little disk is making too much noise, due to access !! :devil:

Regards,
Laurent aka Tartiflette :)