Virtual quantized congestion notification

Congestion management for data traffic in a virtual domain identifies a congestion source and sends a message to the source to adjust data traffic rates. The source may be a virtual machine hosted by a physical server with one or more virtual servers incorporated. A congestion manager may identify the source and send the message to the source without affecting other data sources hosted by the physical server or the virtual servers. In some embodiments, information about the congestion source may be encapsulated in a packet payload readable only by the congestion source so only the congestion source receives the instruction to adjust the transmission rate.

BACKGROUND

The present invention relates to network management, and more specifically, to virtual quantized congestion notification in a network with virtual switching devices.

In conventional physical networks, network equipment working at the lower levels was allowed to handle congestive events by simply dropping excess traffic. Providing reliability was instead left to the upper layers. Handling congestion by dropping frames comes at the expense of wasting network resources to transmit the frames. Hence, a lot of effort has been put into making the hardware network infrastructure lossless through the use of flow controls. In some physical networks, a lossless environment may be achieved using technologies such as Infiniband and Converged Enhanced Ethernet (CEE).

Employing lossless techniques to the virtual networking domain has provided a different set of challenges, especially to the virtual counterparts of the network equipment used inside the hypervisors to provide connectivity to the virtual machines. Flow control for a physical switching device controls the device as a single entity. Flow control for a physical switching device does not account for virtual devices hosted by the physical device. For example, a physical network interface card (NIC) may host multiple virtual machines through a common virtual switch and hypervisor. When the buffer queue of a virtual machine backs up, flow control may send a message to block incoming traffic to the backed up queue. However, since all buffer queues are running through the same hypervisor on the same physical NIC, the NIC is unable to distinguish one virtual machine's queue from the others. The result is that every queue receives the block command even though the other queues may have been running without issue. Thus, the efficiency of virtual switches may drop dramatically whenever congestion occurs in a buffer queue.

SUMMARY

According to one embodiment of the present invention, a computer program product for controlling congestion of data traffic in a virtual switching device, the computer program product comprises a computer readable storage medium having program code embodied therewith. The program code may be readable/executable by a processor. The program code may be configured to determine, by the processor, that a receiving queue in the virtual switching device is receiving data packets at a faster rate than transmission of data packets from the virtual switching device or faster than a programmed rate of reception for the receiving queue, indicating congestion in the receiving queue. The program code may be configured to determine, by the processor, a source of the congestion for the data packets being received by the receiving queue. The program code may be configured to control, by the processor, a decrease in a transmission rate of the data packets from the source of congestion to the receiving queue in the virtual switching device.

According to another embodiment of the present invention, a method of controlling congestion of data traffic in a virtual switching device comprises reading an amount of data packets in a receiving queue of a virtual switching device; determining if the amount of data packets in the receiving queue exceeds a threshold number of data packets for the receiving queue; reading a virtual machine source address of the data packets in the receiving queue; and sending a notification message to the virtual machine source address instructing the virtual machine source address to decrease a rate of transmission of the data packets.

According to yet another embodiment of the present invention, a network switch comprises a physical network interface card (NIC). A virtual switching device may be interfaced with the physical NIC and connected to a source of data traffic. A buffer module may be connected to the virtual switching device including a receiving queue for data packets received by the virtual switching device from the source of data traffic. The virtual switching device may be configured to forward a notification message to the source of data traffic indicating congestion in the receiving queue.

DETAILED DESCRIPTION

Broadly, embodiments of the subject technology provide management of congested data traffic in virtual switches. In some embodiments, a lossless switching environment may be provided in a virtual domain of a network by identifying congestion points and throttling down the source(s) of transmitted data. Control of the source(s) contributing to congestion may be performed on an individual source basis rather than by throttling down all virtual sources associated with a physical switch device. For example, embodiments of the subject technology may compare the traffic injection rate of data sources to the traffic consumption rates at the destinations or bottleneck links along a data traffic path. The mismatch between the injection and consumption rate may be computed by observing the state of the queues of the virtual switching devices over time. The state information may then be sent back towards the source and may be used to adjust the injection rate of the source.

Characteristics may include:

