Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the 'Size of the swap partition' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Size of the swap partition
Authored by: hamarkus on Aug 09, '04 12:55:46PM

According to Activity Monitor, I currently have a VM size of 12GB, this usually hoovers around 10GB, depending on how many big programms I have open. If I use a lot of memory in one application (e.g. 15 tabs in Mozilla, big InDesign project) all of the palettes of e.g. the Adobe programms get pushed out of real memory into the VM part and it takes several seconds to load them again when you switch to these programms.

Shouldn't therefore a really big scratch partition (~10GB) be a better choice?
(1GB RAM, 2.5" 60GB)



[ Reply to This | # ]
Leave space for burning
Authored by: gw on Aug 09, '04 01:43:00PM

If you do partition, note that DVD and CD burning within OSX/Finder rely on spare space on the boot/system partition - so a System size of 6GB may let you run your system but not burn a DVD.

Of course if you don't have a DVD burner it's irrelevant.

I use 10GB system and it works well, I have most applications there too, although a couple of bigger apps (iDVD) are on another partition.

---
----
"I only conceptualize, everything else is hardware."
Prof. L.B. Wilson



[ Reply to This | # ]
Size of the swap partition
Authored by: aramis on Aug 09, '04 02:00:02PM

My understanding of the VM Size is that it includes all shared libraries as well as any memory mapped IO.

Even though a shared library is only loaded into physical memory once (physical being either chips or in swap files), each process gets its own virtual copy of the library mapped into its own space. If 20 processes all load the same 1MB shared library, then the total VM size for all those processes will go up by 20MB. The actual physical memory you use (chips plus swap) will only go up by 1MB, though.

Likewise, if you have a 500MB file memory mapped, the VM size goes up by 500MB, but the actual physical memory goes up by zero since the file is still stored on disk and not actually loaded into memory (not counting disk cache, which is a whole different story).



[ Reply to This | # ]
Size of the swap partition
Authored by: hamarkus on Aug 09, '04 03:46:03PM

Thanks for the info, I always get nervous when the VM size reaches twice the free disk space...



[ Reply to This | # ]
Size of the swap partition
Authored by: folkert on Aug 09, '04 03:13:00PM
i am too lazy to write up a full hint, but since the original poster mentioned a swap partition of one gigabyte...

i also chose a 1GB swap partition, only to find that the dynamic_pager does not make the most efficient use of it with default settings. dynamic_pager seems to have two modes of allocating new virtual memory, one where it doubles the size of the new swapfile with each file, and one where the size of the swapfile is fixed. now, with a one gig partition and a variable swapfile size, the following happpened: dynamic_pager happily created pages when needed, but, after a little over .75GB of VM where in use, refused to create a new swapfile because the size of the new file was slightly larger than the remaining space. the answer i found for my system was to start dynamic_pager with parameters
dynamic_pager -F ${swapdir}/swapfile -S 67108864 -H 33554432 -L 134217728

where -S means 'create swapfiles with a size of 64MB', -H 33554432 means 'create a new file when less than 32MB of free swapfile memory available' and -L 134217728 means 'discard a swapfile if more than 128MB of swapfile memory are unused'.

of course, the actual sizes i chose could be rather braindead. for further reading, try man dynamic_pager.
cheers,
-folkert.

---
$ hexdump /mach_kernel|head -1
0000000 feed face 0000 0012 0000 0000 0000 0002


[ Reply to This | # ]

Size of the swap partition
Authored by: sjk on Aug 12, '04 02:11:19PM
See huge swap files in 10.3.4 ?? on Apple Discussions for more about that topic.

[ Reply to This | # ]