A method and device for implementing multi-level scheduling for virtual interfaces

By retrieving the multi-level queue scheduling strategy of virtual interfaces from the Layer 3 forwarding table entries in the network device, the problem of virtual interfaces being unable to be scheduled independently is solved. This enables independent scheduling of virtual interfaces and physical ports, avoids the impact of queue congestion, and improves the traffic management capabilities of the network device.

CN118590459BActive Publication Date: 2026-03-10NEW H3C TECH CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-06-25
Publication Date
2026-03-10

AI Technical Summary

Technical Problem

Existing network devices cannot implement multi-level queue allocation for HQoS through virtual interfaces, which makes it impossible to independently schedule virtual interfaces and their corresponding physical ports, resulting in congestion in the sending queue and affecting packet forwarding.

Method used

By searching for the Layer 3 forwarding table entries that match the destination IP address of the packet, the scheduling policy identifiers of the first-level and second-level sending queues of the virtual interface are obtained, and the packets are identified and placed into the corresponding sending queues to achieve multi-level scheduling.

Benefits of technology

Independent scheduling of virtual interfaces and physical ports is achieved, avoiding the impact of send queue congestion on packet forwarding and improving the traffic management capabilities of network devices.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118590459B_ABST
    Figure CN118590459B_ABST
Patent Text Reader

Abstract

This application provides a method and apparatus for implementing multi-level scheduling for virtual interfaces. The method includes: searching a Layer 3 forwarding table entry matching the destination IP address of a packet; obtaining the virtual interface sending the packet and its first-level sending queue scheduling policy identifier from the Layer 3 forwarding table entry; identifying a set of first-level sending queues corresponding to the first-level sending queue scheduling policy identifier; placing the packet into a first-level sending queue corresponding to the packet priority information within the identified set of first-level sending queues; and placing the packet into a second-level sending queue mapped by the selected first-level sending queue according to the sending queue hierarchy mapping relationship.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to communication technology, specifically a method and device for implementing multi-level scheduling for virtual interfaces. Background Technology

[0002] QoS (Quality of Service) technology improves service quality by ensuring transmission bandwidth, reducing transmission latency, lowering packet loss rate, and mitigating latency jitter. Typical QoS congestion management uses a single-level queue allocation mechanism. This means that packets received through an interface are assigned to different priority receive queues, and packets sent through the interface are assigned to different priority send queues, ensuring that packets in higher-priority queues are processed and forwarded first. However, as access network services evolve, with increasing user numbers and diverse service types, the single-level queue allocation mechanism of QoS congestion management becomes insufficient to meet the management needs of multi-user, multi-service scenarios.

[0003] HQoS (Hierarchical Qualitative of Service) technology employs a multi-level queue allocation mechanism for congestion management, enabling more granular traffic management.

[0004] However, current network devices cannot implement HQoS multi-level queue allocation for packets sent through virtual interfaces, creating a set of multiple sending queues for the virtual interface; packets sent through the virtual interface are assigned to different priority sending queues of the virtual interface, and then the sending of packets in different queues is scheduled according to the order of priority from high to low. It is not possible to independently schedule the virtual interface and the physical port corresponding to the virtual interface in the outbound packet sending process. Summary of the Invention

[0005] The purpose of this application is to provide a method and device for implementing multi-level scheduling for virtual interfaces, which allows for independent scheduling of virtual interfaces and the physical ports corresponding to virtual interfaces.

[0006] To achieve the above objectives, this application provides a method for implementing multi-level scheduling for virtual interfaces. The method includes: finding a Layer 3 forwarding table entry that matches the destination IP address of a packet; obtaining the virtual interface sending the packet and the first-level sending queue scheduling policy identifier of the virtual interface from the Layer 3 forwarding table entry; identifying a set of first-level sending queues corresponding to the first-level sending queue scheduling policy identifier; placing the packet into a first-level sending queue corresponding to the packet priority information in the identified set of first-level sending queues; and placing the packet into a second-level sending queue mapped by the selected first-level sending queue according to the sending queue hierarchy mapping relationship.

[0007] To achieve the above objectives, this application also provides a device for implementing multi-level scheduling for virtual interfaces. The device includes at least a forwarding module that searches for Layer 3 forwarding entries matching the destination IP address of a packet; obtains the virtual interface sending the packet and the first-level sending queue scheduling policy identifier of the virtual interface from the Layer 3 forwarding entries; a queue module that identifies a set of first-level sending queues corresponding to the first-level sending queue scheduling policy identifier; places the packet into a first-level sending queue corresponding to the packet priority information in the identified set of first-level sending queues; and places the packet into a second-level sending queue mapped by the selected first-level sending queue according to the sending queue hierarchy mapping relationship.

[0008] The beneficial effect of this application is that virtual interfaces and the corresponding physical ports are scheduled independently, avoiding the impact of virtual interface sending queue congestion on the packet forwarding of virtual interface mapped physical ports. Attached Figure Description