Cloud Software as a Service (SaaS): the capability provided to the consumer may be to use the provider's applications running on cloud infrastructure. The applications may be accessible from various client devices through a thin client interface such as a web browser (e.g., web-based email). The consumer need not necessarily manage or control the underlying cloud infrastructure including network, servers, operating systems, storage, or even individual application capabilities, with the possible exception of limited user-specific application configuration settings.

Rapid elasticity: capabilities may be rapidly and elastically provisioned, in some cases automatically to quickly scale out, and may be rapidly released to quickly scale in. To the consumer, the capabilities available for provisioning often appear to be unlimited and can be purchased in any quantity at any time.

As will be appreciated by one skilled in the art, aspects of the present invention may be embodied as a system, method or process, or computer program product.

Referring now toFIG. 1, a schematic of an example of a cloud computing node10is shown. The cloud computing node10illustrated is only one example of a suitable cloud computing node and is not intended to suggest any limitation as to the scope of use or functionality of embodiments of the invention described herein.

Regardless, the cloud computing node10is capable of being implemented and/or performing any of the functionality set forth herein.

As shown inFIG. 1, a computer system/server12in the cloud computing node10is shown in the form of a general-purpose computing device. The components of the computer system/server12may include, but are not limited to, one or more processing units or processors16, a system memory28, and a bus18that couples various system components including the system memory28to the processor16.

The computer system/server12may typically include a variety of computer system readable media. Such media could be chosen from any available media that is accessible by computer system/server12, including volatile and non-volatile media, removable and non-removable media.

A virtualization layer62provides an abstraction layer from which the following examples of virtual entities may be provided: virtual machines, virtual servers; virtual storage; virtual networks, including virtual private networks; virtual applications; and operating systems; and virtual clients.

In one example, a management layer64may provide the functions described below. Resource provisioning may provide dynamic procurement of computing resources and other resources that are utilized to perform tasks within the cloud computing environment. Metering and Pricing may provide cost tracking, as resources are utilized within the cloud computing environment, and may provide billing or invoicing for consumption of these resources. In one example, these resources may comprise application software licenses. Security may provide identity verification for cloud consumers and tasks, as well as protection for data and other resources. A user portal may provide access to the cloud computing environment for consumers and system administrators. Service level management may provide cloud computing resource allocation and management such that required service levels are met. Service Level Agreement (SLA) planning and fulfillment may provide pre-arrangement for, and procurement of, cloud computing resources for which a future requirement is anticipated in accordance with an SLA.

A workloads layer66may provide functionality for which the cloud computing environment may be utilized. Examples of workloads and functions that may be provided from this layer include: mapping and navigation; software development and lifecycle management; virtual classroom education delivery; data analytics processing; transaction processing; and data traffic congestion management.

Referring now toFIG. 4, a switching system100is shown according to an exemplary embodiment of the present invention. The switching system100may include a virtualized server110connected to a network150. The virtualized server110may include a virtual switch120with one or more congestion points of data traffic. The virtual switch120may be connected to the network150via a network interface card (NIC)130controlled by a NIC driver135. A hypervisor115may be configured to control one or more virtual machines140(labeled “VM0” through “VM n”) connected to the virtual switch120through virtual NICs125(labeled “vNIC0” through “vNIC n”). The hypervisor115may include a congestion manager module125with computer readable/executable instructions configured to control the injection rate of data packets into the virtual switch120. In some embodiments, the processor16(FIG. 1) may execute the instructions provided by the congestion manager125. The network150may include physical switches (not shown) and other virtual switches120′. The physical switches and other virtual switches120′ in the network150may include other congestion points and sources of congestion. While only one virtual switch120′ is shown in the network150, it will be understood that multiple virtual switches120′ may be present.

Referring now toFIG. 5, a switching system200is shown according to an exemplary embodiment of the present invention. In some embodiments, congestion management may be provided between sources and congested switches that are on separate physical switches. The system200is similar to the system100except that two virtualized servers110(shown as110aand110brespectively) are connected to one another separated by the network150. In the following description ofFIG. 5, when using a number without a subscript, the number may refer to any or all of the elements of that number. The virtualized server110amay include a virtual switch120a, a physical NIC130a, and virtual machines140aand140b. The virtual machine140amay include a transmitting buffer queue122aand a receiving buffer queue124a. Virtual machine140bmay include a transmitting buffer queue122band a receiving buffer queue124b. Virtual switch120amay include a transmitting buffer queue122cand a receiving buffer queue124c. The virtualized server110bmay include a virtual switch120b, a physical NIC130b, and virtual machines140cand140d. The virtual machine140cmay include a transmitting buffer queue122dand a receiving buffer queue124d. The virtual machine140dmay include a transmitting buffer queue122eand a receiving buffer queue124e. The virtual switch120bmay include a transmitting buffer queue122fand a receiving buffer queue124f. The transmitting buffer queues122may also be referred to as egress queues. The receiving buffer queues124may also be referred to as ingress queues.

Virtualized server110amay be connected to the network150through physical switch155a(“Physical Switch1”). Virtual switch110bmay be connected to the network150through physical switch155b(“Physical Switch2”). Physical switches155aand155bmay be connected to a physical switch155cso that data flows passing through physical switch155amay go directly to physical switch155b(or vice versa) or may go indirectly from physical switch155ato physical switch155bthrough physical switch155c. The buffer receiving queues124may be receiving data packets from any of the transmitting buffer queues122outside of their own associated switching device (virtual switch120or virtual machine140).

The congestion manager125may be configured to determine which source (transmitting buffer queue122) is causing congestion in a receiving buffer queue124. The congestion manager may identify when a receiving buffer queue124is congested with data packets. For example, receiving buffer queue124dof virtual machine140cmay represent a congested queue. The congestion manager125may determine that receiving buffer queue124dmay be receiving data packets at a faster rate than a transmission of data packets from the virtual machine140c. In some embodiments, the source of congestion may reside on the same virtualized server110. For example, the virtual machine140dresiding on virtualized server110bmay be the source of congestion providing data packets to virtual machine140cfaster than expected. In some embodiments, the source of congestion may reside on a different virtualized server110. For example, the virtual machine140aresiding on virtualized server110amay be the source of congestion. While shown as being connected to one another via separate physical switches155, it will be understood that some embodiments include the virtualized servers110aand110bbeing connected to the same physical switch155(not shown).

Referring now toFIGS. 5 and 6, a traffic manager system300is shown according to an exemplary embodiment of the present invention. The traffic manager system300may reside for example, between the virtual machine140and the virtual switch120. The traffic manager system300may include the congestion manager125connected to a buffer module320, a virtual priority queue module330, and an interface340to the physical NIC130. The priority queue module330may be managed by the hypervisor115and the interface between virtual machines(s)140and the hypervisor115to send and receive packets between the two entities via, for example, a vNIC125. Each vNIC125may have a dedicated number of queues (122,124) assigned to it.

The buffer module320may include a buffer manager324and buffer memory328. The buffer memory328may hold the data packets in the buffer queues122and124. The buffer manager324may control the egress and ingress of data packets from the buffer memory328. The buffer manager324may be configured to monitor the number of data packets in the buffer queues122and124. For example, a threshold value for the number of data packets in queue may be stored for each buffer queue122and124. The buffer manager324may indicate to the congestion manager125when the threshold value has been reached.

In an exemplary embodiment, the congestion manager125may be configured to sample the rate of data packets being transmitted by the transmitting buffer queue122to the receiving buffer queue124. The congestion manager125may select a flow of data entering the receiving buffer queue124from one of the transmitting buffer queues122for sampling. The flow selection for sampling may be based on a predetermined order. The sampling may be based on various data flow attributes read by the buffer manager324. The rate of flow entering the receiving buffer queue124may be, for example, in terms of kilobytes per second (kb/s). In some embodiments, the congestion manager125may be set to start reading a data flow after a predetermined number of are detected flows have entered the receiving buffer queue124. The congestion manager125may poll the receiving buffer queue124to read a current number of data packets being present within a window of time. The congestion manager125may compare this current number of data packets to a preset value of data packets. The preset value of data packets may represent an equilibrium value for data packets that should be present the receiving buffer queue124during the window of time. The congestion manager125may compute the difference (Δ) between the current number of data packets and the equilibrium value. In some embodiments the Δ may only be considered for the positive value (the current number of data packets exceeding the equilibrium) or the Δ may be taken as an absolute value. The congestion manager125may then compare determine whether the difference (Δ) exceeds a preset threshold Δ within the transmission window of time. When the preset threshold Δ is exceeded, then the receiving buffer queue124may be considered congested (for example as receiving buffer queue124′).

