Uploaded image for project: 'Documentation'
  1. Documentation
  2. DOCS-4037

Mongod and VMware vmmemctl (balloon driver) needs an official explanation

      The balloon driver for VMWare (or Xen, Hyper-V,etc) seems like is not compatible with mongod.

      The explanation about the balloon driver utility is the following:

      If a database VM needs to compete for the same physical memory space with other VMs, the hypervisor could start allocating memory on disk.

      Using vmmemctl (balloon driver), if the hypervisor decides that it wants to reduce the amount of physical memory used by the VM, the driver starts to perform memory allocations inside the VM pushing out other memory data to disk (to the swap space).

      This behaviour is highly desirable in general, because otherwise the hypervisor would have to allocate the VM memory data in it's own swap file. In that case the OS believes that it has allocated physical memory, and the application will experience some unexplainable delays and result in performance problems.

      The main concern with the balloon driver relates to the experience of some of our customers in which crashes no longer occur when the driver is disabled.

      I found a bug in the driver related to mmap allocation. IMHO VMware bug KB1003586 do not affect mongod because it don't pin or lock memory pages (SERVER-8121) for now.

      Our recommendation is to disable the balloon driver, but I might add the need for reserve sufficient physical memory in the hypervisor for the VM to ensure the database’s working set fits within it.

            Assignee:
            michael.paik Michael Paik
            Reporter:
            ricardo.lorenzo Ricardo Lorenzo
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved:
              7 years, 39 weeks, 2 days ago