IP Library › Granted Patent US 9,086,921
Granted Patent B2
US 9,086,921 · App. 13/460,547 · Granted Jul 21, 2015

Dynamic database memory management according to swap rates

Inventors: Boris Weissman (Palo Alto, CA); Aleksandr V. Mirgorodskiy (San Mateo, CA); Ganesh Venkitachalam (Mountain View, CA); Feng Tian (Fremont, CA)
Assignee: VMware, Inc.
G06F9/5016G06F17/30G06F17/30306G06F9/45533
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 9,086,921
App. No.
13/460,547
Granted
Jul 21, 2015
Kind
B2
Abstract

Memory of a database management system (DBMS) that is running in a virtual or physical machine is managed using techniques that that reduce the effect of memory swaps on the performance of the physical or virtual machine. One such technique includes the steps of determining a swap rate while the database application is in an executing state, and decreasing the size of memory space available to the database application if the swap rate is above a threshold.

Claims (29)

1. In a computer system having an operating system and a database application running as a user-level application on top of the operating system, a method of dynamically adjusting a size of memory space available to the database application, said method comprising the steps of:

determining a swap rate of memory pages swapped into memory from disk by the operating system while the database application is in an executing state; and

decreasing the size of memory space available to the database application if the swap rate is above a threshold, wherein the decreasing is carried out at a rate proportional to the swap rate.

2. The method of claim 1 , wherein said decreasing is carried out at the same rate as the swap rate.

3. The method of claim 1 , wherein the swap rate is a weighted average of multiple swap rates obtained over a period of time.

4. The method of claim 1 , further comprising:

if the swap rate is below the threshold for a period of time, increasing the size of memory space available to the database application.

5. The method of claim 4 , wherein the increasing is done at an exponentially increasing rate.

6. The method of claim 1 , wherein the computer system is a virtual machine running in a physical machine.

7. The method of claim 1 , wherein the computer system is a physical machine.

8. A non-transitory computer readable storage medium comprising instructions for causing a computer system having an operating system and a database application running as a user-level application on top of the operating system to carry out a method of dynamically adjusting a size of memory space available to the database application as a function of swap rate, said method comprising the steps of:

determining a swap rate of memory pages that are swapped into memory from disk by the operating system while the database application is in an executing state; and

decreasing the size of memory space available to the database application if the swap rate is above a threshold, wherein the decreasing is carried out at a rate proportional to the swap rate.

9. The non-transitory computer readable storage medium of claim 8 , wherein said decreasing is carried out at the same rate as the swap rate.

10. The non-transitory computer readable storage medium of claim 8 , wherein the swap rate is a weighted average of multiple swap rates obtained over a period of time.

11. The non-transitory computer readable storage medium of claim 8 , wherein the method further comprises:

if the swap rate is below the threshold for a period of time, increasing the size of memory space available to the database application.

12. The non-transitory computer readable storage medium of claim 11 , wherein the increasing is done at an exponentially increasing rate.

13. A method of managing memory of a database management system running in a virtual machine instantiated on a host computer having machine memory, wherein the database management system partitions an allocated memory address space into a plurality of memory pools and an initial size for each of the memory pools has been determined based on an initial allocation of guest physical memory to the virtual machine by the host system and a purpose for which the memory pool has been created, the method comprising:

periodically determining a current amount of guest physical memory allocated by the host computer to the virtual machine during execution of the database management system;

adjusting downward the current amount of guest physical memory allocated by the host computer to the virtual machine at a rate proportional to a swap rate of memory pages that are swapped into guest physical memory from disk in the virtual machine in response to the swap rate being above a threshold;

determining, for each memory pool, a current memory allocation measurement based on a current size of the memory pool and the determined current amount of guest physical memory;

requesting a release of a portion of memory from a memory pool if the determined current memory allocation measurement for the memory pool is greater than a target memory allocation measurement for the memory pool, wherein the target memory allocation measurement is based on the initial size of the memory pool and the initial allocation of guest physical memory to the virtual machine; and

requesting an additional allocation of a portion of memory for a memory pool if the determined current memory allocation measurement for the memory pool is less than the target memory allocation measurement for the memory pool.

14. The method of claim 13 , wherein the swap rate is a weighted average of multiple swap rates obtained over a period of time.

15. The method of claim 13 , wherein the current amount of guest physical memory allocated by the host computer to the virtual machine is adjusted downward at the same rate as the swap rate if the swap rate is above a threshold.

16. The method of claim 13 , further comprising:

adjusting upward the current amount of guest physical memory allocated by the host computer to the virtual machine in response to the swap rate continuing to be below a threshold for a predetermined duration of time.

17. The method of claim 16 , wherein the current amount of guest physical memory allocated by the host computer to the virtual machine is adjusted upward at an exponentially increasing rate.

Assignments (2)
CHANGE OF NAME Recorded Apr 15, 2024
From: VMWARE, INC.
To: VMWARE LLC
Reel/Frame 067102/0395 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded May 21, 2012
From: WEISSMAN, BORIS; MIRGORODSKIY, ALEKSANDR V.; VENKITACHALAM, GANESH; TIAN, FENG
To: VMWARE, INC.
Reel/Frame 028243/0715 →
Continuity (1)
Related Publication 20130290595A1 · Oct 31, 2013