CN113595911B - Data forwarding method and device, electronic equipment and storage medium - Google Patents

Data forwarding method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN113595911B
CN113595911B CN202111139785.7A CN202111139785A CN113595911B CN 113595911 B CN113595911 B CN 113595911B CN 202111139785 A CN202111139785 A CN 202111139785A CN 113595911 B CN113595911 B CN 113595911B
Authority
CN
China
Prior art keywords
terminal
tunnel
data
identifier
server
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
Application number
CN202111139785.7A
Other languages
Chinese (zh)
Other versions
CN113595911A (en
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.)
Shenzhen Ailing Network Co Ltd
Original Assignee
Shenzhen Ailing Network Co Ltd
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 Shenzhen Ailing Network Co Ltd filed Critical Shenzhen Ailing Network Co Ltd
Priority to CN202111139785.7A priority Critical patent/CN113595911B/en
Publication of CN113595911A publication Critical patent/CN113595911A/en
Application granted granted Critical
Publication of CN113595911B publication Critical patent/CN113595911B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/74Address processing for routing
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/46Interconnection of networks
    • H04L12/4633Interconnection of networks using encapsulation techniques, e.g. tunneling
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W40/00Communication routing or communication path finding
    • H04W40/02Communication route or path selection, e.g. power-based or shortest path routing
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W76/00Connection management
    • H04W76/10Connection setup
    • H04W76/11Allocation or use of connection identifiers
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W76/00Connection management
    • H04W76/10Connection setup
    • H04W76/12Setup of transport tunnels

Landscapes

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

Abstract

The application provides a data forwarding method, a data forwarding device, electronic equipment and a storage medium, and relates to the technical field of communication, wherein in the method, a server can receive a target data packet sent by a first terminal through a first data tunnel, the first data tunnel is a data tunnel which is established by the server according to a first tunnel identifier and is between the server and the first terminal, and the first tunnel identifier is the first terminal identifier; sending a tunnel data forwarding table acquisition request to a data network DN according to the first terminal identifier; and receiving a data forwarding matching table entry returned by the data network DN, and forwarding the target data packet to a second data tunnel corresponding to the IP address of the second terminal according to the data forwarding matching table entry, so that different data tunnels can be distinguished according to the terminal identifier, and even if the IP address of the first terminal or the IP address of the second terminal changes, the embodiment of the application can still ensure that the data forwarding relation between different data tunnels can be normally maintained.

Description

