CN110912725A - Configuration method and configuration device of OpenFlow virtual switch - Google Patents

Configuration method and configuration device of OpenFlow virtual switch Download PDF

Info

Publication number
CN110912725A
CN110912725A CN201811086304.9A CN201811086304A CN110912725A CN 110912725 A CN110912725 A CN 110912725A CN 201811086304 A CN201811086304 A CN 201811086304A CN 110912725 A CN110912725 A CN 110912725A
Authority
CN
China
Prior art keywords
configuration
virtual switch
switch
function
openflow virtual
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.)
Pending
Application number
CN201811086304.9A
Other languages
Chinese (zh)
Inventor
郑世慧
常甫
孙斌
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing University of Posts and Telecommunications
Original Assignee
Beijing University of Posts and Telecommunications
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 Beijing University of Posts and Telecommunications filed Critical Beijing University of Posts and Telecommunications
Priority to CN201811086304.9A priority Critical patent/CN110912725A/en
Publication of CN110912725A publication Critical patent/CN110912725A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • H04L41/0803Configuration setting
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/2866Architectures; Arrangements
    • H04L67/30Profiles

Abstract

The embodiment of the invention provides a configuration method and a configuration device of an OpenFlow virtual switch, wherein the method comprises the following steps: acquiring configuration data of parameters to be configured in the OpenFlow virtual switch to be configured; generating a parameter to be configured based on a YANG model specified by an OF-CONFIG protocol; generating a configuration file by using the acquired configuration data of the parameters to be configured; and sending the configuration file to the OpenFlow virtual switch to be configured so that the OpenFlow virtual switch to be configured is configured according to the configuration file. The embodiment of the invention can realize richer functions of the OpenFlow virtual switch, can automatically generate the configuration file according to the acquired configuration data, and improves the convenience in configuring the OpenFlow virtual switch.

Description

