IP Library Granted Patent US 10,423,450
Granted Patent B2
US 10,423,450 · App. 15/833,779 · Granted Sep 24, 2019

Method and system for scheduling input/output resources of a virtual machine

Inventor: Chao Zhang (Hangzhou, CN)
Assignee: Alibaba Group Holding Limited
G06F9/4881G06F9/45533G06F9/45558G06F9/5011G06F13/102G06F2009/45579
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 10,423,450
App. No.
15/833,779
Granted
Sep 24, 2019
Kind
B2
Abstract

One embodiment provides a system for scheduling I/O resources of a virtual machine. During operation, in response to receiving a plurality of I/O requests, the system identifies a plurality of target virtual disks to which the I/O requests are to be sent, wherein a virtual disk corresponds to a previously created I/O queue. The system assigns a respective I/O request to the corresponding I/O queue for an identified target virtual disk. The system schedules I/O resources to be used by the respective I/O request based on a scheduling parameter that corresponds to the identified target virtual disk.

Claims (72)

1. A computer-implemented method for scheduling I/O resources of a virtual machine, the method comprising:

configuring a scheduling strategy based on a priority for each of a plurality of I/O queues, wherein a respective I/O queue corresponds to a virtual disk of the virtual machine, and wherein a respective virtual disk is stored as a file on a physical machine hosting the virtual machine;

maintaining the plurality of I/O queues based on the scheduling strategy and a portion of shared I/O resources allocated to groups corresponding to the plurality of I/O queues,

wherein a respective group includes a plurality of service trees, wherein a respective service tree includes a first number of the I/O queues, and wherein the first number of the I/O queues comprises a unique part of an entirety of the plurality of I/O queues;

assigning an I/O request to a first I/O queue based on the scheduling strategy and the allocated portion of the shared I/O resources; and

allocating, to the I/O request, a first amount of the portion of the shared I/O resources, wherein the first amount represents a quota for the virtual disk corresponding to the first I/O queue.

2. The method of claim 1 , wherein the groups, the service trees, and the I/O queues are arranged in a tree-like structure with the I/O queues arranged as leaves and the groups arranged as roots,

wherein a respective service tree includes a unique set of the plurality of I/O queues, and

wherein a respective group, a respective service tree, and a respective unique set of the plurality of I/O queues are determined based on a completely fair queuing scheduling algorithm.

3. The method of claim 1 , further comprising:

receiving the I/O request; and

obtaining one or more features from the I/O request.

4. The method of claim 3 , wherein a feature includes one or more of:

a first value which is set by a user of the computer system;

a second value which is set by the computer system; and

a predetermined value, and

wherein the method further comprises:

in response to determining that the feature includes a first value which is set by the user, marking the I/O request.

5. The method of claim 3 , wherein a feature includes a process identifier which indicates whether a source of the I/O request is a virtual machine or a physical machine, and wherein the method further comprises:

in response to determining that the feature includes a process identifier which indicates that the source of the I/O request is a virtual machine, identifying the virtual disk stored as the file identified by a file identifier contained in the I/O request.

6. The method of claim 1 , wherein assigning the I/O request to the first I/O queue is further based on a file identifier contained in the I/O request and scheduling parameters for the virtual disk,

wherein the file identifier uniquely identifies the file storing the virtual disk corresponding to the first I/O queue, and

wherein the scheduling parameters indicate a portion of the shared I/O resources allocated to the virtual disk.

7. The method of claim 1 , further comprising:

setting a first threshold which indicates a value associated with triggering a re-allocation of the shared I/O resources; and

in response to detecting that a virtual disk is idle and has an allocated portion of the shared I/O resources greater than the first threshold, re-allocating the shared I/O resources for virtual disks of the virtual machine.

8. The method of claim 1 , further comprising:

determining a target virtual disk of the virtual machine based on a file identifier contained in the I/O request; and

determining a second I/O queue which is mapped to the target virtual disk, wherein the second I/O queue is the first I/O queue to which the I/O request is assigned.

9. The method of claim 1 , wherein assigning the I/O request to the first I/O queue causes virtual disks of the virtual machine to remain isolated from each other.

10. The method of claim 1 , wherein the I/O request is received from a user of one or more of:

a first physical computing device;

