site_archiver@lists.apple.com Delivered-To: darwin-kernel@lists.apple.com Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=dVCFuZZR7jgiCTRRoz1xtKljBdHoZg0wLk6F7LeQMVc=; b=LpCUx23iCi3iss+n5kGs6JLu3iJ+o9VXGRVKQ20xZUKR9dFe/yrHI70f+y6LGrof+D 2Joi5lVVQPkCtEpZk5/oASG8u7yv1oHrEmye6iPQRtnMPb/Y8uYaR0DGwT+nlRP8wLPV SeAN2ywsq4VVgHiOB8WtLoIokvwiTI3SGCyEM= Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=oqPEDvyYOIc4a1whAhFxMEtAn4OHhXZocf7xbC5vn+xtL2GJw4rkgGILL6crhfqVFy OlAkXV9Tui9JVgS9rsHJybckz8sO00tQg6iBDbQKTqzRZ8SDqpz0IPkCuy3uRkGMZ6O4 LrEVzxe8PQh0PMWn9GRgA4Hy7yM4JzZ3svrFk= Hi Nathan, there is or was certainly a reason for this limit, a hard limit is either more than or equal to a soft limit, as you said the soft limit can be changed through sysctl command, this value wasn't always defined as 2500, for instance, NPROC is using MAXUSERS, macosx is "by default" compiled with a "Medium scale" limit you can change it at compile time to setup a "larger scale" limit anyway these specifications are available in the UNIX03 process structure part Cheers! On Thu, Jan 29, 2009 at 11:15 AM, Nathan <nathan.stocks@gmail.com> wrote:
I've been posting about this to macos-x-server and unix-porting for a few days before it dawned on me that there was probably a kernel mailing list. So...Hi! My name's Nathan and this is my first post.
----
After a frustrating and long search for the root of the various problems I was having with my new Xserve serving email via IMAP, I was tipped off by...
http://support.apple.com/kb/TS1659
...that the kernel has insanely low defaults (for a server) for kern.maxproc (532), which controls the maximum amount of processes allowed to run on the system. While trying to raise the default to a reasonable value (Linux defaults to 32,768 for example), I discovered that I couldn't raise it above 2500. Peter O'Gorman tells me off that this is a hard-coded limit in Xnu:
./bsd/conf/param.c:#define HNPROC 2500 /* based on thread_max */
I've already filed rdar://6536876 asking that this be raised, but as I've had very poor returns with my filed bugs that I spent a long time researching, and very good returns on Apple mailing lists (go apple-x11!), I thought I'd post here too. :-)
Is there any reason the hard limit couldn't be raised an order of magnitude or two? Even with raising kern.maxproc (and kern.maxprocperuid and the launchd settings that mirror it and launchd's maxfiles setting, etc. etc) my Xserve will run into the process limit far before it exhausts CPU, RAM, disk, or bandwidth resources.
I'd be happy to provide some legwork (testing, doing some sanity checks on stuff in the kernel source code, etc.) if that would help. I am a registered ADC member and I'm willing to get my hands dirty to get this fixed. I've set up four-dozen OS X stations up in my company, as well as 200 linux stations, all of which access our Xserve for mail. It was very embarassing when we switched from our email hosting provider (who used OpenBSD) to our own Apple Xserve (I didn't want to have to learn to configure courier+cyrus+postfix+whatever all by myself on a Linux server) that we had so many problems for so long and it took two months to narrow it down to an apparently arbitrarily small value for kern.maxproc (and launchd).
~ Nathan _______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-kernel mailing list (Darwin-kernel@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-kernel/openspecies%40gmail.com
This email sent to openspecies@gmail.com
-- -mmw _______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-kernel mailing list (Darwin-kernel@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-kernel/site_archiver%40lists.a... This email sent to site_archiver@lists.apple.com