Configuration method and configuration device of OpenFlow virtual switch
Technical Field
The present invention relates to the field of network communication technologies, and in particular, to a configuration method and a configuration device for an OpenFlow virtual switch.
Background
The network based on the IP protocol can guarantee the most basic network connectivity, but when the service has a requirement other than the network connectivity, for example, when the route selection is performed based on the source address, the device needs to be implemented in a special manner, and different implementation schemes of different device manufacturers are different, which easily results in an increase in the user investment cost.
In this context, the OpenFlow technique has emerged. OpenFlow is a network communication protocol for controlling the data plane of a network switch. In recent years, with the rapid rise of cloud computing and virtualization, based on the programmable characteristics brought to the Network by the OpenFlow protocol, an SDN (Software Defined Network) appears, the core of which is to separately forward and manage, so that a traditional switch and a traditional router are only responsible for forwarding a packet, and forwarding policies and rules of the packet are managed by a centralized controller.
With the development and wide application of the SDN application, the number of OpenFlow-based SDN network switching devices is increasing. The controller communicates with the configured switch according to the OpenFlow protocol. The configuration of the switch needs to be completed before normal operation, and the configuration is beyond the scope of the OpenFlow protocol specification and needs to be completed through other configuration protocols. In order to configure and manage an OpenFlow switch, an OF-CONFIG configuration management protocol is proposed by an Open Network Foundation (ONF), which is a network management protocol for an OpenFlow switch.
In the existing virtual switch configuration method, the virtual switch can be configured by combining a YANG model and a NETCONF protocol. Among them, the YANG model is called YetAnother Next Generation model.
However, because the custom YANG model and the NETCONF protocol are used in the existing method and do not conform to the OF-CONFIG protocol specification, only basic configuration, such as adding/deleting a bridge and configuring an IP address OF a switch, can be performed in the process OF configuring the OpenFlow virtual switch, and thus the richer functions OF the OpenFlow virtual switch cannot be realized.
Disclosure of Invention
Embodiments of the present invention provide a configuration method and a configuration device for an OpenFlow virtual switch, so as to enable the configured OpenFlow virtual switch to have richer functions. The specific technical scheme is as follows:
in a first aspect, an embodiment of the present invention provides a configuration method for an OpenFlow virtual switch, where the method includes:
acquiring configuration data of parameters to be configured in the OpenFlow virtual switch to be configured; the parameters to be configured are generated based on a YANG model specified by an OF-CONFIG protocol; different configuration parameters are used for realizing different functions of the OpenFlow virtual switch, where the functions at least include: a logical switch management function, a port management function, a controller management function, and a switch setup backup function;
generating a configuration file by using the acquired configuration data of the parameter to be configured;
and sending the configuration file to an OpenFlow virtual switch to be configured so that the OpenFlow virtual switch to be configured is configured according to the configuration file.
Preferably, the method further comprises:
generating a configuration command by using the acquired configuration data of the parameter to be configured;
and sending the configuration command to an OpenFlow virtual switch to be configured so that the OpenFlow virtual switch to be configured performs configuration according to the configuration command.
Preferably, the logical switch management function includes: the logic switch creates a sub-function, the logic switch modifies the sub-function and the logic switch removes the sub-function;
the port management functions include: a port creation/removal sub-function; a port parameter configuration sub-function; binding a port and a physical network card with a sub-function; a queue creation and configuration sub-function; a queue removal sub-function; a VxLAN tunnel creating and configuring sub-function; a VxLAN tunnel removal sub-function;
the controller management functions include: the controller connects and modifies the sub-function; the controller removes the sub-function;
the switch setting backup function includes: the switch backup sets the subfunction; the switch restores the setting sub-function; a switch clear setup sub-function; a switch backup management sub-function; the switch configures sub-functions in batch;
the step of generating a configuration command by using the acquired configuration data of the parameter to be configured includes:
generating a first configuration command according to the acquired first configuration data, wherein the first configuration data are: configuration data of parameters to be configured related to the port and physical network card binding subfunction; the first configuration command is used for binding a port of the OpenFlow virtual switch to a physical network card.
Preferably, the step of obtaining configuration data of each parameter to be configured in the OpenFlow virtual switch to be configured includes:
receiving configuration data of each parameter to be configured in the OpenFlow virtual switch to be configured, which is sent by a user side device browser; the browser is used for displaying a setting interface of the parameters to be configured in the OpenFlow virtual switch to be configured, and the setting interface is used for a user to set the parameters to be configured.
Preferably, the step of generating a configuration file by using the acquired configuration data of each parameter to be configured includes:
and generating a configuration file in an extensible markup language (XML) format, wherein the configuration file in the XML format records the configuration data of each parameter to be configured.
Preferably, the step of sending the configuration file to an OpenFlow virtual switch to be configured includes:
and sending the configuration file to the OpenFlow virtual switch to be configured through a netoper client through a NETCONF protocol.
In a second aspect, an embodiment of the present invention provides a configuration apparatus for an OpenFlow virtual switch, where the apparatus includes:
the obtaining module is used for obtaining configuration data of parameters to be configured in the OpenFlow virtual switch to be configured; the parameters to be configured are generated based on a YANG model specified by an OF-CONFIG protocol; different configuration parameters are used for realizing different functions of the OpenFlow virtual switch, where the functions at least include: a logical switch management function, a port management function, a controller management function, and a switch setup backup function;
the configuration file generation module is used for generating a configuration file by using the acquired configuration data of the parameter to be configured;
and the configuration file sending module is used for sending the configuration file to the OpenFlow virtual switch to be configured so that the OpenFlow virtual switch to be configured is configured according to the configuration file.
Preferably, the apparatus further comprises:
the configuration command generation module is used for generating a configuration command by using the acquired configuration data of the parameter to be configured;
and the configuration command sending module is used for sending the configuration command to the OpenFlow virtual switch to be configured so that the OpenFlow virtual switch to be configured performs configuration according to the configuration command.
In a third aspect, an embodiment of the present invention provides an electronic device, including a processor, a communication interface, a memory, and a communication bus, where the processor, the communication interface, and the memory complete mutual communication through the communication bus; the machine-readable storage medium stores machine-executable instructions executable by the processor, the processor being caused by the machine-executable instructions to: the method for configuring the OpenFlow virtual switch provided in the first aspect of the embodiment of the present invention is implemented.
In a fourth aspect, an embodiment of the present invention provides a computer-readable storage medium, where a computer program is stored in the computer-readable storage medium, and the computer program is executed by a processor to perform the method steps of the configuration method for an OpenFlow virtual switch provided in the first aspect of the embodiment of the present invention.
The configuration method and the configuration device for the OpenFlow virtual switch provided by the embodiment OF the invention comprise the steps OF firstly, acquiring configuration data OF parameters to be configured in the OpenFlow virtual switch to be configured, wherein the parameters to be configured are generated based on a YANG model specified by an OF-CONFIG protocol; then, the server generates a configuration file by using the acquired configuration data of the parameters to be configured; and generating the configuration file to the OpenFlow virtual switch to be configured, so that the OpenFlow virtual switch to be configured can be configured according to the configuration file. The parameters to be configured are generated based on a YANG model specified by the OF-CONFIG protocol, so that the method conforms to the OF-CONFIG protocol, and has the capabilities OF configuring a logic switch management function, a port management function, a controller management function and a switch setting backup function OF the OpenFlow virtual switch, thereby realizing richer functions OF the OpenFlow virtual switch. In addition, according to the embodiment of the invention, the configuration file can be automatically generated according to the acquired configuration data, so that the convenience in configuration of the OpenFlow virtual switch is improved. Of course, it is not necessary for any product or method of practicing the invention to achieve all of the above-described advantages at the same time.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts.
Fig. 1 is a schematic flowchart of a configuration method of an OpenFlow virtual switch according to an embodiment of the present invention;
FIG. 2 is a system architecture diagram of an embodiment of the present invention;
fig. 3 is another schematic flow chart of a configuration method of an OpenFlow virtual switch according to an embodiment of the present invention;
fig. 4 is a schematic structural diagram of a configuration apparatus of an OpenFlow virtual switch according to an embodiment of the present invention;
fig. 5 is a schematic structural diagram of a configuration apparatus of an OpenFlow virtual switch according to an embodiment of the present invention;
fig. 6 is a schematic structural diagram of an electronic device according to an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
As shown in fig. 1, an embodiment of the present invention provides a configuration method for an OpenFlow virtual switch, where the configuration method may include the following steps:
s101, obtaining configuration data of parameters to be configured in the OpenFlow virtual switch to be configured.
In the embodiment of the present invention, the OpenFlow virtual switch to be configured refers to an OpenFlow virtual switch that is not configured yet, and in an SDN network environment, if a function of the virtual switch is to be implemented, the virtual switch needs to be configured. The OpenFlow virtual switch refers to a virtual switch operating based on an OpenFlow network communication protocol, for example, an ovs (open vswitch) virtual switch.
The OpenFlow virtual switch may be configured by a configuration parameter, for example, the virtual switch may be named by a configuration parameter of virtual-switch-id (local-switches-id). Of course, the above example is only one of the configuration parameters of the OpenFlow virtual switch. It is easy to understand that when a configuration parameter is not set, it can be called a parameter to be configured. Generally, the configuration data of the parameters to be configured may be set manually, so that the server may obtain the configuration data of the parameters to be configured.
As an optional implementation manner of the embodiment of the present invention, the configuration method of the OpenFlow virtual switch according to the embodiment of the present invention may be implemented based on a B/S (Browser/Server) architecture, that is, a setting interface is displayed in a Browser of a user end device, where the setting interface shows each parameter to be configured in the OpenFlow virtual switch, and a user may complete configuration parameter setting by inputting configuration data, for example, in a local-switches-id option of the parameter to be configured, the user inputs a name switch 1 of the virtual switch, and thus may complete setting of an id of the virtual switch. Then, the configuration data is transmitted to the server through the network, and the server acquires the configuration data input by the user. The configuration data typically includes simple english, letters, and numbers.
And S102, generating a configuration file by using the acquired configuration data of the parameters to be configured.
After the server obtains the configuration data of the parameters to be configured, a configuration file can be generated, and various configuration parameters of the OpenFlow virtual switch to be configured are recorded in the configuration file.
As an optional implementation manner OF the embodiment OF the present invention, the format OF the generated configuration file may be an XML (Extensible Markup Language) format, which is a simple data storage Language, and is widely applied to the fields OF data storage and data transmission, and may be used to describe a data structure OF a NETCONF or OF-CONFIG protocol. As can be seen from the foregoing, since the configuration data usually contains simple english, letters, and numbers, the configuration data can be easily written into the configuration file in the XML format.
And S103, sending the configuration file to the OpenFlow virtual switch to be configured so that the OpenFlow virtual switch to be configured is configured according to the configuration file.
As shown in fig. 2, which is a system architecture diagram according to an embodiment of the present invention, a server may be connected to multiple client devices, and the server may also be connected to multiple OpenFlow virtual switches to be configured, so as to send a configuration file to the OpenFlow virtual switches to be configured.
After receiving the configuration file, the OpenFlow virtual switch to be configured can analyze configuration data OF each configuration parameter in the configuration file, and configure by using the configuration data, so that each function OF the OpenFlow virtual switch is realized.
The specific configuration process may be that the server connects to the OpenFlow virtual switch using a connect command; the server sends the xml-type configuration file to the OpenFlow virtual switch through an edge-config command to complete corresponding configuration; after configuration is complete, the server disconnects using a disconnect command.
As an optional implementation manner of the embodiment of the present invention, before step S103, the server may be connected to the host where the OpenFlow virtual switch is located in an SSH (Secure Shell, Secure Shell protocol) public key password-free authentication manner, so that a password may not be input in a subsequent automatic configuration.
As can be seen from the above, different configuration parameters may implement different functions of the OpenFlow virtual switch, where the functions at least include: logical switch management functions, port management functions, controller management functions, and switch setup backup functions. Also, these functions may include multiple sub-functions.
The logical switch management function in the embodiment of the present invention may include: the logical switch creates a sub-function, the logical switch modifies the sub-function, and the logical switch removes the sub-function.
Each sub-work may correspond to a plurality of configuration parameters, and the configuration parameters may be further divided into required configuration parameters and non-required configuration parameters. The required configuration parameters are parameters which are required to be used when the OpenFlow virtual switch is configured, and lack of the required configuration parameters may cause unsuccessful configuration of the OpenFlow virtual switch; the non-essential configuration parameters refer to parameters which are not essential when the OpenFlow virtual switch is configured, and the absence of the non-essential configuration parameters does not cause the configuration of the OpenFlow virtual switch to be unsuccessful.
Referring to table 1, for the partitioning of each configuration parameter when creating a logical switch (i.e., an OpenFlow virtual switch):
table 1 partitioning of configuration parameters when creating logical switches
Figure BDA0001803228530000081
Referring to table 2, for the partition of each configuration parameter when modifying the logical switch:
table 2 partitioning of configuration parameters when modifying logical switches
Parameter(s) Whether it is necessary or not
id (logical switch identifier) Is that
Referring to table 3, for the partitioning of each configuration parameter when removing the logical switch:
table 3 partitioning of configuration parameters when removing logical switches
Parameter(s) Whether it is necessary or not
id (logical switch identifier) Is that
Specifically, the port management function may include: a port creation/removal sub-function; a port parameter configuration sub-function; binding a port and a physical network card with a sub-function; a queue creation and configuration sub-function; a queue removal sub-function; a VxLAN tunnel creating and configuring sub-function; the VxLAN tunnel removes the subfunction.
Referring to table 4, for the partitioning of each configuration parameter when creating/removing a port:
table 4 partitioning of configuration parameters when creating/removing ports
Figure BDA0001803228530000091
Referring to table 5, the partitioning condition of each configuration parameter when the port is bound to the physical network card is:
TABLE 5 partitioning of configuration parameters when ports are bound to physical network cards
Figure BDA0001803228530000101
See Table 6 for partitioning of configuration parameters when creating and configuring queues
TABLE 6 partitioning of configuration parameters when creating and configuring queues
Figure BDA0001803228530000102
See Table 7 for partitioning of configuration parameters for queue removal
TABLE 7 partitioning of configuration parameters when removing queues
Figure BDA0001803228530000111
See table 8 for partitioning of configuration parameters when creating and configuring a VxLAN tunnel
Table 8 partitioning of configuration parameters when creating and configuring VxLAN tunnels
Figure BDA0001803228530000112
See Table 9 for partitioning of configuration parameters for VxLAN tunnel removal
Table 9 partitioning of configuration parameters when VxLAN tunnels are removed
Figure BDA0001803228530000121
Specifically, the controller management function may include: the controller connects and modifies the sub-function; the controller removes the sub-function.
Referring to table 10, for the partitioning of each configuration parameter when connecting and modifying the controller:
TABLE 10 partitioning of configuration parameters when connecting and modifying controllers
Figure BDA0001803228530000122
Referring to table 11, for the partitioning of each configuration parameter when the controller is removed:
TABLE 11 partitioning of configuration parameters when removing controllers
Figure BDA0001803228530000131
Specifically, the setting of the backup function by the switch may include: the switch backup sets the subfunction; the switch restores the setting sub-function; a switch clear setup sub-function; a switch backup management sub-function; the switch configures the sub-functions in batches.
Referring to table 12, the partition condition of each configuration parameter during backup, restore, and clearing is set for the switch:
TABLE 12 partitioning of configuration parameters for switch settings backup, restore, and purge
Figure BDA0001803228530000132
Referring to table 13, for the partition condition of each configuration parameter during switch management and batch configuration:
TABLE 13 partitioning of configuration parameters for switch management and batch configuration
Figure BDA0001803228530000133
The configuration method OF the OpenFlow virtual switch provided by the embodiment OF the invention comprises the steps OF firstly, obtaining configuration data OF parameters to be configured in the OpenFlow virtual switch to be configured, wherein the parameters to be configured are generated based on a YANG model specified by an OF-CONFIG protocol; then, the server generates a configuration file by using the acquired configuration data of the parameters to be configured; and generating the configuration file to the OpenFlow virtual switch to be configured, so that the OpenFlow virtual switch to be configured can be configured according to the configuration file. The parameters to be configured are generated based on a YANG model specified by the OF-CONFIG protocol, so that the method conforms to the OF-CONFIG protocol, and has the capabilities OF configuring a logic switch management function, a port management function, a controller management function and a switch setting backup function OF the OpenFlow virtual switch, thereby realizing richer functions OF the OpenFlow virtual switch. In addition, according to the embodiment of the invention, the configuration file can be automatically generated according to the acquired configuration data, so that the convenience in configuration of the OpenFlow virtual switch is improved.
An embodiment of the present invention further provides a configuration method for an OpenFlow virtual switch, and as shown in fig. 3, the configuration method may include the following steps:
s201, obtaining configuration data of parameters to be configured in the OpenFlow virtual switch to be configured.
S202, generating a configuration file by using the acquired configuration data of the parameters to be configured.
And S203, sending the configuration file to the OpenFlow virtual switch to be configured so that the OpenFlow virtual switch to be configured is configured according to the configuration file.
The steps S201 to S203 are the same as S101 to S103 in the first embodiment, and are not described herein again.
And S204, generating a configuration command by using the acquired configuration data of the parameters to be configured.
After the server obtains the configuration data of the parameters to be configured, a configuration command can be generated, and the OpenFlow virtual switch is configured by using the configuration command.
And S205, sending the configuration command to the OpenFlow virtual switch to be configured, so that the OpenFlow virtual switch to be configured performs configuration according to the configuration command.
The server can be connected to a host where the OpenFlow virtual switch is located through an SSH protocol, a command-line interface (CLI) command is generated based on an open-CONFIG protocol and a network connection protocol, the CLI command is sent to the OpenFlow virtual switch to be configured, and corresponding configuration is carried out on the OpenFlow virtual switch to be configured; after the configuration is completed, the connection is disconnected using the exit command.
Specifically, the logical bridge of the OpenFlow virtual switch may be bound to the physical network card through the configuration command, a gateway may be set for the logical bridge, and a static route may be set for the vxlan network card.
As an optional implementation manner of the embodiment of the present invention, step S205 may specifically include:
and generating a first configuration command according to the acquired first configuration data.
Wherein the first configuration data is: and configuration data of parameters to be configured related to the port and physical network card binding subfunction. The first configuration command is used for binding the port of the OpenFlow virtual switch to the physical network card. The OpenFlow virtual switch can perform different configurations according to different received configuration commands.
As an optional implementation manner of the embodiment of the present invention, the mobile terminal and the server may pre-store instruction codes corresponding to each configuration command, for example, the instruction code 1 corresponds to a first configuration command, the user may send the code to the server through the mobile terminal, and the server identifies the configuration command corresponding to the instruction code and sends the configuration command to the OpenFlow virtual switch to be configured, so that the user can configure the OpenFlow virtual switch at any time or place, thereby further improving flexibility in configuration operation. It should be noted that the mobile terminal may be a mobile terminal device such as a smart phone and a tablet computer, which is equipped with an operating system.
Compared with the prior art, the embodiment of the invention has the advantages that:
when the configuration method of the embodiment of the invention is used for carrying out automatic configuration on the OpenFlow virtual switch, a server can automatically generate a correct configuration file and send the configuration file to equipment for configuration only by selecting a corresponding function and inputting a small amount of parameters by a user.
In actual work, even a skilled manager has difficulty in remembering various options required for configuration, and often needs to refer to a help document. In the embodiment of the invention, the user only needs to select the corresponding function without memorizing a plurality of options, and obviously, the configuration process can be accelerated.
In addition, a network failure in reality is caused by human error in some cases. The embodiment of the invention obviously reduces the input content of the user in the configuration process, thereby reducing the errors possibly occurring in manual configuration and further enabling the network configuration management to become more stable.
According to the configuration method of the OpenFlow virtual switch, the server can not only enable the OpenFlow virtual switch to be configured according to the configuration file by sending the configuration file, but also enable the OpenFlow virtual switch to be configured according to the configuration command by sending the configuration command, so that the flexibility in configuring the OpenFlow virtual switch is improved.
A specific embodiment of the configuration device for an OpenFlow virtual switch according to an embodiment of the present invention corresponds to the flow shown in fig. 1, and referring to fig. 4, fig. 4 is a schematic structural diagram of the configuration device for an OpenFlow virtual switch according to an embodiment of the present invention, and includes:
an obtaining module 301, configured to obtain configuration data of a parameter to be configured in an OpenFlow virtual switch to be configured; generating parameters to be configured based on a YANG model specified by an OF-CONFIG protocol; different configuration parameters are used for realizing different functions of the OpenFlow virtual switch, and the functions at least comprise: logical switch management functions, port management functions, controller management functions, and switch setup backup functions.
The configuration file generating module 302 is configured to generate a configuration file by using the acquired configuration data of the parameter to be configured.
The configuration file sending module 303 is configured to send the configuration file to the OpenFlow virtual switch to be configured, so that the OpenFlow virtual switch to be configured performs configuration according to the configuration file.
The obtaining module 301 is specifically configured to:
receiving configuration data of each parameter to be configured in the OpenFlow virtual switch to be configured, which is sent by a user side device browser; the browser is used for displaying a setting interface of parameters to be configured in the OpenFlow virtual switch to be configured, and the setting interface is used for setting the parameters to be configured by a user.
The configuration file generating module 302 is specifically configured to:
and generating a configuration file in an extensible markup language (XML) format, wherein the configuration file in the XML format records configuration data of each parameter to be configured.
The configuration file sending module 303 is specifically configured to:
and sending the configuration file to the OpenFlow virtual switch to be configured by utilizing the netoperer client through a NETCONF protocol.
The configuration device OF the OpenFlow virtual switch provided by the embodiment OF the invention comprises the following steps OF firstly, obtaining configuration data OF parameters to be configured in the OpenFlow virtual switch to be configured, wherein the parameters to be configured are generated based on a YANG model specified by an OF-CONFIG protocol; then, the server generates a configuration file by using the acquired configuration data of the parameters to be configured; and generating the configuration file to the OpenFlow virtual switch to be configured, so that the OpenFlow virtual switch to be configured can be configured according to the configuration file. The parameters to be configured are generated based on a YANG model specified by the OF-CONFIG protocol, so that the method conforms to the OF-CONFIG protocol, and has the capabilities OF configuring a logic switch management function, a port management function, a controller management function and a switch setting backup function OF the OpenFlow virtual switch, thereby realizing richer functions OF the OpenFlow virtual switch. In addition, according to the embodiment of the invention, the configuration file can be automatically generated according to the acquired configuration data, so that the convenience in configuration of the OpenFlow virtual switch is improved.
An embodiment of the present invention further provides a configuration device for an OpenFlow virtual switch, where as shown in fig. 5, on the basis of the device structure shown in fig. 4, the configuration device further includes:
a configuration command generating module 304, configured to generate a configuration command by using the acquired configuration data of the parameter to be configured.
The configuration command sending module 305 is configured to send a configuration command to the OpenFlow virtual switch to be configured, so that the OpenFlow virtual switch to be configured performs configuration according to the configuration command.
According to the configuration device of the OpenFlow virtual switch, the server can not only enable the OpenFlow virtual switch to be configured according to the configuration file by sending the configuration file, but also enable the OpenFlow virtual switch to be configured according to the configuration command by sending the configuration command, so that the flexibility in configuring the OpenFlow virtual switch is improved.
An embodiment of the present invention further provides an electronic device, as shown in fig. 6, including a processor 401, a communication interface 402, a memory 403, and a communication bus 404, where the processor 401, the communication interface 402, and the memory 403 complete mutual communication through the communication bus 404,
a memory 403 for storing a computer program;
the processor 401, when executing the program stored in the memory 403, implements the following steps:
acquiring configuration data of parameters to be configured in the OpenFlow virtual switch to be configured;
generating a configuration file by using the acquired configuration data of the parameters to be configured;
and sending the configuration file to the OpenFlow virtual switch to be configured so that the OpenFlow virtual switch to be configured is configured according to the configuration file.
The electronic device provided by the embodiment OF the invention comprises the steps OF firstly, obtaining configuration data OF parameters to be configured in an OpenFlow virtual switch to be configured, wherein the parameters to be configured are generated based on a YANG model specified by an OF-CONFIG protocol; then, the server generates a configuration file by using the acquired configuration data of the parameters to be configured; and generating the configuration file to the OpenFlow virtual switch to be configured, so that the OpenFlow virtual switch to be configured can be configured according to the configuration file. The parameters to be configured are generated based on a YANG model specified by the OF-CONFIG protocol, so that the method conforms to the OF-CONFIG protocol, and has the capabilities OF configuring a logic switch management function, a port management function, a controller management function and a switch setting backup function OF the OpenFlow virtual switch, thereby realizing richer functions OF the OpenFlow virtual switch. In addition, according to the embodiment of the invention, the configuration file can be automatically generated according to the acquired configuration data, so that the convenience in configuration of the OpenFlow virtual switch is improved.
The communication bus mentioned in the electronic device may be a Peripheral Component Interconnect (PCI) bus, an Extended Industry Standard Architecture (EISA) bus, or the like. The communication bus may be divided into an address bus, a data bus, a control bus, etc. For ease of illustration, only one thick line is shown, but this does not mean that there is only one bus or one type of bus.
The communication interface is used for communication between the electronic equipment and other equipment.
The Memory may include a Random Access Memory (RAM) or a non-volatile Memory (non-volatile Memory), such as at least one disk Memory. Optionally, the memory may also be at least one memory device located remotely from the processor.
The Processor may be a general-purpose Processor, and includes a Central Processing Unit (CPU), a Network Processor (NP), and the like; the device can also be a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field Programmable Gate Array (FPGA) or other Programmable logic device, a discrete Gate or transistor logic device, or a discrete hardware component.
An embodiment of the present invention further provides a computer-readable storage medium, in which a computer program is stored, and is configured to execute the following steps:
acquiring configuration data of parameters to be configured in the OpenFlow virtual switch to be configured;
generating a configuration file by using the acquired configuration data of the parameters to be configured;
and sending the configuration file to the OpenFlow virtual switch to be configured so that the OpenFlow virtual switch to be configured is configured according to the configuration file.
The computer-readable storage medium provided by the embodiment OF the present invention first obtains configuration data OF a parameter to be configured in an OpenFlow virtual switch to be configured, where the parameter to be configured is generated based on a YANG model specified by an OF-CONFIG protocol; then, the server generates a configuration file by using the acquired configuration data of the parameters to be configured; and generating the configuration file to the OpenFlow virtual switch to be configured, so that the OpenFlow virtual switch to be configured can be configured according to the configuration file. The parameters to be configured are generated based on a YANG model specified by the OF-CONFIG protocol, so that the method conforms to the OF-CONFIG protocol, and has the capabilities OF configuring a logic switch management function, a port management function, a controller management function and a switch setting backup function OF the OpenFlow virtual switch, thereby realizing richer functions OF the OpenFlow virtual switch. In addition, according to the embodiment of the invention, the configuration file can be automatically generated according to the acquired configuration data, so that the convenience in configuration of the OpenFlow virtual switch is improved.
For the apparatus/electronic device/storage medium embodiment, since it is substantially similar to the method embodiment, the description is relatively simple, and for the relevant points, reference may be made to part of the description of the method embodiment.
It should be noted that the apparatus, the electronic device, and the storage medium according to the embodiments of the present invention are an apparatus, an electronic device, and a storage medium to which the configuration method of the OpenFlow virtual switch is applied, and all embodiments of the configuration method of the OpenFlow virtual switch are applicable to the apparatus, the electronic device, and the storage medium, and can achieve the same or similar beneficial effects.
It is noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
All the embodiments in the present specification are described in a related manner, and the same and similar parts among the embodiments may be referred to each other, and each embodiment focuses on the differences from the other embodiments. In particular, for the system embodiment, since it is substantially similar to the method embodiment, the description is simple, and for the relevant points, reference may be made to the partial description of the method embodiment.
The above description is only for the preferred embodiment of the present invention, and is not intended to limit the scope of the present invention. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention shall fall within the protection scope of the present invention.

