[go: up one dir, main page]

WO2017219667A1 - Method, device, and system for modifying mss - Google Patents

Method, device, and system for modifying mss Download PDF

Info

Publication number
WO2017219667A1
WO2017219667A1 PCT/CN2017/071583 CN2017071583W WO2017219667A1 WO 2017219667 A1 WO2017219667 A1 WO 2017219667A1 CN 2017071583 W CN2017071583 W CN 2017071583W WO 2017219667 A1 WO2017219667 A1 WO 2017219667A1
Authority
WO
WIPO (PCT)
Prior art keywords
mss value
mss
network
data device
network nodes
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.)
Ceased
Application number
PCT/CN2017/071583
Other languages
French (fr)
Chinese (zh)
Inventor
贾臻
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
ZTE Corp
Original Assignee
ZTE Corp
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by ZTE Corp filed Critical ZTE Corp
Publication of WO2017219667A1 publication Critical patent/WO2017219667A1/en
Anticipated expiration legal-status Critical
Ceased legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/10Flow control; Congestion control
    • H04L47/36Flow control; Congestion control by determining packet size, e.g. maximum transfer unit [MTU]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W84/00Network topologies
    • H04W84/02Hierarchically pre-organised networks, e.g. paging networks, cellular networks, WLAN [Wireless Local Area Network] or WLL [Wireless Local Loop]
    • H04W84/10Small scale networks; Flat hierarchical networks
    • H04W84/12WLAN [Wireless Local Area Networks]

