CN107147575B - Method, device and system for realizing management channel switching - Google Patents

Method, device and system for realizing management channel switching Download PDF

Info

Publication number
CN107147575B
CN107147575B CN201710402871.XA CN201710402871A CN107147575B CN 107147575 B CN107147575 B CN 107147575B CN 201710402871 A CN201710402871 A CN 201710402871A CN 107147575 B CN107147575 B CN 107147575B
Authority
CN
China
Prior art keywords
management
sdn
message
access device
address
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201710402871.XA
Other languages
Chinese (zh)
Other versions
CN107147575A (en
Inventor
王晓杰
谢维
李琼
王鹏
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Raisecom Technology Co Ltd
Original Assignee
Raisecom Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Raisecom Technology Co Ltd filed Critical Raisecom Technology Co Ltd
Priority to CN201710402871.XA priority Critical patent/CN107147575B/en
Publication of CN107147575A publication Critical patent/CN107147575A/en
Application granted granted Critical
Publication of CN107147575B publication Critical patent/CN107147575B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/22Alternate routing
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/46Interconnection of networks
    • H04L12/4641Virtual LANs, VLANs, e.g. virtual private networks [VPN]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/10Active monitoring, e.g. heartbeat, ping or trace-route
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L61/00Network arrangements, protocols or services for addressing or naming
    • H04L61/50Address allocation
    • H04L61/5007Internet protocol [IP] addresses
    • H04L61/5014Internet protocol [IP] addresses using dynamic host configuration protocol [DHCP] or bootstrap protocol [BOOTP]

Landscapes

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

Abstract

The application discloses a method, a device and a system for realizing management channel switching; the method for realizing management channel switching comprises the following steps: after a first SDN access device establishes an OpenFlow connection with an SDN controller through a management channel, sending a detection message to the SDN controller according to a detection period, and detecting a detection response message returned by the SDN controller; when the detection result of the detection response message meets the management channel switching condition, the first SDN access device removes all interfaces of the first SDN access device from the management VLAN, and sends a first preset message carrying a message sequence number.

Description

Method, device and system for realizing management channel switching
Technical Field
The present invention relates to network communication technologies, and in particular, to a method, an apparatus, and a system for implementing management channel switching.
Background
SDN (Software Defined Network) is a new Network architecture, and its core is forwarding and control separation. Under the SDN framework, the control plane is moved to the SDN controller, and the SDN equipment forwards messages according to the indication of the SDN controller.
Due to the fact that access equipment in the SDN is larger and larger in scale and wider in distribution range, batch online of the equipment brings a series of problems that repeated configuration is carried out, workload is large, and equipment disconnection needs manual intervention to be recovered.
Disclosure of Invention
The following is a summary of the subject matter described in detail herein. This summary is not intended to limit the scope of the claims.
The embodiment of the application provides a method, a device and a system for realizing management channel switching, which realize automatic switching of management channels and save switching overhead.
In a first aspect, an embodiment of the present application provides a method for implementing management channel switching, which is applied to a first SDN access device, and includes:
after a first SDN access device establishes an OpenFlow connection with an SDN controller through a management channel, sending a detection message to the SDN controller according to a detection period, and detecting a detection response message returned by the SDN controller;
when the detection result of the detection response message meets the management channel switching condition, the first SDN access device removes all interfaces of the first SDN access device from a management Virtual Local Area Network (VLAN), and sends a first preset message carrying a message sequence number.
The management channel switching condition may include: detecting response messages replied by the SDN controller are not received within the timeout duration for N times or M times continuously; wherein N is the number of detection cycles for managing channel switching, M is the number of detection cycles for OpenFlow disconnection, N, M are positive integers, and N is smaller than M.
After the sending of the first predetermined message, the method may further include:
receiving a first response message sent by the SDN controller and aiming at the first preset message;
configuring a local management IP address according to the management IP address carried by the first response message and enabling the management IP address to take effect locally, or enabling the locally configured management IP address to take effect according to the first response message;
and adding the interface receiving the first response message into a management VLAN.
The establishing, by the first SDN access device, an OpenFlow connection with an SDN controller through a management channel may include:
the first SDN access equipment sends a second preset message; the message serial number carried by the second preset message is smaller than the message serial number carried by the first preset message;
receiving a second response message from the SDN controller for the second predetermined message;
configuring a local management IP address according to the management IP address carried by the second response message and enabling the management IP address to take effect locally, or enabling the locally configured management IP address to take effect according to the second response message;
adding the interface receiving the second response message into a management VLAN;
and establishing an OpenFlow connection with the SDN controller through an established management channel between the SDN controller and the OpenFlow connection.
The sending, by the first SDN access device, a second predetermined packet may include:
when the first SDN access device judges that the first SDN access device does not have a configured management IP address, the second preset message carries a management IP address set to be empty;
when the first SDN access device judges that the configured management IP address exists, the configured management IP address is carried in the second preset message.
When the second predetermined packet carries a configured management IP address, the management IP address allocated to the first SDN access device carried by the second response packet may be the configured management IP address.
Wherein, the second response message may also carry the following information: detecting period time interval, the number of detecting periods of OpenFlow disconnection, and the number of detecting periods of management channel switching;
after receiving a second response packet from the SDN controller for the second predetermined packet, the method may further include: and recording the information carried by the second response message.
After the first SDN access device establishes an OpenFlow connection with the SDN controller through a management channel, the method may further include:
receiving a third preset message carrying a message serial number of a second SDN access device;
when the interface receiving the third predetermined message is a management interface, sending the third predetermined message to the SDN controller through an established management channel; when the interface receiving the third predetermined message is a non-management interface, transmitting the third predetermined message to the SDN controller through an OpenFlow protocol message, and adding the interface receiving the third predetermined message into a management VLAN according to the notification of the SDN controller;
and transmitting a third response message, which is returned by the SDN controller and is directed to the third predetermined message, to the second SDN access device through a management interface.
The method can also be applied to a second SDN access device connected with the first SDN access device; the above method may further comprise:
the second SDN access equipment sends a third preset message carrying a message serial number;
receiving a third response message sent by the SDN controller and sent by the first SDN access device for the third predetermined message;
configuring a local management IP address according to the management IP address carried by the third response message and enabling the management IP address to take effect locally, or enabling the locally configured management IP address to take effect according to the third response message;
adding the interface receiving the third response message into a management VLAN;
establishing an OpenFlow connection with the SDN controller through a management channel.
The first predetermined message and the second predetermined message may both be Dynamic Host Configuration Protocol (DHCP) request messages, and the first response message and the second response message may both be DHCP response messages.
The first SDN access device may carry the configured management IP address through a client address (ciaddr) field of a DHCP request packet.
In a second aspect, an embodiment of the present application provides a method for implementing management channel switching, which is applied to an SDN controller, and includes:
after a first SDN access device and an SDN controller establish an OpenFlow connection through a management channel, the SDN controller receives a first preset message carrying a message sequence number of the first SDN access device;
the SDN controller opens a standby management channel from the first SDN access device to the SDN controller after confirming that the first predetermined message of the first SDN access device is not processed.
Wherein the opening a standby management channel from the first SDN access device to the SDN controller may include:
when the SDN controller identifies that the first SDN access device does not have a configured management IP address according to a first preset message, selecting a management IP address from an allocable management IP address pool to allocate to the first SDN access device, and carrying the management IP address allocated to the first SDN access device through a first response message;
when the SDN controller identifies that the first SDN access device has a configured management IP address according to a first preset message, the SDN controller selects the configured management IP address from an allocable management IP address pool to allocate to the first SDN access device, and carries the management IP address allocated to the first SDN access device through a first response message.
When the received first predetermined packet is encapsulated by an OpenFlow protocol message from a third SDN access device, the opening a standby management channel from the first SDN access device to the SDN controller may further include: and informing the third SDN access device to add the interface which receives the first preset message into a management VLAN.
After the opening of the standby management channel from the first SDN access device to the SDN controller, the method may further include:
receiving a third predetermined message, which carries a message sequence number, of a second SDN access device, which is transmitted by the first SDN access device, wherein the second SDN access device is connected with the first SDN access device;
after confirming that a third predetermined message of the second SDN access device is not processed, when the second SDN access device is identified to have no configured management IP address according to the third predetermined message, selecting a management IP address from an allocable management IP address pool to allocate to the second SDN access device, and carrying the management IP address allocated to the second SDN access device through a third response message; when the second SDN access device is identified to have a configured management IP address according to the third predetermined message, selecting the configured management IP address from a allocable management IP address pool to allocate to the second SDN access device, and carrying the management IP address allocated to the second SDN access device through a third response message.
Wherein, the method can also comprise at least one of the following steps: the SDN controller records a management IP address allocated to the first SDN access device as a permanent lease for the first SDN access device; the SDN controller records a management IP address allocated to the second SDN access device as a permanent lease to the second SDN access device.
Wherein, the method can also comprise at least one of the following steps:
when the SDN controller confirms that a first preset message of the first SDN access device is not processed, recording a message sequence number carried by the first preset message of the first SDN access device in a processing list; when determining that a first predetermined message of the first SDN access device is processed, discarding the first predetermined message;
when the SDN controller confirms that a third preset message of the second SDN access device is not processed, recording a message sequence number carried by the third preset message of the second SDN access device in a processing list; and when determining that a third predetermined message of the second SDN access device is processed, discarding the third predetermined message.
The confirming, by the SDN controller, that the first predetermined packet of the first SDN access device is not processed may include:
when the processing list does not have the device information of the first SDN access device, or when the processing list has recorded the device information of the first SDN access device and a recorded message sequence number is smaller than a message sequence number carried by the first predetermined message, determining that the first predetermined message is not processed;
the determining, by the SDN controller, that the third predetermined packet of the second SDN access device is not processed may include:
when the processing list does not include the device information of the second SDN access device, or when the processing list records the device information of the second SDN access device and the recorded packet sequence number is smaller than the packet sequence number carried by the third predetermined packet, it is determined that the third predetermined packet is not processed.
Wherein, the method can also comprise at least one of the following steps:
after a first SDN access device and an SDN controller establish an OpenFlow connection through a management channel, when the SDN controller detects that the OpenFlow connection is disconnected, returning a message sequence number of the first SDN access device recorded in the processing list;
after an OpenFlow connection is established between a second SDN access device and an SDN controller through a management channel, when the SDN controller detects that the OpenFlow connection is disconnected, returning a message sequence number of the second SDN access device recorded in the processing list.
In a third aspect, an embodiment of the present application provides an apparatus for implementing management channel switching, where the apparatus is applied to a first SDN access device, and the apparatus includes:
the connection establishing module is used for establishing OpenFlow connection with the SDN controller through the management channel;
the connection detection module is used for sending a detection message to the SDN controller according to a detection period after the connection establishment module establishes an OpenFlow connection with the SDN controller through a management channel, and detecting a detection response message returned by the SDN controller;
and the switching processing module is used for removing all interfaces of the detection response message from the management VLAN and sending a first preset message carrying a message serial number when the detection result of the detection response message meets the switching condition of the management channel.
The management channel switching condition may include: detecting response messages replied by the SDN controller are not received within the timeout duration for N times or M times continuously; wherein N is the number of detection cycles for managing channel switching, M is the number of detection cycles for OpenFlow disconnection, N, M are positive integers, and N is smaller than M.
In a fourth aspect, an embodiment of the present application provides an apparatus for implementing management channel switching, where the apparatus is applied to an SDN controller, and the apparatus includes:
the device comprises a receiving module, a sending module and a receiving module, wherein the receiving module is used for receiving a first preset message carrying a message sequence number of a first SDN access device after the first SDN access device establishes an OpenFlow connection with an SDN controller through a management channel;
and the processing module is used for opening a standby management channel from the first SDN access device to the SDN controller after confirming that the first predetermined message of the first SDN access device is not processed.
The processing module may be further configured to record, in a processing list, a packet sequence number carried in a first predetermined packet of the first SDN access device when it is determined that the first predetermined packet of the first SDN access device is not processed; when determining that a first predetermined packet of the first SDN access device is processed, discarding the first predetermined packet.
The processing module may be further configured to, after an OpenFlow connection is established between a first SDN access device and an SDN controller through a management channel, when detecting that the OpenFlow connection is disconnected, rollback a packet sequence number of the first SDN access device recorded in the processing list.
In a fifth aspect, an embodiment of the present application provides a system for implementing management channel switching, including: the SDN system comprises an SDN controller and a first SDN access device; the first SDN access device is used for sending a detection message to an SDN controller according to a detection period after an OpenFlow connection with the SDN controller is established through a management channel, and detecting a detection response message returned by the SDN controller; when the detection result of the detection response message meets the management channel switching condition, removing all interfaces of the detection response message from the management VLAN, and sending a first preset message carrying a message serial number; the SDN controller is configured to, after receiving the first predetermined packet and after confirming that the first predetermined packet of the first SDN access device is not processed, open a standby management channel from the first SDN access device to the SDN controller.
The management channel switching condition may include: detecting response messages replied by the SDN controller are not received within the timeout duration for N times or M times continuously; wherein N is the number of detection cycles for managing channel switching, M is the number of detection cycles for OpenFlow disconnection, N, M are positive integers, and N is smaller than M.
The first SDN access device can be further used for receiving a first response message sent by the SDN controller and aiming at a first preset message after the first preset message is sent; configuring a local management IP address according to the management IP address carried by the first response message and enabling the management IP address to take effect locally, or enabling the locally configured management IP address to take effect according to the first response message; adding the interface receiving the first response message into a management VLAN; when the first predetermined message carries a configured management IP address, the management IP address allocated to the first SDN access device carried by the first response message is the configured management IP address.
Wherein, above-mentioned system can also include: the second SDN access device is used for sending a third preset message carrying a message serial number; the first SDN access device may be configured to send the third predetermined packet to the SDN controller through an established management channel when an interface that receives the third predetermined packet is a management interface; when the interface receiving the third predetermined message is a non-management interface, transmitting the third predetermined message to the SDN controller through an OpenFlow protocol message, and adding the interface receiving the third predetermined message into a management VLAN according to the notification of the SDN controller; the first SDN access device may be further configured to transmit, to the second SDN access device through a management interface, a third response packet, which is returned by the SDN controller and is for the third predetermined packet; the second SDN access device may be configured to, after receiving the third response packet, configure a local management IP address according to the management IP address carried in the third response packet and enable the local management IP address to take effect locally, or enable the local configured management IP address to take effect according to the third response packet; and adding the interface receiving the third response message into a management VLAN, and establishing OpenFlow connection with the SDN controller through a management channel.
Wherein, above-mentioned system can also include: the third SDN access device is used for receiving a first preset message of the first SDN access device, encapsulating the first preset message in an OpenFlow protocol message and sending the first preset message to the SDN controller; the third SDN access device is further configured to forward a first response packet sent by the SDN controller for the first predetermined packet to the first SDN access device.
An embodiment of the present application further provides a machine-readable medium, in which computer-executable instructions are stored, and when the computer-executable instructions are executed by a processor, the method for implementing management channel switching according to the first aspect is implemented.
An embodiment of the present application further provides a machine-readable medium, which stores computer-executable instructions, and when the computer-executable instructions are executed by a processor, the method for implementing management channel switching according to the second aspect is implemented.
In the embodiment of the application, automatic online of the SDN access equipment and automatic switching of the management channels can be realized. The SDN access device can complete the switching of the management channels without reestablishing OpenFlow connection, configuration of an SDN controller and the SDN access device caused by reestablishing connection is avoided, and switching overhead is saved. Moreover, automatic online of the SDN access equipment with the static management IP address and automatic switching of the management channel are realized.
Additional features and advantages of the application will be set forth in the description which follows, and in part will be obvious from the description, or may be learned by the practice of the application. The objectives and other advantages of the application may be realized and attained by the structure particularly pointed out in the written description and claims hereof as well as the appended drawings.
Drawings
The accompanying drawings are included to provide a further understanding of the claimed subject matter and are incorporated in and constitute a part of this specification, illustrate embodiments of the subject matter and together with the description serve to explain the principles of the subject matter and not to limit the subject matter.
Fig. 1 is a flowchart of a method for implementing management channel switching according to an embodiment of the present application;
FIG. 2 is a first diagram illustrating an application example of the first embodiment of the present application;
FIG. 3 is a diagram illustrating a second exemplary application according to the first embodiment of the present disclosure;
fig. 4 is a schematic diagram of a third application example of the first embodiment of the present application;
fig. 5 is a fourth schematic diagram of an application example of the first embodiment of the present application;
fig. 6 is a schematic diagram of a device for implementing management channel switching according to a second embodiment of the present application;
fig. 7 is a flowchart of a method for implementing management channel switching according to a third embodiment of the present application;
fig. 8 is a schematic diagram of a device for implementing management channel switching according to a fourth embodiment of the present application.
Detailed Description
The embodiments of the present application will be described in detail below with reference to the accompanying drawings, and it should be understood that the embodiments described below are only for illustrating and explaining the present application and are not intended to limit the present application.
It should be noted that the terms "first," "second," and the like in the description and claims of this application and in the drawings described above are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order.
It should be noted that, if not conflicted, the embodiments and the features of the embodiments can be combined with each other and are within the scope of protection of the present application. The steps illustrated in the flow charts of the figures may be performed in a computer system such as a set of computer-executable instructions. Also, while a logical order is shown in the flow diagrams, in some cases, the steps shown or described may be performed in an order different than here.
The SDN controller manages the SDN access device using various southbound interfaces, such as OpenFlow protocol, network configuration (NETCONF) protocol, and the like. The proposed OpenFlow solves the problem of sending a flow table to an OpenFlow switch by an SDN controller to control the path through which a data flow passes through a network; a packetIn message is defined in a protocol and used for SDN access equipment to send a received message to an SDN controller; an ECHO message (heartbeat message) is defined in the protocol and is used for periodically detecting the communication state with the opposite terminal. The NETCONF protocol is used for managing and configuring SDN access devices, and is a latest XML (extensible markup Language) -based network configuration and management protocol.
Example one
This embodiment provides a method for implementing management channel switching, which is applied to a first SDN access device, and as shown in fig. 1, the method includes:
s101, after a first SDN access device establishes an OpenFlow connection with an SDN controller through a management channel, sending a detection message to the SDN controller according to a detection period, and detecting a detection response message returned by the SDN controller;
s102, when the detection result of the probe response packet satisfies the management channel switching condition, the first SDN access device removes all its interfaces from a Virtual Local Area Network (VLAN), and sends a first predetermined packet carrying a packet sequence number.
The message sequence number carried by the first predetermined message is greater than the message sequence number carried by the predetermined message sent by the first SDN access device last time. Taking a predetermined message as a DHCP request message as an example, if a message sequence number of a DHCP request message sent by the first SDN access device last time is P, a message sequence number of a DHCP request message (corresponding to the first predetermined message) sent after a detection result of the probe response message satisfies a management channel switching condition may be P + 1.
The managing the channel switching condition may include: detecting response messages replied by the SDN controller are not received within the timeout duration for N times or M times continuously; wherein N is the number of detection cycles for managing channel switching, M is the number of detection cycles for OpenFlow disconnection, N, M are positive integers, and N is smaller than M. Since N is less than M, the first SDN access device may perform management channel switching while maintaining OpenFlow connection, thereby avoiding a configuration process of the SDN controller and the SDN access device due to connection re-establishment, and saving switching overhead.
In an exemplary embodiment, the probe messages and the probe response messages may be ECHO messages. However, this is not limited in this application. In other implementation manners, the probe packet and the probe response packet may be other OpenFlow protocol packets or defined private packets.
In S102, sending the first predetermined packet may include:
when judging that the first SDN access device does not have a configured management network protocol (IP) address, the first SDN access device carries a management IP address set to be empty in a first preset message;
when the first SDN access device judges that the configured management IP address exists, the configured management IP address is carried in a first preset message.
In S102, after sending the first predetermined message, the method of this embodiment may further include:
receiving a first response message aiming at a first preset message sent by an SDN controller;
configuring a local management IP address according to the management IP address carried by the first response message and enabling the management IP address to take effect locally, or enabling the locally configured management IP address to take effect locally according to the first response message;
and adding the interface receiving the first response message into the management VLAN.
In an exemplary embodiment, when the first predetermined packet carries a configured management IP address, the management IP address allocated to the first SDN access device carried by the first response packet is the configured management IP address.
In an exemplary embodiment, the first predetermined message may be a Dynamic Host Configuration Protocol (DHCP) request message. The first response message may be a DHCP response (DHCP ACK) message. The DHCP messages are adopted for interaction in the process of managing channel switching, so that the problem that the private messages possibly cannot pass through RELAY (RELAY) equipment is avoided, and extra codes caused by analyzing the private messages are saved. However, this is not limited in this application. In other implementation manners, the first predetermined packet may also be a defined private packet as long as the first predetermined packet is indicated to be used for applying for the management IP address again for the first SDN access device.
In an exemplary embodiment, when the first predetermined message is a DHCP request message, the first SDN access device may carry a configured management IP address through a client address (ciaddr) field of the DHCP request message, thereby indicating that the first SDN access device needs to take effect to use the configured management IP address.
In an exemplary embodiment, after opening the standby management channel, when the OpenFlow connection between the first SDN access device and the SDN controller is not disconnected, the OpenFlow connection may be maintained through the standby management channel; when the OpenFlow connection between the first SDN access device and the SDN controller is disconnected, the OpenFlow connection may be reestablished through the standby management channel.
In this embodiment, before implementing S101, an Openflow connection is already established between the SDN controller and the first SDN access device, that is, a management channel between the first SDN access device and the SDN controller is opened.
The establishing, by the first SDN access device, an OpenFlow connection with the SDN controller through the management channel may include:
the first SDN access equipment sends a second preset message; the message sequence number carried by the second preset message is smaller than the message sequence number carried by the first preset message; for example, the message sequence number carried in the first predetermined message is equal to the message sequence number +1 carried in the second predetermined message;
receiving a second response message aiming at a second preset message from the SDN controller;
configuring a local management IP address according to the management IP address carried by the second response message and enabling the management IP address to take effect locally, or enabling the locally configured management IP address to take effect according to the second response message;
adding the interface receiving the second response message into the management VLAN;
and establishing an OpenFlow connection with the SDN controller through an established management channel between the SDN controller and the OpenFlow connection.
The sending, by the first SDN access device, the second predetermined packet may include:
when the first SDN access device judges that the first SDN access device does not have a configured management IP address, the second SDN access device carries a management IP address set to be empty in a second preset message; in other words, the second predetermined packet may not carry the management IP address;
when the first SDN access device judges that the configured management IP address exists, the configured management IP address is carried in a second preset message.
In an exemplary embodiment, when the second predetermined packet carries a configured management IP address, the management IP address allocated to the first SDN access device carried by the second response packet is the configured management IP address.
In an exemplary embodiment, the second predetermined message may be a DHCP request message. The second response message may be a DHCP response (DHCP ACK) message. However, this is not limited in this application. In other implementation manners, the second predetermined packet may also be a defined private packet as long as the second predetermined packet is indicated to be used for applying for the management IP address of the first SDN access device.
In an exemplary embodiment, when the second predetermined message is a DHCP request message, the first SDN access device may carry a configured management IP address through a client address (ciaddr) field of the DHCP request message, thereby indicating that the first SDN access device needs to take effect to use the configured management IP address.
In an exemplary embodiment, the second response packet may further carry the following information: detecting period time intervals, detecting period number M of open flow connection disconnection, and detecting period number N of management channel switching; after receiving a second response packet from the SDN controller for the second predetermined packet, the method of this embodiment may further include: and recording the information carried by the second response message.
The first SDN access device can send detection messages to the SDN controller every other detection period, the first SDN access device disconnects OpenFlow connection after detecting response messages (such as ECHO messages) replied by the SDN controller are not received for M times continuously in the timeout duration, and the first SDN access device switches the backup management channels after detecting response messages (such as ECHO messages) replied by the SDN controller are not received for N times continuously in the timeout duration.
In an exemplary embodiment, after the first SDN access device establishes an OpenFlow connection with the SDN controller through the management channel, the method of this embodiment may further include:
receiving a third preset message carrying a message serial number of a second SDN access device;
when the interface receiving the third predetermined message is a management interface (i.e. an interface added to a management VLAN), sending the third predetermined message to the SDN controller through the established management channel; when the interface receiving the third predetermined packet is a non-management interface (i.e., an interface not added to the management VLAN), transmitting the third predetermined packet to the SDN controller through an OpenFlow protocol message (e.g., a PacketIn message), and adding the interface receiving the third predetermined packet to the management VLAN according to a notification of the SDN controller;
and transmitting a third response message, which is returned by the SDN controller and aims at the third predetermined message, to the second SDN access device through the management interface. Thus, after receiving the third response message, the second SDN access device may configure a local management IP address according to the management IP address carried in the third response message and enable the local management IP address to take effect locally, or enable the local configured management IP address to take effect according to the third response message; adding the interface receiving the third response message into the management VLAN; an OpenFlow connection is established with the SDN controller through the management channel.
In an exemplary embodiment, the method of this embodiment may also be applied to a second SDN access device, where the second SDN access device is connected to the first SDN access device; the method of this embodiment may further include:
the second SDN access equipment sends a third preset message with a message sequence number;
receiving a third response message returned by the SDN controller transmitted by the first SDN access device aiming at a third preset message;
configuring a local management IP address according to the management IP address carried by the third response message and enabling the management IP address to take effect locally, or enabling the locally configured management IP address to take effect locally according to the third response message;
adding the interface receiving the third response message into the management VLAN;
an OpenFlow connection is established with the SDN controller through the management channel.
In this implementation manner, after the first SDN access device implements management channel switching, by opening a management channel between the first SDN access device and the second SDN access device, the second SDN access device may establish an OpenFlow connection with the SDN controller through the management channel between the second SDN access device and the first SDN access device and a standby management channel of the first SDN access device. The third predetermined message may be a DHCP message, and the third response message may be a DHCP ACK message. The second SDN access device may carry the configured management IP address through the ciaddr field of the DHCP request message, thereby indicating that the second SDN access device needs to validate using the configured management IP address.
The present application will be described below with reference to fig. 2 to 5 by way of an application example.
The present application may be directed to a ring topology similar to, but not limited to, that shown in fig. 2. The SDN access device only needs to have a plurality of physical links to the SDN controller to realize management channel backup, but the SDN access device only has one management channel to the SDN controller.
As shown in fig. 2, the DHCP server (server) is embedded into the SDN controller. The B devices (including B0 and B1 devices) are SDN convergence devices and already have management IP addresses; an L2VPN (L2Virtual private network) management channel from the B device to the SDN controller is configured in advance, and PW (Pseudo-Wire) redundancy is configured to realize management channel backup protection. The Identification (ID) of a management VLAN (Virtual Local Area Network) can be fixed to 4094. The a devices (including a0, a1, a2, A3, a4 devices) are SDN access devices, and an initial state may have no management IP address or may have a configured management IP address; the configured management IP address refers to: the SDN access device has already configured a management IP address through a command line or in other manners, but the configured management IP address is not recorded in the SDN controller embedded with the DHCP server, in other words, the configured management IP address is stored locally but does not take effect, and can take effect only after receiving a DHCP ACK message. C devices (including C0 devices) are used to connect B devices with SDN controllers. In some implementations, the B device may also directly connect to the SDN controller.
The following describes a process in which each SDN access device (a0, a1, a2, A3, a4 device) respectively implements automatic online and establishes a management channel. For convenience of description, it is described that an a0 device and an a4 device are SDN access devices in an initial state without a management IP address, an a1 device is an SDN access device configured with a management IP address, and an a2 device and an A3 device may determine an access method according to a state of a network access at that time, and then perform access processing with reference to an a0 device or an a1 device.
The process of establishing a network management channel in the ring topology network shown in fig. 2 is described below with reference to fig. 2 and 3:
(1) all the equipment A (A0, A1, A2, A3 and A4) are powered on and are set not to forward a DHCP message; the method comprises the steps that a processing list stored by an SDN controller is initially set to be empty, each item of the processing list corresponds to an SDN access device, and each item comprises device information (client id) of the SDN access device and a DHCP request message sequence number (transaction id); wherein, an SDN access device in the processing list corresponds to an entry;
in this example, the SDN controller is preset with an initially empty handling list, however, this is not limited in this application. In other implementations, the SDN controller may not set the processing list in advance, and after receiving the device information of the SDN access device and the DHCP request packet sequence number, generate the processing list for information recording.
(2) The A0 equipment applies for a management IP address to an SDN controller embedded with a DHCP server through B0 equipment, and the detailed process of the step is as follows:
(2-a), the a0 device judges the non-management IP address of itself according to the device record, and initiates a DHCP request (DHCP Discover) message in the management VLAN, wherein the DHCP request message carries an identifier (e.g., 4094) of the management VLAN, device information (clientid) of the a0 device, and a DHCP request message sequence number (transaction id), and a field ciaddr (client address) in the DHCP protocol message is null, that is, the a0 device does not manage the IP address of itself;
in the DHCP application steps of all the A equipment, after the A equipment sends a DHCP request (DHCP Discover) message, constantly detecting whether the DHCP request process is completed (namely whether a DHCP ACK message is received), if so, entering the step (2-d), and if not, the A equipment periodically carries out the DHCP request process, namely, the A equipment initiates the DHCP request process once every other sending period;
the sending period of the DHCP request message may be set to a predetermined value, but preferably may be set to start with a certain initial value and increase exponentially to not exceed the maximum value; each value sending period can be repeatedly used for many times; for example, the initial value is set to 2s, the value of the sending period is exponentially increased after repeating the DHCP request process for 10 times, and repeating the process for 10 times until the value of the sending period is 16s (defined maximum value); here, the exponential increase of the sending period of the DHCP request message is to reduce the burden of the SDN controller and the network, and the repeated use of the sending period of each value is to avoid the situation that the equipment misses the first shortest period as much as possible, which results in the long time for the equipment to get online;
in this step, the initial value of the DHCP request message number (transaction id) may be 1;
(2-B) after receiving the DHCP request message sent by the a0 device, the B0 device identifies a management VLAN, encapsulates the DHCP request message into an MPLS (Multi-Protocol Label Switching) message, and transmits the MPLS message to the C0 device through a management channel, and after decapsulating the MPLS message, the C0 device sends the DHCP request message to the SDN controller;
(2-c), after receiving a DHCP request message of the A0 equipment, the SDN controller identifies the equipment information of the A0 equipment, judges that a management IP address needs to be allocated to the A0 equipment (equipment without management IP) according to the condition that the ciaddr field is empty, allocates the management IP address from an allocable management IP address pool, and transmits the allocated management IP address, the IP address and port of the SDN controller, ECHO period information and other information to the A0 equipment through a DHCP response (DHCP ACK) message; the SDN controller records a management IP address allocated to the A0 device as a permanent lease for the A0 device, and records an entry corresponding to the A0 device in a processing list of the SDN controller, wherein the entry comprises device information of the A0 device and a DHCP request message sequence number;
the SDN controller can send the returned DHCP ACK message to the A0 device through a channel of C0- > B0- > A0;
(2-d) after the device A0 receives the DHCP ACK message, stopping the DHCP application process in the step (2-a), configuring a local management IP address according to the management IP address distributed in the DHCPACK message and taking effect locally, and adding an interface applying for the management IP address (namely the interface receiving the DHCP ACK message) into the management VLAN, thereby opening a management channel between the device A0 and the device B0;
(2-e) after the device A0 applies to a management IP address and acquires information such as an IP address and a port of the SDN controller, actively establishing an OpenFlow connection with the SDN controller, setting ECHO period information distributed by the SDN controller, and restarting a DHCP application process from the step (2) if the device A0 is judged to be failed to establish the OpenFlow connection with the SDN controller;
thus, through the above steps (2-a) to (2-e), the a0 device applies for and validates a management IP address to the SDN controller through the B0 device, and establishes a management channel between the a0 device and the SDN controller.
(3) Similarly, the a4 device serving as the initial unmanaged IP address may apply for the management IP address from the SDN controller through the B1 device, add the interface applied for the IP address into the management VLAN, and establish an OpenFlow connection with the SDN controller.
(4) For the A1 device, after an interface connecting the A0 device and the A1 device needs to be added into a management VLAN, an IP address can be applied and a management channel can be established through an A0- > B0 channel; the detailed process of the step is as follows:
(4-a) the A0 equipment starts the PacketIn channels of all the interfaces except the management interface (the interface added with the management VLAN) and sends the DHCP messages to the SDN controller, namely the management interface does not send the DHCP messages to the SDN controller in a form of packaging the DHCP messages into PacketIn messages after receiving the DHCP messages, and other interfaces still package the DHCP messages into PacketIn messages and send the PacketIn messages to the SDN controller after receiving the DHCP messages;
in this step, the reason why the management interface receives the DHCP request message and does not encapsulate it as a PacketIn message for uploading is that: the management interface is already added into the management VLAN, and the purpose of uploading the PacketIn message is to add the interface into the management VLAN;
(4-b), the A1 equipment sends out a DHCP request message, wherein the DHCP request message carries an identifier (4094, for example) of a management VLAN, equipment information (client id) of the A1 equipment and a DHCP request message sequence number (transaction id); and the configured management IP address is carried by the ciaddr field in the DHCP request message;
in this example, an example is described in which a non-management interface of an a0 device receives a DHCP request message of an a1 device; after a DHCP request message of the A1 equipment reaches the A0 equipment, the A0 equipment sends the DHCP request message to an SDN controller through a PacketIn message; the PacketIn message is transmitted through an established management channel between the A0 equipment and the SDN controller;
in this step, the already configured management IP address of the a0 device is saved locally;
(4-c), the SDN controller receives a DHCP request message, packaged as a PacketIn message, of the A0 equipment, and judges whether the DHCP request message of the A1 equipment is processed or not;
if the DHCP request message of the A1 device is not processed, informing the A0 device of adding an interface which receives the DHCP request message of the A1 device into the management VLAN through a NETCONF protocol message, and recording an entry about the A1 device in a processing list, wherein the entry comprises a client id and a transaction id of the A1 device; if the DHCP request message of the A1 equipment is determined to be processed, discarding the DHCP request message;
if the OpenFlow connection is not established between the a1 device and the SDN controller after the predetermined time, the SDN controller backs off the DHCP request message sequence number (transaction id) of the a1 device recorded in the processing list, for example, subtracting 1 from the recorded DHCP request message sequence number of the a1 device; the preset time length can be determined according to the time required by the SDN controller to establish the OpenFlow connection in different scenes;
in this step, the criterion for determining whether the DHCP request message of the a1 device is processed is as follows: if the processing list does not include an entry corresponding to the client id of the a1 device or an entry corresponding to the client id of the a1 device, but the DHCP request message sequence number (transaction id) of the a1 device in the entry is smaller than the DHCP request message sequence number carried in the DHCP request message, determining that the DHCP request message is not processed; otherwise (namely, the processing list includes an entry corresponding to the client id of the a1 device, and the DHCP request message sequence number (transaction id) of the a1 device in the entry is greater than or equal to the DHCP request message sequence number carried in the DHCP request message), judging that the DHCP request message is processed;
and (4-d) after receiving the NETCONF message of the SDN controller, the A0 equipment adds an interface (an interface which receives the DHCP request message of the A1 equipment) connected with the A1 equipment into the management VLAN, and ensures that the interface does not encapsulate the DHCP request message into a PacketIn message and delivers the PacketIn message to the SDN controller after receiving the DHCP request message.
Thus, the interface where the a0 device and the a1 device are connected is joined to the management VLAN through the above-described steps (4-a) to (4-d).
(5) The A1 equipment applies for a management IP address to the SDN controller, and the detailed process of the step is as follows:
(5-a) the DHCP request message of the A1 equipment reaches the SDN controller through an A0- > B0 channel, the SDN controller identifies the A1 equipment as equipment configured with a management IP address according to the ciaddr field, acquires the management IP address configured by the A1 equipment, allocates the management IP address to the A1 equipment through a DHCP ACK message, and records the allocated management IP address as permanent lease of the A1 equipment;
(5-b), after receiving the DHCP ACK message, the A1 device configures a local management IP address according to the distributed management IP address, takes effect locally, and adds an interface applying for the management IP address into a management VLAN; thereby opening a management channel between the a1 device and the SDN controller.
It should be noted that, in other examples, if the management interface of the a0 device receives the DHCP request message of the a1 device, after the DHCP request message of the a1 device reaches the a0 device, the a0 device directly sends the DHCP request message of the a1 device to the SDN controller through an a0- > B0 channel, and after the SDN controller receives the DHCP request message of the a1 device, the SDN controller determines whether the DHCP request message of the a1 device is processed; if the DHCP request message of the A1 equipment is determined to be processed, discarding the DHCP request message; if the DHCP request message of the A1 equipment is confirmed not to be processed, recording an entry about the A1 equipment in a processing list, wherein the entry comprises a client id and a transaction id of the A1 equipment; moreover, the A1 equipment is identified as equipment configured with the management IP address according to the ciaddr field, the configured management IP address of the A1 equipment is obtained, the management IP address is distributed to the A1 equipment through a DHCP ACK message, and the distributed management IP address is recorded as permanent lease for the A1 equipment; after receiving the DHCP ACK message, the A1 device configures a local management IP address according to the distributed management IP address and takes effect locally, and adds an interface applied to the management IP address into a management VLAN; thereby opening a management channel between the a1 device and the SDN controller.
(6) And in the same way, the A3 device applies for a management IP address through an A4- > B1 channel and establishes an OpenFlow connection with the SDN controller.
(7) And similarly, the A2 device applies for the management IP address through an A1- > A0- > B0 channel, and establishes an OpenFlow connection with the SDN controller. It should be noted that in other examples, the a2 device may also apply for a management IP address through an A3- > a4- > B1 channel, and establish an OpenFlow connection with the SDN controller.
Through steps (1) to (7), the a0, a1, a2, A3 and a4 devices can all establish OpenFlow connections with the SDN controller, and management channels do not loop. The final management channel is shown in fig. 3, where the dashed line represents that the management channel is not through.
In this example, taking an a0 device as a first SDN access device as an example, the second predetermined message is a DHCP request message sent by an a0 device, and the second response message is a DHCP ACK message returned by an SDN controller embedded with a DHCP server for the DHCP request message of the a0 device; at this time, the second SDN access device may be an a1 device, the third predetermined message is a DHCP request message sent by the a1 device, and the third response message is a DHCPACK message returned by the SDN controller for the DHCP request message of the a1 device. Taking the a1 device as the first SDN access device as an example, the second predetermined message is a DHCP request message sent by the a1 device, and the second response message is a DHCP ACK message returned by the SDN controller for the DHCP request message of the a1 device; at this time, the second SDN access device may be an a2 device, the third predetermined message is a DHCP request message sent by the a2 device, and the third response message is a DHCP ACK message returned by the SDN controller for the DHCP request message of the a2 device. Taking the a2 device as the first SDN access device as an example, the second predetermined message is a DHCP request message sent by the a2 device, and the second response message is a DHCP ACK message returned by the SDN controller for the DHCP request message of the a2 device.
It should be noted that, the setting of the state of the initial management IP address of the a0, a1, a4 device in the above steps is illustrative, in other implementation scenarios, the state of the initial management IP address of each SDN access device may be determined according to the requirements of the scenario, each SDN access device, whether being an initial unmanaged IP address or a configured management IP address, may establish an OpenFlow connection with the SDN controller in a similar manner as described above, and the management channel does not form a ring.
The establishment process of the backup management channel is explained below with reference to fig. 4 and 5.
As shown in fig. 4, after the above-mentioned devices are brought online and a management channel is established, SDN access devices (a0, a1, a2, A3, a4 devices) can all be managed by an SDN controller. When the line between the a0 device and the a1 device fails, the process of the a0 device and the a1 device being brought online again through the backup management channel is as follows:
(1) all the equipment A periodically detects the connection state with the SDN controller;
in this step, when the management channel is established (for example, in step (2-e) above), all the devices a have obtained ECHO period information issued by the SDN controller, where the ECHO period information includes an ECHO period time interval, an ECHO period number M for OpenFlow disconnection, and an ECHO period number N for management channel switching;
the device A sends detection messages to the SDN controller every other ECHO period, the device A disconnects OpenFlow connection after continuously receiving no ECHO messages replied by the SDN controller for M times within the timeout duration, and switches backup management channels after continuously receiving no ECHO messages replied by the SDN controller for N times within the timeout duration; n, M are positive integers, N is less than M, and the purpose of switching backup management channels by using the number of ECHO cycles different from OpenFlow disconnection is as follows: and switching the device A to a new management channel without disconnecting the OpenFlow connection.
(2) And opening an interface for connecting the A3 equipment with the A2 equipment by the A2 equipment, wherein the detailed process of the step is as follows:
(2-a), removing all interfaces from a management VLAN (virtual local area network) if the device A2 does not receive an ECHO message sent by the SDN controller or is disconnected from the OpenFlow of the SDN controller within the timeout duration for N times continuously, recovering the current management IP address to the initial state of the access device without deleting local records (if the initial state is the non-management IP address, the current management IP address is recovered to the non-management IP address, and if the current management IP address is the configured management IP address, the configured management IP address is still recorded in the local area but is invalid), re-initiating a DHCP request (DHCP Discover) message within the management VLAN, wherein the sequence number of the DHCP request message is increased by 1 to distinguish the difference from the DHCP request message at the last time; the DHCP request message carries an identifier (e.g., 4094) of a management VLAN, device information (client id) of an a0 device, and a DHCP request message sequence number (transaction id);
in other implementation manners, if the a2 device does not receive an ECHO message sent by the SDN controller or disconnects the OpenFlow connection with the SDN controller within the timeout duration N times continuously, removing all interfaces from the management VLAN, and applying for a management IP address through a DHCP request message before locally recording, but setting the management IP address as invalid; re-initiating a DHCP request (DHCP Discover) message in the management VLAN, wherein the sequence number of the DHCP request message is increased by 1 so as to distinguish the difference from the last DHCP request message; the DHCP request message carries an identifier (e.g., 4094) of a management VLAN, device information (client id) of an a0 device, a DHCP request message sequence number (transaction id), and a configured management IP address recorded locally;
(2-b) after a DHCP request message sent by the A2 equipment reaches the A3 equipment, the A3 equipment sends the DHCP request message to the SDN controller through a PacketIn message; the PacketIn message is transmitted through an established management channel between the A3 equipment and the SDN controller;
(2-c), the SDN controller receives a DHCP request message packaged as a PacketIn message from the A2 equipment, and if the DHCP request message of the A2 equipment is not processed, the SDN controller informs the A3 equipment of adding an interface receiving the DHCP request message of the A2 equipment into a management VLAN through a NETCONF message, so that a backup management channel between the A3 equipment and the A2 equipment is established; recording the client id and transaction id of the A2 device into a processing list; if the DHCP request message of the A2 equipment is determined to be processed, the DHCP request message is discarded;
in this step, the criterion for determining whether the DHCP request message of the a2 device is processed is as follows: if the processing list does not include an entry corresponding to the client id of the a2 device or an entry corresponding to the client id of the a2 device, but the DHCP request message sequence number (transaction id) of the a2 device in the entry is smaller than the DHCP request message sequence number carried in the DHCP request message, determining that the DHCP request message of the a2 device is not processed; otherwise, judging the processed DHCP request message of the A2 equipment;
in this step, if it is determined that the DHCP request of the a2 device is not processed, after passing through the NETCONF message processing interface, a new task is started, that is, after M EHCO cycles, an OpenFlow connection state between the a2 device and the SDN controller is detected, and if the connection is disconnected, the SDN controller backs (for example, subtracts 1) the DHCP request processing sequence number of the a2 device in the processing list; if the OpenFlow connection between the a2 device and the SDN controller is not disconnected, it is indicated that the a2 device maintains the OpenFlow connection with the SDN controller through the backup management channel, and no processing is performed;
(2-d) the A3 equipment receives a NETCONF message of the SDN controller, adds an interface connected with the A2 equipment into a management VLAN, processes the NETCONF message, and ensures that the interface can not be encapsulated into a PacketIn message after receiving a DHCP request message and then sends the PacketIn message to the SDN controller;
(3) the A2 device applies for a management IP address to the SDN controller and keeps OpenFlow connection, and the detailed process of the step is as follows:
the DHCP request message of the (3-a) and A2 equipment is sent to the SDN controller through an A3- > A4- > B1 channel;
(3-b), the SDN controller identifies the equipment information of the A2 equipment, finds that a management IP address is allocated to the A2 equipment before, and allocates the same management IP address to the A2 equipment through a DHCP ACK message;
(3-c), after receiving the DHCP ACK message, the A2 device configures a local management IP address according to the distributed management IP address, takes effect locally, and adds an interface applying for the management IP address into a management VLAN; thereby opening a backup management channel from the a2 device to the SDN controller;
it should be noted that the DHCP ACK message may carry ECHO period information, so as to be used in the subsequent connection status detection process.
(3-d), keeping the OpenFlow connection between the A2 device and the SDN controller through an A3- > A4- > B1 channel, and returning to the step (1) of the backup management channel establishment process;
(4) and similarly, the A1 device maintains the OpenFlow connection with the SDN controller again through the A2- > A3- > A4- > B1 channel.
Through the configuration steps, the offline a1 device and the offline a2 device are connected with the SDN controller through the backup management channel in an OpenFlow manner. The updated management channel is shown in fig. 5, where the dashed line represents that the management channel is not passed.
In this example, taking an a2 device as a first SDN access device as an example, the first predetermined message may be a DHCP request message sent by an a2 device in a channel switching stage, and the first response message refers to a DHCP ACK message returned by an SDN controller embedded with a DHCP server for the DHCP request message of the a2 device; at this time, the third SDN access device may be an A3 device, and the second SDN access device may be an a1 device. Taking the a1 device as the first SDN access device as an example, the first predetermined message may be a DHCP request message sent by the a1 device in the channel switching stage, and the first response message refers to a DHCP ACK message returned by the SDN controller for the DHCP request message of the a1 device; at this time, the third SDN access device may be an a2 device.
It should be noted that, in the process of establishing the backup management channel, the process of establishing the management channel and applying for the management IP address by the device a may refer to the process of establishing the network management channel, and therefore, the same or similar parts are not described in detail again.
In summary, the embodiment not only realizes automatic online of the SDN access device, but also optimizes the switching process of the management channel, and is compatible with the SDN access device configured with the static management IP address. The SDN access equipment can complete the switching of the management channels without reestablishing OpenFlow connection, thereby avoiding the configuration process of an SDN controller and the access equipment caused by reestablishing the connection and saving the switching overhead; the SDN controller uniquely identifies a one-time switching process by using equipment information (client id) and a DHCP request message sequence number (transaction id) of the SDN access equipment, so that on the basis of avoiding ring formation, no requirement is made on the switching frequency of the equipment in a short time, the switching process is more flexible, and more network scenes can be conveniently handled; moreover, since the SDN access device can be switched for many times in a short time, the reachable management channel can be quickly found, and the switching speed is higher; in addition, management channel switching of the SDN access equipment configured with the static management IP address is realized, and because the access behavior of the SDN access equipment configured with the static management IP address is completely the same as the access behavior of the SDN access equipment not configured with the static management IP address, other problems caused by adding the SDN access equipment configured with the static management IP address are avoided.
Example two
The embodiment provides a device for implementing management channel switching, which is applied to a first SDN access device, and as shown in fig. 6, the device includes:
a connection establishing module 601, configured to establish an OpenFlow connection with an SDN controller through a management channel;
a connection detection module 602, configured to send a probe packet to the SDN controller according to a probe cycle after the connection establishment module 601 establishes an OpenFlow connection with the SDN controller through a management channel, and detect a probe response packet returned by the SDN controller;
the switching processing module 603 is configured to remove all interfaces from the management VLAN and send a first predetermined packet carrying a packet sequence number when the detection result of the probe response packet meets the management channel switching condition.
The message sequence number carried by the first predetermined message is greater than the message sequence number carried by the predetermined message sent by the first SDN access device last time. Taking a predetermined message as a DHCP request message as an example, if a message sequence number of a DHCP request message sent by the first SDN access device last time is P, a message sequence number of a DHCP request message (corresponding to the first predetermined message) sent after a detection result of the probe response message satisfies a management channel switching condition may be P + 1.
The managing the channel switching condition may include: detecting response messages replied by the SDN controller are not received within the timeout duration for N times or M times continuously; wherein N is the number of detection cycles for managing channel switching, M is the number of detection cycles for OpenFlow disconnection, N, M are positive integers, and N is smaller than M.
The switching processing module 603 may be configured to, when determining that there is no configured management IP address, carry a management IP address set to be empty in the first predetermined packet; and when judging that the configured management IP address exists, carrying the configured management IP address in the first preset message.
The switching processing module 603 may be further configured to receive a first response packet, which is sent by the SDN controller and is for the first predetermined packet, after sending the first predetermined packet;
the switching processing module 603 may also be configured to configure a local management IP address according to the management IP address carried in the first response packet, and enable the local management IP address to take effect locally, or enable the locally configured management IP address to take effect according to the first response packet; and adding the interface receiving the first response message into the management VLAN.
The connection establishing module 601 may be configured to send a second predetermined message; receiving a second response message aiming at a second preset message from the SDN controller; configuring a local management IP address according to the management IP address carried by the second response message and enabling the management IP address to take effect locally, or enabling the locally configured management IP address to take effect according to the second response message; adding the interface receiving the second response message into the management VLAN; and establishing an OpenFlow connection with the SDN controller through an established management channel between the SDN controller and the OpenFlow connection. And the message serial number carried by the first preset message is greater than the message serial number carried by the second preset message.
The connection establishing module 601 may be configured to, when it is determined that there is no configured management IP address, carry a management IP address set to be empty in the second predetermined packet; and when judging that the configured management IP address exists, carrying the configured management IP address in the second preset message.
In an exemplary embodiment, when the second predetermined packet carries a configured management IP address, the management IP address allocated to the first SDN access device carried by the second response packet is the configured management IP address.
The second response message may also carry the following information: detecting period time interval, the number of detecting periods of OpenFlow disconnection, and the number of detecting periods of management channel switching;
the apparatus of this embodiment may further include: and the information recording module is used for recording the information carried by the second response message.
Wherein, the apparatus of this embodiment may further include:
the message receiving module is configured to receive a third predetermined message carrying a message sequence number of a second SDN access device after the connection establishing module 601 establishes an OpenFlow connection with the SDN controller through the management channel;
the first transmission module is used for sending the third preset message to the SDN controller through the established management channel when the interface receiving the third preset message is the management interface; when the interface receiving the third predetermined packet is a non-management interface, transmitting the third predetermined packet to the SDN controller through an OpenFlow protocol message (for example, a PacketIn message), and adding the interface receiving the third predetermined packet to a management VLAN according to a notification of the SDN controller;
and the second transmission module is used for transmitting a third response message, which is returned by the SDN controller and aims at the third predetermined message, to the second SDN access device through the management interface. Thus, after receiving the third response message, the second SDN access device may configure a local management IP address according to the management IP address carried in the third response message and enable the local management IP address to take effect locally, or enable the local configured management IP address to take effect according to the third response message; and adding the interface receiving the third response message into the management VLAN, and establishing OpenFlow connection with the SDN controller through a management channel.
In this embodiment, the first predetermined message, the second predetermined message, and the third predetermined message may all be DHCP request messages, and the first response message, the second response message, and the third response message may all be DHCP ACK messages. However, this is not limited in this application.
When the first predetermined message and the second predetermined message are both DHCP request messages, the first SDN access device may carry the configured management IP address through a ciaddr field of the DHCP request message. When the third predetermined message is a DHCP request message, the second SDN access device may carry the configured management IP address through the ciaddr field of the DHCP request message.
The processing flow of the apparatus of this embodiment may refer to the method of the first embodiment, and therefore, is not described herein again.
EXAMPLE III
This embodiment provides a method for implementing management channel switching, which is applied to an SDN controller, as shown in fig. 7, and includes:
s701, after the first SDN access device and the SDN controller establish OpenFlow connection through a management channel, the SDN controller receives a first preset message carrying a message serial number of the first SDN access device;
s702, after confirming that the first predetermined packet of the first SDN access device is not processed, the SDN controller opens a standby management channel from the first SDN access device to the SDN controller.
In S702, opening a standby management channel from the first SDN access device to the SDN controller may include:
when the SDN controller identifies that the first SDN access device does not have a configured management IP address according to the first preset message, selecting the management IP address from a distributable management IP address pool to distribute to the first SDN access device, and carrying the management IP address distributed to the first SDN access device through the first response message;
when the SDN controller identifies that the first SDN access device has the configured management IP address according to the first preset message, the SDN controller selects the configured management IP address from the allocable management IP address pool to allocate to the first SDN access device, and carries the management IP address allocated to the first SDN access device through the first response message.
In an exemplary embodiment, when the first predetermined packet is a DHCP request packet, the SDN controller may identify whether the first SDN access device has a configured management IP address locally according to whether a client address (ciaddr) field of the DHCP request packet carries the management IP address. If the ciaddr field is empty, it indicates that the first SDN access device does not have a configured management IP address locally, and if the ciaddr field carries a management IP address, it indicates that the first SDN access device has a configured management IP address carried by the ciaddr field locally but does not take effect.
In an exemplary embodiment, when the received first predetermined packet is encapsulated by an OpenFlow protocol message from a third SDN access device, opening a standby management channel from the first SDN access device to the SDN controller may further include:
and informing the third SDN access device to add the interface which receives the first preset message into the management VLAN. Namely, a management channel between the second SDN access device and the third SDN access device is opened.
Wherein the SDN controller records a management IP address assigned to a first SDN access device as a permanent lease to the first SDN access device.
In an exemplary embodiment, after opening a standby management channel from the first SDN access device to the SDN controller, the method of this embodiment may further include:
receiving a third preset message which is transmitted by first SDN access equipment and carries a message serial number of second SDN access equipment, wherein the second SDN access equipment is connected with the first SDN access equipment;
after confirming that a third preset message of the second SDN access device is not processed, when the second SDN access device is identified to have no configured management IP address according to the third preset message, selecting the management IP address from an allocable management IP address pool to allocate to the second SDN access device, and carrying the management IP address allocated to the second SDN access device through a third response message; when the second SDN access device is identified to have the configured management IP address according to the third predetermined message, the configured management IP address is selected from an allocable management IP address pool and allocated to the second SDN access device, and the third response message carries the management IP address allocated to the second SDN access device.
Wherein the SDN controller records the management IP address allocated to the second SDN access device as a permanent lease for the second SDN access device.
In an exemplary embodiment, when the first predetermined packet carries a configured management IP address, the management IP address assigned to the first SDN access device carried by the first response packet is the configured management IP address carried by the first predetermined packet. When the third predetermined message carries the configured management IP address, the management IP address assigned to the second SDN access device carried by the third response message is the configured management IP address carried by the third predetermined message.
In an exemplary embodiment, the method of the present embodiment may further include at least one of:
when the SDN controller confirms that a first preset message of first SDN access equipment is not processed, a message sequence number carried by the first preset message of the first SDN access equipment is recorded in a processing list; when determining to process a first predetermined message of a first SDN access device, discarding the first predetermined message;
when the SDN controller confirms that a third preset message of a second SDN access device is not processed, a message sequence number carried by the third preset message of the second SDN access device is recorded in a processing list; and when determining to process the third predetermined message of the second SDN access device, discarding the third predetermined message.
The SDN controller may preset an initially empty processing list, or generate the processing list after receiving information of the SDN access device. However, this is not limited in this application.
In an exemplary embodiment, the confirming, by the SDN controller, that the first predetermined packet of the first SDN access device is not processed may include:
when the processing list does not have the device information of the first SDN access device, or when the processing list records the device information of the first SDN access device and the recorded message sequence number is smaller than the message sequence number carried by the first predetermined message, determining that the first predetermined message is not processed;
the SDN controller confirming that the third predetermined packet of the second SDN access device is not processed may include:
when the processing list does not have the device information of the second SDN access device, or when the processing list has recorded the device information of the second SDN access device and the recorded message sequence number is smaller than a message sequence number carried by a third predetermined message, it is determined that the third predetermined message is not processed.
When the device information of the first SDN access device is recorded in the processing list and the recorded message sequence number is greater than or equal to the message sequence number carried by the first predetermined message, it is determined that the first predetermined message is processed. And when the device information of the second SDN access device is recorded in the processing list and the recorded message sequence number is greater than or equal to the message sequence number carried by the third predetermined message, confirming that the third predetermined message is processed.
In an exemplary embodiment, the method of the present embodiment may further include at least one of:
after the first SDN access device and the SDN controller establish an OpenFlow connection through a management channel, when the SDN controller detects that the OpenFlow connection is disconnected, returning a message sequence number of the first SDN access device recorded in a processing list; for example, subtracting 1 from a message sequence number of the first SDN access device recorded in the processing list;
after the second SDN access device and the SDN controller establish an OpenFlow connection through the management channel, when the SDN controller detects that the OpenFlow connection is disconnected, returning the message sequence number of the second SDN access device recorded in the processing list.
In this embodiment, a processing procedure of the SDN controller receiving the second predetermined packet of the first SDN access device is similar to a processing procedure of the first predetermined packet, and a processing procedure of the SDN controller receiving the third predetermined packet of the second SDN access device is similar to a processing procedure of the first predetermined packet, and therefore details are not repeated here.
The method and the application example of the first embodiment can be referred to for the related processing procedure of the method of this embodiment, and thus are not described herein again.
Example four
The embodiment provides a device for implementing management channel switching, which is applied to an SDN controller, as shown in fig. 8, and includes:
a receiving module 801, configured to receive a first predetermined packet carrying a packet sequence number of a first SDN access device after the first SDN access device establishes an OpenFlow connection with an SDN controller through a management channel;
a processing module 802, configured to open a standby management channel from a first SDN access device to an SDN controller after it is determined that a first predetermined packet of the first SDN access device is not processed.
In an example embodiment, the processing module 802 may be configured to tunnel the first SDN access device to a standby management channel of the SDN controller by:
if the first SDN access device is identified to have no configured management IP address according to the first preset message, selecting the management IP address from a distributable management IP address pool to distribute to the first SDN access device, and carrying the management IP address distributed to the first SDN access device through a first response message;
when the first SDN access device is identified to have the configured management IP address according to the first preset message, the configured management IP address is selected from a distributable management IP address pool and allocated to the first SDN access device, and the management IP address allocated to the first SDN access device is carried by the first response message.
In an exemplary embodiment, the processing module 802 may be further configured to, when the first predetermined packet received by the receiving module 801 is encapsulated by an OpenFlow protocol message from a third SDN access device, open a standby management channel of the first SDN access device to the SDN controller by:
and informing the third SDN access device to add the interface which receives the first preset message into the management VLAN.
In an exemplary embodiment, when the first predetermined packet carries a configured management IP address, the management IP address allocated to the first SDN access device carried by the first response packet is the configured management IP address.
The processing module 802 may be further configured to record a management IP address assigned to a first SDN access device as a permanent lease for the first SDN access device.
In an exemplary embodiment, the processing module 802 may be configured to record a packet sequence number of a first SDN access device in a processing list when it is determined that a first predetermined packet of the first SDN access device is not processed; and when the first preset message of the first SDN access device is determined to be processed, discarding the first preset message.
In an exemplary embodiment, the processing module 802 may be configured to confirm that the first predetermined packet of the first SDN access device is not processed by:
when the processing list does not have the device information of the first SDN access device, or when the processing list has recorded the device information of the first SDN access device and the recorded message sequence number is smaller than the message sequence number carried by the first predetermined message, it is determined that the first predetermined message is not processed.
In an exemplary embodiment, the processing module 802 may be further configured to, after the first SDN access device establishes an OpenFlow connection with the SDN controller through the management channel, and when detecting that the OpenFlow connection is disconnected, rollback a packet sequence number of the first SDN access device recorded in the processing list.
For the processing flow of the apparatus of this embodiment, reference may be made to the method for implementing management channel switching in the third embodiment, and therefore, details are not described herein again.
EXAMPLE five
This embodiment provides a system for implementing management channel switching, including: the SDN system comprises an SDN controller and a first SDN access device;
the first SDN access device is used for sending a detection message to the SDN controller according to a detection period after an OpenFlow connection with the SDN controller is established through a management channel, and detecting a detection response message returned by the SDN controller; when the detection result of the detection response message meets the management channel switching condition, removing all interfaces of the detection response message from the management VLAN, and sending a first preset message carrying a message serial number;
the SDN controller is used for opening a standby management channel from the first SDN access device to the SDN controller after confirming that the first predetermined message of the first SDN access device is not processed after receiving the first predetermined message.
The managing the channel switching condition may include: detecting response messages replied by the SDN controller are not received within the timeout duration for N times or M times continuously; wherein N is the number of detection cycles for managing channel switching, M is the number of detection cycles for OpenFlow disconnection, N, M are positive integers, and N is smaller than M.
The first SDN access device may be further configured to receive, after sending the first predetermined packet, a first response packet sent by the SDN controller for the first predetermined packet; configuring a local management IP address according to the management IP address carried by the first response message and enabling the management IP address to take effect locally, or enabling the locally configured management IP address to take effect locally according to the first response message; adding the interface receiving the first response message into a management VLAN; when the first predetermined message carries the configured management IP address, the management IP address assigned to the first SDN access device carried by the first response message is the configured management IP address.
In an exemplary embodiment, the system of this embodiment may further include: the second SDN access device is used for sending a third preset message carrying a message serial number;
the first SDN access device may be configured to send, when an interface that receives the third predetermined packet is a management interface, the third predetermined packet to the SDN controller through an established management channel; when the interface receiving the third predetermined message is a non-management interface, transmitting the third predetermined message to the SDN controller through an OpenFlow protocol message, and adding the interface receiving the third predetermined message into a management VLAN according to the notification of the SDN controller;
the first SDN access device can be further used for transmitting a third response message, which is returned by the SDN controller and is directed to the third predetermined message, to the second SDN access device through the management interface;
the second SDN access device is used for configuring a local management IP address according to the management IP address carried by the third response message and enabling the management IP address to take effect locally after receiving the third response message, or enabling the locally configured management IP address to take effect according to the third response message; and adding the interface receiving the third response message into the management VLAN, and establishing OpenFlow connection with the SDN controller through a management channel.
For example, in the first embodiment, as shown in fig. 3, when the first SDN access device is an a1 device, the second SDN access device may be an a2 device.
In an exemplary embodiment, the system of this embodiment may further include: the third SDN access device is configured to receive a first predetermined packet of the first SDN access device, encapsulate the first predetermined packet in an OpenFlow protocol message (for example, a packetlin message), and send the OpenFlow protocol message to the SDN controller;
the third SDN access device may be further configured to forward a first response packet sent by the SDN controller to the first SDN access device, where the first response packet is for the first predetermined packet.
For example, in the first embodiment, as shown in fig. 3, when the first SDN access device is an a1 device, the third SDN access device may be an a0 device.
In addition, a machine-readable medium is further provided, in which computer-executable instructions are stored, and when the computer-executable instructions are executed by a processor, the method for implementing management channel switching on a first SDN access device side is implemented.
In addition, a machine-readable medium is further provided, in which computer-executable instructions are stored, and when the computer-executable instructions are executed by a processor, the method for implementing management channel switching on the SDN controller side is implemented.
It will be understood by those of ordinary skill in the art that all or some of the steps of the methods, systems, functional modules/units in the devices disclosed above may be implemented as software, firmware, hardware, and suitable combinations thereof. In a hardware implementation, the division between functional modules/units mentioned in the above description does not necessarily correspond to the division of physical components; for example, one physical component may have multiple functions, or one function or step may be performed by several physical components in cooperation. Some or all of the components may be implemented as software executed by a processor, such as a digital signal processor or microprocessor, or as hardware, or as an integrated circuit, such as an application specific integrated circuit. Such software can be distributed on machine-readable media (e.g., computer-readable media), which can include computer storage media (or non-transitory media) and communication media (or transitory media). The term computer storage media includes volatile and nonvolatile, removable and non-removable media implemented in any method or technology for storage of information such as computer readable instructions, data structures, program modules or other data, as is well known to those of ordinary skill in the art. Computer storage media includes, but is not limited to, RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, Digital Versatile Disks (DVD) or other optical disk storage, magnetic cassettes, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other medium which can be used to store the desired information and which can accessed by a computer. In addition, communication media typically embodies computer readable instructions, data structures, program modules or other data in a modulated data signal such as a carrier wave or other transport mechanism and includes any information delivery media as known to those skilled in the art.
Although the embodiments disclosed in the present application are described above, the descriptions are only for the convenience of understanding the present application, and are not intended to limit the present application. It will be understood by those skilled in the art that various changes in form and details may be made therein without departing from the spirit and scope of the disclosure as defined by the appended claims.

Claims (27)

1. A method for implementing management channel switching is applied to a first Software Defined Network (SDN) access device, and comprises the following steps:
after a first SDN access device establishes an OpenFlow connection with an SDN controller through a management channel, sending a detection message to the SDN controller according to a detection period, and detecting a detection response message returned by the SDN controller;
when the detection result of the detection response message meets the management channel switching condition, the first SDN access device removes all interfaces of the first SDN access device from a management Virtual Local Area Network (VLAN) under the condition of not disconnecting an OpenFlow connection, and sends a first preset message carrying a message sequence number;
receiving a first response message sent by the SDN controller and aiming at the first preset message; configuring a local management IP address according to the management network protocol IP address carried by the first response message and enabling the management IP address to take effect locally, or enabling the locally configured management IP address to take effect according to the first response message; adding the interface receiving the first response message into a management VLAN;
the management channel switching condition includes: continuously receiving no detection response message replied by the SDN controller for N times within the timeout duration; wherein N is the number of detection cycles for managing channel switching, N is smaller than M, N, M are positive integers, and M is the number of detection cycles for OpenFlow disconnection.
2. The method of claim 1, further comprising:
and after the detection response message replied by the SDN controller is not received within the timeout duration for M times continuously, the OpenFlow connection is disconnected.
3. The method of claim 1, wherein the first SDN access device establishes an OpenFlow connection with an SDN controller through a management channel, and wherein the method comprises the steps of:
the first SDN access equipment sends a second preset message; the message serial number carried by the second preset message is smaller than the message serial number carried by the first preset message;
receiving a second response message from the SDN controller for the second predetermined message;
configuring a local management IP address according to the management IP address carried by the second response message and enabling the management IP address to take effect locally, or enabling the locally configured management IP address to take effect according to the second response message;
adding the interface receiving the second response message into a management VLAN;
and establishing an OpenFlow connection with the SDN controller through an established management channel between the SDN controller and the OpenFlow connection.
4. The method of claim 3, wherein sending, by the first SDN access device, a second predetermined packet comprises:
when the first SDN access device judges that the first SDN access device does not have a configured management IP address, the second preset message carries a management IP address set to be empty;
when the first SDN access device judges that the configured management IP address exists, the configured management IP address is carried in the second preset message.
5. The method according to claim 4, wherein when the second predetermined packet carries a configured management IP address, the management IP address assigned to the first SDN access device carried by the second response packet is the configured management IP address.
6. The method of claim 3, wherein the second response packet further carries the following information: detecting period time interval, the number of detecting periods of OpenFlow disconnection, and the number of detecting periods of management channel switching;
after the receiving a second response packet from the SDN controller for the second predetermined packet, the method further includes: and recording the information carried by the second response message.
7. The method of claim 1 or 3, wherein after the first SDN access device establishes an OpenFlow connection with the SDN controller through a management channel, the method further comprises:
receiving a third preset message carrying a message serial number of a second SDN access device;
when the interface receiving the third predetermined message is a management interface, sending the third predetermined message to the SDN controller through an established management channel; when the interface receiving the third predetermined message is a non-management interface, transmitting the third predetermined message to the SDN controller through an OpenFlow protocol message, and adding the interface receiving the third predetermined message into a management VLAN according to the notification of the SDN controller;
and transmitting a third response message, which is returned by the SDN controller and is directed to the third predetermined message, to the second SDN access device through a management interface.
8. The method of claim 7, further applied to a second SDN access device connected to the first SDN access device;
the method further comprises the following steps:
the second SDN access equipment sends a third preset message carrying a message serial number;
receiving a third response message sent by the SDN controller and sent by the first SDN access device for the third predetermined message;
configuring a local management IP address according to the management IP address carried by the third response message and enabling the management IP address to take effect locally, or enabling the locally configured management IP address to take effect according to the third response message;
adding the interface receiving the third response message into a management VLAN;
establishing an OpenFlow connection with the SDN controller through a management channel.
9. The method according to claim 3, wherein the first predetermined message and the second predetermined message are both Dynamic Host Configuration Protocol (DHCP) request messages, and the first response message and the second response message are both DHCP response messages.
10. The method of claim 9, wherein the first SDN access device carries the configured management IP address through a client address ciaddr field of a DHCP request message.
11. A method for realizing management channel switching is applied to a Software Defined Network (SDN) controller, and comprises the following steps:
after a first SDN access device and an SDN controller establish an OpenFlow connection through a management channel, the SDN controller receives a first preset message carrying a message sequence number of the first SDN access device under the condition that the OpenFlow connection is not opened;
after confirming that a first preset message of the first SDN access device is not processed, the SDN controller opens a standby management channel from the first SDN access device to the SDN controller;
the first predetermined message is a message sent when the first SDN access device sends a probe message to the SDN controller according to a probe cycle, and a detection result of a probe response message returned by the SDN controller meets a management channel switching condition and removes all interfaces of the first SDN access device from a management Virtual Local Area Network (VLAN) under a condition that an OpenFlow connection is not disconnected; the management channel switching condition includes: continuously receiving no detection response message replied by the SDN controller for N times within the timeout duration; wherein N is the number of detection cycles for managing channel switching, N is smaller than M, N, M are positive integers, and M is the number of detection cycles for OpenFlow disconnection.
12. The method of claim 11, wherein opening a standby management channel of the first SDN access device to the SDN controller comprises:
when the SDN controller identifies that the first SDN access device does not have a configured management network protocol IP address according to the first preset message, selecting a management IP address from an allocable management IP address pool to allocate to the first SDN access device, and carrying the management IP address allocated to the first SDN access device through a first response message;
when the SDN controller identifies that the first SDN access device has a configured management IP address according to a first preset message, the SDN controller selects the configured management IP address from an allocable management IP address pool to allocate to the first SDN access device, and carries the management IP address allocated to the first SDN access device through a first response message.
13. The method of claim 12, wherein opening a standby management channel from the first SDN access device to the SDN controller when the received first predetermined packet is encapsulated by an OpenFlow protocol message from a third SDN access device, further comprises: and informing the third SDN access device to add the interface which receives the first preset message into a management VLAN.
14. The method of claim 11, wherein after opening a standby management channel for the first SDN access device to the SDN controller, the method further comprises:
receiving a third predetermined message, which carries a message sequence number, of a second SDN access device, wherein the third predetermined message is transmitted by the first SDN access device, and the second SDN access device is connected with the first SDN access device;
after confirming that a third predetermined message of the second SDN access device is not processed, when the second SDN access device is identified to have no configured management IP address according to the third predetermined message, selecting a management IP address from an allocable management IP address pool to allocate to the second SDN access device, and carrying the management IP address allocated to the second SDN access device through a third response message; when the second SDN access device is identified to have a configured management IP address according to the third predetermined message, selecting the configured management IP address from a allocable management IP address pool to allocate to the second SDN access device, and carrying the management IP address allocated to the second SDN access device through a third response message.
15. The method according to claim 12 or 14, further comprising at least one of: the SDN controller records a management IP address allocated to the first SDN access device as a permanent lease for the first SDN access device; the SDN controller records a management IP address allocated to the second SDN access device as a permanent lease to the second SDN access device.
16. The method according to claim 11 or 14, further comprising at least one of:
when the SDN controller confirms that a first preset message of the first SDN access device is not processed, recording a message sequence number carried by the first preset message of the first SDN access device in a processing list; when determining that a first predetermined message of the first SDN access device is processed, discarding the first predetermined message;
when the SDN controller confirms that a third preset message of the second SDN access device is not processed, recording a message sequence number carried by the third preset message of the second SDN access device in a processing list; and when determining that a third predetermined message of the second SDN access device is processed, discarding the third predetermined message.
17. The method of claim 16, wherein the SDN controller confirming that a first predetermined packet of the first SDN access device has not been processed comprises:
when the processing list does not have the device information of the first SDN access device, or when the processing list has recorded the device information of the first SDN access device and a recorded message sequence number is smaller than a message sequence number carried by the first predetermined message, determining that the first predetermined message is not processed;
the SDN controller confirming that a third predetermined packet of the second SDN access device has not been processed includes:
when the processing list does not include the device information of the second SDN access device, or when the processing list records the device information of the second SDN access device and the recorded packet sequence number is smaller than the packet sequence number carried by the third predetermined packet, it is determined that the third predetermined packet is not processed.
18. The method of claim 16, further comprising at least one of:
after a first SDN access device and an SDN controller establish an OpenFlow connection through a management channel, when the SDN controller detects that the OpenFlow connection is disconnected, returning a message sequence number of the first SDN access device recorded in the processing list;
after an OpenFlow connection is established between a second SDN access device and an SDN controller through a management channel, when the SDN controller detects that the OpenFlow connection is disconnected, returning a message sequence number of the second SDN access device recorded in the processing list.
19. An apparatus for implementing management channel switching, applied to a first Software Defined Network (SDN) access device, includes:
the connection establishing module is used for establishing OpenFlow connection with the SDN controller through the management channel;
the connection detection module is used for sending a detection message to the SDN controller according to a detection period after the connection establishment module establishes an OpenFlow connection with the SDN controller through a management channel, and detecting a detection response message returned by the SDN controller;
the switching processing module is used for removing all interfaces of the detection response message from the management Virtual Local Area Network (VLAN) under the condition of not disconnecting the OpenFlow connection when the detection result of the detection response message meets the switching condition of the management channel, and sending a first preset message carrying a message serial number; receiving a first response message sent by the SDN controller and aiming at the first preset message; configuring a local management IP address according to the management network protocol IP address carried by the first response message and enabling the management IP address to take effect locally, or enabling the locally configured management IP address to take effect according to the first response message; adding the interface receiving the first response message into a management VLAN;
the management channel switching condition includes: continuously receiving no detection response message replied by the SDN controller for N times within the timeout duration; wherein N is the number of detection cycles for managing channel switching, N is smaller than M, N, M are positive integers, and M is the number of detection cycles for OpenFlow disconnection.
20. The apparatus of claim 19,
the switching processing module is further configured to disconnect the OpenFlow connection after the detection response packet replied by the SDN controller is not received within the timeout duration for M consecutive times.
21. An apparatus for implementing management channel switching, applied to a Software Defined Network (SDN) controller, includes:
the device comprises a receiving module and a sending module, wherein the receiving module is used for receiving a first preset message carrying a message serial number of a first SDN access device under the condition of not opening an OpenFlow connection after the first SDN access device and an SDN controller establish the OpenFlow connection through a management channel;
a processing module, configured to open a standby management channel from the first SDN access device to the SDN controller after it is determined that the first predetermined packet of the first SDN access device is not processed;
the first predetermined message is a message sent when the first SDN access device sends a probe message to the SDN controller according to a probe cycle, and a detection result of a probe response message returned by the SDN controller meets a management channel switching condition and removes all interfaces of the first SDN access device from a management Virtual Local Area Network (VLAN) under a condition that an OpenFlow connection is not disconnected; the management channel switching condition includes: continuously receiving no detection response message replied by the SDN controller for N times within the timeout duration; wherein N is the number of detection cycles for managing channel switching, N is smaller than M, N, M are positive integers, and M is the number of detection cycles for OpenFlow disconnection.
22. The apparatus of claim 21, wherein the processing module is further configured to record, in a processing list, a packet sequence number carried in a first predetermined packet of the first SDN access device when it is determined that the first predetermined packet of the first SDN access device is not processed; when determining that a first predetermined packet of the first SDN access device is processed, discarding the first predetermined packet.
23. The apparatus of claim 22, wherein the processing module is further configured to, after an OpenFlow connection is established between a first SDN access device and an SDN controller through a management channel, rollback a packet sequence number of the first SDN access device recorded in the processing list when detecting that the OpenFlow connection is disconnected.
24. A system for implementing management channel switching, comprising: the software defined network SDN access device comprises a software defined network SDN controller and a first SDN access device;
the first SDN access device is used for sending a detection message to an SDN controller according to a detection period after an OpenFlow connection with the SDN controller is established through a management channel, and detecting a detection response message returned by the SDN controller; when the detection result of the detection response message meets the management channel switching condition, removing all interfaces of the detection response message from the management Virtual Local Area Network (VLAN) under the condition of not disconnecting the OpenFlow connection, and sending a first preset message carrying a message serial number; receiving a first response message sent by the SDN controller and aiming at the first preset message; configuring a local management IP address according to the management network protocol IP address carried by the first response message and enabling the management IP address to take effect locally, or enabling the locally configured management IP address to take effect according to the first response message; adding the interface receiving the first response message into a management VLAN;
the management channel switching condition includes: continuously receiving no detection response message replied by the SDN controller for N times within the timeout duration; wherein N is the number of detection cycles for managing channel switching, N is smaller than M, N, M are positive integers, and M is the number of detection cycles for OpenFlow disconnection;
the SDN controller is configured to, after receiving the first predetermined packet and after confirming that the first predetermined packet of the first SDN access device is not processed, open a standby management channel from the first SDN access device to the SDN controller.
25. The system of claim 24, wherein the first SDN access device is further configured to receive a first response packet sent by the SDN controller for a first predetermined packet after sending the first predetermined packet; configuring a local management IP address according to the management network protocol IP address carried by the first response message and enabling the management IP address to take effect locally, or enabling the locally configured management IP address to take effect according to the first response message; adding the interface receiving the first response message into a management VLAN; when the first predetermined message carries a configured management IP address, the management IP address allocated to the first SDN access device carried by the first response message is the configured management IP address.
26. The system of claim 24, further comprising: the second SDN access device is used for sending a third preset message carrying a message serial number;
the first SDN access device is configured to send the third predetermined packet to the SDN controller through an established management channel when an interface that receives the third predetermined packet is a management interface; when the interface receiving the third predetermined message is a non-management interface, transmitting the third predetermined message to the SDN controller through an OpenFlow protocol message, and adding the interface receiving the third predetermined message into a management VLAN according to the notification of the SDN controller;
the first SDN access device is further used for transmitting a third response message, which is returned by the SDN controller and is directed to the third predetermined message, to the second SDN access device through a management interface;
the second SDN access device is configured, after receiving the third response packet, to configure a local management IP address according to the management IP address carried in the third response packet and enable the local management IP address to take effect locally, or enable the local configured management IP address to take effect according to the third response packet; adding the interface receiving the third response message into a management VLAN; establishing an OpenFlow connection with the SDN controller through a management channel.
27. The system of claim 25, further comprising: the third SDN access device is used for receiving a first preset message of the first SDN access device, encapsulating the first preset message in an OpenFlow protocol message and sending the first preset message to the SDN controller;
the third SDN access device is further configured to forward a first response packet sent by the SDN controller for the first predetermined packet to the first SDN access device.
CN201710402871.XA 2017-06-01 2017-06-01 Method, device and system for realizing management channel switching Active CN107147575B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710402871.XA CN107147575B (en) 2017-06-01 2017-06-01 Method, device and system for realizing management channel switching

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710402871.XA CN107147575B (en) 2017-06-01 2017-06-01 Method, device and system for realizing management channel switching

Publications (2)

Publication Number Publication Date
CN107147575A CN107147575A (en) 2017-09-08
CN107147575B true CN107147575B (en) 2020-10-02

Family

ID=59780382

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710402871.XA Active CN107147575B (en) 2017-06-01 2017-06-01 Method, device and system for realizing management channel switching

Country Status (1)

Country Link
CN (1) CN107147575B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109120520B (en) * 2018-10-15 2021-03-12 迈普通信技术股份有限公司 Fault processing method and equipment

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103067277A (en) * 2013-01-06 2013-04-24 华为技术有限公司 Method of building control channel, forwarding point (FP) and controller
CN103269278A (en) * 2013-04-19 2013-08-28 中国(南京)未来网络产业创新中心 Terminal equipment real-time connecting and disconnecting sensing method based on SDN
CN104158916A (en) * 2013-05-13 2014-11-19 中兴通讯股份有限公司 Method and device for device accessing to network
CN104301129A (en) * 2013-07-16 2015-01-21 上海宽带技术及应用工程研究中心 Dynamic host configuration method and system in software defined network
CN104618156A (en) * 2015-01-26 2015-05-13 杭州华三通信技术有限公司 Network configuration method and device
CN106603739A (en) * 2016-11-30 2017-04-26 瑞斯康达科技发展股份有限公司 Configuration method, apparatus and system thereof

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103067277A (en) * 2013-01-06 2013-04-24 华为技术有限公司 Method of building control channel, forwarding point (FP) and controller
CN103269278A (en) * 2013-04-19 2013-08-28 中国(南京)未来网络产业创新中心 Terminal equipment real-time connecting and disconnecting sensing method based on SDN
CN104158916A (en) * 2013-05-13 2014-11-19 中兴通讯股份有限公司 Method and device for device accessing to network
CN104301129A (en) * 2013-07-16 2015-01-21 上海宽带技术及应用工程研究中心 Dynamic host configuration method and system in software defined network
CN104618156A (en) * 2015-01-26 2015-05-13 杭州华三通信技术有限公司 Network configuration method and device
CN106603739A (en) * 2016-11-30 2017-04-26 瑞斯康达科技发展股份有限公司 Configuration method, apparatus and system thereof

Also Published As

Publication number Publication date
CN107147575A (en) 2017-09-08

Similar Documents

Publication Publication Date Title
CN107623593B (en) Method and equipment for hot standby of dual computers based on CU separation
US7826400B2 (en) Packet ring network system and packet transport method
EP2751960B1 (en) Constructing a network enabling layer-2 interconnection of data centers
EP3672173B1 (en) Communication method and device, and storage medium
TW201722110A (en) Fail recovery method and internet of things system and charging system using the same
JP2006013827A (en) Packet transfer apparatus
US10367680B2 (en) Network relay apparatus, gateway redundancy system, program, and redundancy method
CN108173757B (en) Port state setting method and device
CN111225401A (en) Method and related equipment for realizing disaster tolerance
CN103986638A (en) Method and device for binding multiple public network links for ADVPN tunnel
CN104301298A (en) Rapid startup with dynamic reservation capabilities for network communication systems
CN108449276B (en) Route convergence method and device
CN107147575B (en) Method, device and system for realizing management channel switching
CN109302328B (en) Hot standby switching method and system for VXLAN (virtual extensible local area network)
CN108667640B (en) Communication method and device, and network access system
CN107222409B (en) Method and node for forwarding traffic
US20140092912A1 (en) Fibre channel over ethernet switch implicit logout
EP3293948A1 (en) Redundancy method and device adapted to be implemented at a local network equipment
CN110289978B (en) Port mode switching method and related equipment thereof
CN108599984B (en) Method for sharing port state, access equipment and system for supporting dual-homing protection
EP3068082B1 (en) Fault processing method and apparatus for edge route bridge in trill network
CN113691435B (en) Message processing method, system and device
JP6953713B2 (en) Communication nodes, communication systems, communication methods and programs
US8566460B1 (en) Method and apparatus for initiating temporary configuration allowing remote accessing via a network device
US9554290B2 (en) Wireless communication system and method for automatically switching device identifications

Legal Events

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