From owner-freebsd-questions Thu Jan 16 18:22:34 2003 Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 24E4437B401 for ; Thu, 16 Jan 2003 18:22:32 -0800 (PST) Received: from mail.au.darkbluesea.com (mail.au.darkbluesea.com [203.185.208.1]) by mx1.FreeBSD.org (Postfix) with ESMTP id C175943F18 for ; Thu, 16 Jan 2003 18:22:30 -0800 (PST) (envelope-from d.anker@au.darkbluesea.com) Received: (qmail 63997 invoked by uid 82); 17 Jan 2003 02:18:08 -0000 Received: from unknown (HELO ?10.0.0.188?) (10.0.0.188) by mail.au.darkbluesea.com with SMTP; 17 Jan 2003 02:18:08 -0000 Subject: Re: Increase memory limit ? From: Duncan Anker To: Frank Li Cc: freebsd-questions@freebsd.org In-Reply-To: References: Content-Type: text/plain Organization: Dark Blue Sea Message-Id: <1042770166.17336.86.camel@duncan.au.darkbluesea.com> Mime-Version: 1.0 X-Mailer: Ximian Evolution 1.2.0 Date: 17 Jan 2003 12:22:46 +1000 Content-Transfer-Encoding: 7bit Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Fri, 2003-01-17 at 12:08, Frank Li wrote: > Thanks for all of your replies, > > Now I can do it through recompiling the kernel and the limits did increase. > I haven't tried whether it can increase over 2G (I would love that if it > can!). The code I used cannot be easily changed to reduce memory > consumption but I think 2G would probably be enough for some time. Indeed, > I found the max value I could set is 2048*1024*1024-1, bigger than that will > result in a negative value shown by "limit". Yes, 2G - 1 is the maximum size a signed int can hold ... mind you, any program needing more that 2G of memory really should be implementing on-disk storage of data for itself. > > >You can also tune this at boot time by adding them to the file > >/boot/loader.conf. e.g. > > > >kern.maxdsiz="(256*1024*1024)" > > I added this (though it was actually 1024*1024*1024) to /boot/loader.conf > and also /boot/defaults/loader.conf, and booted the GENERIC kernel. Yes, I just copied the numbers from what was given above - I should have substituted 1024 or more in there. > The limits were still the old ones (i.e.512M). It did not work I don't know > why, but I am already happy as recompiling kernel worked anyway. It may be the case that you cannot specify the value like that in loader.conf, in which case we must do the math ourselves. I am glad your problem is solved. > > The final problem now becomes: Initially I made the swap partition to be 1GB > and there is no more free partition on my harddisk. This value now actually > becomes the bottleneck. Repartitioning will lose all my data and also > applications installed, and thus is very high cost operation. Is there any > easy way to increase the swap partition ? Read this, it may help: http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/adding-swap-space.html -- The information contained in this email is confidential. If you are not the intended recipient, you may not disclose or use the information in this email in any way. Dark Blue Sea does not guarantee the integrity of any emails or attached files. The views or opinions expressed are the author's own and may not reflect the views or opinions of Dark Blue Sea. Dark Blue Sea does not warrant that any attachments are free from viruses or other defects. You assume all liability for any loss, damage or other consequences which may arise from opening or using the attachments. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message