摘要
云数据库中存在许多配置项,包括数据库内部的配置参数以及部署环境的虚拟机资源配置,这些配置项共同决定了数据库的读写性能和资源消耗。在资源弹性伸缩的云环境下,用户关注数据库的服务性能和资源消耗成本。然而,由于配置项众多且负载变化快速,寻找最优的配置项组合变得困难。文中针对负载动态变化的在线调优场景提出了CoTune,一种协同调节云数据库资源与参数的快速调优方法。该方法针对OLTP型动态负载,通过迭代调节云虚拟机资源配置和数据库参数配置,在保障服务质量的前提下降低资源消耗。该方法的创新点如下:首先,在每个调优周期内,采用三阶段方案对资源配额和数据库参数进行调节,优先保障服务质量;其次,根据数据库参数对不同资源的影响进行分类,减小搜索空间,快速调节参数;最后,在数据库参数调节的强化学习模型中,设计特定的奖励函数,快速获取奖励值,加快调节频率。实验结果表明,该方法相比同时调节资源和参数、单独调节资源等方法,能够在保障服务质量的前提下降低资源消耗。通过快速迭代调优,能够应对负载变化的挑战,并在动态负载环境中实现更高效的资源利用。
In cloud databases,there are numerous configuration options,including internal database parameters and virtual machine resource configuration for the environment deployment,which collectively determine the database’s read/write performance and resource consumption.In the cloud environment with elastic resources,users are concerned about both the database’s service performance and resource consumption costs.However,due to the large number of configuration options and rapid workload changes,finding the optimal combination of configurations becomes challenging.To address the online tuning scenario with dynamically changing workloads,this paper proposes CoTune,a fast tuning method for coordinating cloud database resources and parameters.This method focuses on OLTP workloads and iteratively adjusts the configurations of virtual machine resources and database parameters to minimize resource consumption while ensuring service quality.The method introduces several key innovations:firstly,it adopts a three-stage approach within each tuning cycle to adjust resource quotas and database parameters,prioritizing service quality;secondly,it classifies the impact of database parameters on different resources,reducing the search space and enabling rapid parameter adjustments;and finally,it incorporates a reinforcement learning model for database parameter tuning,with a specific reward function designed to quickly obtain reward values and accelerate the tuning frequency.Experimental results demonstrate that,compared to approaches that simultaneously tune resources and parameters or solely focus on resource tuning,the proposed method reduces resource consumption while maintaining service quality.Through rapid iterative tuning,it effectively addresses the challenges posed by workload variations and achieves more efficient resource utilization in dynamic workload environments.
作者
李雨航
谭睿雄
柴云鹏
LI Yuhang;TAN Ruixiong;CHAI Yunpeng(Key Laboratory of Data Engineering and Knowledge Engineering,Ministry of Education,Beijing 100872,China;Engineering Research Center of Database and Business Intelligence,Ministry of Education,Beijing 100872,China;School of Information,Renmin University of China,Beijing 100872,China)
出处
《计算机科学》
CSCD
北大核心
2024年第6期104-110,共7页
Computer Science
基金
国家自然科学基金(61972402,61972275)。
关键词
云数据库
参数调优
服务质量
资源消耗
Cloud database
Parameter tuning
Quality-of-Service
Resource consumption