skip to main content
10.1145/3626246.3653382acmconferencesArticle/Chapter ViewAbstractPublication PagesmodConference Proceedingsconference-collections
research-article

TimeCloth: Fast Point-in-Time Database Recovery in The Cloud

Published: 09 June 2024 Publication History

Abstract

In recent years, we have noted the frequent occurrence of user-triggered database recoveries in the cloud. In contrast to traditional failure-triggered recovery scenarios, they come with unique consumer-centric challenges. Unfortunately, current solutions prove inefficient, falling short either in meeting our customers' requirements or due to their close integration with the native recovery support of the underlying database engines.
In this work, we present TimeCloth, a generic cloud-native recovery mechanism that achieves sublinear recovery time while meeting the specific needs of our customers. It comprises a recovery module optimized for fine-grained point-in-time recoveries and an import module enabling nearly instantaneous access to remote tables. The recovery module performs fast log filtering, parallelizes replay of non-conflicting log records and coalesce log records to reduce the volume of replay work. The import module implements a transparent FUSE-based lazy loading mechanism as well as a smart prefetcher to achieve good access performance for remote tables. Collectively, they significantly accelerate user-triggered recoveries in the cloud. TimeCloth is launched in production at Alibaba Cloud for about 15 months. We have witnesses a reduction in RTO among our customers by 44% on average and sometimes up to 92%.

References

