CN104486244B - A kind of execution method and device of QoS policy - Google Patents
A kind of execution method and device of QoS policy Download PDFInfo
- Publication number
- CN104486244B CN104486244B CN201410725321.8A CN201410725321A CN104486244B CN 104486244 B CN104486244 B CN 104486244B CN 201410725321 A CN201410725321 A CN 201410725321A CN 104486244 B CN104486244 B CN 104486244B
- Authority
- CN
- China
- Prior art keywords
- flow label
- sent
- ipv6 data
- qos policy
- user
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Landscapes
- Data Exchanges In Wide-Area Networks (AREA)
Abstract
Description
技术领域technical field
本发明涉及通信技术领域,尤其涉及一种QoS(Quality of Service,服务质量)策略的执行方法及装置。The present invention relates to the field of communication technology, in particular to a method and device for executing a QoS (Quality of Service, quality of service) policy.
背景技术Background technique
QoS是用来解决网络延迟和阻塞等问题的一种技术。当网络发生拥塞的时候,数据报文会发生丢弃现象。为满足用户对不同应用、不同服务质量的要求,就需要根据用户的要求分配和调度资源,给不同的数据报文提供不同的服务质量,其中,用户不同应用传输的数据报文不同。对实时性强且重要的数据报文优先处理;对于实时性不强的普通数据报文,提供较低的处理优先级,甚至在网络严重拥塞的时候进行丢弃。因此,不同的服务质量是通过网络设备执行不同的QoS策略体现的。QoS is a technology used to solve problems such as network delay and congestion. When network congestion occurs, data packets will be discarded. In order to meet the user's requirements for different applications and different service qualities, it is necessary to allocate and schedule resources according to the user's requirements, and provide different service qualities for different data packets. Among them, the data packets transmitted by different applications of the user are different. Prioritize the processing of important and real-time data packets; provide lower processing priority for ordinary data packets that are not real-time, and even discard them when the network is seriously congested. Therefore, different service qualities are reflected by implementing different QoS policies on network devices.
在现有技术中,网络设备在执行IPv6(Internet Protocol Version 6,网络协议第六版)数据报文的QoS策略时,会先对该IPv6数据报文进行流分类。而进行流分类时,必须读取IPv6数据报文中的源地址、目的地址、源端口号、目的端口号、传输层协议类型,这五类字段可以称为五元组。但是由于源端口号、目的端口号、传输层协议类型这三个字段位于IPv6包头的可扩展字段后,而可扩展字段的扩展长度不固定,会使上述三个字段在IPv6包头中的位置发生改变,因此,导致网络设备在获取上述三个字段的相关内容时效率较低,影响流分类的效率,从而影响了网络设备执行相应QoS策略的效率。In the prior art, when a network device implements a QoS policy for an IPv6 (Internet Protocol Version 6, Internet Protocol Version 6) data packet, it first performs flow classification on the IPv6 data packet. When performing traffic classification, it is necessary to read the source address, destination address, source port number, destination port number, and transport layer protocol type in the IPv6 datagram. These five types of fields can be called quintuples. However, since the three fields of source port number, destination port number, and transport layer protocol type are located after the extensible field of the IPv6 packet header, and the extended length of the extensible field is not fixed, the position of the above three fields in the IPv6 packet header will be changed. Therefore, the efficiency of the network device in obtaining the relevant content of the above three fields is low, which affects the efficiency of flow classification, thereby affecting the efficiency of the network device in executing the corresponding QoS policy.
发明内容Contents of the invention
本发明的实施例提供一种QoS策略的执行方法及装置,能够提高流分类的效率,进而提高网络设备执行QoS策略的效率。Embodiments of the present invention provide a method and device for executing a QoS policy, which can improve the efficiency of flow classification, and further improve the efficiency of network equipment executing the QoS policy.
为达到上述目的,本发明的实施例采用如下技术方案:In order to achieve the above object, embodiments of the present invention adopt the following technical solutions:
一种QoS策略的执行方法,包括:A method for executing a QoS policy, comprising:
获取待发送IPv6数据报文中的流标签,所述流标签用于表示用户设备的用户级别和/或所述IPv6数据报文所属的应用业务类型;Obtain a flow label in the IPv6 data message to be sent, where the flow label is used to indicate the user level of the user equipment and/or the application service type to which the IPv6 data message belongs;
根据所述流标签执行所述待发送IPv6数据报文对应的QoS策略,所述QoS策略包括所述待发送IPv6数据报文与所述待发送IPv6数据报文的转发顺序的映射关系。Execute the QoS policy corresponding to the IPv6 data message to be sent according to the flow label, and the QoS policy includes a mapping relationship between the IPv6 data message to be sent and the forwarding sequence of the IPv6 data message to be sent.
一种QoS策略的执行装置,包括:A device for executing a QoS policy, comprising:
获取单元,用于获取待发送IPv6数据报文中的流标签,所述流标签用于表示用户设备的用户级别和/或所述IPv6数据报文所属的应用业务类型;An acquisition unit, configured to acquire a flow label in the IPv6 data message to be sent, where the flow label is used to indicate the user level of the user equipment and/or the application service type to which the IPv6 data message belongs;
策略执行单元,用于根据所述获取单元获取的所述流标签执行所述待发送IPv6数据报文对应的QoS策略,所述QoS策略包括所述待发送IPv6数据报文与所述待发送IPv6数据报文的转发顺序的映射关系。A policy execution unit, configured to execute the QoS policy corresponding to the IPv6 data message to be sent according to the flow label obtained by the acquisition unit, the QoS policy includes the IPv6 data message to be sent and the IPv6 data message to be sent The mapping relationship of the forwarding sequence of data packets.
本发明实施例提供的一种QoS策略的执行方法及装置,路由器通过获取待发送IPv6数据报文中的流标签,并根据获取到的流标签执行待发送IPv6数据报文对应的QoS策略。相比于现有技术中,在执行QoS策略时必须先获取IPv6数据报文中的五元组对IPv6数据报文进行流分类,而网络设备在获取五元组中的源端口号、目的端口号、传输层协议类型这三个字段的获取效率低,流分类效率低,因此产生了网络设备执行QoS策略效率低的问题。本发明实施例提供了一种网络设备只需获取待发送IPv6数据报文中的流标签,即可执行相应QoS策略的方法,能提高路由器执行QoS策略的效率。In the implementation method and device of a QoS policy provided by the embodiments of the present invention, the router obtains the flow label in the IPv6 data message to be sent, and executes the QoS policy corresponding to the IPv6 data message to be sent according to the obtained flow label. Compared with the prior art, when implementing the QoS policy, the five-tuple in the IPv6 data message must first be obtained to classify the IPv6 data message, and the network device obtains the source port number and destination port number in the five-tuple. The acquisition efficiency of the three fields of number and transport layer protocol type is low, and the flow classification efficiency is low. Therefore, the problem of low efficiency in implementing QoS policies by network devices arises. The embodiment of the present invention provides a method for a network device to execute a corresponding QoS strategy only by obtaining the flow label in the IPv6 data message to be sent, which can improve the efficiency of the router in executing the QoS strategy.
附图说明Description of drawings
为了更清楚地说明本发明实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the following will briefly introduce the drawings that need to be used in the description of the embodiments or the prior art. Obviously, the accompanying drawings in the following description are only These are some embodiments of the present invention. Those skilled in the art can also obtain other drawings based on these drawings without creative work.
图1为本发明实施例提供的一种QoS策略的执行方法流程图;FIG. 1 is a flowchart of a method for executing a QoS policy provided by an embodiment of the present invention;
图2为本发明实施例提供的另一种QoS策略的执行方法流程图;FIG. 2 is a flow chart of another QoS policy execution method provided by an embodiment of the present invention;
图3为本发明实施例提供的另一种QoS策略的执行方法流程图;FIG. 3 is a flow chart of another QoS policy execution method provided by an embodiment of the present invention;
图4为本发明实施例提供的另一种QoS策略的执行方法流程图;FIG. 4 is a flow chart of another QoS policy execution method provided by an embodiment of the present invention;
图5为本发明实施例提供的另一种QoS策略的执行方法流程图;FIG. 5 is a flow chart of another QoS policy execution method provided by an embodiment of the present invention;
图6为本发明实施例提供的一种QoS策略的执行装置组成示意图。FIG. 6 is a schematic diagram of the composition of a device for executing a QoS policy provided by an embodiment of the present invention.
具体实施方式Detailed ways
下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。The following will clearly and completely describe the technical solutions in the embodiments of the present invention with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only some, not all, embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by persons of ordinary skill in the art without creative efforts fall within the protection scope of the present invention.
本发明实施例提供了一种QoS策略的执行方法,可提高路由器执行QoS策略的效率,如图1所示,包括:The embodiment of the present invention provides a method for executing a QoS policy, which can improve the efficiency of implementing a QoS policy by a router, as shown in FIG. 1 , including:
101、路由器获取待发送IPv6数据报文中的流标签。101. The router obtains the flow label in the IPv6 data packet to be sent.
其中,本地网关将待发送IPv6数据报文发送至路由器。路由器读取待发送IPv6数据报文的流标签,其中,流标签用于表示用户设备的用户级别和/或IPv6数据报文所属的应用业务类型。IPv6数据报文所属的应用业务类型由用户设备填写进流标签中。用户设备的用户级别由流标签参数表示,由本地网关将流标签参数填写进用户流标签中。在图5中,对路由器及用户设备及本地网关之间的关系进行详细描述,在此不做赘述。Wherein, the local gateway sends the IPv6 data packet to be sent to the router. The router reads the flow label of the IPv6 data message to be sent, wherein the flow label is used to indicate the user level of the user equipment and/or the application service type to which the IPv6 data message belongs. The application service type to which the IPv6 data packet belongs is filled in the flow label by the user equipment. The user level of the user equipment is indicated by the flow label parameter, and the local gateway fills the flow label parameter into the user flow label. In FIG. 5 , the relationship between the router, the user equipment and the local gateway is described in detail, and details are not repeated here.
102、路由器根据流标签执行待发送IPv6数据报文对应的QoS策略。102. The router executes the QoS policy corresponding to the IPv6 data packet to be sent according to the flow label.
其中,QoS策略包括待发送IPv6数据报文与待发送IPv6数据报文的转发顺序的映射关系。该映射关系在步骤202和步骤302中做了详细描述,在此不做赘述。Wherein, the QoS policy includes a mapping relationship between the IPv6 data packets to be sent and the forwarding sequence of the IPv6 data packets to be sent. The mapping relationship is described in detail in step 202 and step 302, and will not be repeated here.
还需说明的是,在路由器执行待发送IPv6数据报文对应的QoS策略之前,需要判断待发送IPv6数据报文的情况,当待发送IPv6数据报文为不同用户设备的单一报文时,执行步骤201至步骤202;当待发送IPv6数据报文为同一用户设备的不同报文时,执行步骤301至步骤302;当待发送IPv6数据报文为不同用户设备的不同报文时,执行步骤401至步骤402。It should also be noted that before the router executes the QoS policy corresponding to the IPv6 data message to be sent, it needs to judge the situation of the IPv6 data message to be sent. When the IPv6 data message to be sent is a single message of different user equipment, execute Step 201 to step 202; when the IPv6 data message to be sent is a different message of the same user equipment, perform step 301 to step 302; when the IPv6 data message to be sent is a different message of different user equipment, perform step 401 Go to step 402.
本发明实施例提供的一种QoS策略的执行方法,通过获取待发送IPv6数据报文中的流标签,并根据获取到的流标签执行待发送IPv6数据报文对应的QoS策略。相比于现有技术中,在执行QoS策略时必须先获取IPv6数据报文中的五元组对IPv6数据报文进行流分类,而网络设备在获取五元组中的源端口号、目的端口号、传输层协议类型这三个字段的获取效率低,流分类效率低,因此产生了网络设备执行QoS策略效率低的问题。本发明实施例提供了一种网络设备只需获取待发送IPv6数据报文中的流标签,即可执行相应QoS策略的方法,能提高路由器执行QoS策略的效率。A method for executing a QoS policy provided by an embodiment of the present invention obtains the flow label in the IPv6 data message to be sent, and executes the QoS policy corresponding to the IPv6 data message to be sent according to the obtained flow label. Compared with the prior art, when implementing the QoS policy, the five-tuple in the IPv6 data message must first be obtained to classify the IPv6 data message, and the network device obtains the source port number and destination port number in the five-tuple. The acquisition efficiency of the three fields of number and transport layer protocol type is low, and the flow classification efficiency is low. Therefore, the problem of low efficiency in implementing QoS policies by network devices arises. The embodiment of the present invention provides a method for a network device to execute a corresponding QoS strategy only by obtaining the flow label in the IPv6 data message to be sent, which can improve the efficiency of the router in executing the QoS strategy.
本发明实施例还提供了一种QoS策略的执行方法,本实施例适用于待发送IPv6数据报文为不同用户设备的单一报文的情况,此时流标签用于表示用户设备的用户级别,为流标签参数,如图2所示,该方法执行在步骤101之后,包括:The embodiment of the present invention also provides a method for executing a QoS policy. This embodiment is applicable to the situation where the IPv6 data message to be sent is a single message of different user equipments. At this time, the flow label is used to represent the user level of the user equipment. is the flow label parameter, as shown in Figure 2, the method is executed after step 101, including:
201、路由器获取流标签中的流标签参数。201. The router acquires a flow label parameter in the flow label.
其中,流标签参数表示用户设备的用户级别。本发明实施例提供了一种表示流标签参数的方法,如“0xFF1”,但是表示流标签参数的字段长度和具体字段内容,本发明对此不做限定。用户级别可以用阿拉伯数字表示,比如,用户级别为“1”的用户,其优先级高于用户级别为“2”的用户,用户级别为“2”的用户,其优先级高于用户级别为“3”的用户,以此类推,可根据运营商实际部署情况,制定最低用户级别。本发明实施例对最低用户级别不做限定。Wherein, the flow label parameter indicates the user level of the user equipment. The embodiment of the present invention provides a method for indicating a flow label parameter, such as "0xFF1", but the field length and specific field content of the flow label parameter are indicated, which is not limited in the present invention. User levels can be represented by Arabic numerals. For example, a user with a user level of "1" has a higher priority than a user with a user level of "2", and a user with a user level of "2" has a higher priority than a user with a user level of "3" users, and so on, can set the minimum user level according to the actual deployment situation of the operator. The embodiment of the present invention does not limit the minimum user level.
202、路由器根据流标签参数和第一预设规则执行待发送IPv6数据报文对应的QoS策略。202. The router executes the QoS policy corresponding to the IPv6 data packet to be sent according to the flow label parameter and the first preset rule.
其中,第一预设规则表示流标签参数和QoS策略的映射关系。流标签参数和QoS策略的映射关系如表1所示。表1中包括用户级别和流标签参数两类表项,表1中第一行从左至右分别是用户级别和流标签参数。通过表1,可找到与用户级别一一对应的流标签参数。如表1中第二行所示,用户级别为“1”,代表该用户为“VIP(very important people,贵宾)”用户,对应流标签参数为“0xFF1”;第三行用户级别为“2”,代表该用户为“白金”用户,对应流标签参数为“0xFF2”;第四行用户级别为“3”,对应流标签参数为“0xFF3”,代表该用户为“黄金”用户;第五行用户级别为“4”,代表该用户为“银”用户,对应流标签参数为“0xFF4”;第六行用户级别为“5”,代表该用户为“铜”用户,对应流标签参数为“0xFF5”。表1中由上至下用户级别依次降低。Wherein, the first preset rule represents the mapping relationship between flow label parameters and QoS policies. The mapping relationship between flow label parameters and QoS policies is shown in Table 1. Table 1 includes two types of entries of user level and flow label parameters, and the first row in Table 1 is respectively user level and flow label parameters from left to right. Through Table 1, the flow label parameters corresponding to the user level can be found one-to-one. As shown in the second line of Table 1, the user level is "1", which means that the user is a "VIP (very important people, VIP)" user, and the corresponding flow label parameter is "0xFF1"; the third line of user level is "2 ", which means that the user is a "platinum" user, and the corresponding flow label parameter is "0xFF2"; the user level in the fourth line is "3", and the corresponding flow label parameter is "0xFF3", which means that the user is a "gold" user; the fifth line The user level is "4", which means that the user is a "silver" user, and the corresponding flow label parameter is "0xFF4"; the user level in the sixth line is "5", which means that the user is a "copper" user, and the corresponding flow label parameter is " 0xFF5". In Table 1, the user levels decrease in order from top to bottom.
需要说明的是,表1中的用户级别与网络设备需要执行的QoS策略对应,不同的用户级别执行不同的QoS策略。例如:在路由器读取到两个用户的待传输数据包中的流标签参数分别为0xFF1和0xFF5,由于在表1中0xFF1对应的用户级别为1级,0xFF5对应的用户级别为5级,因此,在网络负载较高,拥塞严重时,如果路由器同时接收到了流标签参数为0xFF1的IPv6数据报文和流标签参数为0xFF5的IPv6数据报文,路由器会优先对用户级别高的IPv6数据报文进行处理。It should be noted that the user levels in Table 1 correspond to the QoS policies that need to be implemented by network devices, and different user levels implement different QoS policies. For example: the flow label parameters in the data packets to be transmitted of two users read by the router are 0xFF1 and 0xFF5 respectively, since the user level corresponding to 0xFF1 in Table 1 is level 1, and the user level corresponding to 0xFF5 is level 5, so , when the network load is high and the congestion is severe, if the router receives both the IPv6 data packet with the flow label parameter 0xFF1 and the IPv6 data packet with the flow label parameter 0xFF5, the router will give priority to the IPv6 data packet with high user level. to process.
表1Table 1
还需说明的是,本发明并不限定只用如表1所示的五个用户级别等级。可以有更多以及更细致的级别定义,同时流标签参数也可以根据运营商的需求改变长度,如果需要更精细的级别定义,可以适当增加流标签参数的长度。It should also be noted that the present invention is not limited to the five user levels shown in Table 1. There can be more and more detailed level definitions. At the same time, the length of the flow label parameter can also be changed according to the needs of the operator. If a finer level definition is required, the length of the flow label parameter can be appropriately increased.
本发明实施例还提供了一种QoS策略的执行方法,本实施例适用于当待发送IPv6数据报文为单一用户设备的不同报文的情况,此时流标签用于表示IPv6数据报文所属的应用业务类型,为应用业务类型,如图3所示,该方法执行在步骤101之后,包括:The embodiment of the present invention also provides a method for executing a QoS policy. This embodiment is applicable when the IPv6 data message to be sent is a different message of a single user equipment. At this time, the flow label is used to indicate that the IPv6 data message belongs to The application business type is the application business type, as shown in Figure 3, the method is executed after step 101, including:
301、路由器获取流标签中的应用业务类型。301. The router obtains the application service type in the flow label.
其中,每个待发送数据包都有其固定的应用业务类型。应用业务类型至少包括:视频流业务,下载业务,游戏类业务等。本发明实施例不限定只有上述三种应用业务类型,除上述三种应用业务类型以外的其他应用业务类型,均可应用到本发明实施例中。比如一个游戏应用,用户设备标记该应用发送的待发送数据包的应用业务类型为游戏类。同样的,如果是视频类应用或者是其他类型应用,则根据应用类型对待发送数据包进行标记。应用业务类型是由用户设备根据应用类型生成的,如果应用程序或用户设备不支持,则置为0。其中,0的优先级为最低。Wherein, each data packet to be sent has its fixed application service type. Application service types include at least: video streaming service, download service, game service, etc. The embodiment of the present invention does not limit only the above three types of application services, and other application service types except the above three types of application services can be applied to the embodiments of the present invention. For example, for a game application, the user equipment marks the application service type of the data packet to be sent sent by the application as a game type. Similarly, if it is a video application or other type of application, the data packet to be sent is marked according to the application type. The application service type is generated by the user equipment according to the application type. If the application program or the user equipment does not support it, it will be set to 0. Among them, 0 has the lowest priority.
302、路由器根据应用业务类型和第二预设规则执行待发送IPv6数据报文对应的QoS策略。302. The router executes the QoS policy corresponding to the IPv6 data packet to be sent according to the application service type and the second preset rule.
其中,第二预设规则表示应用业务类型和QoS策略的映射关系。Wherein, the second preset rule represents the mapping relationship between the application service type and the QoS policy.
比如:视频流业务和游戏类业务的优先级高于下载业务。这样,对单一用户来说,当网络发生拥塞的时候,会优先选择标记为视频流业务类型或游戏类业务类型的待发送IPv6数据报文优先进行发送。For example: the priority of video streaming service and game service is higher than that of download service. In this way, for a single user, when the network is congested, the IPv6 data packets marked as the video stream service type or the game service type will be preferentially sent.
本发明实施例还提供了一种QoS策略的执行方法,本实施例适用于当待发送IPv6数据报文为不同用户设备的不同报文的情况,此时流标签用于表示用户设备的用户级别和IPv6数据报文所属的应用业务类型,流标签为流标签参数和应用业务类型,如图4所示,该方法执行在步骤101之后,包括:The embodiment of the present invention also provides a method for executing a QoS policy. This embodiment is applicable when the IPv6 data packets to be sent are different packets of different user equipments. At this time, the flow label is used to indicate the user level of the user equipment. and the application service type to which the IPv6 data message belongs, the flow label is a flow label parameter and an application service type, as shown in Figure 4, the method is performed after step 101, including:
401、路由器获取流标签中的流标签参数,并根据流标签参数和第一预设规则,确定包含于同一用户设备的所有报文的发送顺序。401. The router acquires a flow label parameter in a flow label, and determines a sending sequence of all packets included in the same user equipment according to the flow label parameter and a first preset rule.
例如:路由器同时获取到了用户设备1和用户设备2发送的所有不同类型的待传输IPv6数据报文。路由器读取用户设备1发送的所有不同类型的待传输IPv6数据报文中的流标签参数为“0xFF1”,读取用户设备2发送的所有不同类型的待传输IPv6数据报文中的流标签参数为“0xFF2”。因为在第一预设规则中,“0xFF1”对应的用户级别为1级,“0xFF2”对应的用户级别为2级,所以在网络发生阻塞的时候,路由器会先发送流标签参数为“0xFF1”的所有不同类型的待传输IPv6数据报文,也就说,路由器会先处理用户设备1发送的所有不同类型的待传输IPv6数据报文。而后发送属于用户设备2的所有不同类型的待传输IPv6数据报文。For example: the router obtains all different types of IPv6 data packets to be transmitted sent by the user equipment 1 and the user equipment 2 at the same time. The router reads the flow label parameters in all different types of IPv6 data packets to be transmitted sent by user equipment 1 as "0xFF1", and reads the flow label parameters in all different types of IPv6 data packets to be transmitted sent by user equipment 2 is "0xFF2". Because in the first preset rule, the user level corresponding to "0xFF1" is level 1, and the user level corresponding to "0xFF2" is level 2, so when the network is blocked, the router will first send the flow label parameter as "0xFF1" All different types of IPv6 data packets to be transmitted, that is to say, the router will first process all different types of IPv6 data packets to be transmitted sent by the user equipment 1 . Then all different types of IPv6 data packets to be transmitted belonging to the user equipment 2 are sent.
402、路由器获取流标签中的应用业务类型,根据应用业务类型和第二预设规则,确定包含于同一用户设备的每个报文对应的QoS策略。402. The router obtains the application service type in the flow label, and determines a QoS policy corresponding to each packet included in the same user equipment according to the application service type and a second preset rule.
例如:在视频业务类型的优先级高于下载业务类型的优先级时,路由器获取同一用户设备发送的待传输IPv6数据报文1和待传输IPv6数据报文2。路由器读取待传输IPv6数据报文1的流标签,获取到IPv6数据报文1的应用业务类型为视频业务,而读取待传输数报文2的流标签,获取到IPv6数据报文2的应用业务类型为下载业务。由于视频业务类型的优先级高于下载业务类型的优先级,因此,在路由器获取到待传输IPv6数据报文1和待传输IPv6数据报文2时,根据待传输IPv6数据报文1和待传输IPv6数据报文2的应用业务类型,先发送待传输IPv6数据报文1,并执行与待传输IPv6数据报文1应用业务类型对应的QoS策略,再发送待传输IPv6数据报文2,并执行与待传输IPv6数据报文2应用业务类型对应的QoS策略。For example: when the priority of the video service type is higher than that of the download service type, the router acquires the IPv6 data packet 1 to be transmitted and the IPv6 data packet 2 to be transmitted sent by the same user equipment. The router reads the flow label of the IPv6 data packet 1 to be transmitted, obtains that the application service type of the IPv6 data packet 1 is a video service, reads the flow label of the data packet 2 to be transmitted, and obtains the IPv6 data packet 2 The application service type is download service. Since the priority of the video service type is higher than that of the download service type, when the router obtains the IPv6 data packet 1 to be transmitted and the IPv6 data packet 2 to be transmitted, according to the IPv6 data packet 1 to be transmitted and the IPv6 data packet to be transmitted For the application service type of IPv6 data message 2, first send the IPv6 data message 1 to be transmitted, and execute the QoS policy corresponding to the application service type of the IPv6 data message 1 to be transmitted, then send the IPv6 data message 2 to be transmitted, and execute A QoS policy corresponding to the application service type of the IPv6 data packet 2 to be transmitted.
其中,第一预设规则表示流标签参数和发送顺序的映射关系,第二预设规则表示应用业务类型和QoS策略的映射关系。Wherein, the first preset rule represents the mapping relationship between the flow label parameter and the sending sequence, and the second preset rule represents the mapping relationship between the application service type and the QoS policy.
需要说明的是,对于不同的用户设备,路由器根据不同用户设备的用户级别进行处理,用户级别高的用户设备发送的待发送报文优先进行处理。另外,对于同一用户设备发送的不同类型的待发送IPv6数据报文,路由器根据待发送IPv6数据报文的应用业务类型进行处理,应用业务类型优先级高的待传输数据包优先处理。It should be noted that, for different user equipments, the router performs processing according to user levels of different user equipments, and the packets to be sent sent by user equipments with higher user levels are prioritized for processing. In addition, for different types of IPv6 data packets to be sent sent by the same user equipment, the router processes according to the application service type of the IPv6 data message to be sent, and the data packets to be transmitted with higher priority of the application service type are processed first.
为方便本发明的理解,在本发明的另一实施例中,提供了另一种QoS策略的执行方法流程图,如图5所示。该图5所示的方法流程,应用在下述实施场景中,该场景包括:一个用户设备,一个本地网关,一个DHCPv6(Dynamic Host configuration Protocol version 6,动态主机配置协议第六版)服务器,一个路由器,一个缓存服务器,并且,在上述场景中,用户设备可以与DHCPv6服务器、本地网关、缓存服务器互相通信;本地网关可以与DHCPv6服务器、路由器互相通信;路由器可以与缓存服务器进行通信。综上所述,本发明的整体方法流程为:To facilitate the understanding of the present invention, in another embodiment of the present invention, a flow chart of another QoS policy execution method is provided, as shown in FIG. 5 . The method flow shown in Figure 5 is applied in the following implementation scenarios, which include: a user equipment, a local gateway, a DHCPv6 (Dynamic Host configuration Protocol version 6, Dynamic Host Configuration Protocol version 6) server, a router , a cache server, and, in the above scenario, the user equipment can communicate with the DHCPv6 server, the local gateway, and the cache server; the local gateway can communicate with the DHCPv6 server and the router; and the router can communicate with the cache server. In summary, the overall method process of the present invention is:
0)、在DHCPv6服务器中存储流标签参数、流标签参数和用户级别的映射关系、用户ID(Identity,身份标识号码)和用户级别的对应关系。同时,在路由器上存储第一预设规则,以及第二预设规则。这样,当待发送IPv6数据报文经过路由器时,路由器获取待发送IPv6数据报文中的流标签参数,并根据与流标签参数对应的QoS策略对待发送IPv6数据报文进行转发。0), storing the flow label parameter, the mapping relationship between the flow label parameter and the user level, and the corresponding relationship between the user ID (Identity, identification number) and the user level in the DHCPv6 server. At the same time, the first preset rule and the second preset rule are stored on the router. In this way, when the IPv6 data message to be sent passes through the router, the router obtains the flow label parameter in the IPv6 data message to be sent, and forwards the IPv6 data message to be sent according to the QoS policy corresponding to the flow label parameter.
1)、用户设备向DHCPv6服务器发起上线请求,该请求中包含用户ID。1) The user equipment initiates an online request to the DHCPv6 server, and the request includes the user ID.
2)、DHCPv6服务器根据接收到的用户上线请求中的用户ID,确定用户级别,并根据用户级别将流标签参数下发至本地网关。2) The DHCPv6 server determines the user level according to the user ID in the received user online request, and sends the flow label parameters to the local gateway according to the user level.
值得说明的是,与流标签参数一同下发到本地网关的还有DHCPv6为该用户设备分配的IPv6地址和DNS(Domain Name System,域名系统)服务器地址。It is worth noting that the IPv6 address and DNS (Domain Name System, Domain Name System) server address assigned to the user equipment by DHCPv6 are sent to the local gateway together with the flow label parameters.
3)、本地网关保存DHCPv6服务器下发的流标签参数、用户本地标识符、IPv6地址和DNS服务器地址。3) The local gateway saves the flow label parameters, user local identifier, IPv6 address and DNS server address issued by the DHCPv6 server.
其中,用户本地标识符是用户的MAC(Media Access Control,介质访问控制)地址,其本身对执行QoS策略没有影响,但是考虑到后续部署还有跟用户管理相关的需求,所以标识每一个用户是为管理功能做准备。用户本地标识符与上述用户ID不同,用户ID只用于在向DHCPv6服务器发送上线请求时,表明用户身份。Among them, the user's local identifier is the user's MAC (Media Access Control, Media Access Control) address, which itself has no effect on the implementation of the QoS policy, but considering the subsequent deployment and user management-related requirements, so identifying each user is Prepare for administrative functions. The user local identifier is different from the above user ID, and the user ID is only used to indicate the user identity when sending an online request to the DHCPv6 server.
4)、本地网关对用户设备进行上线配置,具体为给用户设备配置IPv6地址和DNS服务器地址。4) The local gateway configures the user equipment online, specifically configuring the user equipment with an IPv6 address and a DNS server address.
5)、用户设备在发送待发送IPv6数据报文时,先在本地将待发送IPv6数据报文所属的应用业务类型填写进待发送IPv6数据报文的流标签中,再将待发送IPv6数据报文发送至本地网关。5), when the user equipment sends the IPv6 data message to be sent, it first fills in the flow label of the IPv6 data message to be sent with the application service type to which the IPv6 data message to be sent belongs locally, and then sends the IPv6 data message to be sent The text is sent to the local gateway.
6)、本地网关将DHCPv6服务器下发的流标签参数和用户本地标识填写进待发送IPv6数据报文的流标签字段中,并将待发送IPv6数据报文发送至路由器。6), the local gateway fills in the flow label parameter and the user local identifier issued by the DHCPv6 server into the flow label field of the IPv6 data message to be sent, and sends the IPv6 data message to be sent to the router.
7)、路由器接收到本地网关发送的待发送IPv6数据报文,读取待发送IPv6数据报文中的流标签,根据流标签执行相应的第一预设规则和第二预设规则,并根据第一预设规则和第二预设规则将待发送IPv6数据报文发送至缓存服务器。7), the router receives the IPv6 data message to be sent sent by the local gateway, reads the flow label in the IPv6 data message to be sent, executes the corresponding first preset rule and the second preset rule according to the flow label, and according to The first preset rule and the second preset rule send the IPv6 data packet to be sent to the cache server.
8)、缓存服务器与用户设备进行数据交互。8). The cache server exchanges data with the user equipment.
本发明实施例提供的一种QoS策略的执行方法,通过获取待发送IPv6数据报文中的流标签,并根据获取到的流标签执行待发送IPv6数据报文对应的QoS策略。相比于现有技术中,在执行QoS策略时必须先获取IPv6数据报文中的五元组对IPv6数据报文进行流分类,而网络设备在获取五元组中的源端口号、目的端口号、传输层协议类型这三个字段的获取效率低,流分类效率低,因此产生了网络设备执行QoS策略效率低的问题。本发明实施例提供了一种网络设备只需获取待发送IPv6数据报文中的流标签,即可执行相应QoS策略的方法,能提高路由器执行QoS策略的效率。A method for executing a QoS policy provided by an embodiment of the present invention obtains the flow label in the IPv6 data message to be sent, and executes the QoS policy corresponding to the IPv6 data message to be sent according to the obtained flow label. Compared with the prior art, when implementing the QoS policy, the five-tuple in the IPv6 data message must first be obtained to classify the IPv6 data message, and the network device obtains the source port number and destination port number in the five-tuple. The acquisition efficiency of the three fields of number and transport layer protocol type is low, and the flow classification efficiency is low. Therefore, the problem of low efficiency in implementing QoS policies by network devices arises. The embodiment of the present invention provides a method for a network device to execute a corresponding QoS strategy only by obtaining the flow label in the IPv6 data message to be sent, which can improve the efficiency of the router in executing the QoS strategy.
一种QoS策略的执行装置,如图6所示,包括:获取单元61、策略执行单元62。A QoS policy execution device, as shown in FIG. 6 , includes: an acquisition unit 61 and a policy execution unit 62 .
获取单元61,用于获取待发送IPv6数据报文中的流标签。The acquiring unit 61 is configured to acquire the flow label in the IPv6 data packet to be sent.
其中,流标签用于表示用户设备的用户级别和/或IPv6数据报文所属的应用业务类型。Wherein, the flow label is used to indicate the user level of the user equipment and/or the application service type to which the IPv6 data packet belongs.
策略执行单元62,用于根据获取单元61获取的流标签执行待发送IPv6数据报文对应的QoS策略。The policy execution unit 62 is configured to execute the QoS policy corresponding to the IPv6 data packet to be sent according to the flow label obtained by the obtaining unit 61.
其中,QoS策略包括待发送IPv6数据报文与待发送IPv6数据报文的转发顺序的映射关系。Wherein, the QoS policy includes a mapping relationship between the IPv6 data packets to be sent and the forwarding sequence of the IPv6 data packets to be sent.
如图6所示,在本发明的另一实施例中,As shown in Figure 6, in another embodiment of the present invention,
获取单元61,具体用于获取流标签中的流标签参数。The obtaining unit 61 is specifically configured to obtain flow label parameters in the flow label.
其中,流标签参数表示用户设备的优先级。Wherein, the flow label parameter indicates the priority of the user equipment.
策略执行单元62,具体用于根据获取单元61获取的流标签参数和第一预设规则执行待发送IPv6数据报文对应的QoS策略。The policy execution unit 62 is specifically configured to execute the QoS policy corresponding to the IPv6 data packet to be sent according to the flow label parameters obtained by the obtaining unit 61 and the first preset rule.
其中,第一预设规则表示流标签参数和QoS策略的映射关系。Wherein, the first preset rule represents the mapping relationship between flow label parameters and QoS policies.
如图6所示,在本发明的另一实施例中,As shown in Figure 6, in another embodiment of the present invention,
获取单元61,具体还用于获取流标签中的应用业务类型。The obtaining unit 61 is also specifically configured to obtain the application service type in the flow label.
策略执行单元62,具体还用于根据获取单元61获取的应用业务类型和第二预设规则执行待发送IPv6数据报文对应的QoS策略。The policy execution unit 62 is specifically further configured to execute the QoS policy corresponding to the IPv6 data packet to be sent according to the application service type obtained by the obtaining unit 61 and the second preset rule.
其中,第二预设规则表示应用业务类型和QoS策略的映射关系。Wherein, the second preset rule represents the mapping relationship between the application service type and the QoS policy.
如图6所示,在本发明的另一实施例中,As shown in Figure 6, in another embodiment of the present invention,
获取单元61,具体还用于获取流标签中的流标签参数,并根据流标签参数和第一预设规则,确定包含于同一用户设备的所有报文的发送顺序。The acquiring unit 61 is further configured to acquire the flow label parameter in the flow label, and determine the sending order of all packets included in the same user equipment according to the flow label parameter and the first preset rule.
获取单元61,具体还用于获取流标签中的应用业务类型,根据应用业务类型和第二预设规则,确定包含于同一用户设备的每个报文对应的QoS策略。The obtaining unit 61 is further configured to obtain the application service type in the flow label, and determine the QoS policy corresponding to each message included in the same user equipment according to the application service type and the second preset rule.
其中,第一预设规则表示流标签参数和发送顺序的映射关系,第二预设规则表示应用业务类型和QoS策略的映射关系。Wherein, the first preset rule represents the mapping relationship between the flow label parameter and the sending order, and the second preset rule represents the mapping relationship between the application service type and the QoS policy.
值得说明的是,本实施例中如图6所示的装置用于实现上述图1至图5所描述的方法流程。It is worth noting that the device shown in FIG. 6 in this embodiment is used to implement the method flow described above in FIG. 1 to FIG. 5 .
本发明实施例提供的一种QoS策略的执行装置,获取单元通过获取待发送IPv6数据报文中的流标签,策略执行单元根据获取单元获取到的流标签执行待发送IPv6数据报文对应的QoS策略。相比于现有技术中,在执行QoS策略时必须先获取IPv6数据报文中的五元组对IPv6数据报文进行流分类,而网络设备在获取五元组中的源端口号、目的端口号、传输层协议类型这三个字段的获取效率低,流分类效率低,因此产生了网络设备执行QoS策略效率低的问题。本发明实施例提供了一种网络设备只需获取待发送IPv6数据报文中的流标签,即可执行相应QoS策略的方法,能提高路由器执行QoS策略的效率。In the implementation device of a QoS policy provided by the embodiment of the present invention, the acquisition unit acquires the flow label in the IPv6 data message to be sent, and the policy execution unit executes the QoS corresponding to the IPv6 data message to be sent according to the flow label acquired by the acquisition unit Strategy. Compared with the prior art, when implementing the QoS policy, the five-tuple in the IPv6 data message must first be obtained to classify the IPv6 data message, and the network device obtains the source port number and destination port number in the five-tuple. The acquisition efficiency of the three fields of number and transport layer protocol type is low, and the flow classification efficiency is low. Therefore, the problem of low efficiency in implementing QoS policies by network devices arises. The embodiment of the present invention provides a method for a network device to execute a corresponding QoS strategy only by obtaining the flow label in the IPv6 data message to be sent, which can improve the efficiency of the router in executing the QoS strategy.
通过以上的实施方式的描述,所属领域的技术人员可以清楚地了解到本发明可借助软件加必需的通用硬件的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施方式。基于这样的理解,本发明的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在可读取的存储介质中,如计算机的软盘,硬盘或光盘等,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行本发明各个实施例所述的方法。Through the description of the above embodiments, those skilled in the art can clearly understand that the present invention can be realized by means of software plus necessary general-purpose hardware, and of course also by hardware, but in many cases the former is a better embodiment . Based on this understanding, the essence of the technical solution of the present invention or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product is stored in a readable storage medium, such as a floppy disk of a computer , a hard disk or an optical disk, etc., including several instructions for enabling a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods described in various embodiments of the present invention.
以上所述,仅为本发明的具体实施方式,但本发明的保护范围并不局限于此,任何熟悉本技术领域的技术人员在本发明揭露的技术范围内,可轻易想到变化或替换,都应涵盖在本发明的保护范围之内。因此,本发明的保护范围应以所述权利要求的保护范围为准。The above is only a specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Anyone skilled in the art can easily think of changes or substitutions within the technical scope disclosed in the present invention. Should be covered within the protection scope of the present invention. Therefore, the protection scope of the present invention should be determined by the protection scope of the claims.
Claims (8)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410725321.8A CN104486244B (en) | 2014-12-03 | 2014-12-03 | A kind of execution method and device of QoS policy |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410725321.8A CN104486244B (en) | 2014-12-03 | 2014-12-03 | A kind of execution method and device of QoS policy |
Publications (2)
Publication Number | Publication Date |
---|---|
CN104486244A CN104486244A (en) | 2015-04-01 |
CN104486244B true CN104486244B (en) | 2018-06-01 |
Family
ID=52760749
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201410725321.8A Active CN104486244B (en) | 2014-12-03 | 2014-12-03 | A kind of execution method and device of QoS policy |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN104486244B (en) |
Families Citing this family (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106161192A (en) * | 2015-04-08 | 2016-11-23 | 阿里巴巴集团控股有限公司 | A kind of method and apparatus of Message Processing |
CN106911586B (en) * | 2017-03-24 | 2020-04-14 | 京信通信系统(中国)有限公司 | Quality of service (Qos) optimization method and device |
CN110099407A (en) * | 2018-01-30 | 2019-08-06 | 华为技术有限公司 | A kind of service quality QoS control method and relevant device |
CN112398754B (en) * | 2020-11-13 | 2022-09-13 | Oppo广东移动通信有限公司 | Data transmission method, device, medium, electronic equipment and network access equipment |
CN112422435B (en) * | 2020-11-13 | 2022-03-25 | 新华三技术有限公司合肥分公司 | Message forwarding control method and device and electronic equipment |
CN115514579B (en) * | 2022-11-09 | 2023-03-03 | 北京连星科技有限公司 | Method and system for realizing service identification based on IPv6 address mapping flow label |
Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1214832A (en) * | 1996-03-25 | 1999-04-21 | 诺基亚电信公司 | Prioritization of data to be transmitted in router |
CN1468010A (en) * | 2002-07-12 | 2004-01-14 | 华为技术有限公司 | A short message scheduling management method in wireless mobile network |
CN101645849A (en) * | 2009-09-09 | 2010-02-10 | 中兴通讯股份有限公司 | QoS realization method in transitional environment and PE router |
CN103825820A (en) * | 2014-01-22 | 2014-05-28 | 汉柏科技有限公司 | IPv6 flow label-based QoE (Quality of Experience) management method |
CN103856414A (en) * | 2012-11-29 | 2014-06-11 | 中国电信股份有限公司 | IPv6 data packet service quality processing method and device |
US8854965B1 (en) * | 2005-07-20 | 2014-10-07 | Avaya Inc. | Flow label systems and methods |
EP2800328A2 (en) * | 2012-01-20 | 2014-11-05 | Huawei Technologies Co., Ltd. | Method, device and system for controlling quality of service |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101242403B (en) * | 2007-02-07 | 2012-06-27 | 华为技术有限公司 | Stream label allocation method and system and stream label request device and allocation device |
-
2014
- 2014-12-03 CN CN201410725321.8A patent/CN104486244B/en active Active
Patent Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1214832A (en) * | 1996-03-25 | 1999-04-21 | 诺基亚电信公司 | Prioritization of data to be transmitted in router |
CN1468010A (en) * | 2002-07-12 | 2004-01-14 | 华为技术有限公司 | A short message scheduling management method in wireless mobile network |
US8854965B1 (en) * | 2005-07-20 | 2014-10-07 | Avaya Inc. | Flow label systems and methods |
CN101645849A (en) * | 2009-09-09 | 2010-02-10 | 中兴通讯股份有限公司 | QoS realization method in transitional environment and PE router |
EP2800328A2 (en) * | 2012-01-20 | 2014-11-05 | Huawei Technologies Co., Ltd. | Method, device and system for controlling quality of service |
CN103856414A (en) * | 2012-11-29 | 2014-06-11 | 中国电信股份有限公司 | IPv6 data packet service quality processing method and device |
CN103825820A (en) * | 2014-01-22 | 2014-05-28 | 汉柏科技有限公司 | IPv6 flow label-based QoE (Quality of Experience) management method |
Also Published As
Publication number | Publication date |
---|---|
CN104486244A (en) | 2015-04-01 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN111770028B (en) | Method and network device for computer network | |
CN104486244B (en) | A kind of execution method and device of QoS policy | |
US10148573B2 (en) | Packet processing method, node, and system | |
US11026247B2 (en) | Transmitting data based on flow input from base station | |
CN106953737B (en) | Providing application metadata using an export protocol within a computer network | |
US11057298B2 (en) | Providing differentiated service to traffic flows obscured by content distribution systems | |
US9338101B2 (en) | Advertising network layer reachability information specifying a quality of service for an identified network flow | |
US9509631B2 (en) | Quality of service (QoS) for information centric networks | |
US20160285762A1 (en) | Techniques for exchanging control and configuration information in a network visibility system | |
US10291536B2 (en) | Tiered services in border gateway protocol flow specification | |
US20140211714A1 (en) | Method and apparatus for performing policy control on data packet | |
CN102201990B (en) | A kind of service control method for autonomous networks and system | |
US10454712B2 (en) | Access apparatus and access apparatus-performed method for connecting user device to network | |
US9479596B2 (en) | Pairing internal network identifier with external network identifier | |
US20180254921A1 (en) | Packet processing method, apparatus, and system | |
US11240140B2 (en) | Method and system for interfacing communication networks | |
CN106534301A (en) | Method and device for balancing network outbound load | |
CN113395612B (en) | Data forwarding method in optical fiber communication and related device | |
US9942161B1 (en) | Methods and systems for configuring and updating session-based quality of service for multimedia traffic in a local area network | |
WO2022237879A1 (en) | Routing obtaining method and apparatus, storage medium, and electronic apparatus | |
CN109067657B (en) | Message processing method and device | |
KR101897423B1 (en) | Improved network utilization in policy-based networks | |
US9954767B2 (en) | Internet control message protocol for completing a secondary protocol transaction | |
US20120191628A1 (en) | Ip service peering mechanisms | |
WO2017193814A1 (en) | Service chain generation method and system |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |