WO2022041851A1 - 一种通信方法、装置、设备及系统 - Google Patents

一种通信方法、装置、设备及系统 Download PDF

Info

Publication number
WO2022041851A1
WO2022041851A1 PCT/CN2021/093719 CN2021093719W WO2022041851A1 WO 2022041851 A1 WO2022041851 A1 WO 2022041851A1 CN 2021093719 W CN2021093719 W CN 2021093719W WO 2022041851 A1 WO2022041851 A1 WO 2022041851A1
Authority
WO
WIPO (PCT)
Prior art keywords
overlay
gateway
server
client device
tunnel
Prior art date
Application number
PCT/CN2021/093719
Other languages
English (en)
French (fr)
Inventor
侯建强
Original Assignee
华为技术有限公司
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 华为技术有限公司 filed Critical 华为技术有限公司
Priority to EP21859696.3A priority Critical patent/EP4195599A4/en
Publication of WO2022041851A1 publication Critical patent/WO2022041851A1/zh
Priority to US18/176,229 priority patent/US20230208680A1/en

Links

Images

Classifications

    • 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/4604LAN interconnection over a backbone network, e.g. Internet, Frame Relay
    • 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
    • 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/42Loop networks
    • H04L12/437Ring fault isolation or reconfiguration
    • 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/4641Virtual LANs, VLANs, e.g. virtual private networks [VPN]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • 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
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W60/00Affiliation to network, e.g. registration; Terminating affiliation with the network, e.g. de-registration
    • 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/4604LAN interconnection over a backbone network, e.g. Internet, Frame Relay
    • H04L2012/4629LAN interconnection over a backbone network, e.g. Internet, Frame Relay using multilayer switching, e.g. layer 3 switching
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/06Management of faults, events, alarms or notifications
    • H04L41/0654Management of faults, events, alarms or notifications using network fault recovery
    • H04L41/0663Performing the actions predefined by failover planning, e.g. switching to standby network elements
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L61/00Network arrangements, protocols or services for addressing or naming
    • H04L61/09Mapping addresses
    • H04L61/25Mapping addresses of the same type
    • H04L61/2503Translation of Internet protocol [IP] addresses
    • H04L61/2514Translation of Internet protocol [IP] addresses between local and global IP addresses

