Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: system wide new *limit*



--On Wednesday, April 30, 2003 00:26 +0800 Charles So <email@hidden> wrote:

Hi, I am running client version of OSX 10.2.5.

I am doing Java development, and now the default **limit*** is not large
enough. You can type "limit" in a shell and see the default values.

How do I set new values and make them system wide?


This is something that sucks rather a lot about OSX; as far as I've noticed, there are only two ways to get the limits to increase and stay increased for all users (since only root can increase a value, mortal users can not).

First off, like most BSD variants you use the "sysctl" command to increase/modify certain values. For example:

sysctl -w kern.maxproc=1000

Would set the maximum number of processes the kernel can run to 1000...

sysctl -a will report all values...

The second thing you can do is increase the values with ulimit, but the only place that I've gotten this done and had it work is in /etc/rc.common where I have the following:

ulimit -u256 -s8192 -d12288

Sets the following:

cputime unlimited
filesize unlimited
datasize 12288 kbytes
stacksize 8192 kbytes
coredumpsize 0 kbytes
memoryuse unlimited
descriptors 256
memorylocked unlimited
maxproc 256

-u is the maxproc per user -- out of the box osx seems to use the *INSANELY LOW* value of 100, and other than my putting that line at the end of my /etc/rc.common and rebooting, I can't get the values working.

One problem I've had is that if I logout and log back in, the kernel builtin value of 100 takes over and I'm stuck until I next reboot.

There may be other solutions to this problem, but this is the only one that I've stumbled into that works regularly.

Good luck,

Scott
_______________________________________________
macos-x-server mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/macos-x-server
Do not post admin requests to the list. They will be ignored.

References: 
 >system wide new *limit* (From: Charles So <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.