a first virtual machine associated with the first physical computing device;

a second physical computing device which interacts with the first physical computing device or the first virtual machine; and

a second virtual machine which interacts with the first physical computing device or the first virtual machine.

11. A computer system for scheduling I/O resources of a virtual machine, the system comprising:

a processor; and

a memory coupled to the processor and storing instructions, which when executed by the processor cause the processor to perform a method, the method comprising:

configuring a scheduling strategy based on a priority for each of a plurality of I/O queues, wherein a respective I/O queue corresponds to a virtual disk of the virtual machine, and wherein a respective virtual disk is stored as a file on a physical machine hosting the virtual machine;

maintaining the plurality of I/O queues based on the scheduling strategy and a portion of shared I/O resources allocated to groups corresponding to the plurality of I/O queues,

wherein a respective group includes a plurality of service trees, wherein a respective service tree includes a first number of the I/O queues, and wherein the first number of the I/O queues comprises a unique part of an entirety of the plurality of I/O queues;

assigning an I/O request to a first I/O queue based on the scheduling strategy and the allocated portion of the shared I/O resources; and

allocating, to the I/O request, a first amount of the portion of the shared I/O resources, wherein the first amount represents a quota for the virtual disk corresponding to the first I/O queue.

12. The computer system of claim 11 , wherein the groups, the service trees, and the I/O queues are arranged in a tree-like structure with the I/O queues arranged as leaves and the groups arranged as roots,

wherein a respective service tree includes a unique set of the plurality of I/O queues, and

wherein a respective group, a respective service tree, and a respective unique set of the plurality of I/O queues are determined based on a completely fair queuing scheduling algorithm.

13. The computer system of claim 11 , wherein the method further comprises:

receiving the I/O request; and

obtaining one or more features from the I/O request.

14. The computer system of claim 13 , wherein a feature includes one or more of:

a first value which is set by a user of the computer system;

a second value which is set by the computer system; and

a predetermined value, and

wherein the method further comprises:

in response to determining that the feature includes a first value which is set by the user, marking the I/O request.

15. The computer system of claim 13 , wherein a feature includes a process identifier which indicates whether a source of the I/O request is a virtual machine or a physical machine, and wherein the method further comprises:

in response to determining that the feature includes a process identifier which indicates that the source of the I/O request is a virtual machine, identifying the virtual disk stored as the file identified by a file identifier contained in the I/O request.

16. The computer system of claim 11 , wherein assigning the I/O request to the first I/O queue is further based on a file identifier contained in the I/O request and scheduling parameters for the virtual disk,

wherein the file identifier uniquely identifies the file storing the virtual disk corresponding to the first I/O queue, and

wherein the scheduling parameters indicate a portion of the shared I/O resources allocated to the virtual disk.

17. The computer system of claim 11 , wherein the method further comprises:

setting a first threshold which indicates a value associated with triggering a re-allocation of the shared I/O resources; and

in response to detecting that a virtual disk is idle and has an allocated portion of the shared I/O resources greater than the first threshold, re-allocating the shared I/O resources for virtual disks of the virtual machine.

18. The computer system of claim 11 , wherein the method further comprises:

determining a target virtual disk of the virtual machine based on a file identifier contained in the I/O request; and

determining a second I/O queue which is mapped to the target virtual disk, wherein the second I/O queue is the first I/O queue to which the I/O request is assigned.

19. The computer system of claim 11 , wherein assigning the I/O request to the first I/O queue causes virtual disks of the virtual machine to remain isolated from each other.

20. The computer system of claim 11 , wherein the I/O request is received from a user of one or more of:

a first physical computing device;

a first virtual machine associated with the first physical computing device;

a second physical computing device which interacts with the first physical computing device or the first virtual machine; and

a second virtual machine which interacts with the first physical computing device or the first virtual machine.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Apr 21, 2026
From: ALIBABA GROUP HOLDING LIMITED
To: CLOUD INTELLIGENCE ASSETS HOLDING (SINGAPORE) PRIVATE LIMITED
Reel/Frame 075478/0225 →
Priority Claims (1)
CN 2015 1 0197899 · Apr 23, 2015 · national
Continuity (2)
Continuation 15087396 · Mar 31, 2016
Related Publication 20180095789A1 · Apr 5, 2018