Definitions

  • the present invention relates to the field of communications, and in particular, to a method, an apparatus, and a system for modifying an MSS.
  • the negotiation of the Maximum Segment Size (MSS) value in the current Transmission Control Protocol (TCP) connection depends on the server and client that establish the connection.
  • the two parties use the three-way handshake process of TCP to negotiate the MSS value. This negotiation takes the smaller one. However, each operator has different definitions of the MSS value. If no modification is made, the server sends the data packet.
  • operations such as fragmentation and merging are performed, resulting in a significant drop in the data rate, and the user experience of the device is greatly reduced.
  • the server since the operator has different definitions of the MSS value, the server often needs to perform operations such as fragmentation of the data packet when sending the data packet, which is easy to cause the transmission rate of the server to send the data packet to be low and the user experience degree. Poor problems have not yet come up with an effective solution.
  • the embodiment of the present invention provides a method, a device, and a system for modifying an MSS, so as to at least solve the related art, because the operator has different definitions of the MSS value, the server often needs to fragment the data packet when sending the data packet. Such operations, which easily lead to low transmission rate of the server to send packets and poor user experience.
  • a method for modifying an MSS comprising: acquiring a first MSS value received by a data device having a wireless fidelity WiFi function for performing a network connection; and the first MSS value Modified to a second MSS value, where the second MSS value refers to an MSS value obtained by the data device according to a network in which the data device is located.
  • determining the second MSS value by: acquiring some or all network nodes in the network where the data device is located; transmitting a transmission control protocol TCP connection to the part or all network nodes, and receiving the a TCP handshake data packet fed back by some or all network nodes; parsing an MSS value corresponding to some or all network nodes from the TCP handshake data packet, and selecting a minimum MSS value from the MSS value as the second MSS value .
  • the method before sending the transmission control protocol TCP connection to the part or all of the network nodes, the method further includes: acquiring an IP address of the part or all network nodes, where the part is or according to the IP address All network nodes send TCP connections.
  • modifying the first MSS value to the second MSS value pre-saved in the data device comprises: modifying the first MSS value to the second MSS value by using a configured execution rule.
  • a device for modifying a maximum segment size MSS comprising: a first obtaining module, configured to acquire a data device received by a wireless fidelity WiFi function for network connection a first MSS value; a modification module, configured to modify the first MSS value to a second MSS value, where the second MSS value is an MSS value obtained by the data device according to a network where the data device is located .
  • the device further includes: a second acquiring module, configured to acquire some or all network nodes in the network where the data device is located; and a sending module configured to send a transmission control protocol TCP to the part or all network nodes a receiving module, configured to receive a TCP handshake data packet fed back by the part or all network nodes; and a parsing module configured to parse all MSS values corresponding to some or all network nodes from the TCP handshake data packet, and The smallest MSS value is selected as the second MSS value among all the MSS values.
  • a second acquiring module configured to acquire some or all network nodes in the network where the data device is located
  • a sending module configured to send a transmission control protocol TCP to the part or all network nodes
  • a receiving module configured to receive a TCP handshake data packet fed back by the part or all network nodes
  • a parsing module configured to parse all MSS values corresponding to some or all network nodes from the TCP handshake data packet, and The smallest MS
  • the apparatus further includes: a third obtaining module, configured to acquire an IP address of the part or all network nodes, where the TCP connection is sent to the part or all network nodes according to the IP address.
  • a third obtaining module configured to acquire an IP address of the part or all network nodes, where the TCP connection is sent to the part or all network nodes according to the IP address.
  • the modifying module is configured to modify the first MSS value to the second MSS value by using a configured execution rule.
  • a modified system of a maximum segment size MSS comprising: a data device having a wireless fidelity WiFi function, wherein the data device is configured to have a wireless fidelity WiFi function Receiving, by the data device, a first MSS value for performing a network connection; and modifying the first MSS value to a second MSS value, wherein the second MSS value refers to the data device according to the data device The MSS value obtained by the network where it is located.
  • the data device is further configured to acquire some or all network nodes in the network where the data device is located; send a transmission control protocol TCP connection to the part or all network nodes, and receive the part or all of the network The TCP handshake data packet fed back by the node; and parsing the MSS value corresponding to some or all of the network nodes from the TCP handshake data packet, and selecting the smallest MSS value from the MSS value as the second MSS value.
  • a computer storage medium is further provided, and the computer storage medium may store an execution instruction for implementing the modification method of the maximum segment size MSS in the foregoing embodiment.
  • the first MSS value in the network connection performed by the data device is uniformly modified into the second MSS value saved in the data device, and the foregoing technical solution is adopted to solve the related technology, because the operator
  • the MSS value has different definitions. Therefore, when the server sends a data packet, it often needs to perform operations such as fragmentation of the data packet, which may easily cause the server to transmit the data packet with low transmission rate and poor user experience, and thus can pass the solution.
  • the second MSS value in the network connection performed by the data device is consistent with the first MSS value stored in the data device to ensure the data transmission rate of the server, which brings a good user experience to the user.
  • FIG. 1 is a flowchart of a method of modifying an MSS according to an embodiment of the present invention
  • FIG. 2 is a structural block diagram of a modification apparatus of an MSS according to an embodiment of the present invention.
  • FIG. 3 is another structural block diagram of a modification apparatus of an MSS according to an embodiment of the present invention.
  • FIG. 4 is a structural block diagram of a modification system of an MSS according to an example of the present invention.
  • FIG. 5 is a flow chart of a method of modifying an MSS according to an example of the present invention.
  • MTU maximum transmission unit
  • FIG. 1 is a flowchart of a method for modifying an MSS according to an embodiment of the present invention. As shown in FIG. 1, the process includes the following steps:
  • Step S102 Acquire a first MSS value received by the data device with WiFi function for performing network connection.
  • Step S104 Modify the first MSS value to a second MSS value, where the second MSS value refers to an MSS value obtained by the data device according to the network where the data device is located.
  • the first MSS value in the network connection performed by the data device is uniformly modified into the second MSS value saved in the data device, and the foregoing technical solution is used to solve the related technology, because the operator has the MSS value Different definitions, the server often needs to shard the data packet when sending the data packet, which is easy to cause the server to send the data packet with low transmission rate and poor user experience, and thus can pass the number
  • the second MSS value in the network connection performed by the device is consistent with the first MSS value stored in the data device to ensure the data transmission rate of the server, which brings a good user experience to the user.
  • the above technical solution of the embodiment of the present invention intelligently adjusts the MSS value to ensure that the rate is up to standard, and ensures that the MTU value does not change, thereby preventing such a situation that seriously affects the user experience that cannot be used by some applications.
  • determining the second MSS value by: obtaining some or all network nodes in the network where the data device is located; transmitting a transmission control protocol TCP connection to some or all network nodes, and receiving a TCP handshake fed back by some or all network nodes Data packet; parsing all MSS values corresponding to some or all network nodes from the TCP handshake data packet, and selecting the smallest one from all MSS values as the first MSS value, that is, taking some or all network nodes between the terminal and the server as objects, All MSS values corresponding to some or all network nodes are parsed, and the smallest one is selected as the first MSS value from all MSS values.
  • the foregoing method may further perform the following steps: acquiring an IP address of some or all network nodes, where part or all is according to the IP address.
  • the network node sends a TCP connection.
  • the following technical solution may also be implemented: constructing an execution rule, where the execution rule is used to modify the second MSS value to the first MSS value, that is, specifically
  • the data device with the WiFi function in the embodiment of the present invention may be a MiFi (portable broadband wireless device, which may be understood as Mobile, according to the above-mentioned rule of the configuration to modify the second MSS value to the first MSS value.
  • the abbreviation of the WiFi which may be a ufi device, or other data device having a WiFi function, is not limited in this embodiment of the present invention.
  • the method according to the above embodiment can be implemented by means of software plus a necessary general hardware platform, and of course, by hardware, but in many cases, the former is A better implementation.
  • the technical solution of the present invention which is essential or contributes to the prior art, may be embodied in the form of a software product stored in a storage medium (eg, ROM/RAM, disk, and optical disk include instructions for causing a terminal device (which may be a mobile phone, a computer, a server, or a network device, etc.) to perform the methods of various embodiments of the present invention.
  • a modification device of the MSS is further provided, and the device is used to implement the foregoing embodiments and preferred embodiments, and details are not described herein.
  • the term “module” may implement a combination of software and/or hardware of a predetermined function.
  • the apparatus described in the following embodiments is preferably implemented in software, hardware, or a combination of software and hardware, is also possible and contemplated.
  • FIG. 2 is a structural block diagram of a modification apparatus of an MSS according to an embodiment of the present invention. As shown in FIG. 2, the apparatus includes:
  • the first obtaining module 20 is configured to acquire a first MSS value received by the data device with the WiFi function for performing a network connection;
  • the modifying module 22 is configured to modify the first MSS value to a second MSS value, where the second MSS value refers to an MSS value obtained by the data device according to the network where the data device is located.
  • the first MSS value in the network connection performed by the data device is uniformly modified into the second MSS value saved in the data device by using the foregoing various functions of the modules, and the foregoing technical solution is adopted to solve the related technology, because the operator
  • the MSS value is defined differently, so the server often needs to perform operations such as fragmentation of the data packet when sending the data packet, which may easily lead to the problem that the server transmits the data packet with low transmission rate and poor user experience, and thus can pass the data packet.
  • the second MSS value in the network connection performed by the data device is consistent with the first MSS value stored in the data device to ensure the data transmission rate of the server, which brings a good user experience to the user.
  • FIG. 3 is another structural block diagram of a device for modifying an MSS according to an embodiment of the present invention.
  • the device further includes: a second acquiring module 24 configured to be part or all of the network nodes in the network where the data device is located;
  • the sending module 26 is configured to send a transmission control protocol TCP connection to some or all of the network nodes; and the receiving module 28 is configured to receive some or all of the network nodes.
  • the TCP handshake packet is fed;
  • the parsing module 30 is configured to parse all MSS values corresponding to some or all network nodes from the TCP handshake packet, and select the smallest MSS value from all MSS values as the second MSS value.
  • the foregoing apparatus further includes: a third obtaining module 32, configured to acquire an IP address of some or all network nodes, where the TCP connection is sent to some or all network nodes according to the IP address, and the modifying module 22 is further configured to pass The constructed execution rule modifies the first MSS value to the second MSS value.
  • a third obtaining module 32 configured to acquire an IP address of some or all network nodes, where the TCP connection is sent to some or all network nodes according to the IP address
  • the modifying module 22 is further configured to pass The constructed execution rule modifies the first MSS value to the second MSS value.
  • a system for modifying an MSS including:
  • a data device having a wireless fidelity WiFi function wherein the data device is configured to acquire a first MSS value received by the data device having the WiFi function for performing a network connection; and modify the first MSS value to the second The MSS value, where the second MSS value refers to the MSS value obtained by the data device according to the network where the data device is located.
  • the first MSS value in the network connection performed by the data device is uniformly modified into the second MSS value saved in the data device, and the foregoing technical solution is used to solve the related art. Since the operator defines the MSS value differently, the server often needs to perform the operation of fragmenting the data packet when sending the data packet, which may cause the transmission rate of the server to transmit the data packet and the user experience to be poor.
  • the second MSS value in the network connection to be performed by the data device and the first MSS value stored in the data device can be consistent to ensure the data transmission rate of the server, which brings a good user experience to the user.
  • the foregoing data device is further configured to acquire some or all network nodes in the network where the data device is located; send a transmission control protocol TCP connection to some or all network nodes, and receive a TCP handshake packet fed back by some or all network nodes. And parsing the MSS value corresponding to some or all network nodes from the TCP handshake data packet, and selecting the smallest MSS value from the MSS value as the second MSS value.
  • the example of the present invention can be used to adjust the MSS value to adapt to the operator's network, if the user terminal does not modify the MTU by using the intermediate device (ie, the data device with the wireless fidelity WiFi function). This can achieve higher performance when downloading data, and bring a good experience to the user, while not modifying the MTU value to prevent failure problems that cannot be segmented.
  • the intermediate device ie, the data device with the wireless fidelity WiFi function
  • FIG. 4 is a structural block diagram of a modified system of an MSS according to an example of the present invention. As shown in FIG. 4, the method mainly includes:
  • the network status module 40 is detected, the network node module 42 is acquired, the intelligent analysis module 44 is set, and the installation module 46 is set. After detecting the network connection success, the network status module 40 first sends a series of ping packet data on the board side, and records an address that can be normally communicated. Then, the acquiring network node module 42 obtains the IP address on each node by using the address obtained in the previous step, and then through route tracking, and saves and records these addresses. The intelligent parsing module 44 will parse the TCP handshake data returned by the node according to all the IP addresses obtained in the previous step, and intercept the TCP handshake data packet returned by the node, and then parse the MSS value, and finally select the smallest MSS. value.
  • the setup installation module 46 sets the optimal MSS value to the above data device, whereby all the data devices will automatically modify the MSS value to maintain the same network value as the operator, and when downloading data, the data rate will be lower than The rate at which any modification is made is greatly improved, and the MTU value is not modified, so that the performance and evaluation of the device by the user will be very high.
  • FIG. 5 is a flowchart of a method for modifying an MSS according to an example of the present invention. The following detailed flowchart is used to explain how the above modules can intelligently adjust the MSS value.
  • Step S502 The terminal device is normally connected to the network. After the network is successfully connected, the network status module 40 is invoked. The module uses a ping, domain name server (DNS) analysis to determine whether the network can access the internet network normally. And select a well-known IP address, the following 8.8.8.8 address as an example. When the network is not normal, the detection network status module 40 is continuously called until the network is normal.
  • DNS domain name server
  • Step S504 after the network status is normal, call the acquisition network node module 42, and then use the traceroute tool to obtain some or all network nodes between the terminal and the server 8.8.8.8, some of which may be in the carrier network, some It may not be in the carrier network. Since it is impossible to distinguish whether it belongs to the carrier network node, all network nodes are recorded.
  • Step S506 after successfully acquiring the network node, calling the intelligent parsing module 44, the module will perform a TCP connection with the recorded network node by constructing a socket, and intercept the returned TCP handshake data packet by using the hook function, and the slave data packet. Obtain the MSS value returned by each network node, compare all MSS values, and select the smallest MSS value.
  • Step S508 after the intelligent parsing module 44 is completed, the setting installation module 46 is invoked, and a rule is constructed in the data device by using the iptables tool, for example, the following rules are
  • This rule will modify the mss value of min_mss for all tcp handshake connections over the data device to ensure that the device can better adapt to the carrier's network.
  • each of the above modules may be implemented by software or hardware.
  • the foregoing may be implemented by, but not limited to, the foregoing modules are all located in the same processor; or, the above modules are in any combination.
  • the forms are located in different processors.
  • FIG. 1 is a schematic flowchart of a method provided by the method, which mainly includes four modules and is disposed in a wireless router. The provided process ultimately installs the optimal MSS value into the wireless routing module.
  • the MSS values are different. Modifying the MTU value directly has some problems that affect the user experience. Therefore, modifying the MSS value can ensure a better user experience. At the same time, the MSS value can be modified.
  • the network can be intelligently adjusted to ensure that the network can be adjusted under each operator's network. The equipment can achieve a good rate effect, which brings users a high quality experience and improves the competitiveness of the product.
  • the embodiment of the present invention achieves the following technical effects: in the related art, since the operator defines the MSS value differently, the server often needs to perform the operation of fragmenting the data packet when sending the data packet. In this way, the problem that the transmission rate of the data packet sent by the server is low and the user experience is poor, and the second MSS value in the network connection to be performed by the data device can be consistent with the first MSS value stored in the data device. Guarantee the data transmission rate of the server, bringing a good user experience to the user.
  • Embodiments of the present invention also provide a storage medium.
  • the foregoing storage medium may be configured to store program code for performing the following steps:
  • the foregoing storage medium may include, but not limited to, a USB flash drive, a Read-Only Memory (ROM), a Random Access Memory (RAM), a mobile hard disk, and a magnetic memory.
  • ROM Read-Only Memory
  • RAM Random Access Memory
  • a mobile hard disk e.g., a hard disk
  • magnetic memory e.g., a hard disk
  • modules or steps of the present invention described above can be implemented by a general-purpose computing device that can be centralized on a single computing device or distributed across a network of multiple computing devices. Alternatively, they may be implemented by program code executable by the computing device such that they may be stored in the storage device by the computing device and, in some cases, may be different from the order herein.
  • the steps shown or described are performed, or they are separately fabricated into individual integrated circuit modules, or a plurality of modules or steps thereof are fabricated as a single integrated circuit module.
  • the invention is not limited to any specific combination of hardware and software.
  • the foregoing technical solution provided by the embodiment of the present invention may be applied to the process of modifying the MSS value, and uniformly modifying the first MSS value in the network connection performed by the data device to the second MSS value saved in the data device, and adopting
  • the above technical solution solves the related art. Since the operator has different definitions of the MSS value, the server often needs to perform the operation of fragmenting the data packet when sending the data packet, which is easy to cause the transmission rate of the data packet sent by the server. The problem of low user experience is poor, and the second MSS value in the network connection performed by the data device and the first MSS value stored in the data device can be consistent to ensure the data transmission rate of the server.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

Provided in the present invention are a method, a device, and a system for modifying an MSS. The method comprises: acquiring a first MSS value received by a data device having a Wi-Fi function, for a network connection; and modifying the first MSS value to be a second MSS value, the second MSS value referring to an MSS value acquired by the data device according to a network in which the data device is located. Using the described technical solutions, the invention solves the problem in the related art that, operators define the MSS value differently, and servers or clients need to perform operations on data packets, for example, fragmenting data packets, when transmitting the data packets over networks of the operators, easily resulting in a low transmission rate at which the servers or clients transmit the data packets over the networks of the operators as well as poor user experience. Thus, the invention can further maintain the second MSS value in the network connection by means of the data device consistent with the first MSS value stored in the data device, ensuring the data transmission rate of servers.

Description

MSS的修改方法、装置及系统MSS modification method, device and system 技术领域Technical field

本发明涉及通信领域,具体而言,涉及一种MSS的修改方法、装置及系统。The present invention relates to the field of communications, and in particular, to a method, an apparatus, and a system for modifying an MSS.

背景技术Background technique

目前一般的传输控制协议(Transfer Control Protocol,简称为TCP)连接中最大分段大小(Maximum Segment Size,简称为MSS)值的协商是依赖于建立连接的服务器和客户端的。双方通过TCP的三次握手过程,来实现MSS值的协商,这个协商取双方值较小的一方,但是目前各个运营商对于MSS值有不同的定义,如果不进行任何修改,服务器发送的数据包在通过运营商网络传输时,会进行分片,合并等操作,由此导致数据速率的明显下降,用户对设备的体验度大大降低。The negotiation of the Maximum Segment Size (MSS) value in the current Transmission Control Protocol (TCP) connection depends on the server and client that establish the connection. The two parties use the three-way handshake process of TCP to negotiate the MSS value. This negotiation takes the smaller one. However, each operator has different definitions of the MSS value. If no modification is made, the server sends the data packet. When transmitting through the carrier network, operations such as fragmentation and merging are performed, resulting in a significant drop in the data rate, and the user experience of the device is greatly reduced.

针对相关技术中,由于运营商对MSS值有不同的定义,那么服务器在发送数据包时经常会需要对数据包进行分片等操作,这样容易导致服务器发送数据包的传输速率低以及用户体验度差的问题,尚未提出有效的解决方案。In the related art, since the operator has different definitions of the MSS value, the server often needs to perform operations such as fragmentation of the data packet when sending the data packet, which is easy to cause the transmission rate of the server to send the data packet to be low and the user experience degree. Poor problems have not yet come up with an effective solution.

发明内容Summary of the invention

本发明实施例提供了一种MSS的修改方法、装置及系统,以至少解决相关技术中由于运营商对MSS值有不同的定义,那么服务器在发送数据包时经常会需要对数据包进行分片等操作,这样容易导致服务器发送数据包的传输速率低以及用户体验度差的问题。The embodiment of the present invention provides a method, a device, and a system for modifying an MSS, so as to at least solve the related art, because the operator has different definitions of the MSS value, the server often needs to fragment the data packet when sending the data packet. Such operations, which easily lead to low transmission rate of the server to send packets and poor user experience.

根据本发明的一个实施例,提供了一种MSS的修改方法,包括:获取具有无线保真WiFi功能的数据设备接收到的用于进行网络连接的第一MSS值;将所述第一MSS值修改为第二MSS值,其中,所述第二MSS值是指所述数据设备根据该数据设备所在的网络获取的MSS值。 According to an embodiment of the present invention, there is provided a method for modifying an MSS, comprising: acquiring a first MSS value received by a data device having a wireless fidelity WiFi function for performing a network connection; and the first MSS value Modified to a second MSS value, where the second MSS value refers to an MSS value obtained by the data device according to a network in which the data device is located.

可选地,至少通过以下方式确定所述第二MSS值:获取所述数据设备所在网络中的部分或全部网络节点;向所述部分或全部网络节点发送传输控制协议TCP连接,并接收所述部分或全部网络节点反馈的TCP握手数据包;从所述TCP握手数据包中解析出部分或全部网络节点对应的MSS值,从所述MSS值中选取最小的MSS值作为所述第二MSS值。Optionally, determining the second MSS value by: acquiring some or all network nodes in the network where the data device is located; transmitting a transmission control protocol TCP connection to the part or all network nodes, and receiving the a TCP handshake data packet fed back by some or all network nodes; parsing an MSS value corresponding to some or all network nodes from the TCP handshake data packet, and selecting a minimum MSS value from the MSS value as the second MSS value .

可选地,向所述部分或全部网络节点发送传输控制协议TCP连接之前,所述方法还包括:获取所述部分或全部网络节点的IP地址,其中,根据所述IP地址向所述部分或全部网络节点发送TCP连接。Optionally, before sending the transmission control protocol TCP connection to the part or all of the network nodes, the method further includes: acquiring an IP address of the part or all network nodes, where the part is or according to the IP address All network nodes send TCP connections.

可选地,将所述第一MSS值修改为所述数据设备中预先保存的第二MSS值,包括:通过构造的执行规则将所述第一MSS值修改为所述第二MSS值。Optionally, modifying the first MSS value to the second MSS value pre-saved in the data device comprises: modifying the first MSS value to the second MSS value by using a configured execution rule.

根据本发明的另一个实施例,还提供了一种最大分段大小MSS的修改装置,包括:第一获取模块,设置为获取具有无线保真WiFi功能的数据设备接收到的用于进行网络连接的第一MSS值;修改模块,设置为将所述第一MSS值修改为第二MSS值,其中,所述第二MSS值是指所述数据设备根据该数据设备所在的网络获取的MSS值。According to another embodiment of the present invention, a device for modifying a maximum segment size MSS is further provided, comprising: a first obtaining module, configured to acquire a data device received by a wireless fidelity WiFi function for network connection a first MSS value; a modification module, configured to modify the first MSS value to a second MSS value, where the second MSS value is an MSS value obtained by the data device according to a network where the data device is located .

可选地,所述装置还包括:第二获取模块,设置为获取所述数据设备所在网络中的部分或全部网络节点;发送模块,设置为向所述部分或全部网络节点发送传输控制协议TCP连接;接收模块,设置为接收所述部分或全部网络节点反馈的TCP握手数据包;解析模块,设置为从所述TCP握手数据包中解析出部分或全部网络节点对应的所有MSS值,从所述所有MSS值中选取最小的MSS值作为所述第二MSS值。Optionally, the device further includes: a second acquiring module, configured to acquire some or all network nodes in the network where the data device is located; and a sending module configured to send a transmission control protocol TCP to the part or all network nodes a receiving module, configured to receive a TCP handshake data packet fed back by the part or all network nodes; and a parsing module configured to parse all MSS values corresponding to some or all network nodes from the TCP handshake data packet, and The smallest MSS value is selected as the second MSS value among all the MSS values.

可选地,所述装置还包括:第三获取模块,设置为获取所述部分或全部网络节点的IP地址,其中,根据所述IP地址向所述部分或全部网络节点发送TCP连接。Optionally, the apparatus further includes: a third obtaining module, configured to acquire an IP address of the part or all network nodes, where the TCP connection is sent to the part or all network nodes according to the IP address.

可选地,所述修改模块,设置为通过构造的执行规则将所述第一MSS值修改为所述第二MSS值。 Optionally, the modifying module is configured to modify the first MSS value to the second MSS value by using a configured execution rule.

根据本发明的另一个实施例,还提供了一种最大分段大小MSS的修改系统,包括:具有无线保真WiFi功能的数据设备,其中,所述数据设备,设置为具有无线保真WiFi功能的数据设备接收到的用于进行网络连接的第一MSS值;并将所述第一MSS值修改为第二MSS值,其中,所述第二MSS值是指所述数据设备根据该数据设备所在的网络获取的MSS值。According to another embodiment of the present invention, there is also provided a modified system of a maximum segment size MSS, comprising: a data device having a wireless fidelity WiFi function, wherein the data device is configured to have a wireless fidelity WiFi function Receiving, by the data device, a first MSS value for performing a network connection; and modifying the first MSS value to a second MSS value, wherein the second MSS value refers to the data device according to the data device The MSS value obtained by the network where it is located.

可选地,所述数据设备,还设置为获取所述数据设备所在网络中的部分或全部网络节点;向所述部分或全部网络节点发送传输控制协议TCP连接,并接收所述部分或全部网络节点反馈的TCP握手数据包;并从所述TCP握手数据包中解析出部分或全部网络节点对应的MSS值,从所述MSS值中选取最小的MSS值作为所述第二MSS值。Optionally, the data device is further configured to acquire some or all network nodes in the network where the data device is located; send a transmission control protocol TCP connection to the part or all network nodes, and receive the part or all of the network The TCP handshake data packet fed back by the node; and parsing the MSS value corresponding to some or all of the network nodes from the TCP handshake data packet, and selecting the smallest MSS value from the MSS value as the second MSS value.

在本发明实施例中,还提供了一种计算机存储介质,该计算机存储介质可以存储有执行指令,该执行指令用于执行上述实施例中的最大分段大小MSS的修改方法的实现。In an embodiment of the present invention, a computer storage medium is further provided, and the computer storage medium may store an execution instruction for implementing the modification method of the maximum segment size MSS in the foregoing embodiment.

通过本发明实施例,将通过所述数据设备进行的网络连接中的第一MSS值统一修改为数据设备中保存的第二MSS值,采用上述技术方案,解决了相关技术中,由于运营商对MSS值有不同的定义,那么服务器在发送数据包时经常会需要对数据包进行分片等操作,这样容易导致服务器发送数据包的传输速率低以及用户体验度差的问题,进而能够将通过所述数据设备进行的网络连接中的第二MSS值和数据设备中保存的第一MSS值保持一致,保证服务器的数据传输速率,给用户带来了良好的用户体验。According to the embodiment of the present invention, the first MSS value in the network connection performed by the data device is uniformly modified into the second MSS value saved in the data device, and the foregoing technical solution is adopted to solve the related technology, because the operator The MSS value has different definitions. Therefore, when the server sends a data packet, it often needs to perform operations such as fragmentation of the data packet, which may easily cause the server to transmit the data packet with low transmission rate and poor user experience, and thus can pass the solution. The second MSS value in the network connection performed by the data device is consistent with the first MSS value stored in the data device to ensure the data transmission rate of the server, which brings a good user experience to the user.

附图说明DRAWINGS

此处所说明的附图用来提供对本发明的进一步理解,构成本申请的一部分,本发明的示意性实施例及其说明用于解释本发明,并不构成对本发明的不当限定。在附图中:The drawings described herein are intended to provide a further understanding of the invention, and are intended to be a part of the invention. In the drawing:

图1是根据本发明实施例的MSS的修改方法的流程图;1 is a flowchart of a method of modifying an MSS according to an embodiment of the present invention;

图2是根据本发明实施例的MSS的修改装置的结构框图; 2 is a structural block diagram of a modification apparatus of an MSS according to an embodiment of the present invention;

图3是根据本发明实施例的MSS的修改装置的另一结构框图;3 is another structural block diagram of a modification apparatus of an MSS according to an embodiment of the present invention;

图4为根据本发明示例的MSS的修改系统的结构框图;4 is a structural block diagram of a modification system of an MSS according to an example of the present invention;

图5为根据本发明示例的MSS的修改方法的流程图。FIG. 5 is a flow chart of a method of modifying an MSS according to an example of the present invention.

具体实施方式detailed description

下文中将参考附图并结合实施例来详细说明本发明。需要说明的是,在不冲突的情况下,本申请中的实施例及实施例中的特征可以相互组合。The invention will be described in detail below with reference to the drawings in conjunction with the embodiments. It should be noted that the embodiments in the present application and the features in the embodiments may be combined with each other without conflict.

需要说明的是,本发明的说明书和权利要求书及上述附图中的术语“第一”、“第二”等是用于区别类似的对象,而不必用于描述特定的顺序或先后次序。It is to be understood that the terms "first", "second" and the like in the specification and claims of the present invention are used to distinguish similar objects, and are not necessarily used to describe a particular order or order.

发明人在进行试验测试时,尝试修改了笔记本上的最大传输单元(Maximum transmission Unit,简称为MTU)值后,发现速率确实和比样机相差不多,但是后期发现如果修改MTU值,测试机器在使用一些应用(例如PS游戏机)连接时,会出现无法使用的情况,因此修改方案,仅仅修改MSS值来改变TCP连接,结果速率正常,同时不影响应用的使用。When the inventor tried to modify the maximum transmission unit (MTU) value on the notebook during the test, the rate was found to be similar to that of the prototype, but later found that if the MTU value was modified, the test machine was in use. Some applications (such as PS game consoles) will be unusable when connected, so modify the scheme, only modify the MSS value to change the TCP connection, the result rate is normal, and does not affect the application.

因此,在本实施例中提供了一种MSS的修改方法,图1是根据本发明实施例的MSS的修改方法的流程图,如图1所示,该流程包括如下步骤:Therefore, in this embodiment, a method for modifying an MSS is provided. FIG. 1 is a flowchart of a method for modifying an MSS according to an embodiment of the present invention. As shown in FIG. 1, the process includes the following steps:

步骤S102,获取具有WiFi功能的数据设备接收到的用于进行网络连接的第一MSS值;Step S102: Acquire a first MSS value received by the data device with WiFi function for performing network connection.

步骤S104,将所述第一MSS值修改为第二MSS值,其中,第二MSS值是指数据设备根据该数据设备所在的网络获取的MSS值。Step S104: Modify the first MSS value to a second MSS value, where the second MSS value refers to an MSS value obtained by the data device according to the network where the data device is located.

通过上述各个步骤,将通过数据设备进行的网络连接中的第一MSS值统一修改为数据设备中保存的第二MSS值,采用上述技术方案,解决了相关技术中,由于运营商对MSS值由不同的定义,那么服务器在发送数据包时经常会需要对数据包进行分片等操作,这样容易导致服务器发送数据包的传输速率低以及用户体验度差的问题,进而能够将将通过所述数 据设备进行的网络连接中的第二MSS值和数据设备中保存的第一MSS值保持一致,保证服务器的数据传输速率,给用户带来了良好的用户体验。Through the foregoing steps, the first MSS value in the network connection performed by the data device is uniformly modified into the second MSS value saved in the data device, and the foregoing technical solution is used to solve the related technology, because the operator has the MSS value Different definitions, the server often needs to shard the data packet when sending the data packet, which is easy to cause the server to send the data packet with low transmission rate and poor user experience, and thus can pass the number The second MSS value in the network connection performed by the device is consistent with the first MSS value stored in the data device to ensure the data transmission rate of the server, which brings a good user experience to the user.

换而言之,本发明实施例的上述技术方案通过智能的调整MSS值,保证速率达标的情况下,并且保证MTU值不变,防止出现一些应用无法使用的这种严重影响用户体验的情况。In other words, the above technical solution of the embodiment of the present invention intelligently adjusts the MSS value to ensure that the rate is up to standard, and ensures that the MTU value does not change, thereby preventing such a situation that seriously affects the user experience that cannot be used by some applications.

可选地,至少通过以下方式确定第二MSS值:获取数据设备所在网络中部分或全部网络节点;向部分或全部网络节点发送传输控制协议TCP连接,并接收部分或全部网络节点反馈的TCP握手数据包;从TCP握手数据包中解析出部分或全部网络节点对应的所有MSS值,从所有MSS值中选取最小的作为第一MSS值,即将终端和服务器之间部分或全部网络节点作为对象,解析出部分或全部网络节点对应的所有MSS值,从所有MSS值中选取最小的作为第一MSS值。Optionally, determining the second MSS value by: obtaining some or all network nodes in the network where the data device is located; transmitting a transmission control protocol TCP connection to some or all network nodes, and receiving a TCP handshake fed back by some or all network nodes Data packet; parsing all MSS values corresponding to some or all network nodes from the TCP handshake data packet, and selecting the smallest one from all MSS values as the first MSS value, that is, taking some or all network nodes between the terminal and the server as objects, All MSS values corresponding to some or all network nodes are parsed, and the smallest one is selected as the first MSS value from all MSS values.

当然,在本发明实施例中的向部分或全部网络节点发送传输控制协议TCP连接之前,上述方法还可以执行以下步骤:获取部分或全部网络节点的IP地址,其中,根据IP地址向部分或全部网络节点发送TCP连接。Certainly, before sending the transmission control protocol TCP connection to some or all network nodes in the embodiment of the present invention, the foregoing method may further perform the following steps: acquiring an IP address of some or all network nodes, where part or all is according to the IP address. The network node sends a TCP connection.

在一个可选示例中,在执行步骤S104之前,还可以执行以下技术方案:构造执行规则,其中,该执行规则用于将所述第二MSS值修改为所述第一MSS值,即具体是根据构造的上述规则实现将第二MSS值修改为第一MSS值的,需要说明的是,本发明实施例中的具有WiFi功能的数据设备可以是MiFi(便携式宽带无线装置,可以理解为是Mobile WiFi的简称),也可以是ufi设备,还可以是其他具有WiFi功能的数据设备,本发明实施例对此不作限定。In an optional example, before performing step S104, the following technical solution may also be implemented: constructing an execution rule, where the execution rule is used to modify the second MSS value to the first MSS value, that is, specifically The data device with the WiFi function in the embodiment of the present invention may be a MiFi (portable broadband wireless device, which may be understood as Mobile, according to the above-mentioned rule of the configuration to modify the second MSS value to the first MSS value. The abbreviation of the WiFi, which may be a ufi device, or other data device having a WiFi function, is not limited in this embodiment of the present invention.

通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到根据上述实施例的方法可借助软件加必需的通用硬件平台的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施方式。基于这样的理解,本发明的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质(如 ROM/RAM、磁碟、光盘)中,包括若干指令用以使得一台终端设备(可以是手机,计算机,服务器,或者网络设备等)执行本发明各个实施例的方法。Through the description of the above embodiments, those skilled in the art can clearly understand that the method according to the above embodiment can be implemented by means of software plus a necessary general hardware platform, and of course, by hardware, but in many cases, the former is A better implementation. Based on such understanding, the technical solution of the present invention, which is essential or contributes to the prior art, may be embodied in the form of a software product stored in a storage medium (eg, ROM/RAM, disk, and optical disk include instructions for causing a terminal device (which may be a mobile phone, a computer, a server, or a network device, etc.) to perform the methods of various embodiments of the present invention.

实施例2Example 2

在本实施例中还提供了一种MSS的修改装置,该装置用于实现上述实施例及优选实施方式,已经进行过说明的不再赘述。如以下所使用的,术语“模块”可以实现预定功能的软件和/或硬件的组合。尽管以下实施例所描述的装置较佳地以软件来实现,但是硬件,或者软件和硬件的组合的实现也是可能并被构想的。In the embodiment, a modification device of the MSS is further provided, and the device is used to implement the foregoing embodiments and preferred embodiments, and details are not described herein. As used below, the term "module" may implement a combination of software and/or hardware of a predetermined function. Although the apparatus described in the following embodiments is preferably implemented in software, hardware, or a combination of software and hardware, is also possible and contemplated.

图2是根据本发明实施例的MSS的修改装置的结构框图,如图2所示,该装置包括:2 is a structural block diagram of a modification apparatus of an MSS according to an embodiment of the present invention. As shown in FIG. 2, the apparatus includes:

第一获取模块20,设置为获取具有WiFi功能的数据设备接收到的用于进行网络连接的第一MSS值;The first obtaining module 20 is configured to acquire a first MSS value received by the data device with the WiFi function for performing a network connection;

修改模块22,设置为将所述第一MSS值修改为第二MSS值,其中,第二MSS值是指数据设备根据该数据设备所在的网络获取的MSS值。The modifying module 22 is configured to modify the first MSS value to a second MSS value, where the second MSS value refers to an MSS value obtained by the data device according to the network where the data device is located.

通过上述各个模块的综合作用,将通过数据设备进行的网络连接中的第一MSS值统一修改为数据设备中保存的第二MSS值,采用上述技术方案,解决了相关技术中,由于运营商对MSS值由不同的定义,那么服务器在发送数据包时经常会需要对数据包进行分片等操作,这样容易导致服务器发送数据包的传输速率低以及用户体验度差的问题,进而能够将将通过所述数据设备进行的网络连接中的第二MSS值和数据设备中保存的第一MSS值保持一致,保证服务器的数据传输速率,给用户带来了良好的用户体验。The first MSS value in the network connection performed by the data device is uniformly modified into the second MSS value saved in the data device by using the foregoing various functions of the modules, and the foregoing technical solution is adopted to solve the related technology, because the operator The MSS value is defined differently, so the server often needs to perform operations such as fragmentation of the data packet when sending the data packet, which may easily lead to the problem that the server transmits the data packet with low transmission rate and poor user experience, and thus can pass the data packet. The second MSS value in the network connection performed by the data device is consistent with the first MSS value stored in the data device to ensure the data transmission rate of the server, which brings a good user experience to the user.

图3是根据本发明实施例的MSS的修改装置的另一结构框图,如图3所示,上述装置还包括:第二获取模块24,设置为数据设备所在网络中的部分或全部网络节点;发送模块26,设置为向部分或全部网络节点发送传输控制协议TCP连接;接收模块28,设置为接收部分或全部网络节点反 馈的TCP握手数据包;解析模块30,设置为从TCP握手数据包中解析出部分或全部网络节点对应的所有MSS值,从所有MSS值中选取最小的MSS值作为第二MSS值。FIG. 3 is another structural block diagram of a device for modifying an MSS according to an embodiment of the present invention. As shown in FIG. 3, the device further includes: a second acquiring module 24 configured to be part or all of the network nodes in the network where the data device is located; The sending module 26 is configured to send a transmission control protocol TCP connection to some or all of the network nodes; and the receiving module 28 is configured to receive some or all of the network nodes. The TCP handshake packet is fed; the parsing module 30 is configured to parse all MSS values corresponding to some or all network nodes from the TCP handshake packet, and select the smallest MSS value from all MSS values as the second MSS value.

可选地,上述装置还包括:第三获取模块32,设置为获取部分或全部网络节点的IP地址,其中,根据IP地址向部分或全部网络节点发送TCP连接,修改模块22,还设置为通过构造的执行规则将第一MSS值修改为第二MSS值。Optionally, the foregoing apparatus further includes: a third obtaining module 32, configured to acquire an IP address of some or all network nodes, where the TCP connection is sent to some or all network nodes according to the IP address, and the modifying module 22 is further configured to pass The constructed execution rule modifies the first MSS value to the second MSS value.

在本发明实施例中,还提供了一种MSS的修改系统,包括:In the embodiment of the present invention, a system for modifying an MSS is further provided, including:

具有无线保真WiFi功能的数据设备,其中,数据设备,设置为获取具有WiFi功能的数据设备接收到的用于进行网络连接的第一MSS值;并将所述第一MSS值修改为第二MSS值,其中,第二MSS值是指数据设备根据该数据设备所在的网络获取的MSS值。a data device having a wireless fidelity WiFi function, wherein the data device is configured to acquire a first MSS value received by the data device having the WiFi function for performing a network connection; and modify the first MSS value to the second The MSS value, where the second MSS value refers to the MSS value obtained by the data device according to the network where the data device is located.

通过本发明提供的MSS的修改系统,将通过所述数据设备进行的网络连接中的第一MSS值统一修改为数据设备中保存的第二MSS值,采用上述技术方案,解决了相关技术中,由于运营商对MSS值由不同的定义,那么服务器在发送数据包时经常会需要对数据包进行分片等操作,这样容易导致服务器发送数据包的传输速率低以及用户体验度差的问题,进而能够将将通过所述数据设备进行的网络连接中的第二MSS值和数据设备中保存的第一MSS值保持一致,保证服务器的数据传输速率,给用户带来了良好的用户体验。With the modification system of the MSS provided by the present invention, the first MSS value in the network connection performed by the data device is uniformly modified into the second MSS value saved in the data device, and the foregoing technical solution is used to solve the related art. Since the operator defines the MSS value differently, the server often needs to perform the operation of fragmenting the data packet when sending the data packet, which may cause the transmission rate of the server to transmit the data packet and the user experience to be poor. The second MSS value in the network connection to be performed by the data device and the first MSS value stored in the data device can be consistent to ensure the data transmission rate of the server, which brings a good user experience to the user.

可选地,上述数据设备,还设置为获取数据设备所在网络中的部分或全部网络节点;向部分或全部网络节点发送传输控制协议TCP连接,并接收部分或全部网络节点反馈的TCP握手数据包;并从TCP握手数据包中解析出部分或全部网络节点对应的MSS值,从MSS值中选取最小的MSS值作为所述第二MSS值。Optionally, the foregoing data device is further configured to acquire some or all network nodes in the network where the data device is located; send a transmission control protocol TCP connection to some or all network nodes, and receive a TCP handshake packet fed back by some or all network nodes. And parsing the MSS value corresponding to some or all network nodes from the TCP handshake data packet, and selecting the smallest MSS value from the MSS value as the second MSS value.

以下结合一示例对上述技术方案进行解释说明,但不用于限定本发明实施例。 The above technical solutions are explained below in conjunction with an example, but are not intended to limit the embodiments of the present invention.

本发明示例通过中间设备(即上述具有无线保真WiFi功能的数据设备),来达到在用户终端不对MTU进行修改的情况下,可以智能的调整MSS值,使其适配于运营商的网络,由此可以达到在下载数据时的较高的性能,给用户带来很好的体验,同时不修改MTU值,防止出现无法分段的故障问题。The example of the present invention can be used to adjust the MSS value to adapt to the operator's network, if the user terminal does not modify the MTU by using the intermediate device (ie, the data device with the wireless fidelity WiFi function). This can achieve higher performance when downloading data, and bring a good experience to the user, while not modifying the MTU value to prevent failure problems that cannot be segmented.

本发明示例的技术方案还可以从以下角度考虑:The technical solution of the exemplary embodiment of the present invention can also be considered from the following points:

图4为根据本发明示例的MSS的修改系统的结构框图,如图4所示,主要包括:4 is a structural block diagram of a modified system of an MSS according to an example of the present invention. As shown in FIG. 4, the method mainly includes:

检测网络状态模块40,获取网络节点模块42,智能解析模块44,设置安装模块46。其中检测网络状态模块40等待设备联网成功后,首先在板侧发送一系列的ping包数据,并记录可以正常通信的地址。接着,获取网络节点模块42通过上一步中获取的地址,然后通过路由跟踪的方式,获取到每一个节点上的IP地址,并保存记录这些地址。智能解析模块44,将根据上一步获取的所有IP地址,并通过以此向每一个节点发送TCP连接,并截取节点返回的TCP握手数据包,从中解析出MSS值的大小,最后选择最小的MSS值。设置安装模块46将最优的MSS值设置到上述数据设备中,由此所有通过上述数据设备将自动修改MSS值,从而保持与运营商的网络值一致,在下载数据时,数据速率将比不进行任何修改的速率得到较大提升,同时不修改MTU值,由此用户对于设备的性能和评价将非常高。The network status module 40 is detected, the network node module 42 is acquired, the intelligent analysis module 44 is set, and the installation module 46 is set. After detecting the network connection success, the network status module 40 first sends a series of ping packet data on the board side, and records an address that can be normally communicated. Then, the acquiring network node module 42 obtains the IP address on each node by using the address obtained in the previous step, and then through route tracking, and saves and records these addresses. The intelligent parsing module 44 will parse the TCP handshake data returned by the node according to all the IP addresses obtained in the previous step, and intercept the TCP handshake data packet returned by the node, and then parse the MSS value, and finally select the smallest MSS. value. The setup installation module 46 sets the optimal MSS value to the above data device, whereby all the data devices will automatically modify the MSS value to maintain the same network value as the operator, and when downloading data, the data rate will be lower than The rate at which any modification is made is greatly improved, and the MTU value is not modified, so that the performance and evaluation of the device by the user will be very high.

图5为根据本发明示例的MSS的修改方法的流程图,以下用详细的流程图说明上述模块之间如何实现智能调整MSS值的过程。FIG. 5 is a flowchart of a method for modifying an MSS according to an example of the present invention. The following detailed flowchart is used to explain how the above modules can intelligently adjust the MSS value.

步骤S502,终端设备正常的联网,在联网成功后,调用检测网络状态模块40,此模块会采用ping,域名服务(Domain Name Server,简称为DNS)解析等方式,判断网络是否可以正常访问internet网络,并选取好知名的IP地址,下文以8.8.8.8地址为例。当网络不正常时,持续调用检测网络状态模块40,直到网络正常。 Step S502: The terminal device is normally connected to the network. After the network is successfully connected, the network status module 40 is invoked. The module uses a ping, domain name server (DNS) analysis to determine whether the network can access the internet network normally. And select a well-known IP address, the following 8.8.8.8 address as an example. When the network is not normal, the detection network status module 40 is continuously called until the network is normal.

步骤S504,当网络状态正常后,调用获取网络节点模块42,然后利用traceroute工具,获取终端与服务器8.8.8.8之间的部分或全部网络节点,这些网络节点有些可能是运营商网络中的,有些可能不是运营商网络中,由于无法区别是否属于运营商网络节点,因此记录所有的网络节点。Step S504, after the network status is normal, call the acquisition network node module 42, and then use the traceroute tool to obtain some or all network nodes between the terminal and the server 8.8.8.8, some of which may be in the carrier network, some It may not be in the carrier network. Since it is impossible to distinguish whether it belongs to the carrier network node, all network nodes are recorded.

步骤S506,当成功获取到网络节点后,调用智能解析模块44,模块会通过构造一个socket,依次与记录的网络节点进行TCP连接,并利用hook函数截获返回的TCP握手数据包,并从数据包中获取到每一个网络节点所返回的MSS值,比较所有的MSS值,选取最小的MSS值。Step S506, after successfully acquiring the network node, calling the intelligent parsing module 44, the module will perform a TCP connection with the recorded network node by constructing a socket, and intercept the returned TCP handshake data packet by using the hook function, and the slave data packet. Obtain the MSS value returned by each network node, compare all MSS values, and select the smallest MSS value.

步骤S508,智能解析模块44完成后,调用设置安装模块46,并利用iptables工具在数据设备中,构造一条规则,例如如下所示规则,Step S508, after the intelligent parsing module 44 is completed, the setting installation module 46 is invoked, and a rule is constructed in the data device by using the iptables tool, for example, the following rules are

iptables-t mangle-I POSTROUTING-p tcp--tcp-flags SYN,RST SYN-j TCPMSS--set-mss$min_mssIptables-t mangle-I POSTROUTING-p tcp--tcp-flags SYN,RST SYN-j TCPMSS--set-mss$min_mss

这条规则将对所有经过数据设备的tcp握手连接修改其mss值为min_mss,以此保证设备可以更好的适应运营商的网络。This rule will modify the mss value of min_mss for all tcp handshake connections over the data device to ensure that the device can better adapt to the carrier's network.

需要说明的是,上述各个模块是可以通过软件或硬件来实现的,对于后者,可以通过以下方式实现,但不限于此:上述模块均位于同一处理器中;或者,上述各个模块以任意组合的形式分别位于不同的处理器中。It should be noted that each of the above modules may be implemented by software or hardware. For the latter, the foregoing may be implemented by, but not limited to, the foregoing modules are all located in the same processor; or, the above modules are in any combination. The forms are located in different processors.

本发明示例还提供了一种智能识别mss值的设置方法,请参考图1,图1为本实例提供的方法流程示意图,主要包括四个模块,并设置于无线路由器中,通过上述技术方案所提供的处理过程,最终将最优的MSS值安装到无线路由模块中。The present invention also provides a method for setting the smart identification mss value. Referring to FIG. 1 , FIG. 1 is a schematic flowchart of a method provided by the method, which mainly includes four modules and is disposed in a wireless router. The provided process ultimately installs the optimal MSS value into the wireless routing module.

由于现在很多运营商网络中的MTU值,MSS值都不相同,直接修改MTU值会有一些影响用户体验的问题,因此修改MSS值可以保证用户体验更好。同时修改MSS值,可以在面向市场的上述数据设备(具体可以包括ufi设备或MiFi设备)中,对于不通运营商的网络,可以进行智能调整MSS值,保证在每个运营商的网络下,ufi设备都可以达到很好的速率效果,以此带给用户优质的体验,提高产品的竞争力。 Since the MTU values in many carrier networks are different, the MSS values are different. Modifying the MTU value directly has some problems that affect the user experience. Therefore, modifying the MSS value can ensure a better user experience. At the same time, the MSS value can be modified. In the above-mentioned data device (which may include a ufi device or a MiFi device), the network can be intelligently adjusted to ensure that the network can be adjusted under each operator's network. The equipment can achieve a good rate effect, which brings users a high quality experience and improves the competitiveness of the product.

综上所述,本发明实施例达到了以下技术效果:解决了相关技术中,由于运营商对MSS值由不同的定义,那么服务器在发送数据包时经常会需要对数据包进行分片等操作,这样容易导致服务器发送数据包的传输速率低以及用户体验度差的问题,进而能够将将通过数据设备进行的网络连接中的第二MSS值和数据设备中保存的第一MSS值保持一致,保证服务器的数据传输速率,给用户带来了良好的用户体验。In summary, the embodiment of the present invention achieves the following technical effects: in the related art, since the operator defines the MSS value differently, the server often needs to perform the operation of fragmenting the data packet when sending the data packet. In this way, the problem that the transmission rate of the data packet sent by the server is low and the user experience is poor, and the second MSS value in the network connection to be performed by the data device can be consistent with the first MSS value stored in the data device. Guarantee the data transmission rate of the server, bringing a good user experience to the user.

本发明的实施例还提供了一种存储介质。可选地,在本实施例中,上述存储介质可以被设置为存储用于执行以下步骤的程序代码:Embodiments of the present invention also provide a storage medium. Optionally, in the embodiment, the foregoing storage medium may be configured to store program code for performing the following steps:

S1,获取具有WiFi功能的数据设备接收到的用于进行网络连接的第一MSS值;S1. Acquire a first MSS value received by the data device with WiFi function for performing network connection.

S2,将所述第一MSS值修改为所述数据设备中预先保存的第二MSS值。S2. Modify the first MSS value to a second MSS value pre-stored in the data device.

可选地,在本实施例中,上述存储介质可以包括但不限于:U盘、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random Access Memory)、移动硬盘、磁碟或者光盘等各种可以存储程序代码的介质。Optionally, in this embodiment, the foregoing storage medium may include, but not limited to, a USB flash drive, a Read-Only Memory (ROM), a Random Access Memory (RAM), a mobile hard disk, and a magnetic memory. A variety of media that can store program code, such as a disc or a disc.

可选地,本实施例中的具体示例可以参考上述实施例及可选实施方式中所描述的示例,本实施例在此不再赘述。For example, the specific examples in this embodiment may refer to the examples described in the foregoing embodiments and the optional embodiments, and details are not described herein again.

显然,本领域的技术人员应该明白,上述的本发明的各模块或各步骤可以用通用的计算装置来实现,它们可以集中在单个的计算装置上,或者分布在多个计算装置所组成的网络上,可选地,它们可以用计算装置可执行的程序代码来实现,从而,可以将它们存储在存储装置中由计算装置来执行,并且在某些情况下,可以以不同于此处的顺序执行所示出或描述的步骤,或者将它们分别制作成各个集成电路模块,或者将它们中的多个模块或步骤制作成单个集成电路模块来实现。这样,本发明不限制于任何特定的硬件和软件结合。It will be apparent to those skilled in the art that the various modules or steps of the present invention described above can be implemented by a general-purpose computing device that can be centralized on a single computing device or distributed across a network of multiple computing devices. Alternatively, they may be implemented by program code executable by the computing device such that they may be stored in the storage device by the computing device and, in some cases, may be different from the order herein. The steps shown or described are performed, or they are separately fabricated into individual integrated circuit modules, or a plurality of modules or steps thereof are fabricated as a single integrated circuit module. Thus, the invention is not limited to any specific combination of hardware and software.

以上所述仅为本发明的优选实施例而已,并不用于限制本发明,对于 本领域的技术人员来说,本发明可以有各种更改和变化。凡在本发明的精神和原则之内,所作的任何修改、等同替换、改进等,均应包含在本发明的保护范围之内。The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Various modifications and changes of the present invention are possible in the art. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and scope of the present invention are intended to be included within the scope of the present invention.

工业实用性Industrial applicability

本发明实施例提供的上述技术方案,可以应用于MSS值的修改过程中,将通过所述数据设备进行的网络连接中的第一MSS值统一修改为数据设备中保存的第二MSS值,采用上述技术方案,解决了相关技术中,由于运营商对MSS值有不同的定义,那么服务器在发送数据包时经常会需要对数据包进行分片等操作,这样容易导致服务器发送数据包的传输速率低以及用户体验度差的问题,进而能够将通过所述数据设备进行的网络连接中的第二MSS值和数据设备中保存的第一MSS值保持一致,保证服务器的数据传输速率。 The foregoing technical solution provided by the embodiment of the present invention may be applied to the process of modifying the MSS value, and uniformly modifying the first MSS value in the network connection performed by the data device to the second MSS value saved in the data device, and adopting The above technical solution solves the related art. Since the operator has different definitions of the MSS value, the server often needs to perform the operation of fragmenting the data packet when sending the data packet, which is easy to cause the transmission rate of the data packet sent by the server. The problem of low user experience is poor, and the second MSS value in the network connection performed by the data device and the first MSS value stored in the data device can be consistent to ensure the data transmission rate of the server.

Claims (10)

一种最大分段大小MSS的修改方法,包括:A method for modifying the maximum segment size MSS, comprising: 获取具有无线保真WiFi功能的数据设备接收到的用于进行网络连接的第一MSS值;Obtaining a first MSS value received by the data device with the wireless fidelity WiFi function for making a network connection; 将所述第一MSS值修改为第二MSS值,其中,所述第二MSS值是指所述数据设备根据该数据设备所在的网络获取的MSS值。Modifying the first MSS value to a second MSS value, where the second MSS value refers to an MSS value obtained by the data device according to a network where the data device is located. 根据权利要求1所述的方法,其中,至少通过以下方式确定所述第二MSS值:The method of claim 1 wherein said second MSS value is determined at least by: 获取所述数据设备所在网络中的部分或全部网络节点;Obtaining some or all of the network nodes in the network where the data device is located; 向所述部分或全部网络节点发送传输控制协议TCP连接,并接收所述部分或全部网络节点反馈的TCP握手数据包;Transmitting a Transmission Control Protocol (TCP) connection to the part or all of the network nodes, and receiving a TCP handshake data packet fed back by the part or all of the network nodes; 从所述TCP握手数据包中解析出部分或全部网络节点对应的MSS值,从所述MSS值中选取最小的MSS值作为所述第二MSS值。Extracting MSS values corresponding to some or all network nodes from the TCP handshake data packet, and selecting a minimum MSS value from the MSS values as the second MSS value. 根据权利要求2所述的方法,其中,向所述部分或全部网络节点发送传输控制协议TCP连接之前,所述方法还包括:The method of claim 2, wherein before the transmitting the Transmission Control Protocol TCP connection to the part or all of the network nodes, the method further comprises: 获取所述部分或全部网络节点的IP地址,其中,根据所述IP地址向所述部分或全部网络节点发送TCP连接。Obtaining an IP address of the part or all of the network nodes, wherein the TCP connection is sent to the part or all of the network nodes according to the IP address. 根据权利要求1所述的方法,其中,将所述第一MSS值修改为所述数据设备中预先保存的第二MSS值,包括:The method of claim 1, wherein modifying the first MSS value to a second MSS value pre-saved in the data device comprises: 通过构造的执行规则将所述第一MSS值修改为所述第二MSS值。The first MSS value is modified to the second MSS value by a constructed execution rule. 一种最大分段大小MSS的修改装置,包括:A modification device for a maximum segment size MSS, comprising: 第一获取模块,设置为获取具有无线保真WiFi功能的数据设备 接收到的用于进行网络连接的第一MSS值;a first obtaining module, configured to acquire a data device with a wireless fidelity WiFi function The received first MSS value for making a network connection; 修改模块,设置为将所述第一MSS值修改为第二MSS值,其中,所述第二MSS值是指所述数据设备根据该数据设备所在的网络获取的MSS值。And a modification module, configured to modify the first MSS value to a second MSS value, where the second MSS value refers to an MSS value obtained by the data device according to a network where the data device is located. 根据权利要求5所述的装置,其中,所述装置还包括:The device of claim 5, wherein the device further comprises: 第二获取模块,设置为获取所述数据设备所在网络中的部分或全部网络节点;a second acquiring module, configured to acquire some or all network nodes in the network where the data device is located; 发送模块,设置为向所述部分或全部网络节点发送传输控制协议TCP连接;a sending module, configured to send a transmission control protocol TCP connection to the part or all of the network nodes; 接收模块,设置为接收所述部分或全部网络节点反馈的TCP握手数据包;a receiving module, configured to receive a TCP handshake data packet fed back by the part or all of the network nodes; 解析模块,设置为从所述TCP握手数据包中解析出部分或全部网络节点对应的所有MSS值,从所述所有MSS值中选取最小的MSS值作为所述第二MSS值。The parsing module is configured to parse all MSS values corresponding to some or all network nodes from the TCP handshake data packet, and select a minimum MSS value from the all MSS values as the second MSS value. 根据权利要求6所述的装置,其中,所述装置还包括:The apparatus of claim 6 wherein said apparatus further comprises: 第三获取模块,设置为获取所述部分或全部网络节点的IP地址,其中,根据所述IP地址向所述部分或全部网络节点发送TCP连接。And a third acquiring module, configured to acquire an IP address of the part or all network nodes, where the TCP connection is sent to the part or all network nodes according to the IP address. 根据权利要求5所述的装置,其中,所述修改模块,设置为通过构造的执行规则将所述第一MSS值修改为所述第二MSS值。The apparatus of claim 5, wherein the modification module is configured to modify the first MSS value to the second MSS value by a constructed execution rule. 一种最大分段大小MSS的修改系统,包括:具有无线保真WiFi功能的数据设备,其中,A modified system of a maximum segment size MSS, comprising: a data device having a wireless fidelity WiFi function, wherein 所述数据设备,设置为具有无线保真WiFi功能的数据设备接收 到的用于进行网络连接的第一MSS值;并将所述第一MSS值修改为第二MSS值,其中,所述第二MSS值是指所述数据设备根据该数据设备所在的网络获取的MSS值。The data device is configured to receive by a data device having a wireless fidelity WiFi function a first MSS value for performing a network connection; and modifying the first MSS value to a second MSS value, wherein the second MSS value is that the data device obtains according to a network where the data device is located MSS value. 根据权利要求9所述的系统,其中,所述数据设备,还设置为获取所述数据设备所在网络中的部分或全部网络节点;向所述部分或全部网络节点发送传输控制协议TCP连接,并接收所述部分或全部网络节点反馈的TCP握手数据包;并从所述TCP握手数据包中解析出部分或全部网络节点对应的MSS值,从所述MSS值中选取最小的MSS值作为所述第二MSS值。 The system of claim 9, wherein the data device is further configured to acquire some or all of the network nodes in the network in which the data device is located; to send the transmission control protocol TCP connection to the part or all of the network nodes, and Receiving a TCP handshake data packet fed back by the part or all network nodes; and parsing an MSS value corresponding to some or all network nodes from the TCP handshake data packet, and selecting a minimum MSS value from the MSS value as the The second MSS value.
PCT/CN2017/071583 2016-06-21 2017-01-18 Method, device, and system for modifying mss Ceased WO2017219667A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201610451970.2A CN107528792A (en) 2016-06-21 2016-06-21 MSS amending method, apparatus and system
CN201610451970.2 2016-06-21

Publications (1)

Publication Number Publication Date
WO2017219667A1 true WO2017219667A1 (en) 2017-12-28

Family

ID=60735031

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2017/071583 Ceased WO2017219667A1 (en) 2016-06-21 2017-01-18 Method, device, and system for modifying mss

Country Status (2)

Country Link
CN (1) CN107528792A (en)
WO (1) WO2017219667A1 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112866133B (en) * 2019-11-26 2023-07-28 华为技术有限公司 Method and device for obtaining the shared maximum segment size MSS
CN115022419B (en) * 2022-06-30 2024-02-20 武汉思普崚技术有限公司 Method, device and storage medium for automatically adjusting MSS

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102594677A (en) * 2012-02-15 2012-07-18 杭州华三通信技术有限公司 Method and device for path maximum transmission unit (PMTU) learning
US20120250530A1 (en) * 2011-03-28 2012-10-04 Ashok Kumar Jagadeeswaran Systems and Methods for Learning MSS of Services
CN103079232A (en) * 2013-01-16 2013-05-01 大唐移动通信设备有限公司 Method and device for determining maximum capacity of message
CN103647759A (en) * 2013-11-26 2014-03-19 华为技术有限公司 Negotiation method and apparatus of maximum segment size (MSS)
CN105429910A (en) * 2015-11-06 2016-03-23 京信通信技术(广州)有限公司 Message transmission and processing method and device

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
GB2406245B (en) * 2003-09-17 2006-01-04 Siemens Ag A method of transmitting packet data on a network
CN101547146A (en) * 2009-04-24 2009-09-30 上海华为技术有限公司 Method and network equipment for determining length value of maximum message segment
CN101924689A (en) * 2009-06-16 2010-12-22 中兴通讯股份有限公司 Negotiation method of maximum segmentation parameters and network forwarding equipment
CN102594505A (en) * 2012-02-08 2012-07-18 华为技术有限公司 Data transmission method and device

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20120250530A1 (en) * 2011-03-28 2012-10-04 Ashok Kumar Jagadeeswaran Systems and Methods for Learning MSS of Services
CN102594677A (en) * 2012-02-15 2012-07-18 杭州华三通信技术有限公司 Method and device for path maximum transmission unit (PMTU) learning
CN103079232A (en) * 2013-01-16 2013-05-01 大唐移动通信设备有限公司 Method and device for determining maximum capacity of message
CN103647759A (en) * 2013-11-26 2014-03-19 华为技术有限公司 Negotiation method and apparatus of maximum segment size (MSS)
CN105429910A (en) * 2015-11-06 2016-03-23 京信通信技术(广州)有限公司 Message transmission and processing method and device

Also Published As

Publication number Publication date
CN107528792A (en) 2017-12-29

Similar Documents

Publication Publication Date Title
US11140162B2 (en) Response method and system in virtual network computing authentication, and proxy server
US11165805B2 (en) Guard system for automatic network flow controls for internet of things (IoT) devices
US10417061B2 (en) Operating method of routing device, routing device, and terminal device
WO2011109778A1 (en) System and method for connecting network sockets between applications
US10419968B2 (en) Dynamic selection of TCP congestion control for improved performances
US10547647B2 (en) Intra-carrier and inter-carrier network security system
EP3032859A1 (en) Access control method and system, and access point
CN106465161B (en) Access point, method of operating access point, and computer-readable medium
US11218912B2 (en) Method and apparatus for controlling traffic of network device in wireless communication network
WO2017101186A1 (en) Method for establishing wireless connection for application of user equipment
WO2018219009A1 (en) Certificate obtaining method and device
CN106572132B (en) Distributed chain building method, device and system
CN113285810B (en) Target equipment login method and device, storage medium and electronic device
US11147027B2 (en) Method for managing optimal transmission power of a Wi-Fi access point
CN112787975B (en) Method, device and system for determining type of access device
WO2017219667A1 (en) Method, device, and system for modifying mss
CN104333872B (en) A kind of method and system for establishing session based on two-way converting detection technique
RU2693903C1 (en) Method, apparatus and processing system for expanded port
WO2017206460A1 (en) Method, apparatus and device for setting maximum transmission unit value
WO2017161866A1 (en) Network connection method and device
CN113225224B (en) Network speed measuring method, system, storage medium and computer equipment
CN114125023A (en) Data connection determining method and device, storage medium and electronic device
US20170289099A1 (en) Method and Device for Managing Internet Protocol Version 6 Address, and Terminal
TWI608749B (en) Method for controlling a client device to access a network device and control device
CN104980471A (en) Network request packet report method, device and system

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 17814407

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 17814407

Country of ref document: EP

Kind code of ref document: A1