In an exemplary embodiment, the congestion manager125may determine the source of the data packets being received by the congested receiving buffer queue124d(FIG. 5). For example, the congestion manager125may read a virtual machine source address attached to the data packets entering the receiving buffer queue124d. Details of encapsulating the data packets with virtual address and physical address during routing of the data packets from the source to the receiving buffer queue124dwill be described below. When the source of data packets congesting the receiving buffer queue124dis located, the congestion manager125may control the transmitting buffer queue122to decrease a transmission rate of the data packets to the receiving buffer queue124d. While the foregoing was described primarily in the context of a single source congesting the receiving buffer queue124d, it will be understood that multiple sources may contribute to the congestion. Thus, in some embodiments, each of the sources unexpectedly congesting the receiving buffer queue124′ may be identified and throttled down while sources transmitting data flow within expected parameters may continue transmitting undisturbed.

Referring now toFIGS. 4 and 5concurrently withFIGS. 7-10, exemplary data packet schemes for routing data packets between physical and virtual devices in a network150are shown according to an exemplary embodiment of the present invention. In some embodiments, the congestion manager125may be able to distinguish between physical sources or virtual sources as the source of congestion in managing congestion by employing a virtual quantized congestion management (vQCM) technique. In general, the congestion notification manager125may attach a congestion notification (CN) tag to data packets. Congestion management may be enabled at any vNIC125interface. In addition, any data packets that egress from a virtual machine140or virtual switch120may be CN tagged. Data packets with the CN tag detected at the virtual switch120may invoke congestion detection, for example, by initiating sampling of data flows. Data frames may be reconfigured at different point along the network path to provide compatibility between physical to virtual interfaces. The information associated with a congestion source may be maintained allowing the congestion manager125to distinguish between multiple potential sources of congestion; both physical and virtual. The congestion manager may thus send a message back to the source causing congestion and control the transmission rate of data from the source without necessarily affecting other sources. InFIGS. 7-10that follow,FIGS. 7 and 8provide data frame schemes of data packets transmitted from the egress of a virtual switch120or virtual machine140. In some embodiments, no encapsulation of information in the payload portion may be necessary. InFIGS. 9-10, exemplary congestion notification management are provided showing data frames carrying a notification message back to a congestion source. In some embodiments, an encapsulation of the payload may be used to encrypt the notification and instructions to throttle down transmission rate so that other switching devices (physical or virtual) along the network path do not inadvertently adjust their transmission rates.

Referring toFIG. 7, a data frame400may be configured for transmission between a physical switch155and a virtual switch120. The data frame400may include a cyclic redundancy check (CRC) portion410, an Ethernet payload420, a CN tag portion430, a C-tag portion440, an S-tag portion450, a source address (SA) portion460, and a destination address (DA) portion470. The Ethernet payload420may be written for comprehension in an Ethernet environment. In some embodiments, the destination address may be the MAC address for one of the virtual machines140in the virtual switch120. The CN tag portion430may comprise a quantized congestion notification (QCN) tag434with Ethernet compatibility and a FLOWID portion438identifying a flow associated with the data frame. As may be appreciated, the CN instruction on the CN tag430may be compatible in physical switching points since the QCN portion434may be readable under Ethernet standards. Thereafter, the data frame400may be sent to the virtual switch120where it eventually enters the receiving buffer queue124of a virtual machine140.

Referring now toFIG. 8, a data frame500may be configured for transmission between a virtual machine140and the virtual switch120. The data frame500may include a CRC portion510, an Ethernet payload520, a CN tag portion530, a C-tag portion540, a SA portion560, and a DA portion570. In embodiments where the data frame500is being sent from the virtual machine140to the virtual switch120, the source address may be the MAC address for the virtual machine140. The CN tag530may include a QCN tag534with Ethernet compatibility and a FLOWID portion538.

