IP Library Granted Patent US 12,287,758
Granted Patent B2
US 12,287,758 · App. 18/648,223 · Granted Apr 29, 2025

Snapshot and restoration of distributed file system

Inventors: Vijay Karthik (Sunnyvale, CA); Anshul Gupta (Mountain View, CA); Abhay Mitra (Santa Clara, CA); Vivek Sanjay Jain (Palo Alto, CA); Satwant Rana (Mountain View, CA)
Assignee: Rubrik, Inc.
G06F16/128G06F16/164G06F16/1752G06F16/1844
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 12,287,758
App. No.
18/648,223
Granted
Apr 29, 2025
Kind
B2
Abstract

In some examples, a data management system processes snapshots of a distributed file system, the distributed file system having files, each file comprising multiple data chunks. The data management system performs operations including storing file-to-chunk mapping in file system metadata; creating, for each chunk, a chunk generation ID by associating each chunk with a file system generation ID; in a next-generation snapshot of the distributed file system, incrementing, for all chunks in the next-generation snapshot, the respective chunk generation IDs; and taking a snapshot of the file system metadata and storing an updated file-to-chunk mapping associated with the next-generation snapshot.

Claims (58)

1. A method comprising:

storing a file-to-chunk mapping in file system metadata, wherein the file-to-chunk mapping maps a file of a distributed file system to a first set of data chunks and a first file system generation identifier (ID) associated with a first time at which a first snapshot of the distributed file system was obtained;

detecting, after the first time, a trigger event that indicates that the first snapshot is set to expire; and

deleting, based at least in part on the trigger event, a second set of data chunks from the distributed file system based at least in part on the trigger event and further based at least in part on the second set of data chunks being associated with the first file system generation ID and being excluded from the file-to-chunk mapping in the file system metadata, wherein the first set of data chunks remain in the distributed file system after the first snapshot expires based at least in part on the first set of data chunks being included in the file-to-chunk mapping in the file system metadata.

2. The method of claim 1 , further comprising:

obtaining, at the first time, the first snapshot of the distributed file system, wherein the file comprises the first set of data chunks and the second set of data chunks at the first time, and wherein, based at least in part on the file including the first set of data chunks and the second set of data chunks at the first time, the file-to-chunk mapping maps the file to a first entry associated with the first set of data chunks and the first file system generation ID and a second entry associated with the second set of data chunks and the first file system generation ID.

3. The method of claim 2 , further comprising:

copying, based at least in part on an update to physical data after the first time and before a second time associated with a second snapshot of the distributed file system, the physical data from the second set of data chunks to a third set of data chunks; and

removing the second entry associated with the second set of data chunks and the first file system generation ID from the file-to-chunk mapping based at least in part on copying the physical data from the second set of data chunks to the third set of data chunks, wherein the second set of data chunks are associated with the first file system generation ID and excluded from the file-to-chunk mapping based at least in part on removing the second entry.

4. The method of claim 2 , further comprising:

obtaining, at a second time that is after the first time, a second snapshot of the distributed file system, wherein the second time is associated with a second file system generation ID, and wherein the file includes at least a third set of data chunks at the second time; and

modifying, based at least in part on obtaining the second snapshot, the file-to-chunk mapping to map the file to the first entry associated with the first set of data chunks and the first file system generation ID and a third entry associated with the third set of data chunks and the second file system generation ID.

5. The method of claim 4 , wherein:

the trigger event is detected after modifying the file-to-chunk mapping to map the file to the first entry and the third entry; and

the third set of data chunks remain in the distributed file system after the first snapshot expires based at least in part on the third set of data chunks being included in the file-to-chunk mapping in the file system metadata after the first snapshot expires.

6. The method of claim 1 , further comprising:

obtaining, at the first time, the first snapshot of the distributed file system, wherein the file comprises the first set of data chunks and one or more other data chunks at the first time; and

maintaining, based at least in part on a state of the first set of data chunks being maintained between the first time and the trigger event, the file-to-chunk mapping that maps the file to the first set of data chunks and the first file system generation ID.

7. The method of claim 1 , wherein detecting the trigger event comprises:

receiving, via an interface, a request to delete the first snapshot.

8. The method of claim 1 , wherein detecting the trigger event comprises:

detecting that a periodicity associated with garbage collection operations for the distributed file system.

9. An apparatus, comprising:

one or more memories storing processor-executable code; and

one or more processors coupled with the one or more memories and individually or collectively operable to execute the code to cause the apparatus to:

store a file-to-chunk mapping in file system metadata, wherein the file-to-chunk mapping maps a file of a distributed file system to a first set of data chunks and a first file system generation identifier (ID) associated with a first time at which a first snapshot of the distributed file system was obtained;

