On Fri, Sep 12, 2025 at 5:46 PM Rick Macklem <[email protected]> wrote: > > On Fri, Sep 12, 2025 at 8:58 AM Garrett Wollman <[email protected]> > wrote: > > > > <<On Fri, 12 Sep 2025 08:50:10 -0700, Rick Macklem <[email protected]> > > said: > > > > > Ok, but don't we want something that prevents the arc from taking all > > > the memory? (It seems like 932Gbytes should be close to a hard > > > upper bound for a system with 1Tbyte of ram?) > > > > Presently it says: > > > > kstat.zfs.misc.arcstats.c_max: 1098065367040 > > > > That's 1 TiB less 1379 MiB. Which in all honesty *ought to be enough* > > for munin-node, nrpe, ntpd, sendmail, inetd, lldpd, nslcd, sshd, syslogd, > > mountd, and nfsuserd. > If you look at arc_default_max() in > sys/contrib/openzfs/module/os/freebsd/arc_os.c > you'll see it returns "allmem - 1Gbyte". > This may make sense for a machine with a few Gbytes of ram, but I'd bump it > up for machines like you have. (As I noted, a system that boots with > 128Gbyte->1Tbyte > of ram is going to size things a lot larger and "allmem" looks like > the total ram in the > system. They haven't even subtracted out what the kernel uses.) > (Disclaimer: I know nothing about ZFS, so the above may be crap!!) > > It's a trivial function to patch, rick Here's another simple one..look at.. # sysctl -a | fgrep maxmbufmem It appears to be set to 1/2 of the physical memory for me.
Lets see, 50% of memory allocated to mbufs and 99.9% of physical memory allowed for the arc. - This reminds me of the stats CNN puts up, where the percentages never add up to 100. rick > > > > > -GAWollman > >