Definitions

  • the present application relates to the field of communication technologies, and in particular, to a communication method, apparatus, device, and system.
  • SD-WAN Software-defined wide area network
  • SDN software-defined network
  • WAN wide area network
  • the actual deployment scenario of SD-WAN usually involves the scenario where the customer premise equipment (CPE) in SD-WAN registers and connects with the operator's server.
  • CPE customer premise equipment
  • IP Internet protocol
  • the CPE uses its corresponding WAN port Internet protocol (internet protocol, IP) address to access the server, and the server uses the IP address to demarcate the CPE.
  • IP Internet protocol
  • the CPE may not be able to use the same IP address to access the server uniformly, so that the server cannot calibrate the CPE based on the IP address.
  • the embodiments of the present application provide a communication method, apparatus, device, and system, which can solve the problem that the server cannot demarcate the CPE according to the IP address.
  • a communication method includes: a client device creates a loopback loopback interface in an overlay overlay virtual network instance, and configures an IP address for the loopback interface;
  • the overlay virtual network instance establishes a transmission channel to the server side; the client device uses the transmission channel to send a packet to the server side, where the packet at least includes the IP address.
  • the IP address used is the IP address of the loopback interface created in the overlay virtual network instance, and the IP address is used to register with the server, thereby This enables the server to identify the client device based on the IP address.
  • the client device establishes a transmission channel to the server side based on the overlay virtual network instance, including: the client device establishes an overlay tunnel from the overlay virtual network instance to the server side; and/ Or, the client device establishes an inner loop tunnel between the overlay virtual network instance and the virtual network instance that communicates with the server side.
  • the transmission channel that can be established by the client device includes an overlay transmission channel and/or an inner loop tunnel.
  • the overlay tunnel is established based on the overlay virtual network instance, and the packet transmission in the overlay tunnel is independent of the underlay virtual network.
  • the IP of the loopback interface can be encapsulated as the inner IP and the IP of the WAN port.
  • the address is encapsulated as the outer IP.
  • the inner IP address is the IP address of the loopback interface, so that the client device can use the IP address of the loopback interface to register with the server.
  • the inner loop tunnel is constructed based on the overlay virtual network instance and the underlay virtual network instance of the client device. When the client device registers with the server, it can send packets to the server through the established inner loop tunnel and WAN port.
  • the source address is the IP address of the loopback interface to register with the server through this IP address.
  • the client device when a gateway corresponding to the server exists on the server side, the client device establishes an overlay tunnel from the overlay virtual network instance to the server side, including: the client device establishing all The overlay tunnel from the overlay virtual network instance to the gateway corresponding to the server; the client device using the transmission channel to send a packet to the server side, including: the client device using the overlay tunnel to send a packet to the gateway message.
  • the overlay tunnel established by the client device is an overlay tunnel from the overlay virtual network instance to the gateway corresponding to the server, so as to send packets to the gateway corresponding to the server through the overlay tunnel , and then the gateway forwards the message to the server.
  • the client device when there are at least two servers on the server side, and each server corresponds to a different gateway, the client device establishes an overlay tunnel from the overlay virtual network instance to the gateway corresponding to the server , including: the client device establishes an overlay tunnel respectively based on the overlay virtual network instance and the gateways corresponding to each server; the client device uses the overlay tunnel to send packets to the gateway, including: the client The device sends a packet to the corresponding gateway by using at least one of the overlay tunnels.
  • the client device can establish an overlay tunnel to the gateway corresponding to each server based on the overlay virtual network instance, thereby obtaining multiple overlay tunnels .
  • the client device sends a packet to the server side, it can use one or more of the established overlay tunnels to send the packet to the corresponding gateway.
  • other overlay tunnels can be used to transmit packets to increase the fault tolerance mechanism.
  • the at least two servers include an active server and a standby server
  • the client device uses at least one of the overlay tunnels to send a packet to the corresponding gateway, including: the The client device sends a packet to the gateway corresponding to the main server by using the overlay tunnel established by the gateway corresponding to the main server, when the main server and/or the gateway corresponding to the main server fails, The client device sends a packet to the gateway corresponding to the standby server by using the overlay tunnel established by the gateway corresponding to the standby server.
  • an active server and a backup server can be configured, and the client device can preferentially use the overlay tunnel established by the gateway corresponding to the active server to send a message to the gateway corresponding to the active server.
  • the overlay tunnel established by the gateway corresponding to the standby server can be used to send packets to the gateway corresponding to the standby server, thereby improving the reliability of packet transmission.
  • the client device when a server corresponds to at least two gateways, the client device establishes an overlay tunnel from the overlay virtual network instance to the gateway corresponding to the server, including: the client device based on The overlay virtual network instance and each gateway corresponding to the server respectively establish an overlay tunnel; the client device uses the overlay tunnel to send a packet to the server, including: the client device uses the overlay tunnel to send packets to the server. At least one of them sends a message to the corresponding gateway.
  • the client device may establish an overlay tunnel based on the overlay virtual network instance and each gateway corresponding to the server. The client device can use one or more overlay tunnels to send packets to the corresponding gateway.
  • the at least two gateways include an active gateway and a standby gateway
  • the client device uses at least one of the overlay tunnels to send packets to the corresponding gateway, including: the client The terminal device uses the overlay tunnel established with the active gateway to send packets to the active gateway.
  • the client device uses the overlay tunnel established with the standby gateway to send packets to the active gateway.
  • the backup gateway sends the message.
  • an active gateway and a standby gateway may be configured, and the client device preferentially sends packets to the active gateway by using the overlay tunnel established with the active gateway.
  • the client device uses the overlay tunnel established with the standby gateway to send packets to the standby gateway.
  • each of the WAN ports has a corresponding underlay virtual network instance
  • the client device establishes the overlay virtual network instance to
  • the overlay tunnel of the gateway corresponding to the server includes: the client device uses each WAN port to establish an overlay tunnel with the gateway corresponding to the server based on the overlay virtual network instance; the client device uses the Sending the packet to the gateway through the overlay tunnel includes: the client device using at least one of the overlay tunnels to send the packet to the gateway.
  • an overlay tunnel may be established for each WAN port with a gateway corresponding to the server, so as to use the overlay tunnel to send packets to the gateway.
  • the client device when at least two WAN ports include an active WAN port and a standby WAN port, the client device sends a packet to the gateway by using the overlay tunnel, including: the client device Send packets to the gateway by using the overlay tunnel established between the active WAN port and the gateway.
  • the client device uses the standby WAN port to communicate with the gateway.
  • the overlay tunnel established by the gateway sends the message to the gateway.
  • a primary WAN port and a backup WAN port can be configured, and the client device can preferentially use the overlay tunnel established by the primary WAN port and the gateway to send packets to the gateway.
  • the client device can send packets to the gateway using the overlay tunnel established between the standby WAN port and the gateway.
  • the client device uses the overlay tunnel to Before the gateway sends the message, the method further includes: the client device encrypts the message to obtain the encrypted message.
  • the client device establishes an inner loop tunnel between the overlay virtual network instance and the virtual network instance that communicates with the server side, including: the client device and the underlay based on the overlay virtual network instance
  • the virtual network instance establishes an inner loop tunnel, the underlay virtual network instance is associated with the WAN port of the client device, and the WAN port communicates with the server through the underlay network;
  • the client uses the transmission channel to communicate with the server side
  • Sending the message includes: the client device sends the message to the server by using the inner loop tunnel and the underlay network.
  • the client device when the client device exists in the underlay virtual network instance that communicates with the server side, the client device can establish an inner loop tunnel based on the overlay virtual network instance and the underlay virtual network instance, so as to pass the inner loop tunnel and the underlay virtual network instance.
  • the network sends a message to the server.
  • the client device when the client device has at least two WAN ports and different WAN ports are bound to different underlay virtual network instances, the client device is based on the overlay virtual network instance and the The underlay virtual network instance establishes an inner loop tunnel, including: the client device establishes an inner loop tunnel based on the overlay virtual network instance and the underlay virtual network instance corresponding to each WAN port respectively; the client device uses the inner loop tunnel And sending the message from the underlay network to the server includes: the client device sends the message to the server by using at least one of the inner loop tunnels and the corresponding underlay network thereof.
  • the client device may establish an inner loop tunnel between the overlay virtual network instance and the underlay virtual network instance corresponding to the WAN port for each WAN port.
  • the client device can send packets to the server by using one or more inner-loop tunnels and the underlay network corresponding to the inner-loop tunnels.
  • the at least two WAN ports include an active WAN port and a standby WAN port
  • the inner ring tunnel established by the underlay virtual network instance corresponding to the active WAN port is the active inner ring tunnel
  • the inner ring tunnel established by the underlay virtual network instance corresponding to the standby WAN port is a standby inner ring tunnel
  • the client sends a message to the server by using at least one of the inner ring tunnels and its corresponding underlay network
  • the client device sends a message to the server by using the active inner ring tunnel and the underlay network corresponding to the active WAN port, and when the link of the active WAN port fails, the client device Send a message to the server by using the backup inner ring tunnel and the underlay network corresponding to the backup WAN port.
  • a primary WAN port and a backup WAN port may be configured, wherein the inner ring tunnel corresponding to the primary WAN port is the primary inner ring tunnel, and the backup WAN port corresponds to the primary inner ring tunnel.
  • the inner ring tunnel is the backup inner ring tunnel.
  • the client device preferentially uses the primary inner ring tunnel and the underlay network corresponding to the primary WAN port to send packets to the server. When the link of the primary WAN port fails, the client device will use the backup inner ring tunnel and the underlay network corresponding to the backup WAN port to send packets to the server.
  • the overlay tunnel is preferentially used to send packets to the server side. That is, the overlay tunnel has a higher priority than the inner ring tunnel.
  • the method further includes: switching the client device from the overlay tunnel to the inner loop tunnel.
  • the overlay virtual network instance is a service virtual network instance in the client device, the service virtual network instance is an overlay virtual network instance, or the overlay virtual network instance is the client The overlay virtual network instance newly created by the end device.
  • the overlay virtual network instance used may be an overlay virtual network instance existing on the client device itself, or a newly created overlay virtual network instance.
  • the packet further includes the IP address corresponding to the WAN port.
  • the IP address configured on the loopback interface is the public network IP address.
  • the IP address of the loopback interface can be directly configured as the public IP address address without network address translation.
  • a communication method includes: a gateway receives a packet sent by a client device, the packet includes an IP address of a loopback interface in the client device, and the The loopback interface is located in the overlay virtual network instance in the client device; the gateway parses the message to obtain the IP address, and sends the IP address to the server, so that the server can obtain the IP address according to the IP address.
  • the address identifies the client device.
  • the method further includes: decrypting the packet by the gateway.
  • a communication device is provided, and a creation unit is used to create a loopback interface in an overlay virtual network instance, and configure an IP address for the loopback interface;
  • the overlay virtual network instance establishes a transmission channel to the server side;
  • the sending unit is configured to use the transmission channel to send a message to the server side, where the message at least includes the IP address.
  • the establishment unit is specifically configured to establish an overlay tunnel from the overlay virtual network instance to the server side; and/or, in the overlay virtual network instance and the communication between the overlay virtual network instance and the server side Inner-loop tunnels are established between virtual network instances.
  • the establishing unit when a corresponding gateway exists on the server side, the establishing unit is specifically configured to establish an overlay tunnel from the overlay virtual network instance to the gateway corresponding to the server side;
  • the sending unit is specifically configured to send a packet to the gateway by using the overlay tunnel.
  • the establishing unit is specifically configured to respectively establish the gateway corresponding to each server based on the overlay virtual network instance overlay tunnel; the sending unit is specifically configured to use at least one of the overlay tunnels to send a packet to the corresponding gateway.
  • the sending unit is specifically configured to use an overlay tunnel established by a gateway corresponding to the active server to The gateway corresponding to the active server sends a packet
  • the client device uses the overlay tunnel established by the gateway corresponding to the standby server to The gateway corresponding to the standby server sends the packet.
  • the establishing unit is specifically configured to respectively establish an overlay tunnel based on the overlay virtual network instance and each gateway corresponding to the server; the sending The unit is specifically configured to use at least one of the overlay tunnels to send a packet to a corresponding gateway.
  • the at least two gateways include an active gateway and a standby gateway
  • the sending unit is specifically configured to send a message to the active gateway by using an overlay tunnel established with the active gateway.
  • the active gateway fails, use the overlay tunnel established with the standby gateway to send a packet to the standby gateway.
  • each of the WAN ports has a corresponding underlay virtual network instance
  • the establishment unit is specifically configured to be based on the overlay virtual network instance , using each WAN port to establish an overlay tunnel with the gateway corresponding to the server respectively;
  • the sending unit is specifically configured to use at least one of the overlay tunnels to send a packet to the gateway.
  • the sending unit is specifically configured to use the overlay tunnel established between the active WAN port and the gateway to send The gateway sends a message, and when the active WAN port fails, the gateway sends a message to the gateway by using the overlay tunnel established between the standby WAN port and the gateway.
  • the apparatus when the underlay network type corresponding to the WAN port of the client device is a preset network type, the apparatus further includes: an encryption unit, configured to use the overlay tunnel to send to the gateway Before the packet, encrypt the packet to obtain the encrypted packet.
  • an encryption unit configured to use the overlay tunnel to send to the gateway Before the packet, encrypt the packet to obtain the encrypted packet.
  • the establishing unit is specifically configured to establish an inner loop tunnel based on the overlay virtual network instance and the underlay virtual network instance, and the underlay virtual network instance is associated with the WAN port of the client device , the WAN port communicates with the server through the underlay network; the sending unit is specifically configured to send packets to the server by using the inner ring tunnel and the underlay network.
  • the establishment unit is specifically configured to based on the overlay virtual network
  • the network instance respectively establishes an inner loop tunnel with the underlay virtual network instance corresponding to each WAN port;
  • the sending unit is specifically configured to use at least one of the inner loop tunnels and its corresponding underlay network to send a message to the server.
  • the at least two WAN ports include an active WAN port and a standby WAN port
  • the inner ring tunnel established by the underlay virtual network instance corresponding to the active WAN port is the active inner ring tunnel
  • the inner ring tunnel established by the underlay virtual network instance corresponding to the backup WAN port is a backup inner ring tunnel
  • the sending unit is specifically used to utilize the primary inner ring tunnel and the corresponding underlay of the primary WAN port
  • the network sends a message to the server, and when the primary WAN port fails, the backup inner ring tunnel and the underlay network corresponding to the backup WAN port are used to send the message to the server.
  • the priority of the overlay tunnel is higher than that of the inner ring tunnel.
  • the apparatus when the gateway corresponding to the server side fails, the apparatus further includes: a switching unit, configured to switch from the overlay tunnel to the inner loop tunnel.
  • the overlay virtual network instance is a service virtual network instance in the communication device, the service virtual network instance is an overlay virtual network instance, or the overlay virtual network instance is the communication device The newly created overlay virtual network instance.
  • the packet further includes the IP address corresponding to the WAN port.
  • the IP address configured on the loopback interface is a public network IP address.
  • a communication apparatus in a fourth aspect of an embodiment of the present application, includes: a receiving unit configured to receive a packet sent by a client device, where the packet includes an IP address of a loopback interface in the client device address, the loopback interface is located in the overlay virtual network instance in the client device; a parsing unit is used to parse the message to obtain the IP address; a sending unit is used to send the IP address to A server so that the server identifies the client device based on the IP address.
  • the apparatus when the message is an encrypted message, the apparatus further includes: a decryption unit, configured to decrypt the message before parsing the message.
  • a communication device in a fifth aspect of an embodiment of the present application, includes: a processor and a memory; the memory is used to store instructions; the processor is used to execute the The instruction executes the method described in the first aspect.
  • a gateway in a sixth aspect of an embodiment of the present application, includes: a processor and a memory; the memory is used for storing instructions; the processor is used for executing the instructions in the memory , and execute the method described in the second aspect.
  • a communication system in a seventh aspect of the embodiment of the present application, includes: a client device and a server, the client device is configured to create a loopback interface in an overlay virtual network instance, and create a loopback interface for the loopback configuring an IP address on the interface; establishing a transmission channel to the server side based on the overlay virtual network instance; using the transmission channel to send a message to the server, where the message at least includes the IP address. ; the server is configured to identify the client device according to the IP address in the message.
  • the client device is specifically configured to establish an overlay tunnel from the overlay virtual network instance to the server side; and/or, the overlay virtual network instance and the server side communicate with each other. Inner-loop tunnels are established between virtual network instances.
  • the system further includes: a gateway, where the gateway communicates with the server, and the client device is specifically configured to establish a link between the overlay virtual network instance and the gateway corresponding to the server. overlay tunnel; using the overlay tunnel to send a message to the gateway; the gateway being configured to parse the message to obtain the IP address, and send the IP address to the server.
  • the system includes an active gateway and a standby gateway, both the active gateway and the standby gateway communicate with the server, and the client device is specifically configured to utilize and communicate with the server.
  • the overlay tunnel established by the active gateway sends a message to the active gateway, and when the active gateway fails, the overlay tunnel established with the standby gateway is used to send a message to the standby gateway.
  • the client device is specifically configured to establish an inner loop tunnel based on the overlay virtual network instance and the underlay virtual network instance, the underlay virtual network instance and the WAN port of the client device
  • the WAN port communicates with the server through the underlay network; the inner loop tunnel and the underlay network are used to send packets to the server.
  • the client device when the gateway corresponding to the server side fails, is further configured to switch from the overlay tunnel to the inner loop tunnel.
  • a computer-readable storage medium including instructions, which, when executed on a computer, cause the computer to execute the method described in the first aspect and/or the second aspect.
  • a loopback interface is established in the overlay virtual network instance, and an IP address is allocated to the loopback interface.
  • the client device establishes a transmission channel to the server side based on the overlay virtual network instance, and uses the transmission channel to send packets to the server side.
  • the message includes the IP address of the loopback interface, so that the IP address is used to register with the server, so that the server can identify the client device according to the IP address.
  • the transmission channel may include an overlay tunnel and/or an inner loop tunnel.
  • the overlay tunnel is established based on the overlay virtual network instance.
  • the packet transmission in the overlay tunnel is independent of the underlay virtual network.
  • the IP of the loopback interface can be encapsulated as the inner IP
  • the IP address of the WAN port can be encapsulated is the outer IP.
  • the inner IP address is the IP address of the loopback interface, so that the client device can use the IP address of the loopback interface to register with the server.
  • the inner loop tunnel is constructed based on the overlay virtual network instance and the underlay virtual network instance of the client device.
  • the client device When the client device registers with the server, it can send packets to the server through the established inner loop tunnel and WAN port.
  • the source address is the IP address of the loopback interface to register with the server through this IP address.
  • an inner loop tunnel can be established for each WAN port corresponding to the underlay virtual network instance, no matter which inner loop tunnel is used to communicate to the server.
  • the source addresses of the sent packets are the IP addresses of the loopback interfaces in the overlay virtual network instance, so that the client device can use the same IP address to register with the server, so that the server can uniquely identify the client device.
  • Figure 1 is a schematic diagram of a traditional registration scenario
  • FIG. 3 is a flowchart of another communication method provided by an embodiment of the present application.
  • FIG. 4a is a schematic diagram of establishing an overlay tunnel according to an embodiment of the present application.
  • FIG. 4b is another schematic diagram of establishing an overlay tunnel according to an embodiment of the present application.
  • FIG. 4c is another schematic diagram of establishing an overlay tunnel according to an embodiment of the present application.
  • FIG. 4d is still another schematic diagram of establishing an overlay tunnel according to an embodiment of the present application.
  • FIG. 4e is another schematic diagram of establishing an overlay tunnel according to an embodiment of the present application.
  • FIG. 5 is a flowchart of another communication method provided by an embodiment of the present application.
  • 6a is a schematic diagram of establishing an inner ring tunnel according to an embodiment of the present application.
  • FIG. 6b is another schematic diagram of establishing an inner ring tunnel according to an embodiment of the present application.
  • FIG. 6c is another schematic diagram of establishing an inner ring tunnel according to an embodiment of the present application.
  • FIG. 6d is still another schematic diagram of establishing an inner ring tunnel according to an embodiment of the present application.
  • FIG. 7 is a structural diagram of a communication device provided by an embodiment of the present application.
  • FIG. 8 is a structural diagram of another communication device provided by an embodiment of the present application.
  • FIG. 9 is a structural diagram of a communication system provided by an embodiment of the present application.
  • FIG. 10 is a structural diagram of a communication device provided by an embodiment of the present application.
  • the CPE can also create a loopback interface in the underlying virtual network VPN instance and use the IP address corresponding to the loopback interface for registration.
  • a loopback interface 1 is created in the underlay VPN1
  • the IP address corresponding to the loopback interface 1 is used to register with the server through the WAN port 1. That is, it is possible to register with the server through the link formed by the WAN port 1-underlay network 1.
  • the loopback interface corresponds to only one underlay virtual network instance. In this case, when the WAN port 1 fails, the CPE will switch the WAN port 2 to use the IP address of the loopback interface 2 in the underlay virtual network instance corresponding to the WAN port 2 for registration.
  • the server cannot uniquely identify the CPE.
  • NAT network address translation
  • the embodiment of the present application provides a communication method, which is used to solve the problem that the server cannot identify due to the switching of the source IP address when the CPE registers with the server.
  • the underlying network is the network of the current data center network basic forwarding architecture. As long as any two points on the data center network are reachable, it refers to the physical base layer.
  • overlay network refers to a virtualization technology model that is superimposed on the network architecture. It can be separated from other network services, and it is mainly based on the basic network technology based on IP.
  • An overlay network is a virtual network built on an underlay network. The nodes of the overlay network communicate through virtual or logical links, and each virtual or logical link corresponds to a path (Path) of the underlay network, which is composed of multiple consecutive links. It should be noted that the overlay network and the underlay network are independent of each other.
  • the overlay network uses the underlay network to transmit messages peer-to-peer, and how the message is transmitted to the destination node of the overlay network depends entirely on the underlay network. In the control plane and data plane, the processing (such as discarding and forwarding) of packets in the Ingress and Egress nodes of the overlay network is completely determined by the encapsulation protocol of the overlay network.
  • the loopback interface is a pure software virtual interface. After the loopback interface is created, the state of the physical layer and the protocol of the link layer are always in the up state.
  • the loopback interface can be configured with an IP address. To save IP addresses, the system automatically configures a 32-bit subnet mask for the IP address of the loopback interface. Set the loopback interface address as the source address of all ip packets generated by the device. Because the loopback interface address is stable and is a unicast address, the loopback interface address is usually regarded as the sign of the device, and it is allowed to be set on authentication or security servers.
  • FIG. 2 is a flowchart of a communication method provided by an embodiment of the present application, as shown in FIG. 2 , the method may include:
  • the client device creates a loopback interface in the overlay virtual network instance, and configures an IP address for the loopback interface.
  • a loopback interface may be created in the overlay virtual network instance, and an IP address may be configured for the loopback interface.
  • the overlay virtual network instance for creating the loopback interface may be an existing overlay virtual network instance in the client device used for mutual service access, that is, the overlay virtual network instance associated with the LAN port. At the same time, it can also be a newly created overlay virtual network instance, which is independent of the overlay virtual network instance associated with the LAN port.
  • S202 The client device establishes a transmission channel to the server side based on the overlay virtual network instance.
  • the client device may establish a transmission channel to the server side based on the overlay virtual network instance.
  • the transmission channel may include an overlay tunnel and/or an inner loop tunnel.
  • the overlay tunnel refers to a tunnel established by an overlay virtual network instance between two different devices.
  • the client device may establish an overlay tunnel from the overlay virtual network instance to the server side.
  • the two different devices may be two different CPEs, and each CPE is deployed at a different SD-WAN site; or, one is a CPE and the other is a server.
  • the inner loop tunnel refers to the tunnel established between the overlay virtual network instance and the underlay virtual network instance of the same device. That is, the client device establishes an inner loop tunnel on the overlay virtual network instance and the virtual network instance communicating with the server side. The establishment of the overlay tunnel and/or the inner ring tunnel will be described in subsequent embodiments.
  • S203 The client device sends a packet to the server side by using the transmission channel.
  • the client device when the client device establishes a transmission channel to the server side, it can use the transmission to lead to the service
  • the server side sends a packet, and the packet may include the IP address of the loopback interface, so that the server can identify the client device according to the IP address.
  • the client device may use the overlay tunnel and/or the inner loop tunnel to send a packet to the server, where the packet includes the IP address of the loopback interface.
  • the client device When the client device only has an overlay tunnel or an inner-loop tunnel, the client device sends a packet to the server by using the overlay tunnel or the inner-loop tunnel to register with the server through the IP address in the packet.
  • the client device When the client device includes both the overlay tunnel and the inner-loop tunnel, it can select the overlay tunnel or the inner-loop tunnel to send a packet to the server according to actual requirements, so as to use the IP address in the packet for registration.
  • the priority of the overlay tunnel is higher than that of the inner ring tunnel, and the CPE preferentially uses the overlay tunnel to send packets to the server.
  • the client device whether the client device sends a message to the server for registration by using the overlay tunnel or the inner loop tunnel, it all uses the IP address of the loopback interface established in the overlay virtual network instance as the message
  • the source address of the WAN port is no longer used for registration, and the IP address of the loopback interface in the underlay virtual network instance corresponding to the WAN port is no longer used for registration.
  • the client device can establish an overlay tunnel and/or an inner loop tunnel to send messages to the server.
  • the client device can establish an overlay tunnel and/or an inner loop tunnel to send messages to the server.
  • the following will describe how to establish an overlay tunnel and an inner loop tunnel to send messages to the server with reference to the accompanying drawings. illustrate.
  • FIG. 3 is a flowchart of an implementation of constructing an overlay tunnel according to an embodiment of the present application. As shown in FIG. 3 , the method may include:
  • the client device establishes an overlay tunnel from the overlay virtual network instance to the gateway corresponding to the server.
  • the client when the server has a corresponding gateway, the client establishes an overlay tunnel based on its own overlay virtual network instance and the overlay virtual network instance on the gateway.
  • the overlay virtual network instance of the client device itself may be a service virtual network instance currently existing on the client device, and the service virtual network instance is an overlay virtual network instance.
  • the client device creates a loopback interface in the service overlay virtual network instance associated with the LAN port, and configures an IP address for the loopback interface.
  • an overlay tunnel is established with the gateway.
  • the overlay virtual network instance of the client device itself may also be a newly created overlay virtual network instance, which is independent of the service overlay virtual network instance.
  • an overlay virtual network instance is newly created, a loopback interface is created in the overlay virtual network instance, an IP address is configured for the loopback interface, and an overlay tunnel is established with the gateway based on the overlay virtual network instance.
  • S302 The client device sends a packet to the gateway by using the overlay tunnel.
  • the client device can use the overlay tunnel to send a packet to the gateway, where the packet includes the IP address of the loopback interface, so as to use the IP address to register with the server.
  • the gateway parses the packet to obtain the IP address in the packet, and sends the IP address to the server, so that the server can uniquely identify the client device according to the IP address.
  • the client device when it establishes the overlay tunnel, it can also determine whether to encrypt the packets passing through the overlay tunnel according to the type of the underlay network corresponding to the WAN port, so as to avoid arbitrary interception by a third party.
  • the underlay network type corresponding to the WAN port may be multi-protocol Label Switching (MPLS), internet and other types.
  • MPLS multi-protocol Label Switching
  • the client device when the client sends a packet to the gateway using the overlay tunnel, the client device encrypts the packet, obtains the encrypted packet, and sends the encrypted packet to the gateway. The message is sent to the gateway.
  • the encryption key used by the client device to encrypt the message can be negotiated with the gateway in advance, so that when the gateway receives the encrypted message, it can decrypt the message according to the negotiated key to obtain plaintext.
  • the gateway device then parses the decrypted message to obtain an IP address, so as to send the IP address to the server. For example, when the underlying network type is the internet network, after the client device generates a packet, it encrypts the packet to send the encrypted packet to the gateway.
  • the packet when the client device sends a packet to the gateway using the overlay tunnel, the packet may further include the IP address corresponding to the WAN port.
  • the packet when the client device uses the overlay tunnel to send a packet, the packet is encapsulated using an encapsulation protocol, and the IP address of the loopback interface is used as the inner layer address, and the IP address of the WAN port is used as the outer layer address.
  • the gateway decapsulates the packet to obtain the inner IP address, and sends the inner IP address to the server, so that the server can identify the client device through the inner IP address.
  • the client device can establish an overlay tunnel based on the gateway corresponding to each server, thereby Obtain multiple overlay tunnels so that when one of the overlay tunnels fails, the other overlay tunnel can be used for packet transmission.
  • the client device establishes overlay tunnels respectively based on the overlay virtual network instance and the gateways corresponding to each server; the client device uses at least one tunnel in the established overlay tunnels to send packets to the corresponding gateway.
  • the following description takes the existence of two servers as an example, specifically:
  • the client device establishes an overlay tunnel based on the overlay virtual network instance and the gateway corresponding to the first server.
  • the client device establishes an overlay tunnel based on the overlay virtual network instance and the gateway corresponding to the first server.
  • the client device uses the overlay tunnel of the gateway corresponding to the first server to send a message to the gateway corresponding to the first server or uses the overlay tunnel of the gateway corresponding to the second server to send a message to the gateway corresponding to the second server.
  • the client device may establish an overlay tunnel based on the gateway corresponding to each server, so as to use one or more overlay tunnels to send packets to the gateway corresponding to the overlay tunnel.
  • the situation that multiple servers exist on the server side involved in the embodiments of the present invention refers to the situation that there are multiple servers that can implement the embodiments of the present invention on the server side.
  • an active server and a backup server can be configured, and the client device can use the overlay tunnel established by the gateway corresponding to the active server to the gateway corresponding to the active server.
  • Sending packets when the active server and/or the gateway corresponding to the active server fails, the client device can use the overlay tunnel of the gateway corresponding to the standby server to send the packet to the gateway corresponding to the standby server.
  • the client device when one server corresponds to at least two gateways, the client device can establish an overlay tunnel for each gateway, thereby obtaining multiple overlay tunnels, so that when one of the overlay tunnels fails, the client device can utilize Another overlay tunnel is used for packet transmission. Specifically, the client device establishes overlay tunnels respectively based on the overlay virtual network instance and each gateway corresponding to the server; the client device uses at least one of the established overlay tunnels to send packets to the corresponding gateway.
  • the server corresponds to the first gateway and the second gateway, and specifically includes:
  • the client device establishes a first overlay tunnel with the first gateway based on the overlay virtual network instance.
  • the client device establishes a second overlay tunnel with the second gateway based on the overlay virtual network instance.
  • the client device sends a packet to the first gateway using the first overlay tunnel, and/or sends a packet to the second gateway using the second overlay tunnel.
  • the client device may establish an overlay tunnel based on each gateway, so as to use one or more overlay tunnels to send packets to the gateway corresponding to the overlay tunnel.
  • the active gateway and the standby gateway may be pre-configured, and the client device sends packets to the active gateway using the overlay tunnel established with the active gateway.
  • the client device can use the overlay tunnel established with the standby gateway to send packets to the standby gateway.
  • the above embodiments illustrate that when there are multiple servers or multiple gateways on the server side, multiple overlay tunnels can be established to increase the fault tolerance mechanism.
  • the client device has multiple WAN ports, different overlay tunnels can be established based on different WAN ports.
  • the client device uses each WAN port to establish an overlay tunnel with the gateway corresponding to the server based on the overlay virtual network instance; the client device sends a packet to the gateway by using at least one of the established overlay tunnels.
  • the client device has two WAN ports, and the client device establishes different tunnels based on the overlay virtual network instance and different WAN ports. Specifically:
  • the client device uses the first WAN port and the gateway corresponding to the server to establish a third overlay tunnel.
  • the client device uses the second WAN port to establish a fourth overlay tunnel with the gateway corresponding to the server.
  • the client device sends a packet to the gateway using the third overlay tunnel and/or the fourth overlay tunnel.
  • multiple overlay tunnels may be established through different WAN ports, so as to use one or more overlay tunnels to send packets to the gateway corresponding to the overlay tunnel.
  • different WAN ports can correspond to the same underlay network, or can correspond to different underlay networks. As shown in Figure 4e, the first WAN port corresponds to the underlay network 1, and the second WAN port corresponds to the underlay network 2.
  • the primary WAN port and the backup WAN port can be pre-configured, and the client device preferentially uses the overlay tunnel established by the primary WAN port and the gateway to send data to the gateway.
  • the link of the main WAN port fails, the client device can send the packet to the gateway through the overlay tunnel established by the backup WAN port and the gateway, which improves the efficiency of packet transmission and increases the fault tolerance of the client device.
  • the link failure of the WAN port may include a link failure caused by a failure of the WAN port, or may be a link failure between the WAN port of the client device and the WAN port of the gateway.
  • the above embodiment describes the specific implementation of establishing an overlay tunnel between the client device and the gateway of the server and using the overlay tunnel to send messages.
  • the following describes the implementation of establishing an inner loop tunnel for the client device and using the inner loop tunnel to send messages in conjunction with the accompanying drawings.
  • FIG. 5 is a flowchart of an implementation of establishing an inner ring tunnel provided by an embodiment of the present application. As shown in FIG. 5 , the method may include:
  • the client device establishes an inner loop tunnel based on the overlay virtual network instance and the underlay virtual network instance.
  • an inner loop tunnel is established between the two virtual network instances.
  • the underlay virtual network instance is associated with the WAN port of the client device, and the WAN port communicates with the server through the underlay network.
  • the overlay virtual network instance corresponding to the client device itself may be a service virtual network instance currently existing on the client device, and the service virtual network instance is an overlay virtual network instance.
  • a loopback interface is created in the service overlay virtual network instance associated with the LAN port, and an IP address is configured for the loopback interface.
  • An inner loop tunnel is established based on the service overlay virtual network instance and the underlay virtual network instance associated with the WAN port.
  • the overlay virtual network instance corresponding to the client device itself may be a newly created overlay virtual network instance, which is independent of the service overlay virtual network instance.
  • the CPE newly creates an overlay virtual network instance, creates a loopback interface in the overlay virtual network instance, and configures an IP address for the loopback interface.
  • S502 The client device sends a packet to the server by using the inner loop tunnel and the underlay network.
  • the inner loop tunnel and the underlay network corresponding to the WAN port can be used to send packets to the server.
  • the client device when the client device has multiple WAN ports, if the multiple WAN ports correspond to the same underlay virtual network instance, the client device establishes an internal virtual network instance based on the overlay virtual network instance and the underlay virtual network instance. Ring Tunnel. If multiple WAN ports are associated with different underlay virtual network instances, the client device can establish an inner loop tunnel based on the overlay virtual network and the underlay virtual network associated with each WAN port, thereby obtaining multiple inner loop tunnels and implementing a fault tolerance mechanism. Specifically, the client device establishes an inner loop tunnel with the underlay virtual network instance corresponding to each WAN port based on the overlay virtual network instance; the client device uses at least one of the established inner loop tunnels and its corresponding underlay network to send a message to the server message. As shown in Figure 6c, when the client device includes a first WAN port and a second WAN port, the first WAN port corresponds to the underlay virtual network instance virtual network instance 1, and the second WAN port corresponds to the underlay virtual network instance 2.
  • the client device has multiple WAN ports and the multiple WAN ports are associated with different underlay virtual network instances, the specific implementation of establishing an inner-loop tunnel and using the inner-loop tunnel to send packets:
  • the client device establishes a first inner loop tunnel based on the overlay virtual network instance and the underlay virtual network instance corresponding to the first WAN port.
  • the client device establishes a first inner loop tunnel with the underlay virtual network instance 1 based on the overlay virtual network instance.
  • the client device establishes a second inner loop tunnel based on the overlay virtual network instance and the underlay virtual network instance corresponding to the second WAN port.
  • the client device establishes a second inner loop tunnel with the underlay virtual network instance 2 based on the overlay virtual network instance.
  • the client device uses the first inner ring tunnel and the underlay network corresponding to the first WAN port to send packets to the server, and/or uses the second inner ring tunnel and the underlay network corresponding to the second WAN port to send packets to the server.
  • each WAN port can correspond to the same underlay network, and can also correspond to different underlay networks.
  • the first WAN port corresponds to the underlay network 1
  • the second WAN port corresponds to the underlay network 2.
  • the primary WAN port and the backup WAN port can be configured, so that when the link of the primary WAN port fails, the link of the backup WAN port can be configured Perform packet transmission to ensure the quality of packet transmission.
  • the inner ring tunnel established by the underlay virtual network instance corresponding to the main WAN port is the main inner ring tunnel
  • the inner ring tunnel established by the underlay virtual network instance corresponding to the standby WAN port is the backup inner ring tunnel.
  • the client device can preferentially use the main inner ring tunnel and the underlay network corresponding to the main WAN port to send packets to the server.
  • the client device can use the backup inner ring tunnel and the underlay network corresponding to the backup WAN port to send packets to the server.
  • the link failure of the WAN port may include the link failure caused by the failure of the WAN port, or the link failure between the WAN port of the client device and the WAN port of the gateway.
  • the IP address of the loopback interface can be configured directly. It is the public IP address, so as to avoid the IP address of the loopback interface being translated due to NAT mapping, so that the client device can use the IP address of the loopback interface to register the server.
  • the above embodiments respectively describe the specific implementation of the client device establishing the overlay tunnel and the inner loop tunnel based on the overlay virtual network instance, and using the overlay tunnel and the inner loop tunnel to send packets to the server.
  • the overlay tunnel may be set to use a higher priority than the inner-loop tunnel. That is, the overlay tunnel may be used as the primary path, and the inner ring tunnel may be used as the backup path.
  • the CPE of the client device uses the WAN port to establish an overlay tunnel with the gateway, and the CPE establishes an inner loop tunnel based on the overlay virtual network instance and the underlay virtual network instance corresponding to the WAN port.
  • the overlay tunnel cannot be used to send packets to the gateway, and the client device can switch from the overlay tunnel to the inner loop tunnel, and use the inner loop tunnel and the underlay network to send packets to the server. message, so that the server can identify the client device according to the IP address in the message.
  • the embodiments of the present application further provide a communication device, which will be described below with reference to the accompanying drawings.
  • FIG. 7 is a structural diagram of a communication apparatus provided by an embodiment of the present application
  • the apparatus 700 can be applied to a client device to perform the functions of the client device in the embodiments shown in FIGS. 2-6 , which may include:
  • the creating unit 701 is configured to create a loopback interface in the overlay virtual network instance, and configure an IP address for the loopback interface.
  • the creating unit 701 reference may be made to the detailed description of S201 in the embodiment shown in FIG. 2 .
  • the establishing unit 702 is configured to establish a transmission channel to the server side based on the overlay virtual network instance.
  • the establishing unit 702 reference may be made to the detailed description of S202 in the embodiment shown in FIG. 2 , or the detailed description of S301 in the embodiment shown in FIG. 3 , or the detailed description of S501 in the embodiment shown in FIG. 5 .
  • the sending unit 703 is configured to use the transmission channel to send a packet to the server side, where the packet at least includes the IP address.
  • the sending unit 703 refer to the detailed description of S203 in the embodiment shown in FIG. 2 , or the detailed description of S302 in the embodiment shown in FIG. 3 , or the detailed description of S502 in the embodiment shown in FIG. 5 .
  • the establishment unit is specifically configured to establish an overlay tunnel from the overlay virtual network instance to the server side; and/or, in the overlay virtual network instance and the communication between the overlay virtual network instance and the server side Inner-loop tunnels are established between virtual network instances.
  • establishing the overlay tunnel refer to the detailed description of S301 in the embodiment shown in FIG. 3
  • establishing the inner loop tunnel refer to the detailed description of S501 in the embodiment shown in FIG. 5 .
  • the establishing unit when a corresponding gateway exists on the server side, the establishing unit is specifically configured to establish an overlay tunnel from the overlay virtual network instance to the gateway corresponding to the server side;
  • the sending unit is specifically configured to send a packet to the gateway by using the overlay tunnel.
  • the establishing unit is specifically configured to separately establish the gateway corresponding to each server based on the overlay virtual network instance overlay tunnel;
  • the sending unit is specifically configured to send a packet to the corresponding gateway by using at least one of the overlay tunnels.
  • the specific implementation of the establishing unit 702 and the sending unit 703 may refer to the detailed description of S302 in the embodiment shown in FIG. 3 .
  • the sending unit is specifically configured to use an overlay tunnel established by a gateway corresponding to the active server to The gateway corresponding to the active server sends a packet
  • the client device uses the overlay tunnel established by the gateway corresponding to the standby server to The gateway corresponding to the standby server sends the packet.
  • the establishing unit is specifically configured to respectively establish an overlay tunnel based on the overlay virtual network instance and each gateway corresponding to the server.
  • the sending unit is specifically configured to use at least one of the overlay tunnels to send a packet to a corresponding gateway.
  • the specific implementation of the establishing unit 702 may refer to the detailed description of S302 in the embodiment shown in FIG. 3 .
  • the at least two gateways include an active gateway and a standby gateway
  • the sending unit is specifically configured to send a message to the active gateway by using an overlay tunnel established with the active gateway.
  • the active gateway fails, use the overlay tunnel established with the standby gateway to send a packet to the standby gateway.
  • each of the WAN ports has a corresponding underlay virtual network instance
  • the establishment unit is specifically configured to be based on the overlay virtual network instance , using each WAN port to establish an overlay tunnel with the gateway corresponding to the server respectively;
  • the sending unit is specifically configured to send a packet to the gateway by using at least one of the overlay tunnels.
  • the specific implementation of the establishing unit 702 and the sending unit 703 may refer to the detailed description of S302 in FIG. 3 .
  • the sending unit is specifically configured to use the overlay tunnel established between the active WAN port and the gateway to send The gateway sends a message, and when the active WAN port fails, the gateway sends a message to the gateway by using the overlay tunnel established between the standby WAN port and the gateway.
  • the apparatus when the underlay network type corresponding to the WAN port of the client device is a preset network type, the apparatus further includes:
  • An encryption unit configured to encrypt the packet before sending the packet to the gateway by using the overlay tunnel to obtain the encrypted packet.
  • the establishment unit is specifically configured to establish an inner loop tunnel based on the overlay virtual network instance and the underlay virtual network instance, the underlay virtual network instance and the client device
  • the WAN port is associated with the WAN port, and the WAN port communicates with the server through the underlay network;
  • the sending unit is specifically configured to send a message to the server by using the inner ring tunnel and the underlay network.
  • the establishment unit is specifically configured to based on the overlay virtual network
  • the network instance establishes an inner loop tunnel with the underlay virtual network instance corresponding to each WAN port respectively;
  • the sending unit is specifically configured to send a message to the server by using at least one of the inner ring tunnels and its corresponding underlay network.
  • the specific implementation of the establishing unit 702 and the sending unit 703 may refer to the detailed description of S502 in the embodiment shown in FIG. 5 .
  • the at least two WAN ports include an active WAN port and a standby WAN port
  • the inner ring tunnel established by the underlay virtual network instance corresponding to the active WAN port is the active inner ring tunnel
  • the inner ring tunnel established by the underlay virtual network instance corresponding to the backup WAN port is a backup inner ring tunnel
  • the sending unit is specifically used to utilize the primary inner ring tunnel and the corresponding underlay of the primary WAN port
  • the network sends a message to the server, and when the primary WAN port fails, the backup inner ring tunnel and the underlay network corresponding to the backup WAN port are used to send the message to the server.
  • the priority of the overlay tunnel is higher than that of the inner ring tunnel.
  • the apparatus when the gateway corresponding to the server side fails, the apparatus further includes:
  • a switching unit configured to switch from the overlay tunnel to the inner loop tunnel.
  • the overlay virtual network instance is a service virtual network instance in the communication device, the service virtual network instance is an overlay virtual network instance, or the overlay virtual network instance is the communication device The newly created overlay virtual network instance.
  • the packet further includes the IP address corresponding to the WAN port.
  • the IP address configured on the loopback interface is a public network IP address.
  • FIG. 8 this figure is another communication apparatus provided by an embodiment of the present application.
  • the apparatus 800 can be applied to a gateway to perform the functions of the gateway in the embodiments shown in FIGS. 2 to 6 .
  • the apparatus includes:
  • a receiving unit 801 configured to receive a packet sent by a client device, where the packet includes an IP address of a loopback interface in the client device, and the loopback interface is located in the overlay virtual network instance in the client device middle.
  • the specific implementation of the receiving unit 801 may refer to the detailed description of S203 in the embodiment shown in FIG. 2 or the detailed description of S302 in the embodiment shown in FIG. 3 .
  • a parsing unit 802 configured to parse the packet to obtain the IP address.
  • the parsing unit 802 reference may be made to the detailed description of S302 in the embodiment shown in FIG. 3 .
  • a sending unit 803, configured to send the IP address to a server, so that the server identifies the client device according to the IP address.
  • the sending unit 803 reference may be made to the detailed description of S302 in the embodiment shown in FIG. 3 .
  • the device when the message is an encrypted message, the device further includes:
  • a decryption unit configured to decrypt the packet before parsing the packet.
  • FIG. 9 is a structural diagram of a communication system provided by an embodiment of the present application, as shown in FIG. 9 , the system may include a client device 901 and a server 902;
  • the client device 901 is configured to create a loopback interface in the overlay virtual network instance, and configure an IP address for the loopback interface; establish a transmission channel to the server side based on the overlay virtual network instance; use the transmission channel to The server sends a message, and the message includes at least the IP address.
  • the specific implementation of the client device 901 may refer to the detailed descriptions of S201-S203 in the embodiment shown in FIG. 2 , or the detailed descriptions of S301 and S302 in the embodiment shown in FIG. 3 , or the detailed description of S501 in the embodiment shown in FIG. 5 . and detailed description of S502.
  • the server 902 is configured to identify the client device according to the IP address in the packet.
  • the specific implementation of the server 902 may refer to the detailed description of S203 in the embodiment shown in FIG. 2 , or the detailed description of S302 in the embodiment shown in FIG. 3 , or the detailed description of S502 in the embodiment shown in FIG. 5 .
  • the client device is specifically configured to establish an overlay tunnel from the overlay virtual network instance to the server side; and/or, a virtual network communicated between the overlay virtual network instance and the server side.
  • An inner loop tunnel is established between network instances.
  • the system further includes: a gateway, where the gateway communicates with the server, and the client device is specifically configured to establish an overlay from the overlay virtual network instance to the gateway corresponding to the server. tunnel; use the overlay tunnel to send a message to the gateway;
  • the gateway is configured to parse the message to obtain the IP address, and send the IP address to the server.
  • the system includes an active gateway and a standby gateway, and both the active gateway and the standby gateway communicate with the server, and the client device is specifically configured to utilize and communicate with the main gateway. Send a message to the active gateway by using the overlay tunnel established by the gateway, and send a message to the standby gateway by using the overlay tunnel established with the standby gateway when the active gateway fails.
  • the specific implementation of the client device may refer to the detailed description of S302 in the embodiment shown in FIG. 3 .
  • the client device is specifically configured to establish an inner loop tunnel based on the overlay virtual network instance and the underlay virtual network instance, and the underlay virtual network instance is associated with the WAN port of the client device.
  • the WAN port communicates with the server through the underlay network; the inner ring tunnel and the underlay network are used to send packets to the server.
  • the client device when the gateway corresponding to the server side fails, is further configured to switch from the overlay tunnel to the inner ring tunnel.
  • FIG. 10 is a schematic structural diagram of a communication device provided by an embodiment of the application, and the communication device may be, for example, a client device or a gateway device in the embodiments shown in FIG. 2 to FIG. 6 , or may also be FIG. 7 or FIG. 8 . Device implementation of the communication apparatus in the illustrated embodiment.
  • the network device 1000 includes: a processor 1010 , a communication interface 1020 and a memory 1030 .
  • the number of processors 1010 in the packet forwarding device 1000 may be one or more, and one processor is taken as an example in FIG. 10 .
  • the processor 1010 , the communication interface 1020 , and the memory 1030 may be connected through a bus system or other manners, wherein the connection through the bus system 1040 is taken as an example in FIG. 10 .
  • Processor 1010 may be a CPU, NP, or a combination of CPU and NP.
  • the processor 1010 may further include a hardware chip.
  • the above-mentioned hardware chip may be an application-specific integrated circuit (ASIC), a programmable logic device (PLD) or a combination thereof.
  • the above-mentioned PLD may be a complex programmable logic device (CPLD), a field-programmable gate array (FPGA), a general-purpose array logic (generic array logic, GAL) or any combination thereof.
  • the communication interface 1020 is used for receiving and sending messages.
  • the communication interface 1020 may include a receiving interface and a sending interface.
  • the receiving interface may be used to receive packets, and the sending interface may be used to send packets.
  • the number of communication interfaces 1020 may be one or more.
  • the memory 1030 may include a volatile memory (English: volatile memory), such as random-access memory (RAM); the memory 1030 may also include a non-volatile memory (English: non-volatile memory), such as a fast A flash memory (English: flash memory), a hard disk drive (HDD) or a solid-state drive (SSD); the memory 1030 may also include a combination of the above-mentioned types of memory.
  • volatile memory such as random-access memory (RAM)
  • non-volatile memory such as a fast A flash memory (English: flash memory), a hard disk drive (HDD) or a solid-state drive (SSD)
  • SSD solid-state drive
  • the memory 1030 stores an operating system and programs, executable modules or data structures, or their subsets, or their extended sets, wherein the programs may include various operation instructions for implementing various operations.
  • the operating system may include various system programs for implementing various basic services and handling hardware-based tasks.
  • the processor 1010 may read the program in the memory 1030 to implement the communication transmission method provided by the embodiment of the present application.
  • the memory 1030 may be a storage device in the communication device 1000 , or may be a storage device independent of the communication device 1000 .
  • the bus system 1040 may be a peripheral component interconnect (PCI) bus or an extended industry standard architecture (EISA) bus or the like.
  • PCI peripheral component interconnect
  • EISA extended industry standard architecture
  • the bus system 1040 can be divided into an address bus, a data bus, a control bus, and the like. For ease of presentation, only one thick line is used in FIG. 10, but it does not mean that there is only one bus or one type of bus.
  • an embodiment of the present application further provides a gateway, where the gateway includes: a processor and a memory; the memory is used for storing instructions; the processor is used for executing the instructions in the memory, Perform the operation corresponding to the gateway in the embodiment of this application.
  • Embodiments of the present application also provide a computer-readable storage medium, including instructions, which, when executed on a computer, cause the computer to execute the above-described communication method.
  • the disclosed system, apparatus and method may be implemented in other manners.
  • the apparatus embodiments described above are only illustrative.
  • the division of units is only a logical business division. In actual implementation, there may be other division methods.
  • multiple units or components may be combined or integrated. to another system, or some features can be ignored, or not implemented.
  • the shown or discussed mutual coupling or direct coupling or communication connection may be through some interfaces, indirect coupling or communication connection of devices or units, and may be in electrical, mechanical or other forms.
  • Units described as separate components may or may not be physically separated, and components shown as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution in this embodiment.
  • each service unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically alone, or two or more units may be integrated into one unit.
  • the above-mentioned integrated unit may be implemented in the form of hardware, or may be implemented in the form of a software business unit.
  • the integrated unit if implemented as a software business unit and sold or used as a stand-alone product, may be stored in a computer-readable storage medium.
  • the technical solutions of the present application can be embodied in the form of software products in essence, or the parts that contribute to the prior art, or all or part of the technical solutions, and the computer software products are stored in a storage medium , including several instructions to cause a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods in the various embodiments of the present application.
  • the aforementioned storage medium includes: U disk, mobile hard disk, Read-Only Memory (ROM, Read-Only Memory), Random Access Memory (RAM, Random Access Memory), magnetic disk or optical disk and other media that can store program codes .
  • the services described in the present invention may be implemented by hardware, software, firmware or any combination thereof.
  • the services may be stored on or transmitted over as one or more instructions or code on a computer-readable medium.
  • Computer-readable media includes both computer storage media and communication media including any medium that facilitates transfer of a computer program from one place to another.
  • a storage medium can be any available medium that can be accessed by a general purpose or special purpose computer.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Security & Cryptography (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

本申请实施例公开了一种通信方法、装置、设备及系统,在客户端设备存在overlay虚拟网络实例时,在该overlay虚拟网络实例中建立loopback接口,并为该loopback接口分配IP地址。同时客户端设备基于该overlay虚拟网络实例建立到服务器侧的传输通道,并利用该传输通道向服务器侧发送报文。其中,报文中包括loopback接口的IP地址,以利用该IP地址向服务器进行注册,从而使得服务器可以根据该IP地址识别客户端设备。通过该方法,客户端设备在利用传输通道发送报文时,所发送报文的源地址均为overlay虚拟网络实例中loopback接口的IP地址,从而使得客户端设备可以使用同一个IP地址向服务器进行注册,进而实现服务器可以唯一地识别该客户端设备。

Description

一种通信方法、装置、设备及系统
本申请要求于2020年8月31日提交的申请号为202010895959.1、申请名称为“一种通信方法、装置、设备及系统”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及通信技术领域,尤其涉及一种通信方法、装置、设备及系统。
背景技术
软件定义广域网(software-defined wide area network,SD-WAN)是软件定义网络(software-defined-network,SDN)的理念和设计思想在广域网(wide area network,WAN)领域的重要实践。通过软件定义的方法,SD-WAN能够提供一种简易、智能和灵活的WAN互联能力,在企业业务上云和WAN连接Internet化的趋势下,帮助企业随时随地、灵活便捷的获得高品质的广域互联网络。
SD-WAN实际部署场景中通常会涉及到SD-WAN中的客户端设备(customer premise equipment,CPE)向运营商服务器注册并对接的场景。通常情况下,CPE利用其对应的WAN口互联网协议(internet protocol,IP)地址访问服务器,该服务器通过该IP地址来标定CPE。然而,当CPE存在多个WAN口时,不同WAN口对应不同的IP地址,CPE可能无法统一采用同一个IP地址访问服务器,导致服务器无法根据IP地址标定CPE。
发明内容
本申请实施例提供了一种通信方法、装置、设备及系统,可以解决服务器无法根据IP地址标定CPE问题。
在本申请实施例的第一方面,提供了一种通信方法,该方法包括:客户端设备在叠加overlay虚拟网络实例中创建环回loopback接口,并为该loopback接口配置IP地址;客户端设备基于overlay虚拟网络实例建立到服务器侧的传输通道;客户端设备利用该传输通道向服务器侧发送报文,其中,报文至少包括所述IP地址。在该实施例中,客户端设备在向服务器侧发送报文时,所使用的IP地址是在overlay虚拟网络实例中所创建的loopback接口的IP地址,以利用该IP地址向服务器进行注册,从而使得服务器可以根据该IP地址识别客户端设备。
在一种具体的实施方式中,客户端设备基于overlay虚拟网络实例建立到服务器侧的传输通道,包括:所述客户端设备建立所述overlay虚拟网络实例到所述服务器侧的overlay隧道;和/或,所述客户端设备在所述overlay虚拟网络实例以及与服务器侧互通的虚拟网络实例间建立内环隧道。在该实施例中,客户端设备可以建立的传输通道包括overlay传输通道和/或内环隧道。其中,overlay隧道是基于overlay虚拟网络实例建立的,报文在overlay隧道传输独立于underlay虚拟网络,在利用overlay隧道传输报文时,可以将loopback接口的IP封装为内层IP,WAN口的IP地址封装为外层IP。无论该报文通过哪个WAN口传输给服务器,内层IP地址均为loopback接口的IP地址,从而使得客户端设备可以利用该loopback接口的IP地址注册服务器。内环隧道是基于客户端设备的overlay虚拟网络实例和underlay虚拟网络实例构建的,当客户端设备向服务器进行注册时,可以通过建立的内 环隧道以及WAN口向服务器发送报文,该报文的源地址为loopback接口的IP地址,以通过该IP地址向服务器进行注册。
在一种具体的实施方式中,当服务器侧存在与所述服务器对应的网关时,所述客户端设备建立所述overlay虚拟网络实例到服务器侧的overlay隧道,包括:所述客户端设备建立所述overlay虚拟网络实例到所述服务器对应的网关的overlay隧道;所述客户端设备利用所述传输通道向服务器侧发送报文,包括:所述客户端设备利用所述overlay隧道向所述网关发送报文。在该实施例中,当服务器存在对应的网关时,客户端设备所建立的overlay隧道是建立overlay虚拟网络实例到服务器所对应的网关的overlay隧道,以通过overlay隧道向服务器对应的网关发送报文,进而由网关将该报文转发给服务器。
在一种具体的实施方式中,当服务器侧存在至少两个服务器,且每个服务器对应不同的网关时,所述客户端设备建立所述overlay虚拟网络实例到所述服务器对应的网关的overlay隧道,包括:所述客户端设备基于所述overlay虚拟网络实例与各服务器对应的网关分别建立overlay隧道;所述客户端设备利用所述overlay隧道向所述网关发送报文,包括:所述客户端设备利用所述overlay隧道中的至少一个向对应的网关发送报文。在该实施例中,当服务器侧存在多个服务器且每个服务器对应不同的网关时,客户端设备可以基于overlay虚拟网络实例建立到各个服务器各自对应网关的overlay隧道,从而可以获得多个overlay隧道。当客户端设备在向服务器侧发送报文时,可以利用所建立的overlay隧道中的一个或多个向对应网关发送报文。当其中某一overlay隧道故障时,可以利用其它overlay隧道传输报文,增加容错机制。
在一种具体的实施方式中,所述至少两个服务器中包括主用服务器和备用服务器,所述客户端设备利用所述overlay隧道中的至少一个向对应的网关发送报文,包括:所述客户端设备利用与所述主用服务器对应的网关建立的overlay隧道向所述主用服务器对应的网关发送报文,当所述主用服务器和/或所述主用服务器对应的网关故障时,所述客户端设备利用与所述备用服务器对应的网关建立的overlay隧道向所述备用服务器对应的网关发送报文。在该实施例中,当服务器侧存在多个服务器时,可以配置主用服务器和备用服务器,客户端设备可以优先利用与主用服务器对应的网关建立的overlay隧道向主用服务器对应的网关发送报文,当主用服务器和/或主用服务器对应的网关出现故障时,可以利用备用服务器对应的网关建立的overlay隧道向备用服务器对应的网关发送报文,提高报文传输可靠性。
在一种具体的实施方式中,当一个服务器对应至少两个网关时,所述客户端设备建立所述overlay虚拟网络实例到所述服务器对应的网关的overlay隧道,包括:所述客户端设备基于所述overlay虚拟网络实例与所述服务器对应的各网关分别建立overlay隧道;所述客户端设备利用所述overlay隧道向所述服务器发送报文,包括:所述客户端设备利用所述overlay隧道中的至少一个向对应的网关发送报文。在该实施例中,当一个服务器对应多个网关时,客户端设备可以基于overlay虚拟网络实例与服务器所对应的每个网关均建立overlay隧道。客户端设备可以利用一个或多个overlay隧道向对应的网关发送报文。
在一种具体的实施方式中,所述至少两个网关包括主用网关和备用网关,所述客户端 设备利用所述overlay隧道中的至少一个向对应的网关发送报文,包括:所述客户端设备利用与所述主用网关建立的overlay隧道向所述主用网关发送报文,当所述主用网关出现故障时,所述客户端设备利用与所述备用网关建立的overlay隧道向所述备用网关发送报文。在该实施例中,当一个服务器对应多个网关时,可以配置主用网关和备用网关,客户端设备优先利用与主用网关建立的overlay隧道向主用网关发送报文。当主用网关出现故障时,客户端设备利用与备用网关建立的overlay隧道向备用网关发送报文。
在一种具体的实施方式中,当所述客户端设备存在至少两个WAN口时,每个所述WAN口具有对应的underlay虚拟网络实例,所述客户端设备建立所述overlay虚拟网络实例到所述服务器对应的网关的overlay隧道,包括:所述客户端设备基于所述overlay虚拟网络实例,利用每个WAN口分别与所述服务器对应的网关建立overlay隧道;所述客户端设备利用所述overlay隧道向所述网关发送报文,包括:所述客户端设备利用所述overlay隧道中的至少一个向所述网关发送报文。在该实施例中,当客户端设备对应多个WAN口时,可以针对每个WAN口分别于服务器对应的网关建立overlay隧道,以利用该overlay隧道向网关发送报文。
在一种具体的实施方式中,当至少两个WAN口包括主用WAN口和备用WAN口,所述客户端设备利用所述overlay隧道向所述网关发送报文,包括:所述客户端设备利用所述主用WAN口与所述网关建立的overlay隧道向所述网关发送报文,当所述主用WAN口的链路故障时,所述客户端设备利用所述备用WAN口与所述网关建立的overlay隧道向所述网关发送报文。在该实现方式中,当客户端设备存在多个WAN口时,可以配置主用WAN口和备用WAN口,客户端设备可以优先利用主用WAN口与网关建立的overlay隧道向网关发送报文。当主用WAN口出现链路故障时,客户端设备可以利用备用WAN口与网关建立的overlay隧道向网关发送报文。
在一种具体的实施方式中,为保证报文传输的安全性,当客户端设备的WAN口所对应的底层underlay网络类型为预设网络类型时,所述客户端设备利用所述overlay隧道向所述网关发送报文之前,所述方法还包括:所述客户端设备对报文进行加密,获得加密后的报文。
在一种具体的实施方式中,所述客户端设备在所述overlay虚拟网络实例以及与服务器侧互通的虚拟网络实例间建立内环隧道,包括:客户端设备基于所述overlay虚拟网络实例与underlay虚拟网络实例建立内环隧道,所述underlay虚拟网络实例与所述客户端设备的WAN口关联,所述WAN口通过underlay网络与所述服务器互通;所述客户端利用所述传输通道向服务器侧发送报文,包括:所述客户端设备利用所述内环隧道以及所述underlay网络向所述服务器发送报文。在该实施例中,当客户端设备存在于服务器侧互通的underlay虚拟网络实例时,客户端设备可以基于overlay虚拟网络实例与underlay虚拟网络实例建立内环隧道,以通过该内环隧道以及underlay虚拟网络向服务器发送报文。
在一种具体的实施方式中,当所述客户端设备存在至少两个WAN口且不同的WAN口与不同的underlay虚拟网络实例绑定时,所述客户端设备基于所述overlay虚拟网络实例与underlay虚拟网络实例建立内环隧道,包括:所述客户端设备基于所述overlay虚拟网络实 例分别与各WAN口对应的underlay虚拟网络实例建立内环隧道;所述客户端设备利用所述内环隧道以及所述underlay网络向服务器发送报文,包括:所述客户端设备利用所述内环隧道中的至少一个以及其对应的underlay网络向服务器发送报文。在该实施例中,当客户端设备存在多个WAN口时,客户端设备可以针对每个WAN口,建立overlay虚拟网络实例与该WAN口对应的underlay虚拟网络实例之间的内环隧道。客户端设备可以利用一个或多个内环隧道以及该内环隧道对应的underlay网络向服务器发送报文。
在一种具体的实施方式中,所述至少两个WAN口中包括主用WAN口和备用WAN口,与所述主用WAN口对应的underlay虚拟网络实例建立的内环隧道为主用内环隧道,与所述备用WAN口对应的underlay虚拟网络实例建立的内环隧道为备用内环隧道,所述客户端利用所述内环隧道中的至少一个以及其对应的underlay网络向服务器发送报文,包括:所述客户端设备利用所述主用内环隧道以及所述主用WAN口对应的underlay网络向服务器发送报文,当所述主用WAN口的链路故障时,所述客户端设备利用所述备用内环隧道以及所述备用WAN口对应的underlay网络向服务器发送报文。在该实施例中,当客户端设备对应多个WAN口时,可以配置主用WAN口和备用WAN口,其中,主用WAN口对应的内环隧道为主用内环隧道,备用WAN口对应的内环隧道为备用内环隧道。客户端设备优先利用主用内环隧道以及主用WAN口对应的underlay网络向服务器发送报文。当主用WAN口的链路出现故障时,客户端设备将利用备用内环隧道以及备用WAN口对应的underlay网络向服务器发送报文。
在一种具体的实施方式中,当客户端设备同时存在overlay隧道和内环隧道时,优先利用overlay隧道向服务器侧发送报文。即,overlay隧道的优先级高于内环隧道。
在一种具体的实施方式中,当服务器侧对应的网关故障时,所述方法还包括:所述客户端设备从所述overlay隧道切换至所述内环隧道。
在一种具体的实施方式中,所述overlay虚拟网络实例为所述客户端设备中业务虚拟网络实例,所述业务虚拟网络实例为overlay虚拟网络实例,或所述overlay虚拟网络实例为所述客户端设备新建的overlay虚拟网络实例。在该实施例中,客户端设备在建立overlay隧道或内环隧道时,所利用的overlay虚拟网络实例可以为客户端设备本身存在overlay虚拟网络实例,也可以为新建的overlay虚拟网络实例。
在一种具体的实施方式中,所述报文还包括WAN口对应的IP地址。
在一种具体的实施方式中,当所述客户端设备对应的WAN口所连接的网络存在网络地址转换时,所述loopback接口所配置的IP地址为公网IP地址。在该实施例中,为避免网络地址转换导致报文中的IP地址被转换为公网IP地址,造成服务器仍无法识别客户端设备的问题,可以直接将loopback接口的IP地址配置为公网IP地址,无需进行网络地址转换。
在本申请实施例的第二方面,提供了一种通信方法,所述方法包括:网关接收客户端设备发送的报文,所述报文包括所述客户端设备中loopback接口的IP地址,所述loopback接口位于所述客户端设备中的overlay虚拟网络实例中;所述网关解析所述报文获取所述IP地址,并将所述IP地址发送给服务器,以使得所述服务器根据所述IP地址识别所述客户 端设备。
在一种具体的实施方式中,当所述报文为加密报文时,所述网关解析所述报文之前,所述方法还包括:所述网关对所述报文进行解密。
在本申请实施例的第三方面,提供了一种通信装置,创建单元,用于在overlay虚拟网络实例中创建loopback接口,并为所述loopback接口配置IP地址;建立单元,用于基于所述overlay虚拟网络实例建立到服务器侧的传输通道;发送单元,用于利用所述传输通道向服务器侧发送报文,所述报文至少包括所述IP地址。
在一种具体的实施方式中,所述建立单元,具体用于建立所述overlay虚拟网络实例到所述服务器侧的overlay隧道;和/或,在所述overlay虚拟网络实例以及与服务器侧互通的虚拟网络实例间建立内环隧道。
在一种具体的实施方式中,当服务器侧存在对应的网关时,所述建立单元,具体用于建立所述overlay虚拟网络实例到服务器侧对应的网关的overlay隧道;
所述发送单元,具体用于利用所述overlay隧道向所述网关发送报文。
在一种具体的实施方式中,当服务器侧存在至少两个服务器且每个服务器对应不同的网关时,所述建立单元,具体用于基于所述overlay虚拟网络实例与各服务器对应的网关分别建立overlay隧道;所述发送单元,具体用于利用所述overlay隧道中的至少一个向对应的网关发送报文。
在一种具体的实施方式中,当所述至少两个服务器中包括主用服务器和备用服务器,所述发送单元,具体用于利用与所述主用服务器对应的网关建立的overlay隧道向所述主用服务器对应的网关发送报文,当所述主用服务器和/或所述主用服务器对应的网关故障时,所述客户端设备利用与所述备用服务器对应的网关建立的overlay隧道向所述备用服务器对应的网关发送报文。
在一种具体的实施方式中,当一个服务器对应至少两个网关时,所述建立单元,具体用于基于所述overlay虚拟网络实例与所述服务器对应的各网关分别建立overlay隧道;所述发送单元,具体用于利用所述overlay隧道中的至少一个向对应的一网关发送报文。
在一种具体的实施方式中,所述至少两个网关包括主用网关和备用网关,所述发送单元,具体用于利用与所述主用网关建立的overlay隧道向所述主用网关发送报文,当所述主用网关出现故障时,利用与所述备用网关建立的overlay隧道向所述备用网关发送报文。
在一种具体的实施方式中,当所述装置存在至少两个WAN口时,每个所述WAN口具有对应的underlay虚拟网络实例,所述建立单元,具体用于基于所述overlay虚拟网络实例,利用每个WAN口分别与所述服务器对应的网关建立overlay隧道;所述发送单元,具体用于利用所述overlay隧道中的至少一个向所述网关发送报文。
在一种具体的实施方式中,当所述两个WAN口包括主用WAN口和备用WAN口,所述发送单元,具体用于利用所述主用WAN口与所述网关建立的overlay隧道向所述网关发送报文,当所述主用WAN口故障时,利用所述备用WAN口与所述网关建立的overlay隧道向所述网关发送报文。
在一种具体的实施方式中,当客户端设备的WAN口所对应的underlay网络类型为预 设网络类型时,所述装置还包括:加密单元,用于利用所述overlay隧道向所述网关发送报文之前,对报文进行加密,获得加密后的报文。
在一种具体的实施方式中,所述建立单元,具体用于基于所述overlay虚拟网络实例与underlay虚拟网络实例建立内环隧道,所述underlay虚拟网络实例与所述客户端设备的WAN口关联,所述WAN口通过underlay网络与所述服务器互通;所述发送单元,具体用于利用所述内环隧道以及所述underlay网络向服务器发送报文。
在一种具体的实施方式中,当所述客户端设备存在至少两个WAN口且不同的WAN口与不同的underlay虚拟网络实例绑定时,所述建立单元,具体用于基于所述overlay虚拟网络实例分别与各WAN口对应的underlay虚拟网络实例建立内环隧道;所述发送单元,具体用于利用所述内环隧道中的至少一个以及其对应的underlay网络向服务器发送报文。
在一种具体的实施方式中,所述至少两个WAN口中包括主用WAN口和备用WAN口,与所述主用WAN口对应的underlay虚拟网络实例建立的内环隧道为主用内环隧道,与所述备用WAN口对应的underlay虚拟网络实例建立的内环隧道为备用内环隧道,所述发送单元,具体用于利用所述主用内环隧道以及所述主用WAN口对应的underlay网络向服务器发送报文,当所述主用WAN口故障时,利用所述备用内环隧道以及所述备用WAN口对应的underlay网络向服务器发送报文。
在一种具体的实施方式中,当存在overlay隧道和内环隧道,所述overlay隧道的优先级高于所述内环隧道。
在一种具体的实施方式中,当所述服务器侧对应的网关故障时,所述装置还包括:切换单元,用于从所述overlay隧道切换至所述内环隧道。
在一种具体的实施方式中,所述overlay虚拟网络实例为所述通信装置中业务虚拟网络实例,所述业务虚拟网络实例为overlay虚拟网络实例,或所述overlay虚拟网络实例为所述通信装置新建的overlay虚拟网络实例。
在一种具体的实施方式中,所述报文还包括WAN口对应的IP地址。
在一种具体的实施方式中,当所述通信装置对应的WAN口所连接的网络存在网络地址转换时,所述loopback接口所配置的IP地址为公网IP地址。
在本申请实施例第四方面,提供了一种通信装置,所述装置包括:接收单元,用于接收客户端设备发送的报文,所述报文包括所述客户端设备中loopback接口的IP地址,所述loopback接口位于所述客户端设备中的所述overlay虚拟网络实例中;解析单元,用于解析所述报文获取所述IP地址;发送单元,用于将所述IP地址发送给服务器,以使得所述服务器根据所述IP地址识别所述客户端设备。
在一种具体的实施方式中,当所述报文为加密报文时,所述装置还包括:解密单元,用于解析所述报文之前,对所述报文进行解密。
在本申请实施例第五方面,提供了一种通信设备,所述设备包括:处理器和存储器;所述存储器,用于存储指令;所述处理器,用于执行所述存储器中的所述指令,执行第一方面所述的方法。
在本申请实施例第六方面,提供了一种网关,所述网关包括:处理器和存储器;所述 存储器,用于存储指令;所述处理器,用于执行所述存储器中的所述指令,执行第二方面所述的方法。
在本申请实施例第七方面,提供了一种通信系统,所述系统包括:客户端设备和服务器,所述客户端设备,用于在overlay虚拟网络实例中创建loopback接口,并为所述loopback接口配置IP地址;基于所述overlay虚拟网络实例建立到服务器侧的传输通道;利用所述传输通道向服务器发送报文,所述报文至少包括所述IP地址。;所述服务器,用于根据所述报文中的IP地址识别所述客户端设备。
在一种具体的实施方式中,所述客户端设备,具体用于建立所述overlay虚拟网络实例到所述服务器侧的overlay隧道;和/或,在所述overlay虚拟网络实例以及服务器侧互通的虚拟网络实例间建立内环隧道。
在一种具体的实施方式中,所述系统还包括:网关,所述网关与所述服务器通信,所述客户端设备,具体用于建立所述overlay虚拟网络实例到所述服务器对应的网关的overlay隧道;利用所述overlay隧道向所述网关发送报文;所述网关,用于解析所述报文获取所述IP地址,并将所述IP地址发送给服务器。
在一种具体的实施方式中,所述系统包括主用网关和备用网关,所述主用网关和所述备用网关均与所述服务器通信,所述客户端设备,具体用于利用与所述主用网关建立的overlay隧道向所述主用网关发送报文,当所述主用网关故障时,利用与所述备用网关建立的overlay隧道向所述备用网关发送报文。
在一种具体的实施方式中,所述客户端设备,具体用于基于所述overlay虚拟网络实例与underlay虚拟网络实例建立内环隧道,所述underlay虚拟网络实例与所述客户端设备的WAN口关联,所述WAN口通过underlay网络与所述服务器互通;利用所述内环隧道以及所述underlay网络向所述服务器发送报文。
在一种具体的实施方式中,当服务器侧对应的网关故障时,所述客户端设备,还用于从所述overlay隧道切换至所述内环隧道。
在本申请实施例第八方面,提供了一种计算机可读存储介质,包括指令,当其在计算机上运行时,使得计算机执行以上第一方面和/或第二方面所述的方法。
通过本申请实施例所提供的通信方法,在客户端设备存在overlay虚拟网络实例时,在该overlay虚拟网络实例中建立loopback接口,并为该loopback接口分配IP地址。同时客户端设备基于该overlay虚拟网络实例建立到服务器侧的传输通道,并利用该传输通道向服务器侧发送报文。其中,报文中包括loopback接口的IP地址,以利用该IP地址向服务器进行注册,从而使得服务器可以根据该IP地址识别客户端设备。
其中,传输通道可以包括overlay隧道和/或内环隧道。overlay隧道是基于overlay虚拟网络实例建立的,报文在overlay隧道传输独立于underlay虚拟网络,在利用overlay隧道传输报文时,可以将loopback接口的IP封装为内层IP,WAN口的IP地址封装为外层IP。无论该报文通过哪个WAN口传输给服务器,内层IP地址均为loopback接口的IP地址,从而使得客户端设备可以利用该loopback接口的IP地址注册服务器。内环隧道是基于客户端设备的overlay虚拟网络实例和underlay虚拟网络实例构建的,当客户端设备向服务器进 行注册时,可以通过建立的内环隧道以及WAN口向服务器发送报文,该报文的源地址为loopback接口的IP地址,以通过该IP地址向服务器进行注册。当客户端设备存在多个WAN口时,无论多个WAN口是否对应同一个underlay虚拟网络实例,均可以针对每个WAN口对应underlay虚拟网络实例建立内环隧道,无论使用哪个内环隧道向服务器注册,所发送报文的源地址均为overlay虚拟网络实例中loopback接口的IP地址,从而使得客户端设备可以使用同一个IP地址向服务器进行注册,进而实现服务器可以唯一地识别该客户端设备。
附图说明
为了更清楚地说明本申请实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请中记载的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
图1为传统注册场景示意图;
图2为本申请实施例提供的一种通信方法流程图;
图3为本申请实施例提供的另一种通信方法流程图;
图4a为本申请实施例提供的一种建立overlay隧道示意图;
图4b为本申请实施例提供的另一种建立overlay隧道示意图;
图4c为本申请实施例提供的又一种建立overlay隧道示意图;
图4d为本申请实施例提供的再一种建立overlay隧道示意图;
图4e为本申请实施例提供的另一种建立overlay隧道示意图;
图5为本申请实施例提供的又一种通信方法流程图;
图6a为本申请实施例提供的一种建立内环隧道示意图;
图6b为本申请实施例提供的另一种建立内环隧道示意图;
图6c为本申请实施例提供的又一种建立内环隧道示意图;
图6d为本申请实施例提供的再一种建立内环隧道示意图;
图7为本申请实施例提供的一种通信装置结构图;
图8为本申请实施例提供的另一种通信装置结构图;
图9为本申请实施例提供的一种通信系统结构图;
图10为本申请实施例提供的一种通信设备结构图。
具体实施方式
为了使本技术领域的人员更好地理解本发明中的方案,下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅是本发明一部分实施例,而不是全部的实施例。
传统的CPE向服务器注册时,除了利用WAN口的IP地址进行注册外,CPE还可以在底层(underlay)虚拟网络VPN实例中创建环回(loopback)接口并利用该loopback接口对应的IP地址进行注册。例如图1所示,在underlay VPN1中创建loopback接口1,利用该loopback接口1对应的IP地址经过WAN口1向服务器进行注册。即,可以通过由WAN口1-underlay网络1构成的链路向服务器进行注册。然而,当CPE存在多个WAN口且每 个WAN口对应不同的underlay虚拟网络实例时,loopback接口仅对应一个underlay虚拟网络实例。该情况下,当WAN口1出现故障时,CPE将切换WAN口2,以利用WAN口2对应的underlay虚拟网络实例中的loopback接口2的IP地址进行注册,仍出现IP地址切换的问题,使得服务器无法唯一标定该CPE。
另外,当WAN口对应的网络存在网络地址转换(network address translation,NAT)时,发送给服务器的报文经NAT处理后到达服务器的IP地址不是loopback接口的IP地址,仍无法标定CPE。其中,NAT是指使用少量的公有IP地址代表较多的私有IP地址的方式,即可以将多个私有IP地址映射为同一公有IP地址。
基于此,本申请实施例提供了一种通信方法,用于解决CPE向服务器进行注册时,由于源IP地址的切换,导致服务器无法进行识别的问题。
为便于理解本申请实施例,下面将本申请实施例涉及的技术术语进行解释。
底层(underlay)网络就是当前数据中心网路基础转发架构的网络,只要数据中心网络上任意两点路由可达即可,指的是物理基础层。
叠加(overlay)网络在网络技术领域,指的是一种网络架构上叠加的虚拟化技术模式,其大体框架是对基础网络不进行大规模修改的条件下,实现应用在网络上的承载,并能与其它网络业务分离,并且以基于IP的基础网络技术为主。overlay网络是建立在underlay网络之上的虚拟网络。overlay网络的节点通过虚拟的或逻辑的链接进行通信,每一个虚拟的或逻辑的链接对应于underlay网络的一条路径(Path),由多个前后衔接的链接组成。需要注意的是,overlay网络和underlay网络是相互独立的,overlay网络使用underlay网络点对点(peer-to-peer)的传递报文,而报文如何传递到overlay网络的目的节点完全取决于underlay网络的控制平面和数据平面,报文在overlay网络Ingress和Egress节点的处理(如抛弃,转发)则完全由overlay网络的封装协议来决定。
loopback接口是一种纯软件性质的虚拟接口。loopback接口创建后物理层状态和链路层协议永远处于up状态。loopback接口可以配置ip地址,为了节约ip地址,系统会自动给loopback接口的ip地址配置32位的子网掩码。将loopback接口地址设置为该设备产生的所有ip数据包的源地址,因为loopback接口地址稳定且是单播地址,所以通常将loopback接口地址视为设备的标志,在认证或安全等服务器上设置允许或禁止携带loopback接口地址的报文通过,就相当于允许或禁止某台设备产生的报文通过,这样可以简化报文过滤规则。但需要注意的是,将loopback接口用于源地址绑定时,需确保loopback接口到对端的路由可达,而且,任何送到loopback接口的网络数据报文都会被认为是送往设备本身的,设备将不再转发这些数据包。
为便于理解本申请实施例的具体实现,下面将结合附图进行说明。
参见图2,该图为本申请实施例提供的一种通信方法流程图,如图2所示,该方法可以包括:
S201:客户端设备在overlay虚拟网络实例中创建loopback接口,并为loopback接口配置IP地址。
本实施例中,当客户端设备CPE存在overlay虚拟网络实例时,可以在该overlay虚拟 网络实例中创建loopback接口,并为该loopback接口配置IP地址。
其中,创建loopback接口的overlay虚拟网络实例可以为客户端设备中已存在的用于进行业务互访的overlay虚拟网络实例,即与LAN口所关联的overlay虚拟网络实例。同时,也可以为新创建的overlay虚拟网络实例,其独立于LAN口所关联的overlay虚拟网络实例。
S202:客户端设备基于overlay虚拟网络实例建立到服务器侧的传输通道。
本实施例中,客户端设备可以基于overlay虚拟网络实例建立到服务器侧的传输通道。其中,传输通道可以包括overlay隧道和/或内环隧道。其中,overlay隧道是指两个不同的设备之间的overlay虚拟网络实例所建立的隧道。本实施例中,客户端设备可以建立overlay虚拟网络实例到服务器侧的overlay隧道。其中,两个不同的设备可以是两个不同的CPE,每个CPE分别部署在不同的SD-WAN站点;或者,一个为CPE,另一个为服务器。内环隧道是指同一设备的overlay虚拟网络实例与underlay虚拟网络实例之间所建立的隧道。即,客户端设备在overlay虚拟网络实例以及与服务器侧互通的虚拟网络实例建立内环隧道。其中,关于overlay隧道和/或内环隧道的建立将在后续实施例进行说明。
S203:客户端设备利用传输通道向服务器侧发送报文。
本实施例中,当客户端设备建立到服务器侧的传输通道时,可以利用该传输通向服务
器侧发送报文,该报文中可以包括loopback接口的IP地址,以使得服务器可以根据该IP地址对客户端设备进行识别。当传输通道包括overlay隧道和/或内环隧道时,客户端设备可以利用overlay隧道和/或内环隧道向服务器发送报文,该报文中包括loopback接口的IP地址。
当客户端设备仅有overlay隧道或内环隧道时,客户端设备利用overlay隧道或内环隧道向服务器发送报文,以通过该报文中的IP地址向服务器进行注册。客户端设备既包括overlay隧道和内环隧道时,可以根据实际需求选择overlay隧道或内环隧道向服务器发送报文,以利用该报文中的IP地址进行注册。具体地,在一些实现方式中,overlay隧道的优先级高于内环隧道,CPE优先利用overlay隧道向服务器发送报文。
可见,通过本申请实施例提供的通信方法,客户端设备无论是利用overlay隧道还是内环隧道向服务器发送报文进行注册,均使用overlay虚拟网络实例中所建立的loopback接口的IP地址作为报文的源地址,不再使用WAN口的IP地址或WAN口对应的underlay虚拟网络实例中的loopback接口的IP地址进行注册,不存在WAN链路故障导致IP地址切换的问题,进而实现客户端设备可以使用同一个IP地址向服务器进行注册。
上述实施例介绍了客户端设备可以建立overlay隧道和/或内环隧道向服务器发送报文,为便于理解下面将结合附图,对如何建立overlay隧道和内环隧道向服务器发送报文的实现进行说明。
参见图3,该图为本申请实施例提供的一种构建overlay隧道的实现流程图,如图3所示,该方法可以包括:
S301:客户端设备建立overlay虚拟网络实例到服务器对应的网关的overlay隧道。
本实施例中,当服务器存在对应的网关时,客户端基于自身的overlay虚拟网络实例以及网关上的overlay虚拟网络实例建立overlay隧道。
其中,客户端设备自身的overlay虚拟网络实例可以为客户端设备上当前所存在的业务虚拟网络实例,该业务虚拟网络实例为overlay虚拟网络实例。如图4a所示,客户端设备在与LAN口关联的业务overlay虚拟网络实例中创建loopback接口,并为该loopback接口配置IP地址。基于该业务overlay虚拟网络实例与网关建立overlay隧道。当然,客户端设备自身的overlay虚拟网络实例也可以为新创建的overlay虚拟网络实例,其独立于业务overlay虚拟网络实例。如图4b所示,新创建overlay虚拟网络实例,并在该overlay虚拟网络实例中创建loopback接口,同时为该loopback接口配置IP地址,基于该overlay虚拟网络实例与网关建立overlay隧道。
S302:客户端设备利用overlay隧道向网关发送报文。
当客户端设备与网关建立overlay隧道后,客户端设备可以利用该overlay隧道向网关发送报文,该报文包括loopback接口的IP地址,以利用该IP地址向服务器进行注册。网关在接收到报文后,对报文进行解析获得报文中的IP地址,并将该IP地址发送给服务器,以使得服务器可以根据该IP地址唯一识别该客户端设备。
在一种具体的实施方式中,客户端设备在建立overlay隧道时,还可以根据WAN口对应的underlay网络类型确定是否对经过该overlay隧道的报文进行加密,以避免第三方随意截取。其中,WAN口对应的underlay网络类型可以为多协议标签交换(multi-protocol Label Switching,MPLS)、internet等类型。当WAN口对应的underlay网络类型为预设网络类型时,客户端利用overlay隧道向网关发送报文时,客户端设备对该报文进行加密,获得加密后的报文,并将加密后的报文发送给网关。其中,客户端设备对该报文进行加密所使用的加密密钥可以预先和网关进行协商,以便网关在接收到加密后的报文时,可以根据协商的密钥对该报文进行解密,获得明文。网关设备再对解密后的报文进行解析获得IP地址,以将该IP地址发送给服务器。例如,当underlay网络类型为internet网络时,客户端设备在生成报文后,对该报文进行加密,以将加密后的报文发送给网关。
在一种具体的实施方式中,当客户设备端利用overlay隧道向网关发送报文时,报文中还可以包括WAN口对应的IP地址。具体地,客户端设备利用overlay隧道发送报文时,利用封装协议对该报文进行封装,将loopback接口的IP地址作为内层地址,WAN口的IP地址作为外层地址。网关在接收到报文时,进行解封装获得内层IP地址,将该内层IP地址发送给服务器,以使得服务器通过该内层IP地址对客户端设备进行识别。
在一种具体的实施方式中,当服务器侧存在至少两个服务器时且每个服务器对应不同的网关时,如图4c所示,客户端设备可以基于每个服务器对应的网关建立overlay隧道,从而获得多个overlay隧道,以便在其中一个overlay隧道出现故障时,可以利用另一overlay隧道进行报文传输。具体地,客户端设备基于overlay虚拟网络实例与各服务器对应的网关分别建立overlay隧道;客户端设备利用所建立的overlay隧道中的至少一个隧道向对应网关发送报文。为便于理解,下面以存在两个服务器为例进行说明,具体地:
1)客户端设备基于overlay虚拟网络实例与第一服务器对应的网关建立overlay隧道。
2)客户端设备基于overlay虚拟网络实例与第一服务器对应的网关建立overlay隧道。
3)客户端设备利用与第一服务器对应的网关的overlay隧道向第一服务器对应的网关 发送报文或利用与第二服务器对应的网关的overlay隧道向第二服务器对应的网关发送报文。
本实施例中,当服务器侧存在多个服务器时,客户端设备可以基于每个服务器对应的网关均建立overlay隧道,以便利用一个或多个overlay隧道向该overlay隧道对应的网关发送报文。需要说明的是,本发明实施例中所涉及服务器侧存在多个服务器的情况是指服务器侧存在的可实施例本发明实施例的服务器有多个的情况。
在一种具体的实施方式中,当服务器侧存在多个服务器时,可以配置主用服务器和备用服务器,客户端设备可以利用与主用服务器对应的网关建立的overlay隧道向主用服务器对应的网关发送报文,当主用服务器和/或主用服务器对应的网关故障时,客户端设备可以利用备用服务器对应的网关的overlay隧道向备用服务器对应的网关发送报文。
在一种具体的实施方式中,当一个服务器对应至少两个网关时,客户端设备可以针对每个网关建立overlay隧道,从而获得多个overlay隧道,以便在其中一个overlay隧道出现故障时,可以利用另一个overlay隧道进行报文传输。具体地,客户端设备基于overlay虚拟网络实例与服务器对应的各网关分别建立overlay隧道;客户端设备利用所建立的overlay隧道中的至少一个像对应的网关发送报文。如图4d所示,服务器对应第一网关和第二网关,具体包括:
1)客户端设备基于overlay虚拟网络实例与第一网关建立第一overlay隧道。
2)客户端设备基于overlay虚拟网络实例与第二网关建立第二overlay隧道。
3)客户端设备利用第一overlay隧道向第一网关发送报文,和/或利用第二overlay隧道向第二网关发送报文。
本实施例中,当一个服务器对应多个网关时,客户端设备可以基于每个网关建立overlay隧道,以便利用一个或多个overlay隧道向该overlay隧道对应的网关发送报文。
在一些实现方式中,当一个服务器对应多个网关时,可以预先配置主用网关和备用网关,客户端设备利用与主用网关建立的overlay隧道向主用网关发送报文。当主用网关出现故障时,客户端设备可以利用与备用网关建立的overlay隧道向备用网关发送报文。
上述实施例说明了当服务器侧存在多个服务器或多个网关时,可以建立多个overlay隧道,以增加容错机制。此外,当客户端设备存在多个WAN口时,可以基于不同的WAN口建立不同的overlay隧道。具体地,客户端设备基于overlay虚拟网络实例,利用每个WAN口分别与服务器对应的网关建立overlay隧道;客户端设备利用所建立的overlay隧道中的至少一个向网关发送报文。如图4e所示,客户端设备存在两个WAN口,客户端设备基于overlay虚拟网络实例以及不同的WAN口建立不同的隧道。具体为:
1)客户端设备基于overlay虚拟网络实例,利用第一WAN口与服务器对应的网关建立第三overlay隧道。
2)客户端设备基于overlay虚拟网络实例,利用第二WAN口与服务器对应的网关建立第四overlay隧道。
3)客户端设备利用第三overlay隧道和/或第四overlay隧道向网关发送报文。
本实施例中,当客户端设备存在多个WAN口时,可以通过不同的WAN口建立多个 overlay隧道,以便利用一个或多个overlay隧道向该overlay隧道对应的网关发送报文。其中,不同的WAN口可以对应的同一underlay网络,也可以对应不同的underlay网络。如图4e中,第一WAN口对应underlay网络1,第二WAN口对应underlay网络2。
在一种具体的实施方式中,当客户端设备存在多个WAN口时,可以预先配置主用WAN口和备用WAN口,客户端设备优先利用主用WAN口与网关建立的overlay隧道向网关发送报文,当主用WAN口的链路故障时,客户端设备可以备用WAN口与网关建立的overlay隧道向网关发送报文,提高报文传输效率,增加客户端设备的容错能力。其中,WAN口的链路故障可以包括WAN口故障导致的链路故障,也可以为客户端设备的WAN口与网关的WAN口之间的链路故障。
上述实施例说明了客户端设备与服务器的网关建立overlay隧道和使用overlay隧道发送报文的具体实现,下面将结合附图对客户端设备建立内环隧道和使用内环隧道发送报文的实现。
参见图5,该图为本申请实施例提供的一种建立内环隧道的实现流程图,如图5所示,该方法可以包括:
S501:客户端设备基于overlay虚拟网络实例与underlay虚拟网络实例建立内环隧道。
本实施例中,当客户端设备存在overlay虚拟网络实例和underlay虚拟网络实例时,建立两个虚拟网络实例之间的内环隧道。其中,underlay虚拟网络实例与客户端设备的WAN口关联,WAN口通过underlay网络与服务器互通。
其中,客户端设备自身对应的overlay虚拟网络实例可以为客户端设备上当前所存在的业务虚拟网络实例,该业务虚拟网络实例为overlay虚拟网络实例。图6a所示,在与LAN口关联的业务overlay虚拟网络实例中创建loopback接口,并为该loopback接口配置IP地址。基于该业务overlay虚拟网络实例与WAN口关联的underlay虚拟网络实例建立内环隧道。当然,客户端设备自身对应的overlay虚拟网络实例可以为新创建的overlay虚拟网络实例,其独立于业务overlay虚拟网络实例。如图6b所示,CPE新创建overlay虚拟网络实例,并在该overlay虚拟网络实例中创建loopback接口,并为该loopback接口配置IP地址,基于该overlay虚拟网络实例与WAN口对应的underlay虚拟网络实例建立内环隧道。
S502:客户端设备利用内环隧道以及underlay网络向服务器发送报文。
本实施例中,当客户端设备建立内环隧道后,可以利用该内环隧道以及WAN口对应的underlay网络向服务器发送报文。
在一种具体的实施方式中,当客户端设备存在多个WAN口,如果多个WAN口对应同一个underlay虚拟网络实例时,则客户端设备基于overlay虚拟网络实例以及underlay虚拟网络实例建立一个内环隧道。如果多个WAN口关联不同的underlay虚拟网络实例时,客户端设备可以基于overlay虚拟网络与每个WAN口关联的underlay虚拟网络建立内环隧道,从而获得多个内环隧道,实现容错机制。具体地,客户端设备基于overlay虚拟网络实例分别与各WAN口对应的underlay虚拟网络实例建立内环隧道;客户端设备利用所建立的内环隧道中的至少一个以及其对应的underlay网络向服务器发送报文。如图6c所示,当客户端设备包括第一WAN口和第二WAN口,第一WAN口对应underlay虚拟网络实例虚拟网 络实例1,第二WAN口对应underlay虚拟网络实例2。
当客户端设备存在多个WAN口且多个WAN口关联不同的underlay虚拟网络实例,具体建立内环隧道和使用内环隧道发送报文的实现报文:
1)客户端设备基于overlay虚拟网络实例与第一WAN口对应的underlay虚拟网络实例建立第一内环隧道。
例如,客户端设备基于overlay虚拟网络实例与underlay虚拟网络实例1建立第一内环隧道。
2)客户端设备基于overlay虚拟网络实例与第二WAN口对应的underlay虚拟网络实例建立第二内环隧道。
例如,客户端设备基于overlay虚拟网络实例与underlay虚拟网络实例2建立第二内环隧道。
3)客户端设备利用第一内环隧道以及第一WAN口对应的underlay网络向服务器发送报文,和/或利用第二内环隧道以及第二WAN口对应的underlay网络向服务器发送报文。
本实施例中,当客户端设备分别与不同的WAN口建立内环隧道时,可以利用每个WAN口对应的内环隧道以及该WAN口对应的underlay网络向服务器发送报文。其中,每个WAN口可以对应同一underlay网络,也可以对应不同的underlay网络。例如,图6c中,第一WAN口对应underlay网络1,第二WAN口对应underlay网络2。
在一种具体的实施方式中,当客户端设备存在多个WAN口时,可以配置主用WAN口和备用WAN口,以便在主用WAN口的链路故障时,可以备用WAN口的链路进行报文传输,保证报文传输质量。其中,与主用WAN口对应的underlay虚拟网络实例建立的内环隧道为主用内环隧道,与备用WAN口对应的underlay虚拟网络实例建立的内环隧道为备用内环隧道。客户端设备可以优先利用主用内环隧道以及主用WAN口对应的underlay网络向服务器发送报文。当主用WAN口的链路故障时,客户端设备可以利用备用内环隧道以及备用WAN口对应的underlay网络向服务器发送报文。WAN口的链路故障可以包括WAN口故障导致的链路故障,也可以为客户端设备的WAN口与网关的WAN口之间的链路故障。
在一种具体的实施方式中,当WAN口对应的网络存在NAT时,如Internet网络,为避免地址转换导致loopback接口的IP地址被转换为公网IP地址,可以直接将loopback接口的IP地址配置为公网IP地址,从而避免因进行NAT映射导致loopback接口IP地址被转换,从而使得客户端设备可以利用loopback接口的IP地址注册服务器。
上述实施例分别说明了客户端设备基于overlay虚拟网络实例建立overlay隧道和内环隧道,以及利用overlay隧道、内环隧道向服务器发送报文的具体实现。在一些实现方式中,当客户端设备同时建立overlay隧道和内环隧道时,可以设置overlay隧道的使用优先级高于内环隧道。即,可以以overlay隧道为主用路径,以内环隧道为备用路径。如图6d所示,客户端设备CPE基于overlay虚拟网络实例,利用WAN口与网关建立overlay隧道,同时CPE基于overlay虚拟网络实例以及WAN口对应的underlay虚拟网络实例建立内环隧道。
在一种具体的实施方式中,当服务器侧的网关故障时,无法利用overlay隧道向网关发 送报文,客户端设备可以从overlay隧道切换至内环隧道,利用内环隧道以及underlay网络向服务器发送报文,从而使得服务器可以根据报文中的IP地址识别客户端设备。
基于上述方法实施例,本申请实施例还提供了通信装置,下面将结合附图进行说明。
参见图7,该图为本申请实施例提供的一种通信装置结构图,该装置700能够应用于客户端设备,执行图2-图6所示实施例中客户端设备的功能,可以包括:
创建单元701,用于在overlay虚拟网络实例中创建loopback接口,并为所述loopback接口配置IP地址。关于创建单元701的具体实现方式,可以参考图2所示实施例中S201的详细描述。
建立单元702,用于基于所述overlay虚拟网络实例建立到服务器侧的传输通道。关于建立单元702的具体实现,可以参考图2所示实施例中S202的详细描述,或者图3所示实施例中S301的详细描述,或者图5所示实施例中S501的详细描述。
发送单元703,用于利用所述传输通道向服务器侧发送报文,所述报文至少包括所述IP地址。关于发送单元703的具体实现,可以参见图2所示实施例中S203的详细描述,或者图3所示实施例中S302的详细描述,或者图5所示实施例中S502的详细描述。
在一种具体的实施方式中,所述建立单元,具体用于建立所述overlay虚拟网络实例到所述服务器侧的overlay隧道;和/或,在所述overlay虚拟网络实例以及与服务器侧互通的虚拟网络实例间建立内环隧道。其中,关于建立overlay隧道的具体实现可以参见图3所示实施例中S301的详细描述,关于建立内环隧道的具体实现可以参见图5所示实施例中S501的详细描述。
在一种具体的实施方式中,当服务器侧存在对应的网关时,所述建立单元,具体用于建立所述overlay虚拟网络实例到服务器侧对应的网关的overlay隧道;
所述发送单元,具体用于利用所述overlay隧道向所述网关发送报文。
其中,建立单元702和发送单元703的具体实现,可以参见图3所示实施例中S301-S302的详细描述。
在一种具体的实施方式中,当服务器侧存在至少两个服务器且每个服务器对应不同的网关时,所述建立单元,具体用于基于所述overlay虚拟网络实例与各服务器对应的网关分别建立overlay隧道;
所述发送单元,具体用于利用所述overlay隧道中的至少一个向对应的网关发送报文。
其中,当服务器侧存在多个服务器时,建立单元702和发送单元703的具体实现可以参见图3所述实施例中S302的详细描述。
在一种具体的实施方式中,当所述至少两个服务器中包括主用服务器和备用服务器,所述发送单元,具体用于利用与所述主用服务器对应的网关建立的overlay隧道向所述主用服务器对应的网关发送报文,当所述主用服务器和/或所述主用服务器对应的网关故障时,所述客户端设备利用与所述备用服务器对应的网关建立的overlay隧道向所述备用服务器对应的网关发送报文。
其中,关于发送单元703使用主用服务器和备用服务器的具体实现,可以参见图3所述实施例中S302的详细描述。
在一种具体的实施方式中,其特征在于,当一个服务器对应至少两个网关时,所述建立单元,具体用于基于所述overlay虚拟网络实例与所述服务器对应的各网关分别建立overlay隧道;
所述发送单元,具体用于利用所述overlay隧道中的至少一个向对应的一网关发送报文。
其中,当一个服务器对应多个网关时,建立单元702的具体实现可以参见图3所述实施例中S302的详细描述。
在一种具体的实施方式中,所述至少两个网关包括主用网关和备用网关,所述发送单元,具体用于利用与所述主用网关建立的overlay隧道向所述主用网关发送报文,当所述主用网关出现故障时,利用与所述备用网关建立的overlay隧道向所述备用网关发送报文。
其中,当服务器对应主用网关和备用网关时,关于发送单元703使用主用网关和备用网关的具体实现可以参见图3所示实施例中S302的详细描述。
在一种具体的实施方式中,当所述装置存在至少两个WAN口时,每个所述WAN口具有对应的underlay虚拟网络实例,所述建立单元,具体用于基于所述overlay虚拟网络实例,利用每个WAN口分别与所述服务器对应的网关建立overlay隧道;
所述发送单元,具体用于利用所述overlay隧道中的至少一个向所述网关发送报文。
对于装置700所应用的客户端设备存在多个WAN口时,建立单元702和发送单元703的具体实现可以参见图3中S302的详细描述。
在一种具体的实施方式中,当所述两个WAN口包括主用WAN口和备用WAN口,所述发送单元,具体用于利用所述主用WAN口与所述网关建立的overlay隧道向所述网关发送报文,当所述主用WAN口故障时,利用所述备用WAN口与所述网关建立的overlay隧道向所述网关发送报文。
其中,关于发送单元703使用主用WAN口和备用WAN口的具体实现,可以参见图3所示实施例中的S302的详细描述。
在一种具体的实施方式中,当客户端设备的WAN口所对应的underlay网络类型为预设网络类型时,所述装置还包括:
加密单元,用于利用所述overlay隧道向所述网关发送报文之前,对报文进行加密,获得加密后的报文。
其中,关于加密单元的具体实现,可以参见图3所示实施例中S302的详细描述。
在一种具体的实施方式中,其特征在于,所述建立单元,具体用于基于所述overlay虚拟网络实例与underlay虚拟网络实例建立内环隧道,所述underlay虚拟网络实例与所述客户端设备的WAN口关联,所述WAN口通过underlay网络与所述服务器互通;
所述发送单元,具体用于利用所述内环隧道以及所述underlay网络向服务器发送报文。
其中,关于建立单元702的具体实现,可以参见图5所示实施例中S501的详细描述。
在一种具体的实施方式中,当所述客户端设备存在至少两个WAN口且不同的WAN口与不同的underlay虚拟网络实例绑定时,所述建立单元,具体用于基于所述overlay虚拟网络实例分别与各WAN口对应的underlay虚拟网络实例建立内环隧道;
所述发送单元,具体用于利用所述内环隧道中的至少一个以及其对应的underlay网络向服务器发送报文。
其中,当客户端设备存在多个WAN口时,建立单元702和发送单元703的具体实现,可以参见图5所示实施例中S502的详细描述。
在一种具体的实施方式中,所述至少两个WAN口中包括主用WAN口和备用WAN口,与所述主用WAN口对应的underlay虚拟网络实例建立的内环隧道为主用内环隧道,与所述备用WAN口对应的underlay虚拟网络实例建立的内环隧道为备用内环隧道,所述发送单元,具体用于利用所述主用内环隧道以及所述主用WAN口对应的underlay网络向服务器发送报文,当所述主用WAN口故障时,利用所述备用内环隧道以及所述备用WAN口对应的underlay网络向服务器发送报文。
其中,关于发送单元703使用主用WAN口和备用WAN口的具体实现,可以参见图5所示实施例中S502的详细描述。
在一种具体的实施方式中,当存在overlay隧道和内环隧道,所述overlay隧道的优先级高于所述内环隧道。
在一种具体的实施方式中,当所述服务器侧对应的网关故障时,所述装置还包括:
切换单元,用于从所述overlay隧道切换至所述内环隧道。
其中,关于切换单元的具体实现,可以参见图5所示实施例中S502的详细描述。
在一种具体的实施方式中,所述overlay虚拟网络实例为所述通信装置中业务虚拟网络实例,所述业务虚拟网络实例为overlay虚拟网络实例,或所述overlay虚拟网络实例为所述通信装置新建的overlay虚拟网络实例。
在一种具体的实施方式中,所述报文还包括WAN口对应的IP地址。
在一种具体的实施方式中,当所述通信装置对应的WAN口所连接的网络存在网络地址转换时,所述loopback接口所配置的IP地址为公网IP地址。
关于通信装置700具体可执行的功能和实现,可以参见图2-图6所示实施例中关于客户端设备的相应描述,此处不再赘述。
参见图8,该图为本申请实施例提供的另一种通信装置,该装置800能够应用于网关,执行图2-图6所示实施例中网关的功能,装置包括:
接收单元801,用于接收客户端设备发送的报文,所述报文包括所述客户端设备中loopback接口的IP地址,所述loopback接口位于所述客户端设备中的所述overlay虚拟网络实例中。其中,接收单元801的具体实现可以参见图2所示实施例中的S203的详细描述,或者图3所示实施例中S302的详细描述。
解析单元802,用于解析所述报文获取所述IP地址。其中,关于解析单元802的具体实现,可以参见图3所示实施例中S302的详细描述。
发送单元803,用于将所述IP地址发送给服务器,以使得所述服务器根据所述IP地址识别所述客户端设备。其中,关于发送单元803的具体实现,可以参见图3所示实施例中S302的详细描述。
在一种具体的实施方式中,当所述报文为加密报文时,所述装置还包括:
解密单元,用于解析所述报文之前,对所述报文进行解密。
其中,关于解密单元的具体实现,可以参见图3所示实施例中S302的详细描述。
关于通信装置800具体可执行的功能和实现,可以参见图2-图6所示实施例中关于客户端设备的相应描述,此处不再赘述。
参见图9,该图为本申请实施例提供的一种通信系统结构图,如图9所示,该系统可以包括客户端设备901和服务器902;
所述客户端设备901,用于在overlay虚拟网络实例中创建loopback接口,并为所述loopback接口配置IP地址;基于所述overlay虚拟网络实例建立到服务器侧的传输通道;利用所述传输通道向服务器发送报文,所述报文至少包括所述IP地址。
其中,关于客户端设备901的具体实现可以参见图2所示实施例S201-S203的详细描述,或者,图3所示实施例中S301和S302的详细描述,或者图5所示实施例中S501和S502的详细描述。
所述服务器902,用于根据所述报文中的IP地址识别所述客户端设备。
其中,服务器902的具体实现可以参见图2所示实施例中S203的详细描述,或者图3所示实施例中S302的详细描述,或者图5所示实施例中S502的详细描述。
一种可能的实现方式中,所述客户端设备,具体用于建立所述overlay虚拟网络实例到所述服务器侧的overlay隧道;和/或,在所述overlay虚拟网络实例以及服务器侧互通的虚拟网络实例间建立内环隧道。其中,关于客户端设备901的具体实现,可以参见图3所示实施例中S301-S302的详细描述,或者图5所示实施例中S501-S502的详细描述。
一种可能的实现方式中,所述系统还包括:网关,所述网关与所述服务器通信,所述客户端设备,具体用于建立所述overlay虚拟网络实例到所述服务器对应的网关的overlay隧道;利用所述overlay隧道向所述网关发送报文;
所述网关,用于解析所述报文获取所述IP地址,并将所述IP地址发送给服务器。
其中,关于网关的具体实现,可以参见图3所示实施例中S302的详细描述。
一种可能的实现方式中,所述系统包括主用网关和备用网关,所述主用网关和所述备用网关均与所述服务器通信,所述客户端设备,具体用于利用与所述主用网关建立的overlay隧道向所述主用网关发送报文,当所述主用网关故障时,利用与所述备用网关建立的overlay隧道向所述备用网关发送报文。
其中,当系统包括主用网关和备用网关时,客户端设备的具体实现可以参见图3所示实施例中S302的详细描述。
一种可能的实现方式中,所述客户端设备,具体用于基于所述overlay虚拟网络实例与underlay虚拟网络实例建立内环隧道,所述underlay虚拟网络实例与所述客户端设备的WAN口关联,所述WAN口通过underlay网络与所述服务器互通;利用所述内环隧道以及所述underlay网络向所述服务器发送报文。
其中,客户端设备建立内环隧道的具体实现,可以参见图5所示实施例中S501和S502的详细描述。
一种可能的实现方式中,当服务器侧对应的的网关故障时,所述客户端设备,还用于 从所述overlay隧道切换至所述内环隧道。
其中,客户端设备进行切换的具体实现,可以参见图5所示实施例中S502的详细描述。
需要说明的是,本实施例中客户端设备901的具体实现可以参见图2-图6所述实施例,服务器902的具体实现可以参见图2-图6所述实施例,本实施例在此不再赘述。
图10为本申请实施例提供的一种通信设备的结构示意图,该通信设备例如可以是图2-图6所示实施例中的客户端设备或网关设备,或者也可以是图7或图8所示实施例中的通信装置的设备实现。
请参阅图10所示,网络设备1000包括:处理器1010、通信接口1020和存储器1030。其中报文转发设备1000中的处理器1010的数量可以一个或多个,图10中以一个处理器为例。本申请实施例中,处理器1010、通信接口1020和存储器1030可通过总线系统或其它方式连接,其中,图10中以通过总线系统1040连接为例。
处理器1010可以是CPU、NP、或者CPU和NP的组合。处理器1010还可以进一步包括硬件芯片。上述硬件芯片可以是专用集成电路(application-specific integrated circuit,ASIC),可编程逻辑器件(programmable logic device,PLD)或其组合。上述PLD可以是复杂可编程逻辑器件(complex programmable logic device,CPLD),现场可编程逻辑门阵列(field-programmable gate array,FPGA),通用阵列逻辑(generic array logic,GAL)或其任意组合。
通信接口1020用于接收和发送报文,具体地,通信接口1020可以包括接收接口和发送接口。其中,接收接口可以用于接收报文,发送接口可以用于发送报文。通信接口1020的个数可以为一个或多个。
存储器1030可以包括易失性存储器(英文:volatile memory),例如随机存取存储器(random-access memory,RAM);存储器1030也可以包括非易失性存储器(英文:non-volatile memory),例如快闪存储器(英文:flash memory),硬盘(hard disk drive,HDD)或固态硬盘(solid-state drive,SSD);存储器1030还可以包括上述种类的存储器的组合。
可选地,存储器1030存储有操作系统和程序、可执行模块或者数据结构,或者它们的子集,或者它们的扩展集,其中,程序可包括各种操作指令,用于实现各种操作。操作系统可包括各种系统程序,用于实现各种基础业务以及处理基于硬件的任务。处理器1010可以读取存储器1030中的程序,实现本申请实施例提供的通信传输方法。
其中,存储器1030可以为通信设备1000中的存储器件,也可以为独立于通信设备1000的存储装置。
总线系统1040可以是外设部件互连标准(peripheral component interconnect,PCI)总线或扩展工业标准结构(extended industry standard architecture,EISA)总线等。总线系统1040可以分为地址总线、数据总线、控制总线等。为便于表示,图10中仅用一条粗线表示,但并不表示仅有一根总线或一种类型的总线。
此外,本申请实施例还提供了一种网关,该所述网关包括:处理器和存储器;所述存储器,用于存储指令;所述处理器,用于执行所述存储器中的所述指令,执行本申请实施例中网关所对应的操作。
本申请实施例还提供了一种计算机可读存储介质,包括指令,当其在计算机上运行时,使得计算机执行以上所述的通信方法。
本申请的说明书和权利要求书及上述附图中的术语“第一”、“第二”、“第三”、“第四”等(如果存在)是用于区别类似的对象,而不必用于描述特定的顺序或先后次序。应该理解这样使用的数据在适当情况下可以互换,以便这里描述的实施例能够以除了在这里图示或描述的内容以外的顺序实施。此外,术语“包括”和“具有”以及他们的任何变形,意图在于覆盖不排他的包含,例如,包含了一系列步骤或单元的过程、方法、系统、产品或设备不必限于清楚地列出的那些步骤或单元,而是可包括没有清楚地列出的或对于这些过程、方法、产品或设备固有的其它步骤或单元。
所属领域的技术人员可以清楚地了解到,为描述的方便和简洁,上述描述的系统,装置和单元的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。
在本申请所提供的几个实施例中,应该理解到,所揭露的系统,装置和方法,可以通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,单元的划分,仅仅为一种逻辑业务划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性,机械或其它的形式。
作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。
另外,在本申请各个实施例中的各业务单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件业务单元的形式实现。
集成的单元如果以软件业务单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质中,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行本申请各个实施例方法的全部或部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random Access Memory)、磁碟或者光盘等各种可以存储程序代码的介质。
本领域技术人员应该可以意识到,在上述一个或多个示例中,本发明所描述的业务可以用硬件、软件、固件或它们的任意组合来实现。当使用软件实现时,可以将这些业务存储在计算机可读介质中或者作为计算机可读介质上的一个或多个指令或代码进行传输。计算机可读介质包括计算机存储介质和通信介质,其中通信介质包括便于从一个地方向另一个地方传送计算机程序的任何介质。存储介质可以是通用或专用计算机能够存取的任何可用介质。
以上的具体实施方式,对本发明的目的、技术方案和有益效果进行了进一步详细说明,所应理解的是,以上仅为本发明的具体实施方式而已。
以上,以上实施例仅用以说明本申请的技术方案,而非对其限制;尽管参照前述实施例对本申请进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本申请各实施例技术方案的范围。

