Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 06 Jan 2008 22:42:43 +0100
From:      Kris Kennaway <kris@FreeBSD.org>
To:        Vadim Goncharov <vadimnuclight@tpu.ru>
Cc:        freebsd-current@freebsd.org
Subject:   Re: When will ZFS become stable?
Message-ID:  <47814B53.50405@FreeBSD.org>
In-Reply-To: <opt4i0g3k44fjv08@nuclight.avtf.net>
References:  <fll63b$j1c$1@ger.gmane.org>		<20080104163352.GA42835@lor.one-eyed-alien.net>		<9bbcef730801040958t36e48c9fjd0fbfabd49b08b97@mail.gmail.com>		<200801061051.26817.peter.schuller@infidyne.com>		<9bbcef730801060458k4bc9f2d6uc3f097d70e087b68@mail.gmail.com>		<4780D289.7020509@FreeBSD.org>	<flqmbo$eac$1@ger.gmane.org>		<4780E546.9050303@FreeBSD.org>	<9bbcef730801060651y489f1f9bw269d0968407dd8fb@mail.gmail.com>	<4780EF09.4090908@FreeBSD.org>	<flr0ie$euj$1@ger.gmane.org>	<47810BE3.4080601@FreeBSD.org> <flr2lr$kph$1@ger.gmane.org> <4781113C.3090904@FreeBSD.org> <opt4i0g3k44fjv08@nuclight.avtf.net>

next in thread | previous in thread | raw e-mail | index | archive | help
Vadim Goncharov wrote:
> 06.01.08 @ 23:34 Kris Kennaway wrote:
> 
>>> What is the other 512 MB of the 1 GB used for?
>>
>> Everything else that the kernel needs address space for.  Buffer 
>> cache, mbuf allocation, etc.
> 
> Aren't they allocated from the same memory zones? I have a router with 
> 256 Mb RAM, it had a panic with ng_nat once due to exhausted kmem. So, 
> what these number from it's sysctl do really mean?
> 
> vm.kmem_size: 83415040
> vm.kmem_size_max: 335544320
> vm.kmem_size_scale: 3
> vm.kvm_size: 1073737728
> vm.kvm_free: 704638976
> 

I believe that mbufs are allocated from a separate map.  In your case 
you only have ~80MB available in your kmem_map, which is used for 
malloc() in the kernel.  It is possible that ng_nat in combination with 
the other kernel malloc usage exhausted this relatively small amount of 
space without mbuf use being a factor.

Kris



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