Claims (10)

1. A configuration method of an OpenFlow virtual switch, the method comprising:
acquiring configuration data of parameters to be configured in the OpenFlow virtual switch to be configured; the parameters to be configured are generated based on a YANG model specified by an OF-CONFIG protocol; different configuration parameters are used for realizing different functions of the OpenFlow virtual switch, where the functions at least include: a logical switch management function, a port management function, a controller management function, and a switch setup backup function;
generating a configuration file by using the acquired configuration data of the parameter to be configured;
and sending the configuration file to an OpenFlow virtual switch to be configured so that the OpenFlow virtual switch to be configured is configured according to the configuration file.
2. The method of claim 1, further comprising:
generating a configuration command by using the acquired configuration data of the parameter to be configured;
and sending the configuration command to an OpenFlow virtual switch to be configured so that the OpenFlow virtual switch to be configured performs configuration according to the configuration command.
3. The method of claim 2, wherein the logical switch management function comprises: the logic switch creates a sub-function, the logic switch modifies the sub-function and the logic switch removes the sub-function;
the port management functions include: a port creation/removal sub-function; a port parameter configuration sub-function; binding a port and a physical network card with a sub-function; a queue creation and configuration sub-function; a queue removal sub-function; a VxLAN tunnel creating and configuring sub-function; a VxLAN tunnel removal sub-function;
the controller management functions include: the controller connects and modifies the sub-function; the controller removes the sub-function;
the switch setting backup function includes: the switch backup sets the subfunction; the switch restores the setting sub-function; a switch clear setup sub-function; a switch backup management sub-function; the switch configures sub-functions in batch;
the step of generating a configuration command by using the acquired configuration data of the parameter to be configured includes:
generating a first configuration command according to the acquired first configuration data, wherein the first configuration data are: configuration data of parameters to be configured related to the port and physical network card binding subfunction; the first configuration command is used for binding a port of the OpenFlow virtual switch to a physical network card.
4. The method according to claim 1, wherein the step of obtaining configuration data of each parameter to be configured in the OpenFlow virtual switch to be configured includes:
receiving configuration data of each parameter to be configured in the OpenFlow virtual switch to be configured, which is sent by a user side device browser; the browser is used for displaying a setting interface of the parameters to be configured in the OpenFlow virtual switch to be configured, and the setting interface is used for a user to set the parameters to be configured.
5. The method according to claim 1, wherein the step of generating a configuration file by using the acquired configuration data of each parameter to be configured includes:
and generating a configuration file in an extensible markup language (XML) format, wherein the configuration file in the XML format records the configuration data of each parameter to be configured.
6. The method according to claim 1, wherein the step of sending the configuration file to the OpenFlow virtual switch to be configured comprises:
and sending the configuration file to the OpenFlow virtual switch to be configured through a netoper client through a NETCONF protocol.
7. An apparatus for configuring an OpenFlow virtual switch, the apparatus comprising:
the obtaining module is used for obtaining configuration data of parameters to be configured in the OpenFlow virtual switch to be configured; the parameters to be configured are generated based on a YANG model specified by an OF-CONFIG protocol; different configuration parameters are used for realizing different functions of the OpenFlow virtual switch, where the functions at least include: a logical switch management function, a port management function, a controller management function, and a switch setup backup function;
the configuration file generation module is used for generating a configuration file by using the acquired configuration data of the parameter to be configured;
and the configuration file sending module is used for sending the configuration file to the OpenFlow virtual switch to be configured so that the OpenFlow virtual switch to be configured is configured according to the configuration file.
8. The apparatus of claim 7, further comprising:
the configuration command generation module is used for generating a configuration command by using the acquired configuration data of the parameter to be configured;
and the configuration command sending module is used for sending the configuration command to the OpenFlow virtual switch to be configured so that the OpenFlow virtual switch to be configured performs configuration according to the configuration command.
9. An electronic device, comprising a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory complete communication with each other through the communication bus;
the memory is used for storing a computer program;
the processor, when executing the program stored in the memory, is adapted to carry out the method steps of any of claims 1-6.
10. A computer-readable storage medium, characterized in that a computer program is stored in the computer-readable storage medium, which computer program, when being executed by a processor, carries out the method steps of any one of claims 1-6.
CN201811086304.9A 2018-09-18 2018-09-18 Configuration method and configuration device of OpenFlow virtual switch Pending CN110912725A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811086304.9A CN110912725A (en) 2018-09-18 2018-09-18 Configuration method and configuration device of OpenFlow virtual switch

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811086304.9A CN110912725A (en) 2018-09-18 2018-09-18 Configuration method and configuration device of OpenFlow virtual switch