Claims (49)

  1. 一种通信方法,其特征在于,所述方法包括:
    客户端设备在叠加overlay虚拟网络实例中创建环回loopback接口,并为所述loopback接口配置IP地址;
    所述客户端设备基于所述overlay虚拟网络实例建立到服务器侧的传输通道;
    所述客户端设备利用所述传输通道向服务器侧发送报文,所述报文至少包括所述IP地址。
  2. 根据权利要求1所述的方法,其特征在于,所述客户端设备基于所述overlay虚拟网络实例建立到服务器侧的传输通道,包括:
    所述客户端设备建立所述overlay虚拟网络实例到所述服务器侧的overlay隧道;和/或,
    所述客户端设备在所述overlay虚拟网络实例以及与服务器侧互通的虚拟网络实例间建立内环隧道。
  3. 根据权利要求2所述的方法,其特征在于,当服务器侧存在与所述服务器对应的网关时,所述客户端设备建立所述overlay虚拟网络实例到服务器侧的overlay隧道,包括:
    所述客户端设备建立所述overlay虚拟网络实例到所述服务器对应的网关的overlay隧道;
    所述客户端设备利用所述传输通道向服务器侧发送报文,包括:
    所述客户端设备利用所述overlay隧道向所述网关发送报文。
  4. 根据权利要求3所述的方法,其特征在于,当服务器侧存在至少两个服务器,且每个服务器对应不同的网关时,所述客户端设备建立所述overlay虚拟网络实例到所述服务器对应的网关的overlay隧道,包括:
    所述客户端设备基于所述overlay虚拟网络实例与各服务器对应的网关分别建立overlay隧道;
    所述客户端设备利用所述overlay隧道向所述网关发送报文,包括:
    所述客户端设备利用所述overlay隧道中的至少一个向对应的网关发送报文。
  5. 根据权利要求4所述的方法,其特征在于,所述至少两个服务器中包括主用服务器和备用服务器,所述客户端设备利用所述overlay隧道中的至少一个向对应的网关发送报文,包括:
    所述客户端设备利用与所述主用服务器对应的网关建立的overlay隧道向所述主用服务器对应的网关发送报文,当所述主用服务器和/或所述主用服务器对应的网关故障时,所述客户端设备利用与所述备用服务器对应的网关建立的overlay隧道向所述备用服务器对应的网关发送报文。
  6. 根据权利要求3-5任一项所述的方法,其特征在于,当一个服务器对应至少两个网关时,所述客户端设备建立所述overlay虚拟网络实例到所述服务器对应的网关的overlay隧道,包括:
    所述客户端设备基于所述overlay虚拟网络实例与所述服务器对应的各网关分别建立overlay隧道;
    所述客户端设备利用所述overlay隧道向所述服务器发送报文,包括:
    所述客户端设备利用所述overlay隧道中的至少一个向对应的网关发送报文。
  7. 根据权利要求6所述的方法,其特征在于,所述至少两个网关包括主用网关和备用网关,所述客户端设备利用所述overlay隧道中的至少一个向对应的网关发送报文,包括:
    所述客户端设备利用与所述主用网关建立的overlay隧道向所述主用网关发送报文,当所述主用网关出现故障时,所述客户端设备利用与所述备用网关建立的overlay隧道向所述备用网关发送报文。
  8. 根据权利要求3-7任一项所述的方法,其特征在于,当所述客户端设备存在至少两个WAN口时,每个所述WAN口具有对应的underlay虚拟网络实例,所述客户端设备建立所述overlay虚拟网络实例到所述服务器对应的网关的overlay隧道,包括:
    所述客户端设备基于所述overlay虚拟网络实例,利用每个WAN口分别与所述服务器对应的网关建立overlay隧道;
    所述客户端设备利用所述overlay隧道向所述网关发送报文,包括:
    所述客户端设备利用所述overlay隧道中的至少一个向所述网关发送报文。
  9. 根据权利要求8所述的方法,其特征在于,所述至少两个WAN口包括主用WAN口和备用WAN口,所述客户端设备利用所述overlay隧道向所述网关发送报文,包括:
    所述客户端设备利用所述主用WAN口与所述网关建立的overlay隧道向所述网关发送报文,当所述主用WAN口的链路故障时,所述客户端设备利用所述备用WAN口与所述网关建立的overlay隧道向所述网关发送报文。
  10. 根据权利要求3-9任一项所述的方法,其特征在于,当客户端设备的WAN口所对应的底层underlay网络类型为预设网络类型时,所述客户端设备利用所述overlay隧道向所述网关发送报文之前,所述方法还包括:
    所述客户端设备对报文进行加密,获得加密后的报文。
  11. 根据权利要求1-10任一项所述的方法,其特征在于,所述客户端设备在所述overlay虚拟网络实例以及与服务器侧互通的虚拟网络实例间建立内环隧道,包括:
    所述客户端设备基于所述overlay虚拟网络实例与underlay虚拟网络实例建立内环隧道,所述underlay虚拟网络实例与所述客户端设备的WAN口关联,所述WAN口通过underlay网络与所述服务器互通;
    所述客户端利用所述传输通道向服务器侧发送报文,包括:
    所述客户端设备利用所述内环隧道以及所述underlay网络向所述服务器发送报文。
  12. 根据权利要求11所述的方法,其特征在于,当所述客户端设备存在至少两个WAN口且不同的WAN口与不同的underlay虚拟网络实例绑定时,所述客户端设备基于所述overlay虚拟网络实例与underlay虚拟网络实例建立内环隧道,包括:
    所述客户端设备基于所述overlay虚拟网络实例分别与各WAN口对应的underlay虚拟网络实例建立内环隧道;
    所述客户端设备利用所述内环隧道以及所述underlay网络向服务器发送报文,包括:
    所述客户端设备利用所述内环隧道中的至少一个以及其对应的underlay网络向服务器 发送报文。
  13. 根据权利要求12所述的方法,其特征在于,所述至少两个WAN口中包括主用WAN口和备用WAN口,与所述主用WAN口对应的underlay虚拟网络实例建立的内环隧道为主用内环隧道,与所述备用WAN口对应的underlay虚拟网络实例建立的内环隧道为备用内环隧道,所述客户端利用所述内环隧道中的至少一个以及其对应的underlay网络向服务器发送报文,包括:
    所述客户端设备利用所述主用内环隧道以及所述主用WAN口对应的underlay网络向服务器发送报文,当所述主用WAN口的链路故障时,所述客户端设备利用所述备用内环隧道以及所述备用WAN口对应的underlay网络向服务器发送报文。
  14. 根据权利要求1-13任一项所述的方法,其特征在于,当所述客户端设备存在overlay隧道和内环隧道,所述overlay隧道的优先级高于所述内环隧道。
  15. 根据权利要求14所述的方法,其特征在于,当所述服务器侧对应的网关故障时,所述方法还包括:
    所述客户端设备从所述overlay隧道切换至所述内环隧道。
  16. 根据权利要求1-15任一项所述的方法,其特征在于,所述overlay虚拟网络实例为所述客户端设备中业务虚拟网络实例,所述业务虚拟网络实例为overlay虚拟网络实例,或所述overlay虚拟网络实例为所述客户端设备新建的overlay虚拟网络实例。
  17. 根据权利要求1-16任一项所述的方法,其特征在于,所述报文还包括WAN口对应的IP地址。
  18. 根据权利要求1-17任一项所述的方法,其特征在于,当所述客户端设备对应的WAN口所连接的网络存在网络地址转换时,所述loopback接口所配置的IP地址为公网IP地址。
  19. 一种通信方法,其特征在于,所述方法包括:
    网关接收客户端设备发送的报文,所述报文包括所述客户端设备中loopback接口的IP地址,所述loopback接口位于所述客户端设备中的overlay虚拟网络实例中;
    所述网关解析所述报文获取所述IP地址,并将所述IP地址发送给服务器,以使得所述服务器根据所述IP地址识别所述客户端设备。
  20. 根据权利要求19所述的方法,其特征在于,当所述报文为加密报文时,所述网关解析所述报文之前,所述方法还包括:
    所述网关对所述报文进行解密。
  21. 一种通信装置,其特征在于,所述装置包括:
    创建单元,用于在overlay虚拟网络实例中创建loopback接口,并为所述loopback接口配置IP地址;
    建立单元,用于基于所述overlay虚拟网络实例建立到服务器侧的传输通道;
    发送单元,用于利用所述传输通道向服务器侧发送报文,所述报文至少包括所述IP地址。
  22. 根据权利要求21所述的装置,其特征在于,所述建立单元,具体用于建立所述overlay虚拟网络实例到所述服务器侧的overlay隧道;和/或,在所述overlay虚拟网络实例以及与 服务器侧互通的虚拟网络实例间建立内环隧道。
  23. 根据权利要求22所述的装置,其特征在于,当服务器侧存在对应的网关时,所述建立单元,具体用于建立所述overlay虚拟网络实例到服务器侧对应的网关的overlay隧道;
    所述发送单元,具体用于利用所述overlay隧道向所述网关发送报文。
  24. 根据权利要求23所述的装置,其特征在于,当服务器侧存在至少两个服务器且每个服务器对应不同的网关时,所述建立单元,具体用于基于所述overlay虚拟网络实例与各服务器对应的网关分别建立overlay隧道;
    所述发送单元,具体用于利用所述overlay隧道中的至少一个向对应的网关发送报文。
  25. 根据权利要求24所述的装置,其特征在于,当所述至少两个服务器中包括主用服务器和备用服务器,所述发送单元,具体用于利用与所述主用服务器对应的网关建立的overlay隧道向所述主用服务器对应的网关发送报文,当所述主用服务器和/或所述主用服务器对应的网关故障时,所述客户端设备利用与所述备用服务器对应的网关建立的overlay隧道向所述备用服务器对应的网关发送报文。
  26. 根据权利要求23-25任一项所述的装置,其特征在于,当一个服务器对应至少两个网关时,所述建立单元,具体用于基于所述overlay虚拟网络实例与所述服务器对应的各网关分别建立overlay隧道;
    所述发送单元,具体用于利用所述overlay隧道中的至少一个向对应的一网关发送报文。
  27. 根据权利要求26所述的装置,其特征在于,所述至少两个网关包括主用网关和备用网关,所述发送单元,具体用于利用与所述主用网关建立的overlay隧道向所述主用网关发送报文,当所述主用网关出现故障时,利用与所述备用网关建立的overlay隧道向所述备用网关发送报文。
  28. 根据权利要求24-27任一项所述的装置,其特征在于,当所述客户端设备存在至少两个WAN口时,每个所述WAN口具有对应的underlay虚拟网络实例,所述建立单元,具体用于基于所述overlay虚拟网络实例,利用每个WAN口分别与所述服务器对应的网关建立overlay隧道;
    所述发送单元,具体用于利用所述overlay隧道中的至少一个向所述网关发送报文。
  29. 根据权利要求28所述的装置,其特征在于,当所述两个WAN口包括主用WAN口和备用WAN口,所述发送单元,具体用于利用所述主用WAN口与所述网关建立的overlay隧道向所述网关发送报文,当所述主用WAN口故障时,利用所述备用WAN口与所述网关建立的overlay隧道向所述网关发送报文。
  30. 根据权利要求23-29任一项所述的装置,其特征在于,当客户端设备的WAN口所对应的underlay网络类型为预设网络类型时,所述装置还包括:
    加密单元,用于利用所述overlay隧道向所述网关发送报文之前,对报文进行加密,获得加密后的报文。
  31. 根据权利要求22-30任一项所述的装置,其特征在于,所述建立单元,具体用于基于所述overlay虚拟网络实例与underlay虚拟网络实例建立内环隧道,所述underlay虚拟网 络实例与所述客户端设备的WAN口关联,所述WAN口通过underlay网络与所述服务器互通;
    所述发送单元,具体用于利用所述内环隧道以及所述underlay网络向服务器发送报文。
  32. 根据权利要求31所述的装置,其特征在于,当所述装置存在至少两个WAN口且不同的WAN口与不同的underlay虚拟网络实例绑定时,所述建立单元,具体用于基于所述overlay虚拟网络实例分别与各WAN口对应的underlay虚拟网络实例建立内环隧道;
    所述发送单元,具体用于利用所述内环隧道中的至少一个以及其对应的underlay网络向服务器发送报文。
  33. 根据权利要求32所述的装置,其特征在于,所述至少两个WAN口中包括主用WAN口和备用WAN口,与所述主用WAN口对应的underlay虚拟网络实例建立的内环隧道为主用内环隧道,与所述备用WAN口对应的underlay虚拟网络实例建立的内环隧道为备用内环隧道,所述发送单元,具体用于利用所述主用内环隧道以及所述主用WAN口对应的underlay网络向服务器发送报文,当所述主用WAN口故障时,利用所述备用内环隧道以及所述备用WAN口对应的underlay网络向服务器发送报文。
  34. 根据权利要求22-33任一项所述的装置,其特征在于,当存在overlay隧道和内环隧道,所述overlay隧道的优先级高于所述内环隧道。
  35. 根据权利要求34所述的装置,其特征在于,当所述服务器侧对应的网关故障时,所述装置还包括:
    切换单元,用于从所述overlay隧道切换至所述内环隧道。
  36. 根据权利要求22-35任一项所述的装置,其特征在于,所述overlay虚拟网络实例为所述通信装置中业务虚拟网络实例,所述业务虚拟网络实例为overlay虚拟网络实例,或所述overlay虚拟网络实例为所述通信装置新建的overlay虚拟网络实例。
  37. 根据权利要求21-36任一项所述的装置,其特征在于,所述报文还包括WAN口对应的IP地址。
  38. 根据权利要求21-37任一项所述的装置,其特征在于,当所述通信装置对应的WAN口所连接的网络存在网络地址转换时,所述loopback接口所配置的IP地址为公网IP地址。
  39. 一种通信装置,其特征在于,所述装置包括:
    接收单元,用于接收客户端设备发送的报文,所述报文包括所述客户端设备中loopback接口的IP地址,所述loopback接口位于所述客户端设备中的所述overlay虚拟网络实例中;
    解析单元,用于解析所述报文获取所述IP地址;
    发送单元,用于将所述IP地址发送给服务器,以使得所述服务器根据所述IP地址识别所述客户端设备。
  40. 根据权利要求39所述的装置,其特征在于,当所述报文为加密报文时,所述装置还包括:
    解密单元,用于解析所述报文之前,对所述报文进行解密。
  41. 一种通信设备,所述设备包括:处理器和存储器;
    所述存储器,用于存储指令;
    所述处理器,用于执行所述存储器中的所述指令,执行权利要求1-18任意一项所述的方法。
  42. 一种网关,所述网关包括:处理器和存储器;
    所述存储器,用于存储指令;
    所述处理器,用于执行所述存储器中的所述指令,执行权利要求19或20所述的方法。
  43. 一种通信系统,所述系统包括:客户端设备和服务器,
    所述客户端设备,用于在overlay虚拟网络实例中创建loopback接口,并为所述loopback接口配置IP地址;基于所述overlay虚拟网络实例建立到服务器侧的传输通道;利用所述传输通道向服务器发送报文,所述报文至少包括所述IP地址;
    所述服务器,用于根据所述报文中的IP地址识别所述客户端设备。
  44. 根据权利要求43所述的系统,其特征在于,所述客户端设备,具体用于建立所述overlay虚拟网络实例到所述服务器侧的overlay隧道;和/或,在所述overlay虚拟网络实例以及服务器侧互通的虚拟网络实例间建立内环隧道。
  45. 根据权利要求44所述的系统,其特征在于,所述系统还包括:网关,所述网关与所述服务器通信,所述客户端设备,具体用于建立所述overlay虚拟网络实例到所述服务器对应的网关的overlay隧道;利用所述overlay隧道向所述网关发送报文;
    所述网关,用于解析所述报文获取所述IP地址,并将所述IP地址发送给服务器。
  46. 根据权利要求45所述的系统,其特征在于,所述系统包括主用网关和备用网关,所述主用网关和所述备用网关均与所述服务器通信,所述客户端设备,具体用于利用与所述主用网关建立的overlay隧道向所述主用网关发送报文,当所述主用网关故障时,利用与所述备用网关建立的overlay隧道向所述备用网关发送报文。
  47. 根据权利要求44-45任一项所述的系统,其特征在于,所述客户端设备,具体用于基于所述overlay虚拟网络实例与underlay虚拟网络实例建立内环隧道,所述underlay虚拟网络实例与所述客户端设备的WAN口关联,所述WAN口通过underlay网络与所述服务器互通;利用所述内环隧道以及所述underlay网络向所述服务器发送报文。
  48. 根据权利要求44所述的系统,其特征在于,当服务器侧对应的网关故障时,所述客户端设备,还用于从所述overlay隧道切换至所述内环隧道。
  49. 一种计算机可读存储介质,包括指令,当其在计算机上运行时,使得计算机执行以上权利要求1-20任意一项所述的方法。
