huge ktr buffer

rank1seeker at gmail.com rank1seeker at gmail.com
Sun Dec 9 13:41:11 UTC 2012


> As also Alan suggested, a way to workaround the problem is to increase
> NKPT value (e.g. from 32 to 64). Obviously, this is not a proper fix.
> For a proper fix the kernel needs to be able to dynamically set the
> size of NKPT.  In this particular case, this wouldn't be too hard, but
> there is a different case, where people preload a large memory disk
> image at boot time that isn't so easy to fix.
> 
> Thanks,
> 
> Davide


Had a same issue.
I use very big preloaded images, with full world + many compiled ports in it.

Fix:
'sh' code snip ...
----
# Get default NKTP value
nkpt=`cat "/sys/$arch/include/pmap.h" | sed -En 's/.+NKPT[[:blank:]]+([0-9]{2})$/\1/p'`

# How many additional NKPT (4 Mb each), for our image, added to amount of NKPT?
# Calculated in Kb
: $((nkpt += "$img_size" / 4096))
----

But it loads sooooo slow into the RAM.
That should be enhanced, too.


Domagoj Smolčić


More information about the freebsd-hackers mailing list