# US 12,111,795 B2 · Efficient replication of file clones

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 12,111,795 B2
- Document ID: US12111795B2
- Status: Granted
- Kind: B2
- Application number: 17/357,044
- Filed: 2021-06-24
- Published: 2022-12-29
- Granted: 2024-10-08
- Earliest claimed: 2021-06-24
- Assignees: VMware, Inc.
- Applicants: VMware LLC
- Inventors: Abhay Kumar Jain; Sriram Patil; Junlong Gao; Wenguang Wang
- Web page: https://patentgrep.com/patent/US12111795B2

## CPC

- G06F 16/1844: {Management specifically adapted to replicated file systems}
- G06F 16/164: {File meta data generation}
- G06F 16/1734: {Details of monitoring file system events, e.g. by the use of hooks, filter drivers, logs}
- G06F 16/1756: {based on delta files}
- G06F 16/178: Techniques for file synchronisation in file systems
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

A method for managing replication of cloned files is provided. Embodiments include determining, at a source system, that a first file has been cloned to create a second file. Embodiments include sending, from the source system to a replica system, an address of the first extent and an indication that a status of the first extent has changed from non-cloned to cloned. Embodiments include changing, at the replica system, a status of a second extent associated with a replica of the first file on the replica system from non-cloned to cloned and creating a mapping of the address of the first extent to an address of the second extent on the replica system. Embodiments include creating, at the replica system, a replica of the second file comprising a reference to the address of the second extent on the replica system.

## Claims

### Claim 1

A method comprising:
determining, at a source system in a storage replication environment, that a first file on the source system has been cloned to create a second file on the source system;
changing, at the source system, a status of a first extent associated with the first file from non-cloned to cloned;
sending, from the source system to a replica system in the storage replication environment, an update message comprising an address of the first extent on the source system and an indication that the status of the first extent has changed from non-cloned to cloned, the address of the first extent acting as a token;
changing, at the replica system, based on the update message, a status of a second extent associated with a replica of the first file on the replica system from non-cloned to cloned;
creating, at the replica system, based on the update message, a mapping of the address of the first extent on the source system to an address of the second extent on the replica system;
replacing the token with the address of the second extent utilizing the mapping;
creating, at the replica system, based on the mapping, a replica of the second file comprising a reference to the address of the second extent on the replica system;
determining, at the source system, that a portion of the first file has been modified, wherein the portion of the first file begins at a given block offset;
assigning, at the source system, a separate extent on the source system to the portion of the first file; and
updating, at the source system, metadata associated with the first file to indicate that an initial portion of the first file is associated with the address of the first extent up to the given block offset and that the portion of the first file is associated with an address of the separate extent.

### Claim 2 (depends on 1)

The method of claim 1, further comprising:
setting, at the source system, based on the second file being created, a reference count associated with the first extent to two; and
setting, at the replica system, based on the replica of the second file being created, a reference count associated with the second extent to two.

### Claim 3 (depends on 1)

The method of claim 1, wherein:
the address of the first extent comprises a storage address of the first extent on the source system corresponding to a location of the first file; and
the address of the second extent comprises a storage address of the second extent on the replica system corresponding to a location of the replica of the first file.

### Claim 4 (depends on 1)

The method of claim 1, further comprising:
sending, from the source system to the replica system, an additional update message based on the portion of the first file being modified;
assigning, at the replica system, based on the additional update message, an additional extent on the replica system to a portion of the replica of the first file that corresponds to the portion of the first file; and
updating, at the replica system, metadata associated with the replica of the first file to indicate that an initial portion of the replica of the first file is associated with the address of the second extent up to the given block offset and that the portion of the replica of the first file is associated with an address of the additional extent.

### Claim 5 (depends on 4)

The method of claim 4, further comprising:
setting, at the source system, a reference count associated with a portion of the first extent beginning at the given block offset to one; and
setting, at the source system, a reference count associated with the separate extent to one.

### Claim 6 (depends on 5)

The method of claim 5, further comprising:
setting, at the replica system, a reference count associated with a portion of the second extent beginning at the given block offset to one; and
setting, at the replica system, a reference count associated with the additional extent to one.

### Claim 7 (depends on 1)

The method of claim 1, further comprising:
determining, at the source system, that the first file has been deleted;
changing, at the source system, the status of the first extent from cloned to non-cloned;
sending, from the source system to the replica system, an additional update message comprising an address of the first extent on the source system and an indication that the status of the first extent has changed from cloned to non-cloned;
changing, at the replica system, based on the additional update message, the status of the second extent from cloned to non-cloned; and
deleting, at the replica system, the replica of the first file.

### Claim 8

A system comprising:
one or more processors; and
a non-transitory computer-readable medium storing instructions executable by the one or more processors to cause the system to perform operations comprising:
determining, at a source system in a storage replication environment, that a first file on the source system has been cloned to create a second file on the source system;
changing, at the source system, a status of a first extent associated with the first file from non-cloned to cloned;
sending, from the source system to a replica system in the storage replication environment, an update message comprising an address of the first extent on the source system and an indication that the status of the first extent has changed from non-cloned to cloned, the address of the first extent acting as a token;
changing, at the replica system, based on the update message, a status of a second extent associated with a replica of the first file on the replica system from non-cloned to cloned;
creating, at the replica system, based on the update message, a mapping of the address of the first extent on the source system to an address of the second extent on the replica system;
replacing the token with the address of the second extent utilizing the mapping;
creating, at the replica system, based on the mapping, a replica of the second file comprising a reference to the address of the second extent on the replica system;
determining, at the source system, that a portion of the first file has been modified, wherein the portion of the first file begins at a given block offset;
assigning, at the source system, a separate extent on the source system to the portion of the first file; and
updating, at the source system, metadata associated with the first file to indicate that an initial portion of the first file is associated with the address of the first extent up to the given block offset and that the portion of the first file is associated with an address of the separate extent.

