IP Library Granted Patent US 12,164,505
Granted Patent B2
US 12,164,505 · App. 17/957,941 · Granted Dec 10, 2024

Two-phase commit using reserved log sequence values

Inventors: Yiqi Xu (Newark, CA); Eric Knauft (San Francisco, CA); Enning Xiang (San Jose, CA)
Assignee: VMware LLC
G06F16/2379G06F13/1668G06F16/2308
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,164,505
App. No.
17/957,941
Granted
Dec 10, 2024
Kind
B2
Abstract

System and method for managing different classes of storage input/output (I/O) requests for a two-phase commit operation in a distributed storage system assigns reserved log sequence values to each of storage I/O requests of a first class, which are added to a two-phase commit queue. The reserved log sequence values of the storage I/O requests of the first class in the two-phase commit queue are assigned to some of the storage I/O requests of the second class, which are added to the two-phase commit queue.

Claims (47)

1. A method, comprising:

assigning, by a virtual storage area network (VSAN) module of a first host computer, a batch of log sequence values for each of a plurality of storage I/O requests of a first class, wherein the host computer is one of a plurality of host computers in a cluster, the cluster comprising a VSAN that uses local storage resources of one or more of the plurality of host computers, including the first host computer, as a distributed storage system, and one of the log sequence values from the batch of log sequence values for each storage I/O request of the first class is used for that storage I/O request and the other log sequence values from the batch of log sequence values are used as reserved log sequence values;

adding, by the VSAN module, the storage I/O requests of the first class to a two-phase commit queue;

assigning, by the VSAN module, the reserved log sequence values of the storage I/O requests of the first class in the two-phase commit queue to some of a plurality of storage I/O requests of a second class; and

adding, by the VSAN module, the storage I/O requests of the second class to the two-phase commit queue, wherein the reserved log sequence values assigned to some of the storage I/O requests of the second class ensure that at least one of the storage I/O requests of the second class in the two-phase commit queue is committed before at least one of storage I/O requests of the first class in the two-phase commit queue.

2. The method of claim 1 , wherein assigning the batch of log sequence values for each storage I/O request of the first class includes using a highest log sequence value from the batch of log sequence values for that particular storage I/O request of the first class.

3. The method of claim 1 , further comprising changing a size of a batch of log sequence values assigned to a subsequent storage I/O request of the first class based on utilization of reserved log sequence values of the storage I/O requests of the first class.

4. The method of claim 3 , wherein changing the size of the batch of log sequence values comprises:

increasing the number of log sequence values in the batch of log sequence values assigned to the subsequent storage I/O request of the first class when reserved log sequence values assigned to at least one storage I/O request of the first class in the two-phase commit queue are exhausted; or

decreasing the number of log sequence values in the batch of log sequence values assigned to the subsequent storage I/O request of the first class when reserved log sequence values assigned to at least one storage I/O request of the first class in the two-phase commit queue that are available exceeds a threshold.

5. The method of claim 1 , wherein:

the first host computer executes a hypervisor that enables sharing of hardware resources of the first host computer by one or more virtual instances running on the first host computer;

the hypervisor comprises the VSAN module; and

the VSAN module allows virtual instances running on other host computers in the cluster to access data stored in the local storage resources of the first host computer.

6. The method of claim 1 , wherein assigning the reserved log sequence values includes selecting a specific storage I/O request of the first class in the two-phase commit queue that is in a preparing state with the smallest log sequence value among the storage I/O requests of the first class, and determining whether there is any available reserved log sequence value assigned to the specific storage I/O request of the first class.

7. The method of claim 6 , wherein assigning the reserved log sequence values includes, when there is no available reserved log sequence value assigned to the specific storage I/O request of the first class, selecting another specific storage I/O requests of the first class in the two-phase commit queue that is in the preparing state with the second smallest log sequence value, and determining whether there is any available reserved log sequence value assigned to the another specific storage I/O request of the first class.

8. The method of claim 1 , wherein the storage I/O requests of the first class are resynchronization write requests and the storage I/O request of the second class are non-resynchronization write requests.

9. The method of claim 1 , wherein the storage I/O requests of the first class are storage I/O requests from the first host computer and the storage I/O request of the second class are storage I/O requests from other host computers in the cluster.

10. A non-transitory computer-readable storage medium containing program instructions executable by one or more processors of a computer system causes the one or more processors to perform steps operations comprising:

assigning, by a virtual storage area network (VSAN) module of a first host computer, a batch of log sequence values for each of a plurality of storage I/O requests of a first class, wherein the host computer is one of a plurality of host computers in a cluster, the cluster comprising a VSAN that uses local storage resources of one or more of the plurality of host computers, including the first host computer, as a distributed storage system, and one of the log sequence values from the batch of log sequence values for each storage I/O request of the first class is used for that storage I/O request and the other log sequence values from the batch of log sequence values are used as reserved log sequence values;

