Managing copy-on-writes to snapshots
AssigneeSymantec Corporation
InventorPriyesh Narayanan
Life of this patent
Estimating the term…
Abstract
An attempt to write to a block of data in a main volume of data is detected. An indicator associated with the block of data is accessed before a copy-on-write operation to a snapshot volume is performed for the block of data. The indicator is used to determine whether the copy-on-write operation is to be performed for the block of data.
Claims20
A computer memory that stores computer-executable instructions that, when executed, cause a computer system to perform a method comprising:
- detecting an attempt to write to a block of data in a first volume of data by a first application, wherein a copy-on-write snapshot volume is associated with said first volume, wherein said snapshot volume does not include a copy of said block of data, and wherein said snapshot volume includes a pointer that points to said block of data in said first volume;
- prior to performing a copy-on-write operation by a snapshot driver to said snapshot volume for said block of data, accessing an indicator associated with said block of data in response to said attempt to write to said block of data by said first application, wherein a value of said indicator is set to a first value by a second application via said snapshot driver when said block of data is not of interest to said second application or said block of data was read by said second application prior to said attempt to write to said block of data by said first application;
- and
- determining, based on said value of said indicator, whether said copy-on-write operation is to be performed by said first application for said block of data in response to said attempt to write by said first application, wherein said copy-on-write operation is not performed by said first application if said indicator is set to said first value.
A computer memory that stores computer-executable instructions that, when executed, cause a computer system to perform a method comprising:
- attempting, by a first application, to write to a block of data in a volume of data comprising a plurality of blocks of data, wherein a copy-on-write snapshot is associated with said volume;
- designating, by a second application, a subset of said blocks of data as blocks not of interest to said second application or as having been read by said second application prior to said attempt to write to said block of data, wherein said snapshot does not include a copy of blocks of data in said subset, said designating comprising setting a respective bit in a data structure maintained by a snapshot driver for a block of data in said subset;
- and
- in response to said attempt to write to said block of data by said first application, preventing a copy-on-write operation by said snapshot driver to said snapshot for said block of data, and allowing a copy-on-write operation by said snapshot driver to said snapshot for a block of data not included in said subset.
A non-transitory computer storage medium that stores computer-executable components comprising:
- a first application configured to write data to a volume comprising a plurality of blocks of data;
- a snapshot driver configured to create a snapshot for said volume and maintain a bitmap having bits corresponding to said plurality of blocks of data;
- and
- a second application configured to read data from said volume and from said snapshot, wherein said second application designates a subset of said blocks of data as blocks not of interest, wherein said snapshot does not include a copy of blocks of data in said subset, wherein said bitmap for said volume is used to track which of said blocks is in said subset, wherein a block of data in said volume that is read by said second application is added to said subset by said second application via said snapshot driver and said bitmap is updated by said second application via the snapshot driver in response to the read of said block of data, wherein a copy-on-write operation to said snapshot by said snapshot driver for said block of data is not performed in response to a write to said block of data by said first application after said bitmap is updated, and wherein a copy-on-write operation to said snapshot by said snapshot driver for a block of data not in said subset is performed in response to a write to said block of data not in said subset by said first application.
Dependencies are inferred from the claim text.