[1]
[n. d.]. IDERA. https://www.idera.com
[2]
[n. d.]. libfuse 2.9.2. https://github.com/libfuse/libfuse/releases/download/fuse_ 2_9_4/fuse-2.9.2.tar.gz.
[3]
[n. d.]. MongoDB. https://www.mongodb.com/.
[4]
[n. d.]. MySQL. https://www.mysql.com/.
[5]
[n. d.]. MySQL MTS. https://dev.mysql.com/blog-archive/multi-threadedreplication- performance-in-mysql-5--7/
[6]
[n. d.]. Oracle Flashback. https://www.oracle.com/database/technologies/highavailability/ flashback.html.
[7]
[n. d.]. sysbench. https://github.com/akopytov/sysbench.
[8]
[n. d.]. Veritas. https://www.veritas.com/
[9]
2024. Cloud Block Storage - AWS EBS. https://aws.amazon.com/ebs/.
[10]
2024. Oracle Point-In-Time Recovery. https://docs.oracle.com/en-us/iaas/mysqldatabase/ doc/point-time-recovery.html.
[11]
2024. Point-in-time recovery (PITR) for Amazon DynamoDB. https://aws. amazon.com/dynamodb/pitr/.
[12]
2024. Restore a database in Azure SQL Managed Instance to a previous point in time. https://learn.microsoft.com/en-us/azure/azure-sql/managed-instance/ point-in-time-restore?view=azuresql&tabs=azure-portal.
[13]
2024. Restore a SQL Server Database to a Point in Time. https://learn.microsoft.com/en-us/sql/relational-databases/backup-restore/restore-a-sql-serverdatabase-to-a-point-in-time-full-recovery-model?view=sql-server-ver16.
[14]
Mike Accetta, Robert Baron, William Bolosky, David Golub, Richard Rashid, Avadis Tevanian, and Michael Young. 1986. Mach: A new kernel foundation for UNIX development. (1986), 93--112.
[15]
Albert D. Alexandrov, Maximilian Ibel, Klaus E. Schauser, and Chris J. Scheiman. 1997. Extending the Operating System at the User Level: The Ufo Global File System. In Proceedings of the Annual Conference on USENIX Annual Technical Conference (Anaheim, California) (ATEC '97). USENIX Association, USA, 6.
[16]
Panagiotis Antonopoulos, Peter Byrne,Wayne Chen, Cristian Diaconu, Raghavendra Thallam Kodandaramaih, Hanuma Kodavalla, Prashanth Purnananda, Adrian-Leonard Radu, Chaitanya Sreenivas Ravella, and Girish Mittur Venkataramanappa. 2019. Constant Time Recovery in Azure SQL Database. Proc. VLDB Endow. 12, 12 (aug 2019), 2143--2154. https://doi.org/10.14778/3352063.3352131
[17]
Wei Cao, Yingqiang Zhang, Xinjun Yang, Feifei Li, Sheng Wang, Qingda Hu, Xuntao Cheng, Zongzhi Chen, Zhenjun Liu, Jing Fang, Bo Wang, Yuhui Wang, Haiqing Sun, Ze Yang, Zhushi Cheng, Sen Chen, Jian Wu, Wei Hu, Jianwei Zhao, Yusong Gao, Songlu Cai, Yunyang Zhang, and Jiawang Tong. 2021. PolarDB Serverless: A Cloud Native Database for Disaggregated Data Centers. In Proceedings of the 2021 International Conference on Management of Data (Virtual Event, China) (SIGMOD '21). Association for Computing Machinery, New York, NY, USA, 2477--2489. https://doi.org/10.1145/3448016.3457560
[18]
Christopher Clark, Keir Fraser, Steven Hand, Jacob Gorm Hansen, Eric Jul, Christian Limpach, Ian Pratt, and Andrew Warfield. 2005. Live Migration of Virtual Machines. In Proceedings of the 2nd Conference on Symposium on Networked Systems Design & Implementation - Volume 2 (NSDI'05). USENIX Association, USA, 273--286.
[19]
Joel Coburn, Trevor Bunker, Meir Schwarz, Rajesh Gupta, and Steven Swanson. 2013. From ARIES to MARS: Transaction Support for next-Generation, Solid-State Drives. In Proceedings of the Twenty-Fourth ACM Symposium on Operating Systems Principles (Farminton, Pennsylvania) (SOSP '13). Association for Computing Machinery, New York, NY, USA, 197--212. https://doi.org/10.1145/2517349.2522724
[20]
Bailu Ding, Lucja Kot, and Johannes Gehrke. 2018. Improving Optimistic Concurrency Control through Transaction Batching and Operation Reordering. Proc. VLDB Endow. 12, 2 (oct 2018), 169--182. https://doi.org/10.14778/3282495.3282502
[21]
Tuukka Haapasalo, Seppo Sippu, Ibrahim Jaluta, and Eljas Soisalon-Soininen. 2009. Concurrent Updating Transactions on Versioned Data. In Proceedings of the 2009 International Database Engineering & Applications Symposium (Cetraro - Calabria, Italy) (IDEAS '09). Association for Computing Machinery, New York, NY, USA, 77--87. https://doi.org/10.1145/1620432.1620441
[22]
Michael Haubenschild, Caetano Sauer, Thomas Neumann, and Viktor Leis. 2020. Rethinking Logging, Checkpoints, and Recovery for High-Performance Storage Engines. In Proceedings of the 2020 ACM SIGMOD International Conference on Management of Data (Portland, OR, USA) (SIGMOD '20). Association for Computing Machinery, New York, NY, USA, 877--892. https://doi.org/10.1145/3318464. 3389716
[23]
Michael R. Hines, Umesh Deshpande, and Kartik Gopalan. 2009. Post-Copy Live Migration of Virtual Machines. SIGOPS Oper. Syst. Rev. 43, 3 (jul 2009), 14--26. https://doi.org/10.1145/1618525.1618528
[24]
Wangchao Le, Feifei Li, Yufei Tao, and Robert Christensen. 2013. Optimal Splitters for Temporal and Multi-Version Databases. In Proceedings of the 2013 ACM SIGMOD International Conference on Management of Data (New York, New York, USA) (SIGMOD '13). Association for Computing Machinery, New York, NY, USA, 109--120. https://doi.org/10.1145/2463676.2465310
[25]
Yoshinori Matsunobu, Siying Dong, and Herman Lee. 2020. MyRocks: LSM-Tree Database Storage Engine Serving Facebook's Social Graph. Proc. VLDB Endow. 13, 12 (aug 2020), 3217--3230. https://doi.org/10.14778/3415478.3415546
[26]
C. Mohan, Don Haderle, Bruce Lindsay, Hamid Pirahesh, and Peter Schwarz. 1992. ARIES: A Transaction Recovery Method Supporting Fine-Granularity Locking and Partial Rollbacks Using Write-Ahead Logging. ACM Trans. Database Syst. 17, 1 (mar 1992), 94--162. https://doi.org/10.1145/128765.128770
[27]
C. Mohan and Frank E. Levine. 1992. ARIES/IM: an efficient and high concurrency index management method using write-ahead logging. In ACM SIGMOD Conference. https://api.semanticscholar.org/CorpusID:9377623
[28]
C. Mohan and Inderpal Narang. 1994. ARIES/CSA: A Method for Database Recovery in Client-Server Architectures. SIGMOD Rec. 23, 2 (may 1994), 55--66. https://doi.org/10.1145/191843.191849
[29]
Ismail Oukid, Daniel Booss, Wolfgang Lehner, Peter Bumbulis, and Thomas Willhalm. 2014. SOFORT: A Hybrid SCM-DRAM Storage Engine for Fast Data Recovery. In Proceedings of the Tenth InternationalWorkshop on Data Management on New Hardware (Snowbird, Utah) (DaMoN '14). Association for Computing Machinery, New York, NY, USA, Article 8, 7 pages. https://doi.org/10.1145/ 2619228.2619236
[30]
Nalin Ranjan, Zechao Shang, Sanjay Krishnan, and Aaron J. Elmore. 2021. Version Reconciliation for Collaborative Databases. In Proceedings of the ACM Symposium on Cloud Computing (Seattle, WA, USA) (SoCC '21). Association for Computing Machinery, New York, NY, USA, 473--488. https://doi.org/10.1145/3472883. 3486980
[31]
Adam Ruprecht, Danny Jones, Dmitry Shiraev, Greg Harmon, Maya Spivak, Michael Krebs, Miche Baker-Harvey, and Tyler Sanderson. 2018. VM Live Migration At Scale. In Proceedings of the 14th ACM SIGPLAN/SIGOPS International Conference on Virtual Execution Environments (Williamsburg, VA, USA) (VEE '18). Association for Computing Machinery, New York, NY, USA, 45--56. https://doi.org/10.1145/3186411.3186415
[32]
Bin Shi, Haiying Shen, Bo Dong, and Qinghua Zheng. 2022. Memory/Disk Operation Aware Lightweight VM Live Migration. IEEE/ACM Trans. Netw. 30, 4 (mar 2022), 1895--1910. https://doi.org/10.1109/TNET.2022.3155935
[33]
Petter Svärd, Benoit Hudzia, Steve Walsh, Johan Tordsson, and Erik Elmroth. 2015. Principles and Performance Characteristics of Algorithms for Live VM Migration. SIGOPS Oper. Syst. Rev. 49, 1 (jan 2015), 142--155. https://doi.org/10. 1145/2723872.2723894
[34]
Rebecca Taft, Irfan Sharif, Andrei Matei, Nathan VanBenschoten, Jordan Lewis, Tobias Grieger, Kai Niemi, Andy Woods, Anne Birzin, Raphael Poss, Paul Bardea, Amruta Ranade, Ben Darnell, Bram Gruneir, Justin Jaffray, Lucy Zhang, and Peter Mattis. 2020. CockroachDB: The Resilient Geo-Distributed SQL Database. In Proceedings of the 2020 ACM SIGMOD International Conference on Management of Data (Portland, OR, USA) (SIGMOD '20). Association for Computing Machinery, New York, NY, USA, 1493--1509. https://doi.org/10.1145/3318464.3386134
[35]
Bharath Kumar Reddy Vangoor, Prafful Agarwal, Manu Mathew, Arun Ramachandran, Swaminathan Sivaraman, Vasily Tarasov, and Erez Zadok. 2019. Performance and Resource Utilization of FUSE User-Space File Systems. ACM Trans. Storage 15, 2, Article 15 (may 2019), 49 pages. https://doi.org/10.1145/3310148
[36]
Yu Xia, Xiangyao Yu, Andrew Pavlo, and Srinivas Devadas. 2020. Taurus: Lightweight Parallel Logging for in-Memory Database Management Systems. Proc. VLDB Endow. 14, 2 (oct 2020), 189--201. https://doi.org/10.14778/3425879.3425889
[37]
Chang Yao, Divyakant Agrawal, Gang Chen, Qian Lin, Beng Chin Ooi, Weng-Fai Wong, and Meihui Zhang. 2016. Exploiting Single-Threaded Model in Multi-Core In-Memory Systems. IEEE Transactions on Knowledge and Data Engineering 28, 10 (2016), 2635--2650. https://doi.org/10.1109/TKDE.2016.2578319
[38]
Chang Yao, Divyakant Agrawal, Gang Chen, Beng Chin Ooi, and Sai Wu. 2016. Adaptive Logging: Optimizing Logging and Recovery Costs in Distributed In-Memory Databases. In Proceedings of the 2016 International Conference on Management of Data (San Francisco, California, USA) (SIGMOD '16). Association for Computing Machinery, New York, NY, USA, 1119--1134. https://doi.org/10.1145/2882903.2915208
[39]
Chang Yao, Meihui Zhang, Qian Lin, Beng Chin Ooi, and Jiatao Xu. 2018. Scaling Distributed Transaction Processing and Recovery Based on Dependency Logging. The VLDB Journal 27, 3 (jun 2018), 347--368. https://doi.org/10.1007/s00778-018-0500--2
[40]
E. Zayas. 1987. Attacking the Process Migration Bottleneck. In Proceedings of the Eleventh ACM Symposium on Operating Systems Principles (Austin, Texas, USA) (SOSP '87). Association for Computing Machinery, New York, NY, USA, 13--24. https://doi.org/10.1145/41457.37503

Recommendations

Comments

Information & Contributors

Information

Published In

cover image ACM Conferences
SIGMOD/PODS '24: Companion of the 2024 International Conference on Management of Data
June 2024
694 pages
ISBN:9798400704222
DOI:10.1145/3626246
Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than the author(s) must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected].

Sponsors

Publisher

Association for Computing Machinery

New York, NY, United States

Publication History

Published: 09 June 2024

Permissions

Request permissions for this article.

Check for updates

Author Tags

  1. database recovery
  2. point-in-time recovery
  3. transparent lazy loading
  4. user-triggered recovery

Qualifiers

  • Research-article

Conference

SIGMOD/PODS '24
Sponsor:

Acceptance Rates

Overall Acceptance Rate 785 of 4,003 submissions, 20%

Contributors

Other Metrics

Bibliometrics & Citations

Bibliometrics

Article Metrics

  • 0
    Total Citations
  • 267
    Total Downloads
  • Downloads (Last 12 months)267
  • Downloads (Last 6 weeks)27
Reflects downloads up to 28 Feb 2025

Other Metrics

Citations

View Options

Login options

View options

PDF

View or Download as a PDF file.

PDF

eReader

View online with eReader.

eReader

Figures

Tables

Media

Share

Share

Share this Publication link

Share on social media