nmbclusters

Chris chrcoluk at gmail.com
Thu Mar 30 00:11:50 UTC 2006


On 29/03/06, Robert Watson <rwatson at freebsd.org> wrote:
>
> On Wed, 29 Mar 2006, Dag-Erling Smørgrav wrote:
>
> > "Conrad J. Sabatier" <conrads at cox.net> writes:
> >> Chris <chrcoluk at gmail.com> wrote:
> >>> so [kern.ipc.nmbclusters] has no affect, has this become a read only
> >>> tunable again only settable in loader.conf?
> >> To the best of my knowledge, this has *always* been a loader tunable,
> >> not configurable on-the-fly.
> >
> > kern.ipc.nmbclusters is normally computed at boot time.  A compile- time
> > option to override it was introduced in 2.0-CURRENT.  At that time, it was
> > defined in param.c.  A read-only sysctl was introduced in 3.0-CURRENT.  It
> > moved from param.c to uipc_mbuf.c in 4.0-CURRENT, then to subr_mbuf.c when
> > mballoc was introduced in 5.0-CURRENT; became a tunable at some point after
> > that; then moved again to kern_mbuf.c when mballoc was replaced with mbuma
> > in 6.0-CURRENT.  That is the point where it became read-write, for no good
> > reason that I can see; setting it at runtime has no effect, because the size
> > of the mbuf zone is determined at boot time.  Perhaps Bosko (who wrote both
> > mballoc and mbuma, IIRC) knows.
>
> Paul Saab from Yahoo! has a set of patches that allow run-time nmbclusters
> changes to be implemented -- while it won't cause the freeing of clusters
> referenced, it goes through and recalculates dependent variables, propagates
> them into UMA, etc.  I believe they're running with this patch on 6.x, and I
> expect that they will be merged to -CURRENT and -STABLE in the relatively near
> future.  Not before 6.1, however.
>
> If the nmbclusters setting really has no effect right now, we should mark the
> sysctl as read-only to make it more clear it doesn't, since allowing it to be
> set without taking effect is counter-intuitive.
>
> Robert N M Watson
>

thanks for everyones responses.  My 5.4 servers seem to accept the
tunable been changed at runtime although this could be a bug and it
isnt really changing?  4.x I know was a boot only tunable.  I have
tested this now in loader.conf and it works so it seems its a minor
bug where the error message is replaced by a false success output.

Chris


More information about the freebsd-stable mailing list