[0009] Figure 1 A schematic diagram illustrating an embodiment of a method for implementing multi-level scheduling using the virtual interface provided in this application;

[0010] Figure 2 A schematic diagram of an embodiment of multi-level scheduling of the virtual aggregation port provided in this application;

[0011] Figure 3 A schematic diagram illustrating an embodiment of providing a scheduling virtual aggregation port for a specified service type message in this application;

[0012] Figure 4 A schematic diagram illustrating an embodiment of providing a specified service type message for a multi-level scheduling virtual aggregation port for this application;

[0013] Figure 5 A schematic diagram of an embodiment of multi-level scheduling of a Layer 3 sub-interface of a virtual local area network provided in this application;

[0014] Figure 6 A schematic diagram illustrating an embodiment of providing a scheduling virtual LAN Layer 3 sub-interface for a specified service type message;

[0015] Figure 7 A schematic diagram illustrating an embodiment of providing a specified service type message for a multi-level scheduling virtual LAN Layer 3 sub-interface in this application;

[0016] Figure 8 A schematic diagram of a device embodiment that implements multi-level scheduling using the virtual interface provided in this application. Detailed Implementation

[0017] The following detailed description will be provided with reference to several examples illustrated in the accompanying figures. In this detailed description, numerous specific details are used to provide a comprehensive understanding of the present application. Known methods, steps, components, and circuits are not described in detail in the examples to avoid obscuring their meaning.

[0018] In the terminology used, the term "including" means including but not limited to; the term "containing" means including but not limited to; the terms "above," "within," and "below" include the number itself; the terms "greater than" and "less than" mean not including the number itself. The term "based on" means based on at least a portion of them.

[0019] Figure 1 A schematic diagram illustrating an embodiment of a method for implementing multi-level scheduling using a virtual interface provided in this application; the method includes the following steps:

[0020] Step 101: Locate the Layer 3 forwarding table entry that matches the destination IP address of the packet;

[0021] Step 102: Obtain the virtual interface for sending the message and the first-level sending queue scheduling policy identifier of the virtual interface from the three-layer forwarding table entries;

[0022] Step 103: Identify a set of primary transmission queues corresponding to the primary transmission queue scheduling policy identifier;

[0023] Step 104: In the identified set of primary transmission queues, place the message into a primary transmission queue corresponding to the message priority information.

[0024] Step 105: According to the hierarchical mapping relationship of the sending queues, put the message into the second-level sending queue mapped by the selected first-level sending queue.

[0025] The beneficial effect of this application is that virtual interfaces and the corresponding physical ports are scheduled independently, avoiding the impact of virtual interface sending queue congestion on the packet forwarding of virtual interface mapped physical ports.

[0026] Figure 2 This is a schematic diagram of an embodiment of multi-level scheduling of the virtual aggregation port provided in this application.

