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


Click here to return to the 'A solution for Mac OS X process limits' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
A solution for Mac OS X process limits
Authored by: hgd on Oct 05, '04 03:34:49AM
I have modified this solution in a way that may make it more stable across OS upgrades. WindowServer tends to get overwritten, so you'd have to reinstall the wrapper script after each upgrade. That's why I left the WindowServer binary as is and created a wrapper script called WindowServer.local:

#!/bin/sh

ulimit -u 512

/System/Library/Frameworks/ApplicationServices.framework/Frameworks/CoreGraphics.framework/Resources/WindowServer "$*"
I then configured mach_init to launch this script by modifying the file /etc/mach_init.d/WindowServer.plist. This is what it looks like now:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
        <key>ServiceName</key>
        <string>com.apple.windowserver</string>
        <key>Command</key>
        <string>/System/Library/Frameworks/ApplicationServices.framework/Frameworks/CoreGraphics.framework/Resources/WindowServer.local</string>
</dict>
</plist>
This works fine as well. I'm not sure if /etc/mach_init.d/WindowServer.plist isn't overwritten during upgrades as well, so this may all amount to nothing ;-)

[ Reply to This | # ]
A solution for Mac OS X process limits
Authored by: jnathan on Oct 08, '04 01:38:45PM

I've just began looking into this as it's awfully frustating. There may be a simpler fix.

/System/Library/StartupItems/CoreGraphics is a script called as part of the StartupItems process.

the line:
ConsoleMessage -b /System/Library/CoreServices/SystemStarter/QuartzDisplay.bundle/QuartzDisplay


Starts the set of QuartzDisplay components which include WindowServer. I'm going to try setting ulimit -u in the CoreGraphics script.



[ Reply to This | # ]
A solution for Mac OS X process limits
Authored by: hgd on Oct 16, '04 07:24:35AM

So, does that work for you? I doubt it, because the file already sources rc.common. If you set the ulimit in rc.common, it should thus already affect WindowServer, but (apparently) it doesn't ...



[ Reply to This | # ]