Increasing KVM on amd64

Tz-Huan Huang tzhuan at
Sun Jun 8 08:56:39 UTC 2008

On Sun, Jun 8, 2008 at 2:02 PM, Alan Cox <alc at> wrote:
> Tz-Huan Huang wrote:
>> On Sun, Jun 8, 2008 at 7:59 AM, Alan Cox <alc at> wrote:
>>> You can download a patch from
>>> that increases amd64's
>>> kernel virtual address space to 6GB.  This patch also increases the
>>> default
>>> for the kmem map to almost 2GB.  I believe that kernel loadable modules
>>> still work.  However, I suspect that mini-dumps are broken.
>>> I don't plan on committing this patch in its current form.  Some of the
>>> changes are done in a hackish way.  I am, however, curious to hear
>>> whether
>>> or not it works for you.
>> Thanks for the patch. I applied it on 7-stable but got failed on pmap.c.
> [snip]
>> We have no machine running 8-current with more than 6G memory now...
> Sorry, at this point the patch is only applicable to HEAD.  That said, the
> failed chunk is probably easily applied by hand to RELENG_7.

Ok, I applied the patch and fixed the failed chunk by hand.
I also modified the type of vm_kmem_size from u_int to u_long.
Here is the diff:

The patched kernel is compiled and boots without problem. I set the
vm.kmem_size/vm.kmem_size_max to 3G and vfs.zfs.arc_max
to 2G, everything looks fine. Some stress tests are running now,
I'll report if any problem.


More information about the freebsd-hackers mailing list