File cloning across different filesets
First Claim
1. A computer program product for cloning a file across filesets in a clustered file system, the computer program product comprising:
- a non-transitory computer readable storage medium having computer readable program code embodied therewith, the computer readable program code configured to,determine that a write request indicates a clone file that was cloned from a file in a first fileset, wherein the clone file is of a second fileset and a clustered file system comprises the first fileset and the second fileset;
determine a data block of the clone file affected by the write request;
determine that the data block at a current location cannot be modified based on whether the data block and the clone file are part of a same fileset, wherein the computer readable program code being configured to determine that the data block at the current location cannot be modified comprises the computer readable program code being configured todetermine that the data block is not associated with the second fileset;
determine that the data block belongs to a generation different than a generation of the second fileset; and
determine that the data block does not belong to a generation later than a generation of creation of the clone file; and
in response to a determination that the data block at the current location cannot be modified,implement the write request with respect to the data block at a different location; and
indicate that the data block at the different location can be modified for subsequent write requests that indicate the clone file.
1 Assignment
0 Petitions
Accused Products
Abstract
Embodiments include a computer program product and an apparatus for cloning files across different filesets and maintaining the clone files. After a clone file is created from a file, a write request targeting the clone file can be handled. It is determined that the write request indicates the clone file that was cloned from a file in a first fileset. The clone file is of a second fileset and a clustered file system comprises the first fileset and the second fileset. A data block of the clone file affected by the write request is determined. It is then determined that the data block at a current location cannot be modified. The write request is implemented with respect to the data block at a different location. It is indicated that the data block at the different location can be modified for subsequent write requests that indicate the clone file.
-
Citations
6 Claims
-
1. A computer program product for cloning a file across filesets in a clustered file system, the computer program product comprising:
-
a non-transitory computer readable storage medium having computer readable program code embodied therewith, the computer readable program code configured to, determine that a write request indicates a clone file that was cloned from a file in a first fileset, wherein the clone file is of a second fileset and a clustered file system comprises the first fileset and the second fileset; determine a data block of the clone file affected by the write request; determine that the data block at a current location cannot be modified based on whether the data block and the clone file are part of a same fileset, wherein the computer readable program code being configured to determine that the data block at the current location cannot be modified comprises the computer readable program code being configured to determine that the data block is not associated with the second fileset; determine that the data block belongs to a generation different than a generation of the second fileset; and determine that the data block does not belong to a generation later than a generation of creation of the clone file; and in response to a determination that the data block at the current location cannot be modified, implement the write request with respect to the data block at a different location; and indicate that the data block at the different location can be modified for subsequent write requests that indicate the clone file. - View Dependent Claims (2, 3, 4, 5)
-
-
6. An apparatus comprising:
-
a processor; a network interface operable to receive a file write request; and a file system clone module operable to, determine that the file write request indicates a clone file that was cloned from a file in a first fileset, wherein the clone file is of a second fileset and a clustered file system comprises the first fileset and the second fileset; determine a data block of the clone file affected by the file write request; determine that the data block at a current location cannot be modified based on whether the data block and the clone file are part of a same fileset, wherein the computer readable program code being configured to determine that the data block at the current location cannot be modified comprises the computer readable program code being configured to determine that the data block is not associated with the second fileset; determine that the data block belongs to a generation different than a generation of the second fileset; and determine that the data block does not belong to a generation later than a generation of creation of the clone file; and in response to a determination that the data block at the current location cannot be modified, implement the write request with respect to the data block at a different location; and indicate that the data block at the different location can be modified for subsequent write requests that indicate the clone file.
-
Specification