Data forwarding method and device, electronic equipment and storage medium
Technical Field
The present application relates to the field of communications technologies, and in particular, to a data forwarding method and apparatus, an electronic device, and a storage medium.
Background
The fifth Generation mobile communication technology (5 th Generation mobile networks or 5th Generation with less systems, 5th-Generation, 5G or 5G technology for short) is the latest Generation cellular mobile communication technology. The 5G local network developed based on the 5G technology is also called a private 5G network, and it uses the 5G technology to create a private network on the local user site, and the network has uniform connectivity, optimized service and secure communication mode in a specific area, and provides the characteristics of high transmission speed, low delay and massive connection supported by the 5G technology, and is applied in various communication scenarios.
Currently, when a 5G network is applied to an industrial internet of things scene for forwarding a data packet, different data tunnels are mainly distinguished according to an IP address of a terminal to achieve the purpose of data forwarding.
However, because the existing communication method is relatively simple, there is often a problem that the IP address of the terminal changes due to reconnection in the 5G network, which causes data communication through the data tunnel inside the industrial system to fail.
Disclosure of Invention
An object of the present application is to provide a data forwarding method, an apparatus, an electronic device, and a storage medium, which can ensure that a data forwarding relationship between different data tunnels can be maintained normally even when an IP address of a terminal changes, so as to maintain normal data communication between different networking industrial devices.
In order to achieve the above purpose, the technical solutions adopted in the embodiments of the present application are as follows:
in a first aspect, the present invention provides a data forwarding method, including:
the server receives a target data packet sent by a first terminal through a first data tunnel, wherein the target data packet comprises: the IP address of the first terminal and the IP address of the second terminal, wherein the first data tunnel is a data tunnel which is established by the server according to a first tunnel identifier and is between the server and the first terminal, the first tunnel identifier is a first terminal identifier, and the first terminal identifier is acquired by the server according to a tunnel establishment request sent by the first terminal;
the server sends a tunnel data forwarding table acquisition request to a data network DN according to the first terminal identifier, wherein the tunnel data forwarding table acquisition request comprises: a first terminal identifier and an IP address of a second terminal;
the server receives a data forwarding matching table entry returned by the data network DN, and forwards the target data packet to a second data tunnel corresponding to the IP address of the second terminal according to the data forwarding matching table entry, where the data forwarding matching table entry includes: and a second data tunnel identifier corresponding to the IP address of the second terminal, wherein the second data tunnel identifier is the second terminal identifier.
In an alternative embodiment, the data network DN is configured to include: and the source tunnel identifier, other associated destination tunnel identifiers corresponding to the source tunnel identifier, and the mapping relationship between the IP addresses of the terminals corresponding to the other associated destination tunnel identifiers, wherein the source data tunnel indicated by the source tunnel identifier is configured to forward the data packet to the associated destination data tunnel indicated by the other associated destination tunnel identifiers.
In an alternative embodiment, the method further comprises:
the method comprises the following steps that a server receives a tunnel establishment request sent by a first terminal, wherein the tunnel establishment request comprises: an IP address of the first terminal;
and the server establishes a first data tunnel between the server and the first terminal according to the tunnel establishment request.
In an optional embodiment, the establishing, by the server, a first data tunnel between the server and the first terminal according to the tunnel establishment request includes:
the server sends a terminal identifier acquisition request to a Session Management Function (SMF) through a network open function (NEF) according to the tunnel establishment request, wherein the terminal identifier acquisition request comprises: an IP address of the first terminal;
the server receives a first terminal identifier returned by the session management function SMF through a network open function NEF;
and the server establishes a first data tunnel between the server and the first terminal according to the first terminal identification.
In an optional implementation manner, the second data tunnel identifier corresponding to the IP address of the second terminal includes: and the second data tunnel identifications corresponding to the IP addresses of the one or more second terminals.
In a second aspect, the present invention provides a data forwarding method, including:
the first terminal acquires a target data packet after the IP address changes, wherein the target data packet comprises: the IP address of the first terminal and the IP address of the second terminal;
the first terminal sends the target data packet to a server through a first data tunnel, where the first data tunnel is a data tunnel between the server and the first terminal, which is established by the server according to a first tunnel identifier, the first tunnel identifier is a first terminal identifier, and the first terminal identifier is obtained by the server according to a tunnel establishment request sent by the first terminal, so that the server requests a data network DN to obtain a data forwarding matching table according to the first terminal identifier, and forwards the target data packet to a second data tunnel corresponding to an IP address of the second terminal according to the data forwarding matching table, where the data forwarding matching table includes: and a second data tunnel identifier corresponding to the IP address of the second terminal, wherein the second data tunnel identifier is the second terminal identifier.
In an alternative embodiment, the data network DN is configured to include: and the source tunnel identifier, other associated destination tunnel identifiers corresponding to the source tunnel identifier, and the mapping relationship between the IP addresses of the terminals corresponding to the other associated destination tunnel identifiers, wherein the source data tunnel indicated by the source tunnel identifier is configured to forward the data packet to the associated destination data tunnel indicated by the other associated destination tunnel identifiers.
In an alternative embodiment, the method further comprises:
the first terminal sends a tunnel establishment request to the server, wherein the tunnel establishment request comprises: and the IP address of the first terminal is used for enabling the server to establish a first data tunnel between the server and the first terminal according to the tunnel establishment request.
In a third aspect, the present invention provides a data forwarding apparatus, including:
a receiving module, configured to receive, by a server through a first data tunnel, a target data packet sent by a first terminal, where the target data packet includes: the IP address of the first terminal and the IP address of the second terminal, wherein the first data tunnel is a data tunnel which is established by the server according to a first tunnel identifier and is between the server and the first terminal, the first tunnel identifier is a first terminal identifier, and the first terminal identifier is acquired by the server according to a tunnel establishment request sent by the first terminal;
a sending module, configured to send, by the server, a tunnel data forwarding table acquisition request to a data network DN according to the first terminal identifier, where the tunnel data forwarding table acquisition request includes: a first terminal identifier and an IP address of a second terminal;
a forwarding module, configured to receive, by the server, a data forwarding matching entry returned by the data network DN, and forward the target data packet to a second data tunnel corresponding to the IP address of the second terminal according to the data forwarding matching entry, where the data forwarding matching entry includes: and a second data tunnel identifier corresponding to the IP address of the second terminal, wherein the second data tunnel identifier is the second terminal identifier.
In an alternative embodiment, the data network DN is configured to include: and the source tunnel identifier, other associated destination tunnel identifiers corresponding to the source tunnel identifier, and the mapping relationship between the IP addresses of the terminals corresponding to the other associated destination tunnel identifiers, wherein the source data tunnel indicated by the source tunnel identifier is configured to forward the data packet to the associated destination data tunnel indicated by the other associated destination tunnel identifiers.
In an optional implementation manner, the receiving module is further configured to receive, by the server, a tunnel establishment request sent by the first terminal, where the tunnel establishment request includes: an IP address of the first terminal;
and the server establishes a first data tunnel between the server and the first terminal according to the tunnel establishment request.
In an optional implementation manner, the receiving module is specifically configured to send, by the server according to the tunnel establishment request, a terminal identifier obtaining request to a session management function SMF through a network open function NEF, where the terminal identifier obtaining request includes: an IP address of the first terminal;
the server receives a first terminal identifier returned by the session management function SMF through a network open function NEF;
and the server establishes a first data tunnel between the server and the first terminal according to the first terminal identification.
In an optional implementation manner, the second data tunnel identifier corresponding to the IP address of the second terminal includes: and the second data tunnel identifications corresponding to the IP addresses of the one or more second terminals.
In a fourth aspect, the present invention provides a data forwarding apparatus, including:
an obtaining module, configured to obtain, by a first terminal, a target data packet after an IP address changes, where the target data packet includes: the IP address of the first terminal and the IP address of the second terminal;
a sending module, configured to send the target data packet to a server through a first data tunnel by the first terminal, where the first data tunnel is a data tunnel between the server and the first terminal and established according to a first tunnel identifier, the first tunnel identifier is a first terminal identifier, and the first terminal identifier is obtained by the server according to a tunnel establishment request sent by the first terminal, so that the server requests a data network DN to obtain a data forwarding matching entry according to the first terminal identifier, and forwards the target data packet to a second data tunnel corresponding to an IP address of the second terminal according to the data forwarding matching entry, where the data forwarding matching entry includes: and a second data tunnel identifier corresponding to the IP address of the second terminal, wherein the second data tunnel identifier is the second terminal identifier.
In an alternative embodiment, the data network DN is configured to include: and the source tunnel identifier, other associated destination tunnel identifiers corresponding to the source tunnel identifier, and the mapping relationship between the IP addresses of the terminals corresponding to the other associated destination tunnel identifiers, wherein the source data tunnel indicated by the source tunnel identifier is configured to forward the data packet to the associated destination data tunnel indicated by the other associated destination tunnel identifiers.
In an optional implementation manner, the sending module is further configured to send, by the first terminal, a tunnel establishment request to the server, where the tunnel establishment request includes: and the IP address of the first terminal is used for enabling the server to establish a first data tunnel between the server and the first terminal according to the tunnel establishment request.
In a fifth aspect, the present invention provides an electronic device, comprising: the data forwarding device comprises a processor, a storage medium and a bus, wherein the storage medium stores machine-readable instructions executable by the processor, when the electronic device runs, the processor and the storage medium communicate through the bus, and the processor executes the machine-readable instructions to execute the steps of the data forwarding method according to any one of the preceding embodiments.
In a sixth aspect, the present invention provides a computer-readable storage medium, having a computer program stored thereon, where the computer program is executed by a processor to perform the steps of the data forwarding method according to any one of the preceding embodiments.
The beneficial effect of this application is:
in the data forwarding method, the apparatus, the electronic device, and the storage medium provided in the embodiments of the present application, a server may receive a target data packet sent by a first terminal through a first data tunnel, where the target data packet includes: the IP address of the first terminal, the IP address of the second terminal, the first data tunnel is a data tunnel between the server and the first terminal, which is established according to the first tunnel identifier, the first tunnel identifier is a first terminal identifier, and the first terminal identifier is acquired by the server according to the tunnel establishment request sent by the first terminal; the server sends a tunnel data forwarding table acquisition request to the data network DN according to the first terminal identifier, wherein the tunnel data forwarding table acquisition request comprises: a first terminal identifier and an IP address of a second terminal; the server receives a data forwarding matching table entry returned by the data network DN, and forwards a target data packet to a second data tunnel corresponding to the IP address of the second terminal according to the data forwarding matching table entry, wherein the data forwarding matching table entry comprises: the second data tunnel identifier corresponding to the IP address of the second terminal, where the second data tunnel identifier is the second terminal identifier, realizes that different data tunnels can be distinguished according to the terminal identifier, so that even if the IP address of the first terminal or the IP address of the second terminal changes, the embodiment of the present application can still ensure that the target data packet sent by the first terminal can be successfully forwarded to the second terminal, and ensure that the data forwarding relationship between different data tunnels can be normally maintained.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings that are required to be used in the embodiments will be briefly described below, it should be understood that the following drawings only illustrate some embodiments of the present application and therefore should not be considered as limiting the scope, and for those skilled in the art, other related drawings can be obtained from the drawings without inventive effort.
Fig. 1 is a schematic diagram of a network architecture suitable for use in the method provided by the embodiments of the present application;
fig. 2 is a schematic flowchart of a data forwarding method according to an embodiment of the present application;
fig. 3 is a schematic flowchart of another data forwarding method according to an embodiment of the present application;
fig. 4 is a schematic flowchart of another data forwarding method according to an embodiment of the present application;
fig. 5 is a schematic flowchart of another data forwarding method according to an embodiment of the present application;
fig. 6 is a schematic flowchart of another data forwarding method according to an embodiment of the present application;
fig. 7 is a schematic functional module diagram of a data forwarding apparatus according to an embodiment of the present application;
fig. 8 is a schematic structural diagram of an electronic device according to an embodiment of the present application.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are some embodiments of the present application, but not all embodiments. The components of the embodiments of the present application, generally described and illustrated in the figures herein, can be arranged and designed in a wide variety of different configurations.
Thus, the following detailed description of the embodiments of the present application, presented in the accompanying drawings, is not intended to limit the scope of the claimed application, but is merely representative of selected embodiments of the application. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
It should be noted that: like reference numbers and letters refer to like items in the following figures, and thus, once an item is defined in one figure, it need not be further defined and explained in subsequent figures.
The technical scheme of the embodiment of the application can be applied to various local communication systems, such as: global system for mobile communications (GSM) systems, Code Division Multiple Access (CDMA) systems, Wideband Code Division Multiple Access (WCDMA) systems, General Packet Radio Service (GPRS), Long Term Evolution (LTE) systems, LTE Frequency Division Duplex (FDD) systems, LTE Time Division Duplex (TDD), universal mobile telecommunications system (universal mobile telecommunications system, UMTS), Worldwide Interoperability for Microwave Access (WiMAX) communication systems, fifth generation (5G) communication systems, or future radio access (NR) technologies.
Fig. 1 is a schematic diagram of a network architecture suitable for the method provided by the embodiment of the present application. As shown in fig. 1, the network architecture may be, for example, a non-roaming (non-roaming) architecture. The network architecture may specifically include the following network elements:
1. terminal equipment (UE): may be referred to as user equipment, a terminal, an access terminal, a subscriber unit, a subscriber station, a mobile station, a remote terminal, a mobile device, a user terminal, a wireless communication device, a user agent, or user equipment. The UE may also be a cellular phone, a cordless phone, a Session Initiation Protocol (SIP) phone, a Wireless Local Loop (WLL) station, a Personal Digital Assistant (PDA), a handheld device with wireless communication function, a computing device or other processing device connected to a wireless modem, a vehicle-mounted device, a wearable device, a terminal device in a 5G network or a terminal device in a Public Land Mobile Network (PLMN) for future evolution, and the like, and may also be an end device, a logic entity, an intelligent device, a terminal device such as a mobile phone, an intelligent terminal, and the like, or a communication device such as a server, a gateway, a base station, a controller, and the like, or an Internet of things device such as a sensor, an electric meter, a water meter, and the like (Internet of things, IoT) device. The embodiments of the present application do not limit this.
2. Access Network (AN): the method provides a network access function for authorized users in a specific area, and can use transmission tunnels with different qualities according to the level of the users, the requirements of services and the like. The access network may be an access network employing different access technologies. There are two types of current radio access technologies: third generation partnership project (3 GPP) access technologies such as the radio access technologies employed in 3G, 4G or 5G systems and non-third generation partnership project (non-3 GPP) access technologies. The 3GPP access technology refers to an access technology meeting 3GPP standard specifications, and an access network adopting the 3GPP access technology is referred to as a Radio Access Network (RAN), where an access network device in a 5G system is referred to as a next generation Base station (gNB). The non-3GPP access technology refers to an access technology that does not conform to the 3GPP standard specification, for example, an air interface technology represented by an Access Point (AP) in WIFI.
An access network that implements an access network function based on a wireless communication technology may be referred to as a Radio Access Network (RAN). The radio access network can manage radio resources, provide access service for the terminal, and further complete the forwarding of control signals and user data between the terminal and the core network.
The access network equipment may include, among other things, equipment in the access network that communicates over the air-interface, through one or more sectors, with the wireless terminals. The access network system may be configured to interconvert received air frames and Internet Protocol (IP) packets as routers between the wireless terminal and the rest of the access network, which may include an IP network. The radio access network system may also coordinate management of attributes for the air interface. It should be understood that access network devices include, but are not limited to: evolved node B (eNB), Radio Network Controller (RNC), Node B (NB), Base Station Controller (BSC), Base Transceiver Station (BTS), home base station (e.g., home evolved node B or home node B, HNB), baseband unit (BBU), wireless fidelity (WIFI), etc., and may also be 5G, such as NR, a gbb in the system, or a transmission point (TRP or TP), a group of antennas (including multiple antennas) of a base station in the 5G system, or a panel of a base station (NB), such as a network node (RNC), a Base Transceiver Station (BTS), a base transceiver station (BBU), etc., and may also be a wireless relay node (AP), a wireless backhaul node (HNB), a wireless relay node (BBU), a transmission point (TRP or TP), or a transmission point (NB) in the 5G system, or a panel of a base station (NB), or a network panel of a base station (NB), such as a network node B, a base transceiver station (NB), or a base transceiver station (BBU), or a wireless relay node (nbb, a wireless relay node B, a base station (eNB), or a base station (BBU), or a wireless relay node B, a base station (eNB), or a base station (B, a wireless relay node B, a base station (base station, a wireless relay node B, a wireless terminal, or, Distributed Unit (DU), etc.
In some deployments, the gNB may include a Centralized Unit (CU) and a DU. The gNB may also include a Radio Unit (RU). The CU implements part of the function of the gNB, and the DU implements part of the function of the gNB, for example, the CU implements Radio Resource Control (RRC) and Packet Data Convergence Protocol (PDCP) layers, and the DU implements Radio Link Control (RLC), Medium Access Control (MAC) and Physical (PHY) layers. Since the information of the RRC layer eventually becomes or is converted from the information of the PHY layer, the higher layer signaling, such as the RRC layer signaling, may also be considered to be transmitted by the DU or the DU + CU under this architecture. It is to be understood that the access network device may be a CU node, or a DU node, or a device comprising a CU node and a DU node. In addition, the CU may be divided into access network devices in a Radio Access Network (RAN), or may be divided into access network devices in a Core Network (CN), which is not limited herein.
3. Data Network (DN): such as operator services, internet or third party services, etc.
4. Access and mobility management function (AMF) entity: the method is mainly used for mobility management, access management, and the like, and can be used for implementing functions other than session management in Mobility Management Entity (MME) functions, such as functions of lawful interception, or access authorization (or authentication), and the like. In the embodiment of the present application, the method and the device can be used for implementing the functions of the access and mobility management network element.
5. Session Management Function (SMF) entity: the method is mainly used for session management, Internet Protocol (IP) address allocation and management of the UE, selection of a termination point of an interface capable of managing a user plane function, policy control or charging function, downlink data notification, and the like. In the embodiment of the present application, the method and the device can be used for implementing the function of the session management network element.
6. User Plane Function (UPF) entity: i.e. a data plane gateway. The method can be used for packet routing and forwarding, or quality of service (QoS) processing of user plane data, and the like. The user data can be accessed to a Data Network (DN) through the network element. In the embodiment of the application, the method can be used for realizing the function of the user plane gateway.
7. Policy Control Function (PCF) entity: the unified policy framework is used for guiding network behaviors, providing policy rule information for control plane function network elements (such as AMF and SMF network elements) and the like.
8. Unified Data Management (UDM) entity: for handling subscriber identification, access authentication, registration, or mobility management, etc.
9. N3IWF (Non-3 GPP Interwork Function, Non-3GPP interworking Function): is responsible for accessing untrusted non-3GPP access networks (such as Wi-Fi) to the 5G core network. UE and N3IWF establish an IPsec tunnel, and N3IWF accesses the control plane and the user plane of the 5G core network through an N2 interface and an N3 interface respectively.
10. Network Exposure Function (NEF): located between the 5G core network and the external third party application functionality (there may also be part of the internal AF), responsible for managing the data to the external open network, all external applications that want to access the core network internal data must pass through the NEF. The NEF provides corresponding security guarantee to ensure the security of the external application to the 3gpp network, and provides functions of external application Qos customization capability opening, mobility state event subscription, AF request distribution, and the like.
11. 5G core network: the 5G Core network, abbreviated as 5GC, is mainly responsible for mobility management, session management and data transmission, and includes access and mobility management AMF (functions of completing mobility management, signaling processing, signaling routing, and the like), session management SMF (functions of completing session management, UE address allocation and management, and control functions of session and bearer management in MME + SGW + PGW equivalent to 4G), UDM (unified data management, managing and storing subscription data and authentication data, and equivalent to HSS and SPR of 4G), AUSF (authentication server function, which completes identity authentication of user access), UPF user plane function (which completes different user plane processing, equivalent to user plane functions in SGW and PGW), PCF (policy control function, equivalent to PCRF of 4G), NRF (network storage function, which maintains information of deployed NFs, and processes NF discovery requests from other NFs), NEF (network open function, which allows external or internal applications to access information or services provided by the network, customizing network capabilities for different usage scenarios).
It should be understood that the network architecture applied to the embodiments of the present application is only an exemplary network architecture described in terms of a conventional point-to-point architecture and a service architecture, and the network architecture to which the embodiments of the present application are applied is not limited thereto, and any network architecture capable of implementing the functions of the network elements described above is applicable to the embodiments of the present application.
It should also be understood that the AMF entity, SMF entity, UPF entity, PCF entity and UDM entity shown in fig. 1 may be understood as network elements in the core network for implementing different functions, e.g. may be combined into network slices as needed. The core network elements may be independent devices, or may be integrated in the same device to implement different functions, which is not limited in this application. In the network architecture, an N1 interface is a reference point between a terminal and an AMF entity; the N2 interface is a reference point of AN and AMF entities, and is used for sending non-access stratum (NAS) messages and the like; the N3 interface is a reference point between (R) AN and UPF entities, for transmitting user plane data, etc.; the N4 interface is a reference point between the SMF entity and the UPF entity, and is used to transmit information such as tunnel identification information, data cache indication information, and downlink data notification message of the N3 connection; the N5 interface is a reference point between the UPF entity and the DN for transmitting user plane data, etc.
Hereinafter, for convenience of description, an entity for implementing the AMF will be referred to as an AMF, and an entity for implementing the PCF will be referred to as a PCF. It should be understood that the above-mentioned names are only used for distinguishing different functions, and do not represent that these network elements are respectively independent physical devices, and the present application is not limited to the specific form of the above-mentioned network elements, for example, they may be integrated in the same physical device, or they may be different physical devices. Furthermore, the above nomenclature is only used to distinguish between different functions, and should not be construed as limiting the application in any way, and this application does not exclude the possibility of other nomenclature being used in 5G networks and other networks in the future. For example, in a 6G network, some or all of the above network elements may follow the terminology in 5G, and may also adopt other names, etc. The description is unified here, and will not be repeated below.
It should also be understood that the name of the interface between each network element in fig. 1 is only an example, and the name of the interface in the specific implementation may be other names, which is not specifically limited in this application. In addition, the name of the transmitted message (or signaling) between the network elements is only an example, and the function of the message itself is not limited in any way.
The 5G local network based on 5G technology development is also called private 5G network, and it uses 5G technology to create a private network on the local user site, and the network has uniform connectivity, optimized service and secure communication mode in a specific area, and provides the characteristics of high transmission speed, low delay and mass connection supported by 5G technology. The 5G local network is constructed based on 5G equipment, and comprises 5G terminal equipment, a 5G wireless base station and 5G core network equipment, wherein the equipment is dedicated to a network owner, namely a local user, and can be independently managed and easily deployed. The 5G home network may eliminate reliance on wired devices such as ethernet, which are not only expensive and cumbersome, but also unable to connect large numbers of mobile devices and personnel.
The 5G home network may be configured locally and the network is fully controlled by the network owner, e.g., security, network resource usage, etc., who may assign critical devices a higher priority to use the network resources. Almost any campus, enterprise building or public place can deploy a 5G local network, especially in certain areas where public 5G networks are slow to deploy, 5G local networks can enable fast deployment. Currently, 5G local networks are widely used in a variety of scenarios, such as industrial internet of things (IIoT) scenarios, where sensors are installed in a factory to monitor environmental conditions, support quality control, and customize manufacturing. Through the 5G local network, the data of the sensors can be collected and analyzed, and the information of various aspects of factory operation can be mastered in a refined manner. The intelligent robot can transmit the analysis result to the intelligent robot through the 5G local network, and product manufacturing or factory goods transportation is supported. With the aid of the 5G local network, workers can wear the lightweight augmented reality equipment and complete equipment operation through a virtual environment. In order to better understand the present application, in the embodiment of the present application, a data forwarding method provided by the present application is described by taking a 5G local network as an example.
In the prior art, a 5G network is applied to an industrial internet of things scene, in order to perform normal communication between different networked industrial devices, the 5G network needs to perform data forwarding between different tunnels, and during general forwarding, different data tunnels are distinguished only according to a terminal IP address for forwarding, but according to an actual application scene, a terminal often causes an IP address to occur due to reconnection, for example, when device maintenance is performed, the terminal needs to perform reconnection, in this case, the terminal causes the IP address to occur due to reconnection, and the IP address of the terminal changes, which may cause a situation that data communication performed through the data tunnels inside an industrial system fails.
In view of this, the present application provides a data forwarding method, which can still ensure that a data forwarding relationship between different data tunnels can be normally maintained when a terminal IP changes, so that the data forwarding method is applied to an industrial internet of things scenario, and can maintain normal data communication between different networked industrial devices.
Fig. 2 is a schematic flow chart of a data forwarding method according to an embodiment of the present application, where an execution subject of the method may be a server, and the server may be a tunnel server and may perform data communication with a UPF, and optionally, in some scenarios, the server may be a server built in the UPF, that is, integrated inside the UPF, or may be a server external to the UPF, which is not limited herein and may be different according to an actual application scenario. As shown in fig. 2, the data forwarding method may include:
s101, a server receives a target data packet sent by a first terminal through a first data tunnel, wherein the target data packet comprises: the IP address of the first terminal, the IP address of the second terminal, the first data tunnel is the data tunnel between the server and the first terminal, which is established according to the first tunnel identifier, the first tunnel identifier is the first terminal identifier, and the first terminal identifier is acquired by the server according to the tunnel establishment request sent by the first terminal.
The target data packet may be a data packet that the first terminal needs to send to the second terminal, where the IP address of the first terminal may be understood as the IP address of the source terminal, and the IP address of the second terminal may be understood as the IP address of the destination terminal, that is, the first terminal may be understood as the source terminal, and the second terminal may be understood as the destination terminal, and the IP address of the source terminal and the IP address of the destination terminal may be different according to the difference between the source terminal and the destination terminal. Of course, it is understood that the target data packet may also include a communication data packet to be forwarded, that is, a specific forwarding content, and optionally, the communication data packet to be forwarded may include a communication data packet received by the first terminal and forwarded by another device, which is not limited herein.
For example, the industrial internet of things scenario is used for illustration, the first terminal may be in communication connection with at least one networked industrial device, and then the first terminal may receive a communication data packet sent by the at least one networked industrial device, and generate a target data packet according to the communication data packet sent by the at least one networked industrial device, although the specific application scenario is not limited thereto.
As can be seen from the foregoing, the first terminal may send a tunnel establishment request to the server, and the server may request to acquire the first terminal Identifier according to the tunnel establishment request sent by the first terminal, where the first terminal Identifier may be, without limitation, an International Mobile Subscriber Identity (IMSI), a Subscriber Permanent Identifier (SUPI), and the like, as long as the first terminal device can be uniquely identified, the server may establish a first data tunnel with the first terminal according to the acquired first terminal Identifier, and the first tunnel Identifier of the first data tunnel may be the first terminal Identifier, which makes it possible to uniquely mark the first data tunnel between the server and the first terminal by the first terminal Identifier, and it can be seen that, according to the embodiment of the present application, different data tunnels may be distinguished according to the terminal identifiers, therefore, even if the IP address of the first terminal changes, other terminals can establish communication connection with the first terminal according to the first data tunnel marked by the first terminal identification of the first terminal.
It should be noted that, the server receives the target data packet sent by the first terminal through the first data tunnel, where the receiving mode may specifically be indirect receiving, and in some embodiments, when the server is a server outside the UPF, the UPF may receive the target data packet sent by the first terminal through the first data tunnel and forward the target data packet to the server.
S102, the server sends a tunnel data forwarding table acquisition request to the data network DN according to the first terminal identifier, wherein the tunnel data forwarding table acquisition request comprises: a first terminal identification, an IP address of the second terminal.
S103, the server receives a data forwarding matching table entry returned by the data network DN, and forwards a target data packet to a second data tunnel corresponding to the IP address of the second terminal according to the data forwarding matching table entry, wherein the data forwarding matching table entry comprises: and a second data tunnel identifier corresponding to the IP address of the second terminal, wherein the second data tunnel identifier is the second terminal identifier.
The server receives the target data packet, and may send a tunnel data forwarding table acquisition request to the DN according to the first terminal identifier, optionally, the tunnel data forwarding table acquisition request may include the first terminal identifier and an IP address of the second terminal, and the tunnel data forwarding table acquisition request may be used to request to acquire a data forwarding matching table entry corresponding to the target data packet; after receiving the tunnel data forwarding table acquisition request sent by the server, the DN may return a data forwarding matching table entry, where the data forwarding matching table entry may include: and a second data tunnel identifier corresponding to the IP address of the second terminal, where the second data tunnel identifier may be a second terminal identifier of the second terminal. For the server, the server may create a data forwarding relationship for the first data tunnel according to the returned data forwarding matching entry. Optionally, it should be noted that the data forwarding matching entry may further include: and other associated target tunnel identifications corresponding to the first tunnel identification and the mapping relation between the IP addresses of the terminals corresponding to the other associated target tunnel identifications, so that the server can establish the data forwarding relation of the associated target data tunnels corresponding to the other associated target tunnel identifications for the newly-built first data tunnel according to the data forwarding matching table entry, so that the subsequent data forwarding is facilitated, and the mapping relation can be flexibly set according to the actual application scene.
It can be understood that, when the server performs data forwarding at this time, the server may forward the target data packet to the second data tunnel corresponding to the IP address of the second terminal according to the data forwarding matching entry, so that the target data packet sent by the first terminal and received from the first data tunnel may be forwarded to the second data tunnel corresponding to the second terminal, that is, the target data packet sent by the first terminal may be forwarded to the second terminal through the first data tunnel and the second data tunnel.
Therefore, the data forwarding method provided by the embodiment of the application can still ensure that the data forwarding relationship between different data tunnels can be normally maintained, that is, normal forwarding can be realized, under the condition that the IP address of the first terminal or the IP address of the second terminal changes, and it can be understood that when the data forwarding method provided by the application is applied to an industrial internet of things scene, normal data communication between different networked industrial devices can be ensured, wherein the networked industrial devices can be in communication connection with the terminals.
To sum up, in the data forwarding method provided in this embodiment of the present application, a server may receive a target data packet sent by a first terminal through a first data tunnel, where the target data packet includes: the IP address of the first terminal, the IP address of the second terminal, the first data tunnel is a data tunnel between the server and the first terminal, which is established according to the first tunnel identifier, the first tunnel identifier is a first terminal identifier, and the first terminal identifier is acquired by the server according to the tunnel establishment request sent by the first terminal; the server sends a tunnel data forwarding table acquisition request to the DN according to the first terminal identifier, wherein the tunnel data forwarding table acquisition request comprises: a first terminal identifier and an IP address of a second terminal; the server receives a data forwarding matching table entry returned by the DN, and forwards a target data packet to a second data tunnel corresponding to the IP address of the second terminal according to the data forwarding matching table entry, wherein the data forwarding matching table entry comprises: the second data tunnel identifier corresponding to the IP address of the second terminal, where the second data tunnel identifier is the second terminal identifier, realizes that different data tunnels can be distinguished according to the terminal identifier, so that even if the IP address of the first terminal or the IP address of the second terminal changes, the embodiment of the present application can still ensure that the target data packet sent by the first terminal can be successfully forwarded to the second terminal, and ensure that the data forwarding relationship between different data tunnels can be normally maintained.
Optionally, the DN is configured to include: and the source tunnel identifier, other associated destination tunnel identifiers corresponding to the source tunnel identifier, and the mapping relation between the IP addresses of the terminals corresponding to the other associated destination tunnel identifiers, wherein the source data tunnel indicated by the source tunnel identifier is configured to forward the data packet to the associated destination data tunnel indicated by the other associated destination tunnel identifiers.
Optionally, a mapping relationship among the source tunnel identifier, other associated destination tunnel identifiers corresponding to the source tunnel identifier, and IP addresses of terminals corresponding to the other associated destination tunnel identifiers may be recorded in the DN through a tunnel data forwarding table, and it can be understood that a source data tunnel corresponding to a certain source tunnel identifier may forward a data packet to associated destination data tunnels corresponding to which associated destination tunnel identifiers correspond, and IP addresses of terminals corresponding to the associated destination data tunnels.
As can be seen from the above description, after receiving a tunnel data forwarding table acquisition request sent by a server, a DN may analyze the tunnel data forwarding table acquisition request to obtain a first tunnel identifier of a first data tunnel and an IP address of a destination terminal, that is, a first terminal identifier and an IP address of a second terminal, and according to the first terminal identifier and the IP address of the second terminal, a data forwarding matching table entry corresponding to the first terminal identifier and the IP address of the second terminal may be obtained from the mapping relationship, where the data forwarding matching table entry may include: and a second data tunnel identifier corresponding to the IP address of the second terminal, where the second data tunnel identifier is the second terminal identifier, and it can be understood that the second data tunnel identifier is actually an associated tunnel identifier associated with the first terminal identifier.
Optionally, the DN may be deployed with a local network management system, and when querying the data forwarding matching table entry according to a tunnel data forwarding table acquisition request sent by the server, the DN may specifically query and acquire the data forwarding matching table entry through the local network management system.
The source data tunnel indicated by the source tunnel identifier is configured to forward the data packet to the associated destination data tunnel indicated by the other associated destination tunnel identifiers, optionally, the other associated destination tunnel identifiers corresponding to each source tunnel identifier may include one or more, which is not limited herein. Illustratively, if DN includes the following mapping: the source tunnel identifier a1 and other associated tunnel identifiers corresponding to the source tunnel identifier a1 include a2, A3 and a4, and the IP addresses of the terminals corresponding to the associated tunnel identifiers are: IP2, IP3, IP4, and it can be seen from the mapping relationship that the source data tunnel indicated by the source tunnel identification a1 is configured to forward the data packet to the associated destination data tunnel indicated by a2, A3, a 4.
Fig. 3 is a schematic flowchart of another data forwarding method according to an embodiment of the present application. Optionally, as shown in fig. 3, the method further includes:
s201, a server receives a tunnel establishment request sent by a first terminal, wherein the tunnel establishment request comprises: the IP address of the first terminal.
S202, the server establishes a first data tunnel between the server and the first terminal according to the tunnel establishment request.
Alternatively, the first terminal may send a tunnel establishment request to the server each time the IP address changes, and after receiving the tunnel establishment request, a first data tunnel between the server and the first terminal may be established based on the IP address of the first terminal in the tunnel establishment request, and the first tunnel identification of the first data tunnel may be the first terminal identification, the destination data packet sent by the first terminal may be sent to the server through the first data tunnel, which, of course, it can be understood that the first terminal can also receive other communication information sent by the server through the first data tunnel, so that different data tunnels can be distinguished according to the terminal identification, and even if the IP address of the first terminal changes, according to the first data tunnel marked by the first terminal identification of the first terminal, other terminals can also establish communication connection with the first terminal.
Alternatively, when the server accesses the local communication system, the local communication system may allocate an IP address and a specific port to the server, and then the server may operate on the specific port to listen to the tunnel establishment request sent by the first terminal.
Fig. 4 is a flowchart illustrating another data forwarding method according to an embodiment of the present application. Optionally, as shown in fig. 4, the process of the server establishing the first data tunnel between the server and the first terminal according to the tunnel establishment request may include the following steps:
s301, the server sends a terminal identifier acquisition request to the SMF through the NEF according to the tunnel establishment request, wherein the terminal identifier acquisition request comprises: the IP address of the first terminal.
S302, the server receives the first terminal identification returned by the session management function SMF through the network open function NEF.
S303, the server establishes a first data tunnel between the server and the first terminal according to the first terminal identifier.
As can be seen from the foregoing description of SMF, SMF can be used for IP address assignment and management of a terminal, therefore, the SMF may store the IP address of the first terminal and the identifier of the first terminal, and after the server receives the tunnel establishment request sent by the first terminal, if the first terminal identifier needs to be acquired, the server may send a terminal identifier acquisition request to the session management function SMF through the network open function NEF, and after receiving the terminal identifier acquisition request forwarded by the NEF, the first terminal identifier matching with the IP address of the first terminal in the terminal identifier obtaining request may be queried and returned to the NEF, and after the NEF receives the first terminal identifier returned by the SMF, the first terminal identification may be forwarded to a server, which, after receiving the first terminal identification, a first data tunnel between the server and the first terminal may be established and marked with a first terminal identification.
Optionally, the returned first terminal identifier may be IMS, SUPI, etc. of the first terminal, which is not limited herein and may be different according to the actual application scenario.
Optionally, the second data tunnel identifier corresponding to the IP address of the second terminal includes: and the second data tunnel identifications corresponding to the IP addresses of the one or more second terminals.
According to an actual application scenario, if the target data packet sent by the first terminal is a unicast data packet, the second data tunnel identifier corresponding to the IP address of the second terminal may include: a second data tunnel identifier corresponding to the IP address of the second terminal; if the target data packet sent by the first terminal is a multicast data packet, the second data tunnel identifier corresponding to the IP address of the second terminal may include: the second data tunnel identifiers corresponding to the IP addresses of the plurality of second terminals may be different according to an actual data forwarding scenario.
Fig. 5 is a schematic flow chart of another data forwarding method provided in this embodiment of the present application, where an execution subject of the method may be a first terminal in the above interaction process, and as shown in fig. 5, the method may include:
s401, the first terminal obtains a target data packet after the IP address changes, and the target data packet comprises: the IP address of the first terminal, the IP address of the second terminal.
S402, the first terminal sends a target data packet to the server through a first data tunnel, the first data tunnel is established between the server and the first terminal according to the first tunnel identifier, and the first tunnel identifier is the first terminal identifier.
The first terminal identifier is obtained by the server according to a tunnel establishment request sent by the first terminal, so that the server requests to obtain a data forwarding matching table item from the DN according to the first terminal identifier, and forwards a target data packet to a second data tunnel corresponding to the IP address of the second terminal according to the data forwarding matching table item, wherein the data forwarding matching table item comprises: and a second data tunnel identifier corresponding to the IP address of the second terminal, wherein the second data tunnel identifier is the second terminal identifier.
Compared with the last moment, if the IP address of the first terminal changes and the first terminal acquires the target data packet, the first terminal may send the target data packet to the server through the first data tunnel, so that the server may request to acquire the data forwarding matching entry from the DN according to the first terminal identifier, and forward the target data packet to the second data tunnel corresponding to the IP address of the second terminal according to the data forwarding matching entry, thereby implementing successful forwarding of the target data packet. Optionally, the target data packet acquired by the first terminal may include a communication data packet to be forwarded, which is forwarded to the first terminal by other devices, and for the description of this part, reference may be made to the foregoing relevant parts, which are not described herein again.
By applying the embodiment of the application, it can be seen that, because different data tunnels can be distinguished according to the terminal identifier, even if the IP address of the first terminal changes, other terminals can establish communication connection with the first terminal according to the first data tunnel marked by the first terminal identifier of the first terminal.
It should be noted that, for the second terminal, after the IP address changes, the second terminal may refer to the following method for receiving the target data packet sent by the first terminal, and the specific content is as follows:
the second terminal receives a target data packet forwarded by the server according to the data forwarding matching table entry, wherein the data forwarding matching table entry comprises: a second data tunnel identifier corresponding to the IP address of the second terminal, where the second data tunnel identifier is the second terminal identifier, the data forwarding matching table entry is obtained by the server sending a tunnel data forwarding table obtaining request to the DN according to the first terminal identifier, and the tunnel data forwarding table obtaining request includes: the method comprises a first terminal identification and an IP address of a second terminal, wherein the first terminal identification is obtained by a server according to a tunnel establishment request sent by the first terminal, and a target data packet comprises: the IP address of the first terminal, the IP address of the second terminal.
By applying the embodiment of the application, it can be seen that, because different data tunnels can be distinguished according to the terminal identifier, even if the IP address of the second terminal changes, the target data packet forwarded to the second terminal can still be successfully forwarded to the second terminal according to the second data tunnel marked by the second terminal identifier of the second terminal.
Optionally, the DN is configured to include: and the source tunnel identifier, other associated destination tunnel identifiers corresponding to the source tunnel identifier, and the mapping relation between the IP addresses of the terminals corresponding to the other associated destination tunnel identifiers, wherein the source data tunnel indicated by the source tunnel identifier is configured to forward the data packet to the associated destination data tunnel indicated by the other associated destination tunnel identifiers.
For the content of this part, reference is made to the related part mentioned above, and the description of this application is not repeated here.
Fig. 6 is a flowchart illustrating another data forwarding method according to an embodiment of the present application. Optionally, as shown in fig. 6, the method further includes:
s501, the first terminal sends a tunnel establishment request to the server, and the tunnel establishment request comprises: the IP address of the first terminal, so that the server establishes a first data tunnel between the server and the first terminal according to the tunnel establishment request.
As can be seen from the foregoing relevant portions, a tunnel establishment request may be sent to the server to request the server to establish a first data tunnel with the server, where a first tunnel identifier of the first data tunnel may be a first terminal identifier, and it can be understood that terminal identifiers of terminals are different, so that it is achieved that different data tunnels may be distinguished through the terminal identifiers.
Of course, the sending time of the tunnel establishment request is not limited in the present application, and may be after the IP address of the first terminal changes every time, or before data forwarding is performed every time, which is not limited in this case, and may be flexibly set according to an actual application scenario.
Fig. 7 is a schematic diagram of functional modules of a data forwarding apparatus, which may be the aforementioned server, provided in this embodiment of the present application, and the basic principle and the generated technical effect of the apparatus are the same as those of the aforementioned corresponding method embodiment, and for brief description, the corresponding contents in the method embodiment may be referred to for parts not mentioned in this embodiment. As shown in fig. 7, the data forwarding apparatus 100 may include:
a receiving module 110, configured to receive, by a server, a target data packet sent by a first terminal through a first data tunnel, where the target data packet includes: the IP address of the first terminal, the IP address of the second terminal, the first data tunnel is a data tunnel between the server and the first terminal, which is established according to the first tunnel identifier, the first tunnel identifier is a first terminal identifier, and the first terminal identifier is acquired by the server according to the tunnel establishment request sent by the first terminal;
a sending module 120, configured to send, by the server, a tunnel data forwarding table acquisition request to the data network DN according to the first terminal identifier, where the tunnel data forwarding table acquisition request includes: a first terminal identifier and an IP address of a second terminal;
a forwarding module 130, configured to receive a data forwarding matching entry returned by the data network DN, and forward the target data packet to the second data tunnel corresponding to the IP address of the second terminal according to the data forwarding matching entry, where the data forwarding matching entry includes: and a second data tunnel identifier corresponding to the IP address of the second terminal, wherein the second data tunnel identifier is the second terminal identifier.
In an alternative embodiment, the data network DN is configured to include: and the source tunnel identifier, other associated destination tunnel identifiers corresponding to the source tunnel identifier, and the mapping relation between the IP addresses of the terminals corresponding to the other associated destination tunnel identifiers, wherein the source data tunnel indicated by the source tunnel identifier is configured to forward the data packet to the associated destination data tunnel indicated by the other associated destination tunnel identifiers.
In an optional implementation manner, the receiving module 110 is further configured to receive, by the server, a tunnel establishment request sent by the first terminal, where the tunnel establishment request includes: an IP address of the first terminal;
the server establishes a first data tunnel between the server and the first terminal according to the tunnel establishment request.
In an optional implementation manner, the receiving module 110 is specifically configured to send, by the server according to the tunnel establishment request, a terminal identifier obtaining request to the session management function SMF through the network open function NEF, where the terminal identifier obtaining request includes: an IP address of the first terminal;
the server receives a first terminal identifier returned by a Session Management Function (SMF) through a network open function (NEF);
and the server establishes a first data tunnel between the server and the first terminal according to the first terminal identifier.
In an optional embodiment, the second data tunnel identifier corresponding to the IP address of the second terminal includes: and the second data tunnel identifications corresponding to the IP addresses of the one or more second terminals.
The present application further provides a data forwarding apparatus, which may be the aforementioned first terminal, the basic principle and the generated technical effect of the apparatus are the same as those of the aforementioned corresponding method embodiment, for brief description, no mention in this embodiment may refer to corresponding contents in the method embodiment, and the data forwarding apparatus may include:
an obtaining module, configured to obtain, by a first terminal, a target data packet after an IP address changes, where the target data packet includes: the IP address of the first terminal and the IP address of the second terminal;
a sending module, configured to send a target data packet to a server through a first data tunnel by a first terminal, where the first data tunnel is a data tunnel between the server and the first terminal, where the first tunnel is identified as a first terminal identifier, and the first terminal identifier is obtained by the server according to a tunnel establishment request sent by the first terminal, so that the server requests a data network DN to obtain a data forwarding matching entry according to the first terminal identifier, and forwards the target data packet to a second data tunnel corresponding to an IP address of a second terminal according to the data forwarding matching entry, where the data forwarding matching entry includes: and a second data tunnel identifier corresponding to the IP address of the second terminal, wherein the second data tunnel identifier is the second terminal identifier.
In an alternative embodiment, the data network DN is configured to include: and the source tunnel identifier, other associated destination tunnel identifiers corresponding to the source tunnel identifier, and the mapping relation between the IP addresses of the terminals corresponding to the other associated destination tunnel identifiers, wherein the source data tunnel indicated by the source tunnel identifier is configured to forward the data packet to the associated destination data tunnel indicated by the other associated destination tunnel identifiers.
In an optional implementation manner, the sending module is further configured to send, by the first terminal, a tunnel establishment request to the server, where the tunnel establishment request includes: the IP address of the first terminal, so that the server establishes a first data tunnel between the server and the first terminal according to the tunnel establishment request.
The above-mentioned apparatus is used for executing the method provided by the foregoing embodiment, and the implementation principle and technical effect are similar, which are not described herein again.
These above modules may be one or more integrated circuits configured to implement the above methods, such as: one or more Application Specific Integrated Circuits (ASICs), or one or more microprocessors, or one or more Field Programmable Gate Arrays (FPGAs), etc. For another example, when one of the above modules is implemented in the form of a Processing element scheduler code, the Processing element may be a general-purpose processor, such as a Central Processing Unit (CPU) or other processor capable of calling program code. For another example, these modules may be integrated together and implemented in the form of a system-on-a-chip (SOC).
Fig. 8 is a schematic structural diagram of an electronic device according to an embodiment of the present application, where the electronic device may be a server or a first terminal. As shown in fig. 8, the electronic device may include: a processor 210, a storage medium 220, and a bus 230, wherein the storage medium 220 stores machine-readable instructions executable by the processor 210, and when the electronic device is operated, the processor 210 communicates with the storage medium 220 via the bus 230, and the processor 210 executes the machine-readable instructions to perform the steps of the above-mentioned method embodiments. The specific implementation and technical effects are similar, and are not described herein again.
Optionally, the present application further provides a storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the computer program performs the steps of the above method embodiments. The specific implementation and technical effects are similar, and are not described herein again.
In the several embodiments provided in the present application, it should be understood that the disclosed apparatus and method may be implemented in other ways. For example, the above-described apparatus embodiments are merely illustrative, and for example, a division of a unit is merely a logical division, and an actual implementation may have another division, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
Units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, or in a form of hardware plus a software functional unit.
The integrated unit implemented in the form of a software functional unit may be stored in a computer readable storage medium. The software functional unit is stored in a storage medium and includes several instructions to enable a computer device (which may be a personal computer, a server, or a network device) or a processor (processor) to execute some steps of the methods according to the embodiments of the present application. And the aforementioned storage medium includes: a U disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
It is noted that, in this document, relational terms such as "first" and "second," and the like, may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
The above description is only a preferred embodiment of the present application and is not intended to limit the present application, and various modifications and changes may be made by those skilled in the art. Any modification, equivalent replacement, improvement and the like made within the spirit and principle of the present application shall be included in the protection scope of the present application. It should be noted that: like reference numbers and letters refer to like items in the following figures, and thus, once an item is defined in one figure, it need not be further defined and explained in subsequent figures. The above description is only a preferred embodiment of the present application and is not intended to limit the present application, and various modifications and changes may be made by those skilled in the art. Any modification, equivalent replacement, improvement and the like made within the spirit and principle of the present application shall be included in the protection scope of the present application.

Claims (10)

1. A method for forwarding data, comprising:
the server receives a target data packet sent by a first terminal through a first data tunnel, wherein the target data packet comprises: the IP address of the first terminal and the IP address of the second terminal, wherein the first data tunnel is a data tunnel which is established by the server according to a first tunnel identifier and is between the server and the first terminal, the first tunnel identifier is a first terminal identifier, and the first terminal identifier is acquired by the server according to a tunnel establishment request sent by the first terminal;
the server sends a tunnel data forwarding table acquisition request to a data network DN according to the first terminal identifier, wherein the tunnel data forwarding table acquisition request comprises: a first terminal identifier and an IP address of a second terminal;
the server receives a data forwarding matching table entry returned by the data network DN, and forwards the target data packet to a second data tunnel corresponding to the IP address of the second terminal according to the data forwarding matching table entry, where the data forwarding matching table entry includes: and a second data tunnel identifier corresponding to the IP address of the second terminal, wherein the second data tunnel identifier is the second terminal identifier.
2. The method of claim 1, wherein the data network DN is configured to include: and the source tunnel identifier, other associated destination tunnel identifiers corresponding to the source tunnel identifier, and the mapping relationship between the IP addresses of the terminals corresponding to the other associated destination tunnel identifiers, wherein the source data tunnel indicated by the source tunnel identifier is configured to forward the data packet to the associated destination data tunnel indicated by the other associated destination tunnel identifiers.
3. The method of claim 1, further comprising:
the method comprises the following steps that a server receives a tunnel establishment request sent by a first terminal, wherein the tunnel establishment request comprises: an IP address of the first terminal;
and the server establishes a first data tunnel between the server and the first terminal according to the tunnel establishment request.
4. The method of claim 3, wherein the server establishes a first data tunnel between the server and the first terminal according to the tunnel establishment request, and comprising:
the server sends a terminal identifier acquisition request to a Session Management Function (SMF) through a network open function (NEF) according to the tunnel establishment request, wherein the terminal identifier acquisition request comprises: an IP address of the first terminal;
the server receives a first terminal identifier returned by the session management function SMF through a network open function NEF;
and the server establishes a first data tunnel between the server and the first terminal according to the first terminal identification.
5. The method according to any one of claims 1 to 4, wherein the second data tunnel identification corresponding to the IP address of the second terminal comprises: and the second data tunnel identifications corresponding to the IP addresses of the one or more second terminals.
6. A method for forwarding data, comprising:
the first terminal acquires a target data packet after the IP address changes, wherein the target data packet comprises: the IP address of the first terminal and the IP address of the second terminal;
the first terminal sends the target data packet to a server through a first data tunnel, where the first data tunnel is a data tunnel between the server and the first terminal, which is established by the server according to a first tunnel identifier, the first tunnel identifier is a first terminal identifier, and the first terminal identifier is obtained by the server according to a tunnel establishment request sent by the first terminal, so that the server requests a data network DN to obtain a data forwarding matching table according to the first terminal identifier, and forwards the target data packet to a second data tunnel corresponding to an IP address of the second terminal according to the data forwarding matching table, where the data forwarding matching table includes: and a second data tunnel identifier corresponding to the IP address of the second terminal, wherein the second data tunnel identifier is the second terminal identifier.
7. The method of claim 6, wherein the data network DN is configured to include: and the source tunnel identifier, other associated destination tunnel identifiers corresponding to the source tunnel identifier, and the mapping relationship between the IP addresses of the terminals corresponding to the other associated destination tunnel identifiers, wherein the source data tunnel indicated by the source tunnel identifier is configured to forward the data packet to the associated destination data tunnel indicated by the other associated destination tunnel identifiers.
8. The method of claim 6, further comprising:
the first terminal sends a tunnel establishment request to the server, wherein the tunnel establishment request comprises: and the IP address of the first terminal is used for enabling the server to establish a first data tunnel between the server and the first terminal according to the tunnel establishment request.
9. An electronic device, comprising: a processor, a storage medium and a bus, the storage medium storing machine-readable instructions executable by the processor, the processor and the storage medium communicating via the bus when the electronic device is operating, the processor executing the machine-readable instructions to perform the steps of the data forwarding method according to any one of claims 1 to 8.
10. A computer-readable storage medium, in which a computer program is stored which, when being executed by a processor, carries out the steps of the data forwarding method according to any one of claims 1 to 8.
CN202111139785.7A 2021-09-28 2021-09-28 Data forwarding method and device, electronic equipment and storage medium Active CN113595911B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111139785.7A CN113595911B (en) 2021-09-28 2021-09-28 Data forwarding method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111139785.7A CN113595911B (en) 2021-09-28 2021-09-28 Data forwarding method and device, electronic equipment and storage medium

Publications (2)

Publication Number Publication Date
CN113595911A CN113595911A (en) 2021-11-02
CN113595911B true CN113595911B (en) 2021-12-03

Family

ID=78242183

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111139785.7A Active CN113595911B (en) 2021-09-28 2021-09-28 Data forwarding method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN113595911B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114466322B (en) * 2022-02-15 2024-01-23 阿里巴巴(中国)有限公司 Communication method, system, device, storage medium and processor
CN114650197B (en) * 2022-03-31 2023-05-23 联想(北京)有限公司 Communication method, device, user plane network element and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101610447A (en) * 2008-06-20 2009-12-23 华为技术有限公司 The acquisition methods of tunnel identification information, sending method, equipment and system
CN106027356A (en) * 2016-07-04 2016-10-12 杭州迪普科技有限公司 Tunnel identifier conversion method and device
CN112995053A (en) * 2019-12-17 2021-06-18 华为技术有限公司 Method and device for sending message
CN113395214A (en) * 2021-08-18 2021-09-14 深圳艾灵网络有限公司 Industrial equipment networking method, electronic equipment and storage medium

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10666458B2 (en) * 2016-09-30 2020-05-26 Huawei Technologies Co., Ltd Method and apparatus for data transmission involving tunneling in wireless communication networks
US10397184B2 (en) * 2017-10-24 2019-08-27 Verizon Patent And Licensing Inc. Mobility management using identifier-locator addressing (ILA)

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101610447A (en) * 2008-06-20 2009-12-23 华为技术有限公司 The acquisition methods of tunnel identification information, sending method, equipment and system
CN106027356A (en) * 2016-07-04 2016-10-12 杭州迪普科技有限公司 Tunnel identifier conversion method and device
CN112995053A (en) * 2019-12-17 2021-06-18 华为技术有限公司 Method and device for sending message
CN113395214A (en) * 2021-08-18 2021-09-14 深圳艾灵网络有限公司 Industrial equipment networking method, electronic equipment and storage medium

Also Published As

Publication number Publication date
CN113595911A (en) 2021-11-02

Similar Documents

Publication Publication Date Title
US11864103B2 (en) Network slicing method and device, and storage medium
CN113395214B (en) Industrial equipment networking method, electronic equipment and storage medium
WO2023280121A1 (en) Method and apparatus for obtaining edge service
CN113260016B (en) Multi-mode terminal access control method and device, electronic equipment and storage medium
CN113207191B (en) Session establishment method, device and equipment based on network slice and storage medium
US11582820B2 (en) Techniques to extend a multiple access session and access traffic steering, switching, and splitting low-layer (ATSSS-LL) policies to an enterprise network
WO2020048469A1 (en) Communication method and apparatus
CN113382468B (en) Address allocation method for local network device, electronic device, and storage medium
CN106470465B (en) WIFI voice service initiating method, LTE communication equipment, terminal and communication system
CN113595911B (en) Data forwarding method and device, electronic equipment and storage medium
CN113038590B (en) Time synchronization method, electronic device, and storage medium
CN114980074B (en) Data communication method, device, equipment and medium based on virtual local area network
WO2023051430A1 (en) Communication method and apparatus
CN114885382B (en) Service session management method, device and storage medium
CN114465845B (en) Data communication method, device, equipment and storage medium based on field bus
CN115499894A (en) Network slice adjusting method, device and equipment
US11246011B1 (en) Cellular access of user-defined networks
WO2023051428A1 (en) Method and apparatus for information transmission
WO2023051431A1 (en) Communication method and apparatus
WO2023142717A1 (en) Method and apparatus for determining user equipment route selection policy
US20230397296A1 (en) Network-initiated group disconnect for wireless devices
WO2023160390A1 (en) Communication method and apparatus
WO2023051427A1 (en) Communication method and apparatus
WO2023133871A1 (en) Communication method and apparatus
CN116233953A (en) Data transmission method, device, equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant