VM UMA counters.

Mark Johnston markj at freebsd.org
Wed Jan 20 14:17:38 UTC 2021


On Tue, Jan 19, 2021 at 12:44:14PM +0000, Santiago Martinez wrote:
> Hi there, sorry to ask this as it might be a silly question...
> 
> Since a few weeks im seeing random locks on application and sometimes
> when using truss it show resource temporally unavailable.
>
> Now, checking random things, i see that the
> vm.uma.256_Bucket.stats.fails counter is increasing while the other are
> not (at least for now).
> 
> Here goes the output:
> 
> vm.uma.256_Bucket.stats.xdomain: 0
> vm.uma.256_Bucket.stats.fails: 762142
> vm.uma.256_Bucket.stats.frees: 41935
> vm.uma.256_Bucket.stats.allocs: 42721
> vm.uma.256_Bucket.stats.current: 786
> 
> root at tucho:/home/smartinez # uname -a
> FreeBSD tucho 13.0-ALPHA1 FreeBSD 13.0-ALPHA1 #13
> main-c256107-g7d3310c4fcdd: Tue Jan 19 10:50:12 GMT 2021    
> smartinez at tucho:/usr/obj/usr/src/amd64.amd64/sys/GENERIC-NODEBUG  amd64
> 
> My question is, is this the expected behavior?

There are situations where bucket allocations must fail to avoid
recursing back into the VM.  For instance, allocation of a UMA slab may
require allocation of a radix node entry from UMA, which may attempt
allocation of a bucket, which could trigger allocation of a slab.

It's therefore normal to see a non-zero number of failures after
booting, but after that the bucket zone's caches are populated and
failures should become rare.  Failures might also be triggered during
severe memory shortages.  Could you show vmstat -s from an affected
system?  Are you using any DRM graphics drivers by any chance?


More information about the freebsd-current mailing list