Skip to main content

Automated SQL tuning through trial and (sometimes) error

Publication ,  Journal Article
Herodotou, H; Babu, S
Published in: Proceedings of the 2nd International Workshop on Testing Database Systems, DBTest '09
November 23, 2009

SQL tuning - the attempt to improve a poorly-performing execution plan produced by the database query optimizer - is a critical aspect of database performance tuning. Ironically, as commercial databases strive to improve on the manageability front, SQL tuning is becoming more of a black art. It requires a high level of expertise in areas like (i) query optimization, run-time execution of query plan operators, configuration parameter settings, and other database internals; (ii) identification of missing indexes and other access structures; (iii) statistics maintained about the data; and (iv) characteristics of the underlying storage system. Since database systems, their workloads, and the data that they manage are not getting any simpler, database users and administrators often rely on trial and error for SQL tuning. In this paper, we take the position that the trial-and-error (or, experiment-driven) process of SQL tuning can be automated by the database system in an e cient manner; freeing the user or administrator from this burden in most cases. A number of current approaches to SQL tuning indeed take an experiment-driven approach. We are prototyping a tool, called zTuned, that automates experiment-driven SQL tuning. This paper describes the design choices in zTuned to address three nontrivial issues: (i) how is the SQL tuning logic integrated with the regular query optimizer, (ii) how to plan the experiments to conduct so that a satisfactory (new) plan can be found quickly, and (iii) how to conduct experiments with minimal impact on the user-facing production workload. We conclude with a preliminary empirical evaluation and outline promising new directions in automated SQL tuning. Copyright 2009 ACM.

Duke Scholars

Published In

Proceedings of the 2nd International Workshop on Testing Database Systems, DBTest '09

DOI

Publication Date

November 23, 2009
 

Citation

APA
Chicago
ICMJE
MLA
NLM
Herodotou, H., & Babu, S. (2009). Automated SQL tuning through trial and (sometimes) error. Proceedings of the 2nd International Workshop on Testing Database Systems, DBTest ’09. https://doi.org/10.1145/1594156.1594171
Herodotou, H., and S. Babu. “Automated SQL tuning through trial and (sometimes) error.” Proceedings of the 2nd International Workshop on Testing Database Systems, DBTest ’09, November 23, 2009. https://doi.org/10.1145/1594156.1594171.
Herodotou H, Babu S. Automated SQL tuning through trial and (sometimes) error. Proceedings of the 2nd International Workshop on Testing Database Systems, DBTest ’09. 2009 Nov 23;
Herodotou, H., and S. Babu. “Automated SQL tuning through trial and (sometimes) error.” Proceedings of the 2nd International Workshop on Testing Database Systems, DBTest ’09, Nov. 2009. Scopus, doi:10.1145/1594156.1594171.
Herodotou H, Babu S. Automated SQL tuning through trial and (sometimes) error. Proceedings of the 2nd International Workshop on Testing Database Systems, DBTest ’09. 2009 Nov 23;

Published In

Proceedings of the 2nd International Workshop on Testing Database Systems, DBTest '09

DOI

Publication Date

November 23, 2009