Publications (1)

Publication Number Publication Date
CN110912725A true CN110912725A (en) 2020-03-24

Family

ID=69812784

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811086304.9A Pending CN110912725A (en) 2018-09-18 2018-09-18 Configuration method and configuration device of OpenFlow virtual switch

Country Status (1)

Country Link
CN (1) CN110912725A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113708966A (en) * 2021-08-24 2021-11-26 清华大学 Networked online configuration method, system and equipment for switch
US11212317B2 (en) * 2019-11-11 2021-12-28 International Business Machines Corporation Extending managed switching network to a virtualization layer in a computer
WO2023035777A1 (en) * 2021-09-13 2023-03-16 中兴通讯股份有限公司 Network configuration method, proxy component, controller, electronic device and storage medium

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103563304A (en) * 2012-12-18 2014-02-05 华为技术有限公司 Switch configuration method and cluster management device based on virtual networking
US20160380874A1 (en) * 2014-03-27 2016-12-29 Nicira, Inc. Packet tracing in a software-defined networking environment
CN107332686A (en) * 2017-05-23 2017-11-07 烽火通信科技股份有限公司 A kind of method and system that qos feature is realized in SPTN equipment

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103563304A (en) * 2012-12-18 2014-02-05 华为技术有限公司 Switch configuration method and cluster management device based on virtual networking
US20160380874A1 (en) * 2014-03-27 2016-12-29 Nicira, Inc. Packet tracing in a software-defined networking environment
CN107332686A (en) * 2017-05-23 2017-11-07 烽火通信科技股份有限公司 A kind of method and system that qos feature is realized in SPTN equipment

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
MCKEOWNN: "OpenFlow:enabling innovation in campus networks", 《ACM SIGCOMN COMPUTER COMMUNICATION REVIEW》 *
鲍方艳: "OpenFlow交换机的远程管理系统设计", 《中国优秀硕士论文数据库》 *

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US11212317B2 (en) * 2019-11-11 2021-12-28 International Business Machines Corporation Extending managed switching network to a virtualization layer in a computer
CN113708966A (en) * 2021-08-24 2021-11-26 清华大学 Networked online configuration method, system and equipment for switch
CN113708966B (en) * 2021-08-24 2022-05-31 清华大学 Networked online configuration method, system and equipment for switch
WO2023035777A1 (en) * 2021-09-13 2023-03-16 中兴通讯股份有限公司 Network configuration method, proxy component, controller, electronic device and storage medium