### Claim 9 (depends on 8)

The system of claim 8, the operations further comprising:
setting, at the source system, based on the second file being created, a reference count associated with the first extent to two; and
setting, at the replica system, based on the replica of the second file being created, a reference count associated with the second extent to two.

### Claim 10 (depends on 8)

The system of claim 8, wherein:
the address of the first extent comprises a storage address of the first extent on the source system corresponding to a location of the first file; and
the address of the second extent comprises a storage address of the second extent on the replica system corresponding to a location of the replica of the first file.

### Claim 11 (depends on 8)

The system of claim 8, the operations further comprising:
sending, from the source system to the replica system, an additional update message based on the portion of the first file being modified;
assigning, at the replica system, based on the additional update message, an additional extent on the replica system to a portion of the replica of the first file that corresponds to the portion of the first file; and
updating, at the replica system, metadata associated with the replica of the first file to indicate that an initial portion of the replica of the first file is associated with the address of the second extent up to the given block offset and that the portion of the replica of the first file is associated with an address of the additional extent.

### Claim 12 (depends on 11)

The system of claim 11, the operations further comprising:
setting, at the source system, a reference count associated with a portion of the first extent beginning at the given block offset to one; and
setting, at the source system, a reference count associated with the separate extent to one.

### Claim 13 (depends on 12)

The system of claim 12, the operations further comprising:
setting, at the replica system, a reference count associated with a portion of the second extent beginning at the given block offset to one; and
setting, at the replica system, a reference count associated with the additional extent to one.

### Claim 14 (depends on 8)

The system of claim 8, the operations further comprising:
determining, at the source system, that the first file has been deleted;
changing, at the source system, the status of the first extent from cloned to non-cloned;
sending, from the source system to the replica system, an additional update message comprising an address of the first extent on the source system and an indication that the status of the first extent has changed from cloned to non-cloned;
changing, at the replica system, based on the additional update message, the status of the second extent from cloned to non-cloned; and
deleting, at the replica system, the replica of the first file.

### Claim 15

A non-transitory computer-readable medium storing instructions that, when executed by one or more processors of a computing system, cause the computing system to perform operations comprising:
determining, at a source system in a storage replication environment, that a first file on the source system has been cloned to create a second file on the source system;
changing, at the source system, a status of a first extent associated with the first file from non-cloned to cloned, the address of the first extent acting as a token;
sending, from the source system to a replica system in the storage replication environment, an update message comprising an address of the first extent on the source system and an indication that the status of the first extent has changed from non-cloned to cloned;
changing, at the replica system, based on the update message, a status of a second extent associated with a replica of the first file on the replica system from non-cloned to cloned;
creating, at the replica system, based on the update message, a mapping of the address of the first extent on the source system to an address of the second extent on the replica system;
replacing the token with the address of the second extent utilizing the mapping;
creating, at the replica system, based on the mapping, a replica of the second file comprising a reference to the address of the second extent on the replica system;
determining, at the source system, that a portion of the first file has been modified, wherein the portion of the first file begins at a given block offset;
assigning, at the source system, a separate extent on the source system to the portion of the first file; and
updating, at the source system, metadata associated with the first file to indicate that an initial portion of the first file is associated with the address of the first extent up to the given block offset and that the portion of the first file is associated with an address of the separate extent.

### Claim 16 (depends on 15)

The non-transitory computer-readable medium of claim 15, the operations further comprising:
setting, at the source system, based on the second file being created, a reference count associated with the first extent to two; and
setting, at the replica system, based on the replica of the second file being created, a reference count associated with the second extent to two.

### Claim 17 (depends on 15)

The non-transitory computer-readable medium of claim 15, wherein:
the address of the first extent comprises a storage address of the first extent on the source system corresponding to a location of the first file; and
the address of the second extent comprises a storage address of the second extent on the replica system corresponding to a location of the replica of the first file.

### Claim 18 (depends on 15)

The non-transitory computer-readable medium of claim 15, the operations further comprising:
sending, from the source system to the replica system, an additional update message based on the portion of the first file being modified;
assigning, at the replica system, based on the additional update message, an additional extent on the replica system to a portion of the replica of the first file that corresponds to the portion of the first file; and
updating, at the replica system, metadata associated with the replica of the first file to indicate that an initial portion of the replica of the first file is associated with the address of the second extent up to the given block offset and that the portion of the replica of the first file is associated with an address of the additional extent.

### Claim 19 (depends on 18)

The non-transitory computer-readable medium of claim 18, the operations further comprising:
setting, at the source system, a reference count associated with a portion of the first extent beginning at the given block offset to one; and
setting, at the source system, a reference count associated with the separate extent to one.

### Claim 20 (depends on 19)

The non-transitory computer-readable medium of claim 19, the operations further comprising:
setting, at the replica system, a reference count associated with a portion of the second extent beginning at the given block offset to one; and
setting, at the replica system, a reference count associated with the additional extent to one.

### Claim 21 (depends on 15)

The non-transitory computer-readable medium of claim 15, the operations further comprising:
determining, at the source system, that the first file has been deleted;
changing, at the source system, the status of the first extent from cloned to non-cloned;
sending, from the source system to the replica system, an additional update message comprising an address of the first extent on the source system and an indication that the status of the first extent has changed from cloned to non-cloned;
changing, at the replica system, based on the additional update message, the status of the second extent from cloned to non-cloned; and
deleting, at the replica system, the replica of the first file.