Referring toFIG. 9, an exemplary congestion notification management (CNM) frame600is shown. The CNM frame600may be configured for transmission from the physical switch155to the virtual switch120that holds the source of congestion. The CNM frame600may be similar to the data frame400except that instead of an Ethernet payload420, the data frame600includes a CNM payload620. The CNM frame600may include a CRC portion610, the CNM payload620, a CN tag portion630, a C-tag portion640, an S-tag portion650, an SA portion660, and a DA portion670. The CNM payload may be encapsulated with code written for translation in a virtual environment. The CNM payload620may include the notification message with instructions to throttle down the transmission rate of data packets. The destination address670may be the virtual address of the virtual switch120. The virtual switch120may decrypt the encapsulated CNM payload620for the MAC address of the congestion source. The virtual switch120may then modify the CNM frame600for transmission to its intended destination; the congestion source.

Referring now toFIG. 10, an exemplary CNM frame700is shown. The CNM frame700may be configured for transmission from the virtual switch120to the virtual machine140with the source of congestion. The CNM frame700may be similar to the data frame500except that instead of an Ethernet payload520, the data frame700includes a CNM payload720. The CNM frame700may include a CRC portion710, the CNM payload720, a CN tag portion730, a C-tag portion740, an SA portion760, and a DA portion770. In some embodiments, there may be multiple congestion sources intermediate the physical switch120and the intended destination of the data frame700. For example, there may be multiple virtual machines140connected to the virtual switch120that may also be sources of congestion. The virtual switch120may distinguish between the various virtual machines140by reading the destination MAC address of the virtual machine140as determined by the congestion manager125. The destination MAC address may be encapsulated in the CNM payload720for decrypting by virtual machines140. If a virtual machine140other than the destination virtual machine140is on the route to the intended source, the intermediate virtual machine140may just forward the CNM frame700on to its next stop until it reaches its destination where the indication to throttle down data transmission is received and invoked. Thus, the notification message may be sent to the appropriate source of congestion without affecting connected virtual devices.

InFIG. 11that follows, the actions in the blocks may be stored as instructions within the congestion manager125, and executed by the processor16.

Referring now toFIG. 11, a method800of controlling congestion of data traffic in a virtual switching device is shown according to an exemplary embodiment of the present invention. The congestion manager125monitors through sampling (in block805) the queue length.

The sampling may be done according to any distribution. From the read queues length values, the congestion manager125may measure the built up severity of congestion (in block810) in a queue. The congestion manager125may determine (in block815) whether the receiving queue length and its growth exceed a threshold number of data packets and growth for the receiving queue. For example, the threshold may be exceeded when a difference in the sampled queue length and growth in comparison to preset equilibrium values exceeds a predetermined value. The congestion manager125may, after a predetermined time or other condition (for example, after a predetermined number of packets have been received), read again (in block805) the receiving queue length until the threshold is exceeded. The congestion manager125may identify (in block820) a source of congestion. The identification may be done via different methods. For example, it may be based on the values of certain packet fields e.g. source MAC address, destination MAC address and priority field, a combination of the aforementioned values or for example, a hash code or explicit tag inserted at the source. The congestion manager125may determine (in block825) if the source is local (residing on the same virtualized server) or remote (residing on a different virtualized server). The congestion manager125may notify a remote source to decrease a rate of transmission of data packets (in block835) via notification messages. The notification messages may both be explicit or encapsulated. The congestion manager125may notify a local source to decrease a rate of transmission of data packets (in block830) via similar notification messages as for a remote source or use some other light weight communication scheme.

The terminology used herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the invention. As used herein, the singular forms “a”, “an” and “the” are intended to include the plural forms as well, unless the context clearly indicates otherwise. It will be further understood that the terms “comprises” and/or “comprising,” when used in this specification, specify the presence of stated features, integers, steps, operations, elements, and/or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and/or groups thereof. The corresponding structures, materials, acts, and equivalents of all means or step plus function elements in the claims below are intended to include any structure, material, or act for performing the function in combination with other claimed elements as specifically claimed. The description of the present invention has been presented for purposes of illustration and description, but is not intended to be exhaustive or limited to the invention in the form disclosed. Many modifications and variations will be apparent to those of ordinary skill in the art without departing from the scope and spirit of the invention. The embodiment was chosen and described in order to best explain the principles of the invention and the practical application, and to enable others of ordinary skill in the art to understand the invention for various embodiments with various modifications as are suited to the particular use contemplated.