Similar Documents

Publication Publication Date Title
CN108600029B (en) Configuration file updating method and device, terminal equipment and storage medium
US10972362B2 (en) Network service configuration method and network management device
CN106445528B (en) Method and device for rapidly configuring SETUP option of BIOS
CN110912725A (en) Configuration method and configuration device of OpenFlow virtual switch
CN109450708A (en) A kind of Nginx Dynamic Configuration and system
US20160284013A1 (en) Order processing system and order processing method
CN114025000B (en) Method, device, equipment and storage medium for establishing network access relationship
CN111770174A (en) Cloud platform deployment method, device, equipment and readable storage medium
CN107888426B (en) Configuration method and device of network terminal equipment, batch processing equipment and storage medium
CN107547277B (en) Method for realizing virtualization control board and network communication equipment
CN111416732B (en) Method and device for automatically configuring service for capacity expansion of network equipment in SDN
CN113641388A (en) Cloud mobile phone updating method, related device and computer program product
CN109062733A (en) A kind of method, system, equipment and storage medium restoring BMC initial setting up
CN106933932B (en) Data processing method and device and application server
CN110851166A (en) User-unaware application program updating method and device and computer equipment
CN113282374B (en) Server control method, device and system
US20230350712A1 (en) Bmc parameter configuration and effect-taking method and apparatus, device, and medium
CN111090853B (en) Account management method, system, electronic equipment and storage medium
CN109361554A (en) The method and apparatus of the customized management page and default configuration
CN115268951A (en) Installation method, device, equipment and storage medium of operating system
WO2016101424A1 (en) Method and apparatus for realizing terminal service information processing
CN112511321B (en) Method and device for configuring 5G core network
WO2017096889A1 (en) Method and device for upgrading and downgrading system
CN105282204B (en) Tr069 protocol method processing method, device and gateway
CN110971716B (en) Address configuration method, device, system and computer readable storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20200324