adding, by the VSAN module, the storage I/O requests of the first class to a two-phase commit queue;

assigning, by the VSAN module, the reserved log sequence values of the storage I/O requests of the first class in the two-phase commit queue to some of a plurality of storage I/O requests of a second class; and

adding, by the VSAN module, the storage I/O requests of the second class to the two-phase commit queue, wherein the reserved log sequence values assigned to some of the storage I/O requests of the second class ensure that at least one of the storage I/O requests of the second class in the two-phase commit queue is committed before at least one of storage I/O requests of the first class in the two-phase commit queue.

11. The non-transitory computer-readable storage medium of claim 10 , wherein assigning the batch of log sequence values for each storage I/O request of the first class includes using a highest log sequence value from the batch of log sequence values for that particular storage I/O request of the first class.

12. The non-transitory computer-readable storage medium of claim 10 , wherein the steps further comprise changing a size of a batch of log sequence values assigned to a subsequent storage I/O request of the first class based on utilization of reserved log sequence values of the storage I/O requests of the first class.

13. The non-transitory computer-readable storage medium of claim 12 , wherein changing the size of the batch of log sequence values comprises:

increasing the number of log sequence values in the batch of log sequence values assigned to the subsequent storage I/O request of the first class when reserved log sequence values assigned to at least one storage I/O request of the first class in the two-phase commit queue are exhausted; or

decreasing the number of log sequence values in the batch of log sequence values assigned to the subsequent storage I/O request of the first class when reserved log sequence values assigned to at least one storage I/O request of the first class in the two-phase commit queue that are available exceeds a threshold.

14. The non-transitory computer-readable storage medium of claim 10 , wherein:

the first host computer executes a hypervisor that enables sharing of hardware resources of the first host computer by one or more virtual instances running on the first host computer;

the hypervisor comprises the VSAN module; and

the VSAN module allows virtual instances running on other host computers in the cluster to access data stored in the local storage resources of the first host computer.

15. The non-transitory computer-readable storage medium of claim 10 , wherein assigning the reserved log sequence values includes selecting a specific storage I/O request of the first class in the two-phase commit queue that is in a preparing state with the smallest log sequence value among the storage I/O requests of the first class, and determining whether there is any available reserved log sequence value assigned to the specific storage I/O request of the first class.

16. The non-transitory computer-readable storage medium of claim 15 , wherein assigning the reserved log sequence values includes, when there is no available reserved log sequence value assigned to the specific storage I/O request of the first class, selecting another specific storage I/O requests of the first class in the two-phase commit queue that is in the preparing state with the second smallest log sequence value, and determining whether there is any available reserved log sequence value assigned to the another specific storage I/O request of the first class.

17. The non-transitory computer-readable storage medium of claim 10 , wherein the storage I/O requests of the first class are resynchronization write requests and the storage I/O request of the second class are non-resynchronization write requests.

18. The non-transitory computer-readable storage medium of claim 10 , wherein the storage I/O requests of the first class are storage I/O requests from a the first host computer and the storage I/O request of the second class are storage I/O requests from other host computers in the cluster.

19. A computer system comprising:

memory; and

a processor configured to:

assigning, by a virtual storage area network (VSAN) module of a first host computer, a batch of log sequence values for each of a plurality of storage I/O requests of a first class, wherein the host computer is one of a plurality of host computers in a cluster, the cluster comprising a VSAN that uses local storage resources of one or more of the plurality of host computers, including the first host computer, as a distributed storage system, and one of the log sequence values from the batch of log sequence values for each storage I/O request of the first class is used for that storage I/O request and the other log sequence values from the batch of log sequence values are used as reserved log sequence values;

adding, by the VSAN module, the storage I/O requests of the first class to a two-phase commit queue;

assigning, by the VSAN module, the reserved log sequence values of the storage I/O requests of the first class in the two-phase commit queue to some of a plurality of storage I/O requests of a second class; and

adding, by the VSAN module, the storage I/O requests of the second class to the two-phase commit queue, wherein the reserved log sequence values assigned to some of the storage I/O requests of the second class ensure that at least one of the storage I/O requests of the second class in the two-phase commit queue is committed before at least one of storage I/O requests of the first class in the two-phase commit queue.

20. The computer system of claim 19 , wherein:

the first host computer executes a hypervisor that enables sharing of hardware resources of the first host computer by one or more virtual instances running on the first host computer;

the hypervisor comprises the VSAN module; and

the VSAN module allows virtual instances running on other host computers in the cluster to access data stored in the local storage resources of the first host computer.

Assignments (2)
CHANGE OF NAME Recorded May 8, 2024
From: VMWARE, INC.
To: VMWARE LLC
Reel/Frame 067355/0001 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Nov 14, 2022
From: XU, YIQI; KNAUFT, ERIC; XIANG, ENNING
To: VMWARE, INC.
Reel/Frame 061762/0153 →
Continuity (1)
Related Publication 20240111755A1 · Apr 4, 2024