detect, after the first time, a trigger event that indicates that the first snapshot is set to expire; and

delete, based at least in part on the trigger event, a second set of data chunks from the distributed file system based at least in part on the trigger event and further based at least in part on the second set of data chunks being associated with the first file system generation ID and being excluded from the file-to-chunk mapping in the file system metadata, wherein the one or more processors are individually or collectively operable to execute the code to cause the apparatus to maintain the first set of data chunks in the distributed file system after the first snapshot expires based at least in part on the first set of data chunks being included in the file-to-chunk mapping in the file system metadata.

10. The apparatus of claim 9 , wherein the one or more processors are individually or collectively further operable to execute the code to cause the apparatus to:

obtain, at the first time, the first snapshot of the distributed file system, wherein the file comprises the first set of data chunks and the second set of data chunks at the first time, and wherein, based at least in part on the file including the first set of data chunks and the second set of data chunks at the first time, the file-to-chunk mapping maps the file to a first entry associated with the first set of data chunks and the first file system generation ID and a second entry associated with the second set of data chunks and the first file system generation ID.

11. The apparatus of claim 10 , wherein the one or more processors are individually or collectively further operable to execute the code to cause the apparatus to:

copy, based at least in part on an update to physical data after the first time and before a second time associated with a second snapshot of the distributed file system, the physical data from the second set of data chunks to a third set of data chunks; and

remove the second entry associated with the second set of data chunks and the first file system generation ID from the file-to-chunk mapping based at least in part on copying the physical data from the second set of data chunks to the third set of data chunks, wherein the second set of data chunks are associated with the first file system generation ID and excluded from the file-to-chunk mapping based at least in part on removing the second entry.

12. The apparatus of claim 10 , wherein the one or more processors are individually or collectively further operable to execute the code to cause the apparatus to:

obtain, at a second time that is after the first time, a second snapshot of the distributed file system, wherein the second time is associated with a second file system generation ID, and wherein the file includes at least a third set of data chunks at the second time; and

modify, based at least in part on obtaining the second snapshot, the file-to-chunk mapping to map the file to the first entry associated with the first set of data chunks and the first file system generation ID and a third entry associated with the third set of data chunks and the second file system generation ID.

13. The apparatus of claim 12 , wherein:

the one or more processors are individually or collectively operable to execute the code to cause the apparatus to detect the trigger event after modifying the file-to-chunk mapping to map the file to the first entry and the third entry; and

the one or more processors are individually or collectively operable to execute the code to cause the apparatus to maintain the third set of data chunks in the distributed file system after the first snapshot expires based at least in part on the third set of data chunks being included in the file-to-chunk mapping in the file system metadata after the first snapshot expires.

14. The apparatus of claim 9 , wherein the one or more processors are individually or collectively further operable to execute the code to cause the apparatus to:

obtain, at the first time, the first snapshot of the distributed file system, wherein the file comprises the first set of data chunks and one or more other data chunks at the first time; and

maintain, based at least in part on a state of the first set of data chunks being maintained between the first time and the trigger event, the file-to-chunk mapping that maps the file to the first set of data chunks and the first file system generation ID.

15. The apparatus of claim 9 , wherein, to detect the trigger event, the one or more processors are individually or collectively operable to execute the code to cause the apparatus to:

receive, via an interface associated with the apparatus, a request to delete the first snapshot.

16. The apparatus of claim 9 , wherein, to detect the trigger event, the one or more processors are individually or collectively operable to execute the code to cause the apparatus to:

detect that a periodicity associated with garbage collection operations for the distributed file system.

17. A non-transitory computer-readable medium storing code, the code comprising instructions executable by at one or more processors to:

store a file-to-chunk mapping in file system metadata, wherein the file-to-chunk mapping maps a file of a distributed file system to a first set of data chunks and a first file system generation identifier (ID) associated with a first time at which a first snapshot of the distributed file system was obtained;

detect, after the first time, a trigger event that indicates that the first snapshot is set to expire; and

delete, based at least in part on the trigger event, a second set of data chunks from the distributed file system based at least in part on the trigger event and further based at least in part on the second set of data chunks being associated with the first file system generation ID and being excluded from the file-to-chunk mapping in the file system metadata, wherein the instructions are further executable by the one or more processors to maintain the first set of data chunks in the distributed file system after the first snapshot expires based at least in part on the first set of data chunks being included in the file-to-chunk mapping in the file system metadata.

18. The non-transitory computer-readable medium of claim 17 , wherein the instructions are further executable by the one or more processors to:

obtain, at the first time, the first snapshot of the distributed file system, wherein the file comprises the first set of data chunks and the second set of data chunks at the first time, and wherein, based at least in part on the file including the first set of data chunks and the second set of data chunks at the first time, the file-to-chunk mapping maps the file to a first entry associated with the first set of data chunks and the first file system generation ID and a second entry associated with the second set of data chunks and the first file system generation ID.

19. The non-transitory computer-readable medium of claim 18 , wherein the instructions are further executable by the one or more processors to:

copy, based at least in part on an update to physical data after the first time and before a second time associated with a second snapshot of the distributed file system, the physical data from the second set of data chunks to a third set of data chunks; and

remove the second entry associated with the second set of data chunks and the first file system generation ID from the file-to-chunk mapping based at least in part on copying the physical data from the second set of data chunks to the third set of data chunks, wherein the second set of data chunks are associated with the first file system generation ID and excluded from the file-to-chunk mapping based at least in part on removing the second entry.

20. The non-transitory computer-readable medium of claim 18 , wherein the instructions are further executable by the one or more processors to:

obtain, at a second time that is after the first time, a second snapshot of the distributed file system, wherein the second time is associated with a second file system generation ID, and wherein the file includes at least a third set of data chunks at the second time; and

modify, based at least in part on obtaining the second snapshot, the file-to-chunk mapping to map the file to the first entry associated with the first set of data chunks and the first file system generation ID and a third entry associated with the third set of data chunks and the second file system generation ID.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Jan 31, 2025
From: KARTHIK, VIJAY; GUPTA, ANSHUL; MITRA, ABHAY; JAIN, VIVEK SANJAY; RANA, SATWANT
To: RUBRIK, INC.
Reel/Frame 070081/0294 →
Continuity (3)
Continuation 17363694 · Jun 30, 2021
Provisional Application 63053146 · Jul 17, 2020
Related Publication 20240289302A1 · Aug 29, 2024
References Cited (28)
US 8370302B2 · Otani · 2013 [cited by applicant]
US 8527544B1 · Colgrove et al. · 2013 [cited by applicant]
US 8930648B1 · Storer · 2015 [cited by examiner]
US 9189342B1 · Von et al. · 2015 [cited by applicant]
US 9298723B1 · Pradeep · 2016 [cited by applicant]
US 9715346B2 · Jain · 2017 [cited by examiner]
US 10275321B1 · Bajaj · 2019 [cited by applicant]
US 20060218364A1 · Kitamura · 2006 [cited by applicant]
US 20100070466A1 · Prahlad et al. · 2010 [cited by applicant]
US 20100070474A1 · Lad · 2010 [cited by applicant]
US 20140129524A1 · Ueoka et al. · 2014 [cited by applicant]
US 20150127618A1 · Alberti et al. · 2015 [cited by applicant]
US 20160124665A1 · Jain et al. · 2016 [cited by applicant]
US 20160125059A1 · Jain · 2016 [cited by examiner]
US 20160274980A1 · Kim et al. · 2016 [cited by applicant]
US 20170262345A1 · Wang et al. · 2017 [cited by applicant]
US 20180046553A1 · Okamoto · 2018 [cited by applicant]
US 20180089224A1 · Muthuswamy et al. · 2018 [cited by applicant]
US 20190050302A1 · Juniwal · 2019 [cited by examiner]
US 20190108099A1 · Mazumdar · 2019 [cited by applicant]
US 20190171374A1 · Jain et al. · 2019 [cited by applicant]
US 20190213123A1 · Agarwal · 2019 [cited by examiner]
US 20220027313A1 · George et al. · 2022 [cited by applicant]
Soules, Craig A. N., et al., “Metadata Efficiency in a Comprehensive Versioning File System”, CMU-CS-01-145, Carnegie Mellon University, Pittsburgh, PA, May 2002, pp. 1-33. [cited by examiner]
Stender, Jan, “Snapshots in Large-Scale Distributed File Systems”, Dissertation, Humboldt-Universität zu Berlin, 2013, 139 pages. [cited by examiner]
Zhang, Wei, et al., “VM-centric snapshot deduplication for cloud data backup”, MSST 2015, Santa Clara, CA, May 30-Jun. 5, 2015, 12 pages. [cited by examiner]
Cao, Zhichao, et al., “A Tier-Aware Data Deduplication-Based File System”, ACM Transactions on Storage, vol. 15, No. 1, Article 4, Feb. 2019, 26 pages. [cited by applicant]
Song, Weijia, et al., “The Freeze-Frame File System”, SoCC '16, Santa Clara, CA, Oct. 5-7, 2016, pp. 307-320. [cited by applicant]