Abstract
This paper presents a predictive approach to database buffer allocation that utilizes real-time queuing models to optimize system-wide throughput and disk utilization. By moving beyond static allocation rules like those in DBMIN, the proposed algorithms adapt to dynamic workloads and varying memory availability. Experimental results demonstrate that these predictive methods consistently outperform traditional techniques, particularly in I/O-bound scenarios with complex query patterns.
Introduction
In relational database management systems (RDBMS), the buffer manager serves as the critical gatekeeper of memory. It must simultaneously manage admission control—deciding when to start a query—and buffer allocation—deciding how much memory to grant it. Historically, these decisions were governed by static rules that either ignored query behavior or ignored system load. This paper introduces a "predictive" approach that uses simple queuing models to forecast the impact of allocation decisions in real-time, allowing for a more flexible and efficient use of system resources.
The Challenge of Static Allocation
Traditional state-of-the-art methods, such as DBMIN, rely on the concept of a "locality set"—the minimum number of buffers a query needs to run efficiently. Under DBMIN, a query is only admitted if its exact locality set is available. While this prevents thrashing, it is fundamentally static. If the system is under-utilized, DBMIN will not grant extra buffers that could further improve performance. Conversely, if the system is heavily loaded, it may block queries that could have run adequately with fewer resources.
The goal is to find the "golden cut": an optimal allocation that maximizes total system throughput by balancing query-specific patterns with current memory availability and dynamic workload shifts.
Predictive Methodology
The core innovation of this work is the replacement of static rules with real-time Predictors. Before admitting a query, the system employs a mathematical model to estimate if the decision will improve overall performance.
- Queueing Model: A closed queueing model with CPU and Disk servers allows for $O(1)$ performance estimation, making it suitable for high-frequency admission decisions.
- Performance Measures: Two primary predictors are used:
- Throughput (TP): Directly estimates the change in completed queries per second.
- Effective Disk Utilization (EDU): Focuses on keeping the disk busy with unavoidable work by minimizing "wasted" time spent on avoidable page faults.
- Flexible Allocation Policies: The system can choose between Optimistic (maximum useful buffers), Pessimistic (minimum buffers), or 2-Pass (a hybrid approach that distributes "luxury" buffers after initial conservative allocation) strategies.
Performance Evaluation
The algorithms were evaluated using a detailed simulation environment across various query mixes. Mix 1, for instance, was dominated by looping references (70%), which are highly sensitive to buffer availability.
As shown in Figure 3, the predictive algorithms (TP-o, EDU-o, and EDU-2) consistently outperformed DBMIN. In scenarios with many looping queries, the predictive methods achieved throughput gains of 30-35%. A key insight is that giving a query fewer buffers than its ideal locality set can actually improve total system throughput if it enables higher concurrency without causing disk thrashing.
Furthermore, the predictive models demonstrated superior adaptability. Unlike parameterized models (like MG-x-y) which require manual tuning for specific workloads, the TP and EDU predictors automatically adjusted to changing query mixes and exploited data sharing in the buffer pool more effectively than static alternatives.
Conclusion
Predictive load control represents a significant shift from rule-based buffer management to model-based optimization. By considering the disk as the primary bottleneck and using real-time predictors to guide allocation, database systems can achieve higher throughput and better adaptability to dynamic real-world workloads. Future work will extend these models to multi-disk environments and explore deeper analytical frameworks for data-sharing dynamics.
Summary updated