PCT/CN2021/093719 2020-08-31 2021-05-14 一种通信方法、装置、设备及系统 WO2022041851A1 (zh)

Priority Applications (2)

Application Number Priority Date Filing Date Title
EP21859696.3A EP4195599A4 (en) 2020-08-31 2021-05-14 COMMUNICATION METHOD AND DEVICE AS WELL AS DEVICE AND SYSTEM
US18/176,229 US20230208680A1 (en) 2020-08-31 2023-02-28 Communication method, and communications apparatus, device, and system

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202010895959.1 2020-08-31
CN202010895959.1A CN114124617A (zh) 2020-08-31 2020-08-31 一种通信方法、装置、设备及系统

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US18/176,229 Continuation US20230208680A1 (en) 2020-08-31 2023-02-28 Communication method, and communications apparatus, device, and system

Publications (1)

Publication Number Publication Date
WO2022041851A1 true WO2022041851A1 (zh) 2022-03-03

Family

ID=80352577

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/093719 WO2022041851A1 (zh) 2020-08-31 2021-05-14 一种通信方法、装置、设备及系统

Country Status (4)

Country Link
US (1) US20230208680A1 (zh)
EP (1) EP4195599A4 (zh)
CN (1) CN114124617A (zh)
WO (1) WO2022041851A1 (zh)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106330605A (zh) * 2016-08-23 2017-01-11 杭州华三通信技术有限公司 一种报文处理方法及装置
US20170346736A1 (en) * 2016-05-27 2017-11-30 Cisco Technology, Inc. Techniques for managing software defined networking controller in-band communications in a data center network
CN108429824A (zh) * 2018-05-31 2018-08-21 新华三技术有限公司 一种地址分配方法及装置
CN109995654A (zh) * 2017-12-29 2019-07-09 中兴通讯股份有限公司 一种基于隧道传输数据的方法及装置

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
BR112012033693B8 (pt) * 2010-06-29 2022-07-19 Huawei Tech Co Ltd Componente de rede para encaminhamento de quadro de dados
CN108075969B (zh) * 2016-11-17 2020-01-03 新华三技术有限公司 报文转发方法和装置
US10567482B2 (en) * 2017-08-24 2020-02-18 Nicira, Inc. Accessing endpoints in logical networks and public cloud service providers native networks using a single network interface and a single routing table
CN108259302B (zh) * 2017-10-31 2021-04-27 新华三技术有限公司 一种集中式网关组网实现方法及装置

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20170346736A1 (en) * 2016-05-27 2017-11-30 Cisco Technology, Inc. Techniques for managing software defined networking controller in-band communications in a data center network
CN106330605A (zh) * 2016-08-23 2017-01-11 杭州华三通信技术有限公司 一种报文处理方法及装置
CN109995654A (zh) * 2017-12-29 2019-07-09 中兴通讯股份有限公司 一种基于隧道传输数据的方法及装置
CN108429824A (zh) * 2018-05-31 2018-08-21 新华三技术有限公司 一种地址分配方法及装置

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
L. DUNBAR FUTUREWEI B. SARIKAYA DENPEL INFORMATIQUE B.KHASNABISH INDEPENDENT T. HERBERT INTEL S. DIKSHIT ARUBA-HPE: "Virtual Machine Mobility Solutions for L2 and L3 Overlay Networks; draft-ietf-nvo3-vmm-16.txt", VIRTUAL MACHINE MOBILITY SOLUTIONS FOR L2 AND L3 OVERLAY NETWORKS; DRAFT-IETF-NVO3-VMM-16.TXT, no. 16, 17 June 2020 (2020-06-17), pages 1 - 17, XP015140131 *
See also references of EP4195599A4

