Freebsd 8.0 kmem map too small

Giulio Ferro auryn at zirakzigil.org
Mon May 3 12:26:59 UTC 2010


On 03.05.2010 13:01, Jeremy Chadwick wrote:
> On Mon, May 03, 2010 at 12:41:50PM +0200, Giulio Ferro wrote:
>    
>> NFS server amd64 Freebsd 8.0 recent (2 days ago)
>>
>> This server has been running for several months without problems.
>> Beginning last week, however, I'm experiencing panics (about 1 per day)
>> with the error in the subject
>>
>> Current settings:
>>
>>
>> vm.kmem_size_scale: 3
>> vm.kmem_size_max: 329853485875
>> vm.kmem_size_min: 0
>> vm.kmem_size: 2764046336
>> ...
>> hw.physmem: 8568225792
>> hw.usermem: 6117404672
>> hw.realmem: 9395240960
>> ...
>> vfs.zfs.l2arc_noprefetch: 0
>> vfs.zfs.l2arc_feed_secs_shift: 1
>> vfs.zfs.l2arc_feed_secs: 1
>> vfs.zfs.l2arc_headroom: 128
>> vfs.zfs.l2arc_write_boost: 67108864
>> vfs.zfs.l2arc_write_max: 67108864
>> vfs.zfs.arc_meta_limit: 431882240
>> vfs.zfs.arc_meta_used: 431874720
>> vfs.zfs.arc_min: 215941120
>> vfs.zfs.arc_max: 1727528960
>>
>>
>> I've set nothing in either /boot/loader.conf or sysctl.conf
>>
>>
>> What should I do?
>>      
> You need to adjust vm.kmem_size to provide more space for the ARC.
>
> Below are ZFS-relevant entries in our /boot/loader.conf on production
> RELENG_8 systems with 8GB of RAM.  The reason we set kmem_size to half
> our physical system memory is because I didn't want to risk other
> processes which use a larger maxdsiz/dfldsiz/maxssiz to potentially
> exhaust all memory.
>
>
> # Increase vm.kmem_size to allow for ZFS ARC to utilise more memory.
> vm.kmem_size="4096M"
> vfs.zfs.arc_max="3584M"
>
> # Disable ZFS prefetching
> # http://southbrain.com/south/2008/04/the-nightmare-comes-slowly-zfs.html
> # Increases overall speed of ZFS, but when disk flushing/writes occur,
> # system is less responsive (due to extreme disk I/O).
> # NOTE: 8.0-RC1 disables this by default on systems<= 4GB RAM anyway
> # NOTE: System has 8GB of RAM, so prefetch would be enabled by default.
> vfs.zfs.prefetch_disable="1"
>
> # Decrease ZFS txg timeout value from 30 (default) to 5 seconds.  This
> # should increase throughput and decrease the "bursty" stalls that
> # happen during immense I/O with ZFS.
> # http://lists.freebsd.org/pipermail/freebsd-fs/2009-December/007343.html
> # http://lists.freebsd.org/pipermail/freebsd-fs/2009-December/007355.html
> vfs.zfs.txg.timeout="5"
>
>
>    


Thanks, I'll try these settings.

I'll keep you posted.


More information about the freebsd-stable mailing list