pf can't get memory for tables

Scott Bennett bennett at
Sat Feb 18 13:12:48 UTC 2017

Arthur Chance <freebsd at> wrote:

> On 17/02/2017 09:19, Scott Bennett wrote:
> [much snippage]
> > After
> > puzzling over this turn of events on my screen for several seconds...aha!
> > The machine has only 4 GB of RAM, so a long while back I added
> > 
> > vm.kmem_size_max=805306368
> > 
> > to /boot/loader.conf in order to limit the tendency at the time for ZFS to
> > take over everything with a growing ARC.  Unfortunately, vm.kmem_size_max
> > is one of those tunables that can only be set at boot time, so I can't easily
> > experiment with increasing the value. 
> If you want to control the ARC size, surely setting vfs.zfs.arc_max in
> /boot/loader.conf is more specific than vm.kmem_size_max? Unfortunately
> that's a boot time tunable as well.
     The problem with vfs.zfs.arc_max is that it is one of several tunables
that are not available when zfs.ko is not currently loaded (or compiled into
the kernel).  There are some situations from time to time where I don't want
ZFS present, so I unload the module before continuing the boot sequence, and
then if vfs.zfs.arc_max is specified in /boot/loader.conf, it results in an
error condition and message.  vm.kmem_size_max may seem a bit ham-handed, but
it does do the job whether ZFS is present or not.

                                  Scott Bennett, Comm. ASMELG, CFIAG
* Internet:   bennett at   *xor*   bennett at  *
* "A well regulated and disciplined militia, is at all times a good  *
* objection to the introduction of that bane of all free governments *
* -- a standing army."                                               *
*    -- Gov. John Hancock, New York Journal, 28 January 1790         *

More information about the freebsd-questions mailing list