[0027] Virtual Aggregator Port (LAG) of network devices Figure 2 (Not shown) corresponds to two physical member ports m1 and m2 ( Figure 2 (Not shown).

[0028] Network device queue scheduling configuration module ( Figure 2 (Not shown), apply for a first-level transmission queue Q1 for the virtual aggregation port LAG and configure the first-level transmission queue scheduling policy Qos1; apply for a second-level transmission queue Q2 and Q3 for the physical ports m1 and m2 corresponding to the virtual aggregation port LAG, respectively.

[0029] The network device's queue scheduling setting module sets the hierarchical mapping relationship of the sending queues; this hierarchical mapping relationship records the queues of the second-level sending queues Q2 or Q3, which are respectively mapped to the 8 queues of the first-level sending queue Q1; the network device's forwarding module ( Figure 2 (Not shown), in the Layer 3 forwarding table 21, the identifier Qos1 of the Level 1 sending queue scheduling strategy is recorded in the virtual aggregation port LAG as each Layer 3 forwarding table entry of the outgoing interface.

[0030] like Figure 2 As shown, when the forwarding module of the network device receives packets p1, p2, and p3, it searches for the Layer 3 forwarding table entries that match the destination IP addresses of these packets; it then retrieves the virtual aggregation port LAG of the outgoing interface of packets p1, p2, and p3, as well as the first-level sending queue scheduling policy identifier QoS1, from the Layer 3 forwarding table entries.

[0031] After the forwarding module of the network device determines that the outgoing interface of packets p1, p2, and p3 is a virtual aggregation port (LAG) by looking up the Layer 3 forwarding table 21, it can perform flow classification, token bucket, traffic policing / traffic shaping, weighted random early detection (WRED) and other processing on these packets, and then allocate the sending queue through the queue module 22.

[0032] The queue module 22 identifies the primary transmission queue scheduling policy identifier Qos1 of messages p1, p2, and p3, which corresponds to the primary transmission queue Q1. It also identifies the message priority information (such as DSCP priority) of message p1, which corresponds to queue 1 of Q1, and places message p1 into queue 1 of Q1. The queue module 22 identifies the message priority information of message p2, which corresponds to queue 8 of Q1, and places message p2 into queue 8 of Q1. The queue module 22 identifies the message priority information of message p3, which corresponds to queue 2 of Q1, and places message p3 into queue 2 of Q1.

[0033] According to the hierarchical mapping relationship of the sending queue, the queue module 22 performs re-queueing processing, putting message P1 into queue 2 of the secondary sending queue Q2 mapped to queue 1 in the selected Q1; putting message P2 into queue 2 of the secondary sending queue Q3 mapped to queue 8 in the selected Q1; and putting message P3 into queue 3 of the secondary sending queue Q2 mapped to queue 2 in the selected Q1.

[0034] Thus, the transmitting module of the switching chip in the network device ( Figure 2 (Not shown), messages P1 and P3 are sent through physical member port m1, and message P2 is sent through physical member port m2.

[0035] Figure 3 A schematic diagram illustrating an embodiment of providing a scheduling virtual aggregation port for a specified service type message in this application;

[0036] Network device queue scheduling configuration module ( Figure 3 (Not shown) is a virtual aggregation port LAG ( Figure 3 (Not shown) Request a set of primary transmission queues Q1 and configure the primary transmission queue scheduling policy Qos1; the network devices are two physical ports m1 and m2 of the virtual aggregation port, which respectively request a set of secondary transmission queues Q2 and Q3.

[0037] Network device queue scheduling configuration module ( Figure 3 (Not shown), set the sending queue hierarchy mapping relationship; in this sending queue hierarchy mapping relationship, the eight first-level sending queues of Q1 are respectively mapped to the second-level sending queues of Q2 or Q3.

[0038] Forwarding module of network device ( Figure 2 (Not shown), in the Layer 3 forwarding table 31, the identifier Qos1 of the Level 1 sending queue scheduling strategy is recorded in the virtual aggregation port LAG as each Layer 3 forwarding table entry of the outgoing interface.

[0039] The network device's queue scheduling configuration module also applies for at least one set of service type transmission queues Q4 for the virtual aggregation port LAG and a specified service type, and sets the corresponding specified service scheduling policy Qos2.

[0040] The flow classification module 32 of the network device is also used to record the ACL (Access Control List) entries that identify the virtual aggregation port LAG and the specified service scheduling policy corresponding to the specified service type.

[0041] like Figure 3 As shown, when the forwarding module of the network device receives packets p1, p2, and p3, it searches for the Layer 3 forwarding table entries that match the destination IP address of these packets; it then retrieves the outgoing interface virtual aggregation port LAG and the first-level sending queue scheduling policy identifier Qos1 from the Layer 3 forwarding table entries.

[0042] After the forwarding module of the network device finds that the outgoing interface of packets p1, p2, and p3 is a virtual aggregation port (LAG), it can perform flow classification on these packets.

[0043] The flow classification module 32 of the network device finds the ACL entries based on the virtual aggregation port LAG of the sent packets p1, p2, and p3 and the service type of the packets p1, p2, and p3, and obtains the identifier QoS2 of the specified service scheduling policy from the ACL entries.

[0044] Afterwards, the network device performs token bucket, traffic policing / traffic shaping, WRED and other processing on packets p1, p2 and p3, and then allocates the transmission queue through the queue module 33.

[0045] The queue module 33 prioritizes the allocation of sending queues for messages p1, p2, and p3 according to the queue scheduling strategy of the specified service type.

[0046] Queue module 33 identifies the identifier QoS2 of the specified service scheduling policy for message P1, identifies the message priority information of message P1, and puts message P1 into queue 1 of service type sending queue Q4; queue module 32 identifies the message priority information of message P2 into queue 3 of service type sending queue Q4, and puts message P2 into queue 3 of Q4; queue module 33 identifies the message priority information of message P3 into queue 2 of service type sending queue Q4, and puts message P3 into queue 2 of Q4.

[0047] Thus, the transmitting module of the switching chip in the network device ( Figure 3 (Not shown), when processing messages p1, p2, and p3 in queues 1, 2, and 3 of service type sending queue Q4, the hash values ​​of messages p1, p2, and p3 are calculated respectively according to the load sharing hash algorithm, and the physical member ports m1 and m2 of the virtual aggregation port LAG are selected to send the messages.

[0048] Figure 3 In this embodiment, the allocation of the sending queue for a specified service type sent through the virtual aggregation port LAG is independent of the allocation mechanism for the sending queue for an unspecified service type sent through the virtual aggregation port LAG, thereby enabling rich allocation of sending queues according to service requirements.

[0049] Figure 4 This is a schematic diagram illustrating an embodiment of providing a specified service type message for a multi-level scheduling virtual aggregation port in this application.

[0050] Network device queue scheduling configuration module ( Figure 4 (Not shown) is a virtual aggregation port LAG ( Figure 3 (Not shown) Request a set of primary transmission queues Q1 and configure the corresponding primary transmission queue scheduling policy Qos1; the network devices are two physical ports m1 and m2 of the virtual aggregation port, which respectively request a set of secondary transmission queues Q2 and Q3.

[0051] Network device queue scheduling configuration module ( Figure 4 (Not shown), set the sending queue hierarchy mapping relationship; in this sending queue hierarchy mapping relationship, the eight first-level sending queues of the first-level sending queue Q1 are respectively mapped to the second-level sending queues Q2 or Q3.

[0052] Forwarding module of network device ( Figure 4 (Not shown), in the Layer 3 forwarding table 41, the identifier Qos1 of the Level 1 sending queue scheduling strategy is recorded in the virtual aggregation port LAG as each Layer 3 forwarding table entry of the outgoing interface.

[0053] The network device's queue scheduling setting module also applies for at least one set of designated service level-one transmission queues Q4 for the virtual aggregation port LAG and a designated service type, and sets the corresponding designated service scheduling policy Qos2.

[0054] The queue scheduling setting module of the network device applies for a set of designated service secondary transmission queues Q5 and Q6 for the two physical ports m1 and m2 of the virtual aggregation port, respectively. It sets the service level mapping relationship to record that the eight queues of the designated service primary transmission queue Q4 are respectively mapped to the designated service secondary transmission queues Q5 or Q6.

[0055] The flow classification module 42 of the network device is also used to record the ACL entry that identifies the virtual aggregation port LAG and the specified service scheduling policy corresponding to the specified service type, and the identifier QoS2.

[0056] like Figure 4 As shown, when the forwarding module of the network device receives packets p1, p2, and p3, it searches for Layer 3 forwarding table entries that match the destination IP addresses of these packets. From the Layer 3 forwarding table entries, it retrieves the outgoing interface virtual aggregation port LAG of packets p1, p2, and p3, as well as the first-level sending queue scheduling policy identifier Qos1.

[0057] Subsequently, the flow classification module 42 of the network device finds the ACL entries based on the virtual aggregation port LAG of the sent packets p1, p2, and p3 and the service type of the packets p1, p2, and p3, and obtains the identifier QoS2 of the specified service scheduling policy from the ACL entries.

[0058] Afterwards, the network device performs token bucket, traffic policing / traffic shaping, WRED and other processing on packets p1, p2 and p3, and then allocates the transmission queue through the queue module 43.

[0059] The queue module 43 identifies the identifier QoS2 of the specified service scheduling policy for messages p1, p2, and p3, which corresponds to the first-level transmission queue Q4 of the specified service. It identifies the message priority information of message p1 and places it into queue 1 of Q4. The queue module 43 identifies the message priority information of message p2 and places it into queue 8 of Q4. The queue module 43 identifies the message priority information of message p3 and places it into queue 2 of Q4.

[0060] According to the service level mapping relationship, the queue module 43 performs re-queueing processing, placing message P1 into queue 8 of the designated service secondary transmission queue Q5 mapped to queue 1 in the selected Q4; placing message P2 into queue 2 of the designated service secondary transmission queue Q6 mapped to queue 8 in the selected Q4; and placing message P3 into queue 1 of the designated service secondary transmission queue Q6 mapped to queue 2 in the selected Q4.

[0061] Thus, the transmitting module of the switching chip in the network device ( Figure 2 (Not shown), message P1 is sent through physical member port m1 of the virtual aggregation port LAG, and messages P2 and P3 are sent through physical member port m2 of the virtual aggregation port LAG.

[0062] Figure 5 A schematic diagram of an embodiment of multi-level scheduling of a Layer 3 sub-interface of a virtual local area network provided in this application; physical port m3 of the network device ( Figure 5 The Layer 3 sub-interface int100 (not shown) is configured with VLAN 100. Figure 5 (Not shown) and VLAN200's Layer 3 sub-interface int200 ( Figure 5 (Not shown).

[0063] The network device's queue scheduling configuration module requests a first-level transmission queue Q7 for the Layer 3 sub-interface int100 and configures the corresponding first-level transmission queue scheduling policy Qos3; requests a first-level transmission queue Q8 for the Layer 3 sub-interface int200 and configures the corresponding first-level transmission queue scheduling policy Qos4; and requests a second-level transmission queue Q9 for the physical port m3 corresponding to the Layer 3 sub-interfaces int100 and int200.

[0064] The network device's queue scheduling setting module sets the hierarchical mapping relationship of the transmission queues; in this hierarchical mapping relationship, the first-level transmission queues of Q7 and Q8 are respectively mapped to the second-level transmission queues of Q9.

[0065] Forwarding module of network device ( Figure 5 (Not shown) In the Layer 3 forwarding table 51, the identifier Qos3 of the Level 1 sending queue scheduling policy is recorded in the Layer 3 sub-interface int100 as each Layer 3 forwarding table entry of the outgoing interface; the identifier Qos4 of the Level 1 sending queue scheduling policy is recorded in int200 as each Layer 3 forwarding table entry of the outgoing interface.

[0066] When the forwarding module of the network device receives packet p10, it finds the Layer 3 forwarding table entry that matches the destination IP address of packet p10; it then retrieves the first-level sending queue scheduling policy identifier Qos3 of the outgoing interface int10 and the Layer 3 sub-interface int100 from the Layer 3 forwarding table entry.

[0067] When the forwarding module of the network device receives packet p20, it finds the Layer 3 forwarding table entry that matches the destination IP address of packet p20; it then retrieves the first-level sending queue scheduling policy identifier QoS4 of the outgoing interface int200 and the Layer 3 sub-interface int300 from the Layer 3 forwarding table entry.

[0068] After the forwarding module of the network device determines that the outgoing interfaces of packets p10 and p20 are int100 and int200 respectively, it can perform flow classification, token bucket, traffic policing / traffic shaping, WRED and other processing on packets p10 and p20, and then allocate a sending queue through the queue module 52.

[0069] The queue module 52 identifies that the first-level sending queue scheduling policy identifier Qos3 of message p10 corresponds to Q7, identifies that the message priority information of message p10 corresponds to queue 2 of Q7, and puts message p1 into queue 2 of Q7.

[0070] The queue module 52 identifies that the first-level sending queue scheduling policy identifier Qos4 of message p20 corresponds to Q8, identifies the message priority information of message p20 corresponding to queue 1 of Q8, and puts message p20 into queue 1 of Q8.

[0071] According to the sending queue hierarchy mapping relationship, the queue module 52 performs re-queueing processing, putting message P10 into queue 1 of Q9 mapped to queue 2 of Q7; and putting message P20 into queue 2 of Q9 mapped to queue 1 of Q8.

[0072] Thus, the transmitting module of the switching chip in the network device ( Figure 5 (Not shown), the messages P10 and P20 of queues 1 and 2 of Q9 are sent through the physical port m3 corresponding to the Layer 3 sub-interfaces int100 and int200.

[0073] Figure 6 A schematic diagram illustrating an embodiment of providing a scheduling virtual LAN Layer 3 sub-interface for a specified service type message;

[0074] The physical port m3 of the network device Figure 6 The Layer 3 sub-interface int100 (not shown) is configured with VLAN 100. Figure 6 (Not shown) and VLAN200's Layer 3 sub-interface int200 ( Figure 6 (Not shown).

[0075] Network device queue scheduling configuration module ( Figure 6(Not shown), request a set of first-level transmission queue Q7 for the Layer 3 sub-interface int100 and configure the corresponding first-level transmission queue scheduling policy Qos3; request a set of first-level transmission queue Q8 for the Layer 3 sub-interface int200 and configure the corresponding first-level transmission queue scheduling policy Qos4; request a set of second-level transmission queue Q9 for the physical port m3 corresponding to the Layer 3 sub-interfaces int100 and int200.

[0076] The network device's queue scheduling setting module sets the hierarchical mapping relationship of the sending queues; in this hierarchical mapping relationship, the eight queues of Q7 and Q8 are respectively mapped to the queues of Q9.

[0077] Forwarding module of network device ( Figure 6 (Not shown) In the three-layer forwarding table 61, the identifier Qos3 of the first-level sending queue scheduling policy is recorded in the three-layer sub-interface int100 as each entry of the three-layer forwarding table of the outgoing interface; the identifier Qos4 of the first-level sending queue scheduling policy is recorded in int200 as each entry of the three-layer forwarding table of the outgoing interface.

[0078] The network device's queue scheduling configuration module also applies for at least one set of designated service level 1 transmission queues Q10 for the VLAN200 Layer 3 sub-interface int200 and a designated service type, and sets the corresponding designated service scheduling policy Qos5.

[0079] The flow classification module 62 of the network device is also used to record the ACL entry of the identifier QoS5 of the Layer 3 sub-interface int200 and the specified service scheduling policy corresponding to the specified service type.

[0080] like Figure 6 As shown, the forwarding module of the network device ( Figure 6 (Not shown) Upon receiving message p10, search for the Layer 3 forwarding table entry that matches the destination IP address of message p10; retrieve the Layer 3 sub-interface int100 for sending the message and the Level 1 sending queue scheduling policy identifier Qos3 from the Layer 3 forwarding table entry.

[0081] Figure 6 Network devices' processing of packet p10 and Figure 5 The network devices in China process message p10 in the same way. Figure 5 The processing of message 10 is combined here.

[0082] When the forwarding module of the network device receives packet p20, it looks up the Layer 3 forwarding table entry that matches the destination IP address of packet p20 in Layer 3 forwarding table 61; it then retrieves the Layer 3 sub-interface int200 for sending the packet and the Level 1 sending queue scheduling policy identifier QoS4 from the Layer 3 forwarding table entry.

[0083] The network device's forwarding module determines that the outgoing port of packet p20 is the Layer 3 sub-interface int200 of VLAN 20.

[0084] The flow classification module 62 of the network device is used to obtain the identifier QoS5 of the specified service scheduling policy based on the sending message p20 and the service type of message p20.

[0085] Afterwards, the network device performs token bucket, traffic policing / traffic shaping, WRED and other processing on the packet p20, and then allocates the transmission queue through the queue module 63.

[0086] The queue module 63 prioritizes allocating a transmission queue for message P20 according to the queue scheduling policy of the specified service type. The queue module 63 identifies the identifier QoS5 of the specified service scheduling policy of message P20, identifies the message priority information of message P20, and puts message P20 into queue 1 of the service type transmission queue Q10.

[0087] The transmitting module of the switching chip in the network device ( Figure 6 (Not shown), message 10 from queue 1 of Q9 and message 20 from queue 1 of Q10 are sent through physical port m3 corresponding to Layer 3 sub-interfaces int100 and int200.

[0088] Figure 7 A schematic diagram illustrating an embodiment of providing a specified service type message for a multi-level scheduling virtual LAN Layer 3 sub-interface in this application;

[0089] The physical port m3 of the network device Figure 7 The Layer 3 sub-interface int100 (not shown) is configured with VLAN 100. Figure 6 (Not shown) and VLAN200's Layer 3 sub-interface int200 ( Figure 6 (Not shown).

[0090] Network device queue scheduling configuration module ( Figure 7 (Not shown), apply for a first-level transmission queue Q7 for the Layer 3 sub-interface int100 and configure the corresponding first-level transmission queue scheduling policy Qos3; apply for a first-level transmission queue Q8 for the Layer 3 sub-interface int200 and configure the corresponding first-level transmission queue scheduling policy Qos4; apply for a second-level transmission queue Q9 for the physical port m3 corresponding to the Layer 3 sub-interfaces int100 and int200 respectively.

[0091] The network device's queue scheduling setting module sets the hierarchical mapping relationship of the sending queues; in this hierarchical mapping relationship, the eight first-level sending queues Q7 and Q8 are respectively mapped to the second-level sending queue Q9, which is the second-level sending queue.

[0092] Forwarding module of network device ( Figure 7 (Not shown) In the Layer 3 forwarding table 71, the identifier Qos3 of the Level 1 sending queue scheduling policy is recorded in the Layer 3 sub-interface int100 as each Layer 3 forwarding table entry of the outgoing interface; the identifier Qos4 of the Level 1 sending queue scheduling policy is recorded in int200 as each Layer 3 forwarding table entry of the outgoing interface.

[0093] The network device's queue scheduling setting module also applies for at least one set of designated service level-one transmission queues Q10 for the three-layer sub-interface int200 and a designated service type, and sets the corresponding designated service scheduling policy Qos5.

[0094] The network device's queue scheduling setting module requests a set of designated service secondary transmission queues Q11 for the physical port m3 corresponding to the Layer 3 sub-interface int200. It sets up a service level mapping relationship to record that the eight queues of the designated service primary transmission queue Q10 of the Layer 3 sub-interface int200 are respectively mapped to the designated service secondary transmission queue Q11.

[0095] The flow classification module 72 of the network device is also used to record the ACL entry of the identifier QoS5 of the specified service scheduling policy corresponding to the specified service type.

[0096] The processing of message p10 received by the network device and Figure 5 and Figure 6 same.

[0097] When the forwarding module of the network device receives packet p20, it searches for the Layer 3 forwarding table entry that matches the destination IP address of packet p20; it then retrieves the Layer 3 sub-interface int200 that sent the packet and the Level 1 sending queue scheduling policy identifier QoS4 of the Layer 3 sub-interface int200 from the Layer 3 forwarding table entry.

[0098] Subsequently, the flow classification module 72 of the network device is used to find a matching ACL entry for the outgoing interface inter200 service type of packet p20, and obtain the identifier QoS6 of the specified service scheduling policy from the found ACL entry.

[0099] The network device performs token bucket, traffic policing / traffic shaping, WRED and other processing on the packet p20, and then allocates the transmission queue through the queue module 73.

[0100] The queue module 73 identifies the identifier QoS6 of the specified service scheduling policy of message p20, which corresponds to the first-level transmission queue Q10 of the specified service. It also identifies the message priority information of message p20 and places it into queue 1 of Q10.

[0101] The queue module 73 performs re-queueing processing according to the service level mapping relationship, and puts the message P20 into queue 8 of the designated service secondary transmission queue Q11 mapped by queue 1 in the selected Q10.

[0102] The transmitting module of the switching chip in the network device ( Figure 7 (Not shown), message P1 is sent through physical member port m1 of the virtual aggregation port LAG, and messages P2 and P3 are sent through physical member port m2 of the virtual aggregation port LAG.

[0103] The transmitting module of the switching chip in the network device ( Figure 6 (Not shown), messages P10 and P20 are sent through the physical port m3 corresponding to the Layer 3 sub-interface int100 and Layer 3 sub-interface int200.

[0104] Figure 8 This is a schematic diagram of a device embodiment for implementing multi-level scheduling using the virtual interface provided in this application; the device 80 includes a processor 81, a memory 82, a switching chip 83, and a network interface 831; the switching chip 83 includes at least a forwarding module, a queue module, a flow classification module, and a sending module. The processor 81 uses processor-executable instructions in the memory 82 to configure the queue scheduling module.

[0105] The forwarding module searches for a Layer 3 forwarding entry matching the destination IP address of a packet in the Layer 3 forwarding table recorded in the entry storage module; it retrieves the virtual interface for sending the packet and the first-level sending queue scheduling policy identifier of the virtual interface from the Layer 3 forwarding entry; the queue module identifies a set of first-level sending queues corresponding to the first-level sending queue scheduling policy identifier; it places the packet into a first-level sending queue corresponding to the packet priority information in the identified set of first-level sending queues; and it places the packet into a second-level sending queue mapped by the selected first-level sending queue according to the sending queue hierarchy mapping relationship.

[0106] The flow classification module is used to obtain the specified service scheduling policy identifier based on the virtual interface of the sent packet and the service type of the packet; the queue module is also used to identify a set of specified service sending queues corresponding to the specified service scheduling policy identifier; and in the identified set of specified service sending queues, the packet is placed into a specified service sending queue corresponding to the packet priority information.

[0107] The flow classification module is used to obtain the specified service scheduling policy identifier based on the virtual interface of the sent packet and the service type of the packet; the queue module is also used to identify a set of specified service first-level sending queues corresponding to the specified service scheduling policy identifier; in the identified set of specified service first-level sending queues, the packet is placed into a specified service first-level sending queue corresponding to the packet priority information; according to the service type sending queue hierarchy mapping relationship, the packet is placed into the specified service second-level sending queue mapped by the selected specified service first-level sending queue.

[0108] The queue scheduling setting module is used to apply for a set of first-level sending queues for the virtual interface and configure the corresponding first-level sending queue scheduling policy; apply for a set of second-level sending queues for each physical port corresponding to the virtual interface; and set the sending queue hierarchy mapping relationship. The sending queue hierarchy mapping relationship records the second-level sending queues mapped to each first-level sending queue. The forwarding module is also used to record the first-level sending queue scheduling policy identifier in each layer 3 forwarding table entry of the virtual interface as the outgoing interface.

[0109] The queue scheduling setting module is also used to set the virtual interface and the specified service scheduling policy corresponding to a specified service type; to apply for at least one set of service type sending queues for the virtual interface and a specified service type; the flow classification module is also used to record the identifier of the specified service scheduling policy corresponding to the virtual interface and a specified service type.

[0110] The queue scheduling setting module is also used to set the virtual interface and the specified service scheduling policy corresponding to a specified service type; apply for a set of specified service first-level sending queues for the virtual interface and a specified service type; apply for a set of specified service second-level sending queues for each physical port corresponding to the virtual interface; set the service level mapping relationship; wherein, the service level mapping relationship records the specified service second-level sending queues mapped to each specified service first-level sending queue; the flow classification module is also used to record the identifier of the specified service scheduling policy corresponding to the virtual interface and a specified service type.

[0111] The virtual interface is a VLAN Layer 3 sub-interface; each physical port corresponding to the virtual interface is a physical port configured with a VLAN Layer 3 sub-interface; or, the virtual interface is a virtual aggregation port; each physical port corresponding to the virtual interface is a physical member port of the virtual aggregation port.

[0112] The sending module is used to send the messages that have been queued by the queue module through the physical port corresponding to the virtual interface.

[0113] The above are merely preferred embodiments of this application and are not intended to limit this application. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the scope of protection of this application.

Claims

1. A method for implementing multi-level scheduling for a virtual interface, the method comprising: The method comprises, applying a set of primary sending queues for a virtual interface and configuring a corresponding primary sending queue scheduling strategy; applying a set of secondary sending queues for each physical port corresponding to the virtual interface; setting a sending queue level mapping relationship; wherein the sending queue level mapping relationship records the secondary sending queues mapped by each primary sending queue; recording a primary sending queue scheduling strategy identifier in each three-layer forwarding table item in which the virtual interface serves as an out-interface; finding a three-layer forwarding table item matching a destination IP address of a message; obtaining the virtual interface sending the message and the primary sending queue scheduling strategy identifier of the virtual interface from the three-layer forwarding table item; identifying a set of primary sending queues corresponding to the primary sending queue scheduling strategy identifier; putting the message into a primary sending queue corresponding to message priority information in the identified set of primary sending queues; putting the message into a secondary sending queue mapped by the selected primary sending queue according to the sending queue level mapping relationship.

2. The method of claim 1, wherein, Before identifying the set of primary sending queues corresponding to the primary sending queue scheduling strategy identifier, the method further comprises, obtaining a specified service scheduling strategy identifier according to the virtual interface sending the message and the service type of the message; identifying a set of specified service sending queues corresponding to the specified service scheduling strategy identifier; putting the message into a specified service sending queue corresponding to message priority information in the identified set of specified service sending queues.

3. The method of claim 1, wherein, Before identifying the set of primary sending queues corresponding to the primary sending queue scheduling strategy identifier, the method further comprises, obtaining a specified service scheduling strategy identifier according to the virtual interface sending the message and the service type of the message; identifying a set of specified service primary sending queues corresponding to the specified service scheduling strategy identifier; putting the message into a specified service primary sending queue corresponding to message priority information in the identified set of specified service primary sending queues; putting the message into a specified service secondary sending queue mapped by the selected specified service primary sending queue according to the service type sending queue level mapping relationship.

4. The method of claim 1, wherein, Before finding the three-layer forwarding table item matching the destination IP address of the message, the method further comprises, setting a specified service scheduling strategy corresponding to the virtual interface and a specified service type; applying at least one set of service type sending queues for the virtual interface and the specified service type; recording a specified service scheduling strategy identifier corresponding to the virtual interface and the specified service type.

5. The method of claim 1, wherein, Before finding the three-layer forwarding table item matching the destination IP address of the message, the method further comprises, setting a specified service scheduling strategy corresponding to the virtual interface and a specified service type; applying a set of specified service primary sending queues for the virtual interface and the specified service type; applying the set of specified service secondary sending queues for each physical port corresponding to the virtual interface; setting a service level mapping relationship; wherein the service level mapping relationship records the specified service secondary sending queues mapped by each specified service primary sending queue; The virtual interface and the specified service scheduling policy identifier corresponding to the specified service type are recorded.

6. The method of claim 1, wherein, The virtual interface is a virtual local area network (VLAN) three-layer sub-interface; each physical port corresponding to the virtual interface is a physical port configured with the virtual local area network three-layer sub-interface; or, The virtual interface is a virtual aggregation port; each physical port corresponding to the virtual interface is a physical member port of the virtual aggregation port.

7. A device for implementing multi-level scheduling via virtual interfaces, characterized in that, The device at least comprises; a queue scheduling setting module, configured to apply a group of primary sending queues for a virtual interface and configure a primary sending queue scheduling policy corresponding thereto; apply a group of secondary sending queues for each physical port corresponding to the virtual interface; and set a sending queue level mapping relationship, wherein the sending queue level mapping relationship records each primary sending queue mapping secondary sending queue; a forwarding module, further configured to record the primary sending queue scheduling policy identifier in each three-layer forwarding table item in which the virtual interface serves as an out-interface; find a three-layer forwarding table item matched with a destination IP address of a packet; and obtain the virtual interface sending the packet and the primary sending queue scheduling policy identifier of the virtual interface from the three-layer forwarding table item; a queue module, configured to identify a group of primary sending queues corresponding to the primary sending queue scheduling policy identifier; put the packet into a primary sending queue corresponding to packet priority information in the identified group of primary sending queues; and put the packet into a secondary sending queue mapped by the selected primary sending queue according to the sending queue level mapping relationship.

8. The apparatus of claim 7, wherein, The device further comprises a flow classification module; The flow classification module is configured to obtain a specified service scheduling policy identifier according to a virtual interface sending the packet and a service type of the packet. The queue module is further configured to identify a group of specified service primary sending queues corresponding to the specified service scheduling policy identifier; and put the packet into a specified service primary sending queue corresponding to packet priority information in the identified group of specified service primary sending queues.

9. The apparatus of claim 7, wherein, The device further comprises a flow classification module; The flow classification module is configured to obtain a specified service scheduling policy identifier according to a virtual interface sending the packet and a service type of the packet. The queue module is further configured to identify a group of specified service primary sending queues corresponding to the specified service scheduling policy identifier; and put the packet into a specified service primary sending queue corresponding to packet priority information in the identified group of specified service primary sending queues.

10. The device according to claim 7, wherein The queue scheduling setting module is further configured to set a specified service scheduling policy corresponding to the virtual interface and a specified service type; and apply at least one group of service type sending queues for the virtual interface and the specified service type; The flow classification module is further configured to record the specified service scheduling policy identifier corresponding to the virtual interface and the specified service type.

11. The device according to claim 7, wherein The queue scheduling setting module is further configured to set the virtual interface and a specified service scheduling policy corresponding to a specified service type; apply a group of specified service first-level sending queues for the virtual interface and the specified service type; apply the group of specified service second-level sending queues for each physical port corresponding to the virtual interface; and set a service level mapping relationship, wherein the service level mapping relationship records the specified service second-level sending queues mapped by each specified service first-level sending queue. The flow classification module is further configured to record a specified service scheduling policy identifier corresponding to the virtual interface and the specified service type.

12. The device of claim 7, wherein, the virtual interface is a virtual local area network (VLAN) three-layer sub-interface; and each physical port corresponding to the virtual interface is a physical port configured with the VLAN three-layer sub-interface; or the virtual interface is a virtual aggregation port; and each physical port corresponding to the virtual interface is a physical member port of the virtual aggregation port.

Citation Information

Patent Citations

  • QOS on a virtual interface over multi-path transport

    US20160112305A1