Also Published As

Publication number Publication date
EP4195599A4 (en) 2024-01-17
CN114124617A (zh) 2022-03-01
US20230208680A1 (en) 2023-06-29
EP4195599A1 (en) 2023-06-14

Similar Documents

Publication Publication Date Title
US11711242B2 (en) Secure SD-WAN port information distribution
Lasserre et al. Framework for data center (DC) network virtualization
US9787583B2 (en) Methods and apparatus for implementing connectivity between edge devices via a switch fabric
US7447901B1 (en) Method and apparatus for establishing a dynamic multipoint encrypted virtual private network
US7366894B1 (en) Method and apparatus for dynamically securing voice and other delay-sensitive network traffic
WO2019024880A1 (zh) 发送报文的方法和网络设备
WO2018040529A1 (zh) 一种报文处理方法、设备及系统
US20110113236A1 (en) Methods, systems, and computer readable media for offloading internet protocol security (ipsec) processing using an ipsec proxy mechanism
US20130061034A1 (en) Transparent Mode Encapsulation
US8817815B2 (en) Traffic optimization over network link
EP3459210B1 (en) Troubleshooting multi-layered networks using datapath analysis
JP6107498B2 (ja) 通信方法、通信装置及び通信プログラム
WO2021082803A1 (zh) 路由信息传输方法及装置、数据中心互联网络
EP3817285B1 (en) Method and device for monitoring forwarding table entry
WO2020048348A1 (zh) 数据传输方法和系统
JP2023503825A (ja) パケット転送方法、第1のネットワークデバイス、および第1のデバイスグループ
US20230254183A1 (en) Generating route target values for virtual private network routes
JP4011528B2 (ja) ネットワーク仮想化システム
WO2022041851A1 (zh) 一种通信方法、装置、设备及系统
US20220247598A1 (en) Packet Detection Method, Connectivity Negotiation Relationship Establishment Method, and Related Device
US20220294734A1 (en) Method for Configuring Media Access Control Address Aging Time and Apparatus
CN113300998A (zh) 实现数据加密传输的方法及装置、通信系统
US11695690B1 (en) Network address translation with in-band return path resolution
CN218920438U (zh) 一种基于vxlan的互联网接入控制系统
WO2022267875A1 (zh) 一种报文传输的方法及相关设备

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: 21859696

Country of ref document: EP

Kind code of ref document: A1

ENP Entry into the national phase

Ref document number: 2021859696

Country of ref document: EP

Effective date: 20230309

NENP Non-entry into the national phase

Ref country code: DE