Skip site navigation (1)Skip section navigation (2)
Date:      17 Jan 2003 12:22:46 +1000
From:      Duncan Anker <d.anker@au.darkbluesea.com>
To:        Frank Li <frank19991@hotmail.com>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: Increase memory limit ?
Message-ID:  <1042770166.17336.86.camel@duncan.au.darkbluesea.com>
In-Reply-To: <F74BJjvmZp0mmhQZiCT0000070b@hotmail.com>
References:  <F74BJjvmZp0mmhQZiCT0000070b@hotmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
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




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1042770166.17336.86.camel>