Network configuration method of switch and computing device
Through the switch network configuration method, the network configuration of the switch is simplified by using the visual interface, solving the complexity of multi-level switch configuration in the data center computer room, improving configuration efficiency and reducing operation and maintenance costs.
Patent Information
- Application Number
- CN202411086329.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-07
- Publication Date
- 2024-12-06
AI Technical Summary
In the prior art, there are a lot of duplicate work and high professional technical requirements for network configurations of multiple hierarchical switches in data center computer rooms, resulting in high configuration difficulty and operation and maintenance costs.
Provide a switch network configuration method, providing logical switches to users through a visual interface, receiving network configuration information input by users, generating configuration instructions, simplifying network configurations of uplink port groups and downlink port groups, and reducing complex configurations for each port need.
It realizes rapid configuration of the switch network, reduces configuration difficulty and operation and maintenance costs, and improves network configuration efficiency and user experience.
Smart Images

Figure CN119094333A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of switch design, and in particular to a network configuration method and computing device for a switch. Background Art
[0002] Nowadays, with the increase in business volume, data center computer rooms usually include a large number of cabinet modules. In order to achieve network isolation of each cabinet module and prevent the network failure of a cabinet module from affecting other cabinet modules, multiple levels of switches are usually set up in the data center computer room.
[0003] The network connectivity of multiple levels of switches requires staff to configure the network of each switch in advance. The network configuration of the above switches not only involves a lot of repetitive work, but also has high professional and technical requirements for the staff, which increases the configuration difficulty and operation and maintenance costs of the switches. Summary of the invention
[0004] In order to improve the configuration difficulty and operation and maintenance cost of a switch, an embodiment of the present invention provides a network configuration method and a computing device for a switch.
[0005] In a first aspect, the present application provides a network configuration method for a switch, comprising: outputting a configuration interface of the switch, the configuration interface being used to configure the network configuration of an upstream port group and a downstream port group of the switch; receiving network configuration information input for the configuration interface; determining configuration instructions for the switch based on the network configuration information; the configuration instructions comprising configuration instructions for the upstream port group and configuration instructions for the downstream port group, the configuration instructions for the upstream port group being used to configure a network of at least one upstream port in the upstream port group, and the configuration instructions for the downstream port group being used to configure a network of multiple downstream ports in the downstream port group.
[0006] In this solution, the staff can batch configure at least one uplink port in the uplink port group and multiple downlink ports in the downlink port group through the configuration interface to obtain the network configuration information of the switch. This method does not require the staff to write corresponding configuration instructions for each port, and can determine the configuration instructions of the switch according to the network configuration information, and batch configure the network of at least one uplink port and multiple downlink ports in the switch. In this way, the network configuration difficulty and operation and maintenance cost of the switch are reduced.
[0007] In some embodiments, the switch is one of a core switch, an aggregation switch, and an access switch.
[0008] In this solution, the method establishes corresponding logical switches through a configuration interface based on the device information of core switches, aggregation switches, and access switches, so that users can directly configure the network of at least one uplink port and multiple downlink ports of various types of switches through the configuration interface, reducing the difficulty of network configuration of switches.
[0009] In some embodiments, the network configuration information includes configuration information of the uplink port group, configuration information of the downlink port group, and configuration information of the network to which the uplink port group and the downlink port group are to be connected, and determining the configuration instructions of the switch based on the network configuration information includes: generating a first configuration file of the switch based on the configuration information of the uplink port group, the configuration information of the downlink port group, and configuration information of the network to which the uplink port group and the downlink port group are to be connected; and parsing the first configuration file to determine the configuration instructions of the switch.
[0010] In this solution, the user is provided with the upstream port group, downstream port group, and the network to which the upstream port group and the downstream port group are to be connected of the logical switch through a configuration interface, so that the user can use the configuration interface of the visual interface to configure the network of at least one upstream port and multiple downstream ports of the switch without repeatedly entering complex configuration commands, thereby reducing the learning cost and improving the network configuration efficiency of the switch.
[0011] In some embodiments, the configuration information of the upstream port group includes a protocol type and a port type of at least one upstream port, and the configuration information of the downstream port group includes a protocol type and a port type of a plurality of downstream ports.
[0012] In some embodiments, the configuration information of the network includes a network identification, a network type, a virtual local area network identifier, and a default virtual local area network identifier.
[0013] In this solution, the uplink port group, the downlink port group and the network to which the uplink port group and the downlink port group are connected of the switch can be configured through the configuration information of the uplink port group input by the user and the configuration information of the network, thereby realizing rapid configuration of the switch network.
[0014] In some embodiments, the method also includes: providing a first configuration file of the logical switch to the user through the configuration interface; obtaining network configuration information of the logical switch input by the user, and generating a second configuration file of the switch based on the network configuration information of the logical switch; and parsing the second configuration file to determine the configuration instructions of the switch.
[0015] In this solution, the existing configuration file can be updated based on the network configuration information of the logical switch input by the user to obtain an updated second configuration file, and the network of the switch is configured according to the second configuration file, thereby improving the network configuration efficiency of the switch.
[0016] In some embodiments, determining the configuration instructions of the switch based on the network configuration information also includes: receiving login information input by a user through the configuration interface, and logging into the switch according to the login information; the login information includes the IP address, port identifier, account identifier and password of the switch.
[0017] In this solution, the switch can be quickly logged in through the configuration interface, thereby improving the network efficiency of the switch.
[0018] In some embodiments, based on the network configuration information, a configuration instruction of the switch is determined, and then the method further includes: sending the configuration instruction to the switch so as to configure the network of the switch.
[0019] In this solution, a first configuration file of the switch can be generated according to the network configuration information of the switch. This allows the staff to determine the configuration instructions of the switch according to the first configuration file and configure the network of the switch. This eliminates the need to repeatedly input complex configuration commands, reduces learning costs, and improves the network configuration efficiency of the switch.
[0020] In some embodiments, the method further includes: sending the configuration instruction to a plurality of the switches so as to configure a network of the plurality of switches.
[0021] In this solution, the network of multiple switches with the same configuration can be configured through the configuration instructions of the switch determined by the first configuration file, thereby improving the network configuration efficiency of the switch.
[0022] On the other hand, an embodiment of the present invention provides a computing device, which includes a processor and a memory; wherein the memory is used to store program instructions; the processor is used to execute the program instructions so that the processor executes the network configuration method of the above-mentioned switch.
[0023] It should be understood that the beneficial effects achieved by the technical solution of the second aspect of the embodiment of the present application and the corresponding possible implementation methods can be referred to the above-mentioned technical effects of the first aspect, and will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS
[0024] Figure 1 This is a network diagram of the data center computer room;
[0025] Figure 2 This is a schematic diagram of the network configuration scenario of the switch;
[0026] Figure 3 is a schematic diagram of a switch management module of a software program of a computing device;
[0027] Figure 4 is a schematic diagram of a logical switch creation module of a software program of a computing device;
[0028] Figure 5 is a schematic diagram of a network configuration module of a software program of a computing device;
[0029] Figure 6 is a schematic diagram of a network configuration module of a software program of a computing device;
[0030] Figure 7 It is a flow chart of a network configuration method of a switch disclosed in the present application;
[0031] Figure 8 This is a schematic diagram of establishing a logical switch;
[0032] Fig. 9 It is a schematic diagram of the network configuration of the switch;
[0033] Fig.10 A schematic diagram of the structure of a computing device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0034] The terms "first", "second", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and need not be used to describe a specific order or sequential order. It should be understood that the terms used in this way can be interchangeable under appropriate circumstances, which is only to describe the distinction mode adopted by the objects of the same attributes when describing in the embodiments of the present application. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, so that the process, method, system, product or equipment comprising a series of units need not be limited to those units, but may include other units that are not clearly listed or inherent to these processes, methods, products or equipment.
[0035] In order to facilitate understanding of the technical solution of the present application, the relevant terms involved in this article are explained below.
[0036] Network: Networks are divided into Ethernet networks and storage networks. Therefore, switches are also divided into Ethernet and storage switches. Ethernet networks are usually more commonly used. The configuration of Ethernet networks is mainly through the configuration of VLAN (Virtual Local Area Network) of Ethernet switches, so as to achieve Ethernet network planning and network isolation.
[0037] VLAN (Virtual Local Area Network): is a technology for creating a virtual network on a switch. It allows network administrators to divide a physical network into multiple virtual networks, each of which corresponds to an independent broadcast domain. VLAN technology divides the network based on ports or protocols.
[0038] According to the network protocol type, VLAN can be divided into three types of switch ports: ETH (Ethernet, Ethernet port), FcoE (Fibre Channel over Ethernet, Fibre Channel Ethernet port), and FC (Fibre Channel, storage network port).
[0039] ETH is usually connected to EthNetwork (Ethernet Network), which usually requires an Ethernet switch.
[0040] The actual physical property of FCoE is an Ethernet port. By mapping Fibre Channel to Ethernet, Fibre Channel information can be inserted into Ethernet packets, allowing Fibre Channel requests and data from server SAN storage devices to be transmitted over Ethernet connections.
[0041] FC is usually connected to SanNetwork (Storage Area Network), which usually requires a storage switch.
[0042] Storage arrays and server hosts, establish a regional network dedicated to data storage.
[0043] According to the switch port attributes and usage, VLAN can also be divided into three types of switch ports: Access port, Trunk port, and Hybrid port.
[0044] Access ports only allow one VLAN to pass through and are used to connect to the ports of terminal devices, such as servers or computers. Trunk ports can allow multiple VLANs to pass through and are used to connect to switches or ports related to switches. Hybrid ports can allow multiple VLANs to pass through and are used to connect to ports of switches or computing devices.
[0045] Trunk ports and Hybrid ports can receive and send packets from multiple VLANs. When a Hybrid port allows packets from multiple VLANs to be sent, no label is added to the Hybrid port; when a Trunk port only allows packets from the default VLAN to be sent, no label is added to the Trunk port.
[0046] Tag VLAN means that when a port is configured in tag mode, a VLAN tag will be added to the data frame transmitted through the port. This tag contains the VLAN ID (Virtual Local Area Network Identifier). Tag mode ports are usually used to connect to other switches or routers. These devices need to identify which VLAN the data frame belongs to.
[0047] Untagged VLAN means that when a port is configured in untagged mode, no VLAN tag is added to the data frame transmitted through the port. Ports in untagged mode are usually used to connect to terminal devices such as computers, printers, etc. These devices do not need to identify VLAN tags because they belong to only one VLAN. On an untagged port, the data frame belongs to the VLAN configured for the port by default. This VLAN is called the "default VLAN" or "native VLAN".
[0048] VLAN ID refers to the identifier used to identify and distinguish a VLAN on a network device. A physical network can be divided into multiple virtual networks through VLAN ID. Each virtual network has its own independent broadcast domain.
[0049] PVID (Port-base VLAN ID, the default or default VLAN ID of the switch) is the VLAN ID added by the switch when it receives an external untagged message. Any switch port can only have one PVID.
[0050] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art to which this application belongs. The terms used herein are only for the purpose of describing the embodiments of this application and are not intended to limit this application.
[0051] Nowadays, with the increase in business volume, data center computer rooms usually include a large number of cabinet modules. In order to achieve network isolation of each cabinet module and prevent the network failure of a cabinet module from affecting other cabinet modules, multiple levels of switches are usually set up in the data center computer room.
[0052] For example, Figure 1 The figure shows the network diagram of the data center computer room. Figure 1As shown, the data center computer room includes a core switch 200, an aggregation switch 310, an aggregation switch 320, an access switch 410, an access switch 420, an access switch 430, and a server 510, an access switch 520, an access switch 530, and a server 540. The core switch 200 is connected to the aggregation switch 310 and the aggregation switch 320 for communication; the aggregation switch 310 is connected to the access switch 410, the access switch 420, and the access switch 430 for communication; the access switch 420 is connected to the server 510, the access switch 520, the access switch 530, and the server 540 for communication.
[0053] When a user needs to access a server in a data center computer room, such as server 510, the access request needs to be redirected to the core switch 200 through the firewall, and then the access request is aggregated from the core switch 200 to the aggregation switch 310, and then input to the access switch 420 by the aggregation switch 310, and access port 511 of the server 510 is accessed through port 424 of the access switch 420, thereby realizing the access request of the above-mentioned user.
[0054] The network connectivity of switches at multiple levels requires staff to configure the network of each switch in advance. The network configuration of the above switches involves a lot of repetitive work. For example, there are multiple ports in the switch. When configuring the network of the switch, staff need to write multiple corresponding configuration instructions for each port and configure the network of the switch according to the multiple configuration instructions. At the same time, when it is necessary to configure the network of multiple switches with the same configuration, staff are also required to write multiple corresponding configuration instructions for the multiple ports of each switch. The above network configuration work requires high professional skills from the staff and also increases the configuration difficulty and operation and maintenance cost of the switch.
[0055] In order to reduce the difficulty of network configuration and operation and maintenance costs of switches. The present application provides a network configuration method for switches. The method provides a user with a logical switch corresponding to the switch through a configuration interface of a visual interface (hereinafter referred to as the configuration interface), receives network configuration information of the logical switch input by the user, determines the configuration information of the upstream port group, the downstream port group, and the network to which the upstream port group and the downstream port group are to be connected, generates a configuration file of the switch based on the above configuration information, parses the configuration file into configuration instructions of the upstream port group and the downstream port group that the switch can recognize, and configures the network of at least one upstream port of the switch according to the configuration instructions of the upstream port group, and configures the network of multiple downstream ports of the switch according to the configuration instructions of the downstream port group. The method simplifies the network configuration process and improves the network configuration efficiency of the switch.
[0056] In order to facilitate understanding of the technical solution of the present application, an application scenario of an embodiment of the present application is first introduced below.
[0057] For example, Figure 2 What is shown is a schematic diagram of a network configuration scenario of a switch provided by an embodiment of the present application. Figure 2 As shown, in this network configuration scenario, a computing device 100 and Figure 1 The core switch 200, the aggregation switch 310, and the access switch 420 shown in FIG. 4 , wherein the aggregation switch 320, the access switch 410, the access switch 430, the access switch 520, and the access switch 530 are in FIG. Figure 2 Shown in.
[0058] The computing device 100 is used to provide a configuration interface 10 to the user so that the user can connect to any switch among the core switch 200, the aggregation switch 310, the aggregation switch 320, the access switch 410, the access switch 420, the access switch 430, the access switch 520 and the access switch 530 through the configuration interface 100.
[0059] By way of example and not limitation, the computing device may communicate and connect with the switch using SSH (Secure Shell), or may communicate and connect with the switch using NETCONF (Network Configuration Protocol), and this application does not limit this.
[0060] The user can establish a corresponding logical switch on the configuration interface 10 provided by the computing device 100 according to the device information of any of the above switches, for example, the core switch 200, the aggregation switch 310, the aggregation switch 320, the access switch 410, the access switch 420, the access switch 430, the access switch 520 and one of the access switches 530.
[0061] Each switch includes a plurality of physical ports, and a logical switch established according to the device information of the switch also includes a plurality of logical ports, and the plurality of physical ports correspond to the plurality of logical ports one by one.
[0062] Next, the device information of the switch is introduced through the following content.
[0063] The device information of the switch includes the manufacturer identification, model identification, function identification of the switch, and physical information of multiple ports in the switch.
[0064] The vendor ID is used to indicate the product manufacturer or brand of the switch.
[0065] The model ID is used to indicate the specific model of the switch.
[0066] The function identifier is used to indicate the specific function of a switch, for example, whether a switch is a core switch, an aggregation switch, or an access switch.
[0067] By way of example and not limitation, the physical information of the multiple ports includes the port rate, working mode, connector type, and port shape and size of a port, which is not limited in the present application.
[0068] It is worth noting that the content of the aforementioned switch device information is only for the purpose of facilitating the understanding of this application and is not intended to limit this application. In actual implementation, the switch device information may also include the switch's physical address, performance indicators, and firmware version information, which are not limited in this application.
[0069] The computing device 100 is also used to provide the established logical switch to the user through the configuration interface 10, so that the user can configure multiple logical ports in a logical switch and the networks to which the multiple logical ports are to be connected.
[0070] As mentioned above, users can use VLAN technology to divide a physical network into multiple virtual networks, where each virtual network corresponds to an independent broadcast domain to achieve network isolation of each cabinet module. Therefore, users can configure multiple logical ports of a switch and the networks to which the multiple logical ports are connected according to configuration requirements on the configuration interface 10 provided by the computing device 100.
[0071] The computing device 100 is also used to obtain multiple logical ports of any switch input by the user through the configuration interface 10, and configuration information of the networks to which the multiple logical ports are to be connected, and generate a configuration file for the logical switch based on the above configuration information.
[0072] Next, the configuration information of multiple logical ports and networks to which the multiple logical ports are to be connected is introduced through the following content.
[0073] The configuration information of the networks to which the multiple logical ports are to be connected includes configuration parameters of at least one network, wherein the configuration parameters of a certain network include the network identifier of the network, the network type, such as Ethernet or storage network, VLAN ID and PVID.
[0074] The configuration information of multiple logical ports includes configuration parameters of each logical port, wherein the configuration parameters of a logical port include the protocol type of the logical port, such as ETH or FcoE or FC, the port type such as Access or Trunk or Hybrid, and the connection relationship between the port and the network to which the port is to be connected.
[0075] The computing device 100 is also used to parse a configuration file of a logical switch, determine the configuration instructions of the switch corresponding to the logical switch, and send the configuration instructions to the switch to configure the network of the switch.
[0076] The computing device 100 includes a software program 110. When the software program 110 is executed, the configuration interface 10 can be provided to the user and the network configuration method of the switch proposed in the present application can be implemented. The configuration interface 10 includes a switch connection page 10a, a logical switch creation page 10b, a network configuration page 10c, and a management page 10d.
[0077] The software program 110 of the computing device 100 includes a switch management module 111 , a logical switch creation module 112 , a network configuration module 113 , and a configuration management module 114 .
[0078] The switch management module 111 is used to provide a switch connection page 10a to the user, receive login information of a switch input by the user through the switch connection page 10a, and log in to the switch according to the login information.
[0079] The logical switch creation module 112 is used to provide a logical switch creation page 10b to the user, receive device information of a switch input by the user through the logical switch creation page 10b, and establish a logical switch corresponding to the switch according to the device information of the switch.
[0080] The network configuration module 113 is used to provide the user with a network configuration page 10c, receive configuration information of a certain network input by the user through the network configuration page 10c, and establish a corresponding network according to the configuration information of the certain network.
[0081] The network configuration module 113 is used to receive the configuration information of the uplink port group, the downlink port group and the network to which the uplink port group and the downlink port group are to be connected sent by the network configuration page 10c; and generate a configuration file of the logical switch based on the above configuration information.
[0082] The network configuration module 113 is also used to parse the configuration file of the logical switch, generate the configuration instruction of the switch corresponding to the logical switch, and send the configuration instruction to the switch corresponding to the logical switch. The configuration instruction includes the configuration instruction of the logical switch uplink port group and the configuration instruction of the downlink port group, the configuration instruction of the uplink port group is used to configure the network of at least one uplink port of the switch, and the configuration instruction of the downlink port group is used to configure the network of multiple downlink ports of the switch.
[0083] The configuration management module 114 is used to manage the logical switches established by the user and according to multiple configuration files.
[0084] For example, Figure 3 Shown is a schematic diagram of a switch management module of a software program of a computing device, such as Figure 3 As shown, when the software program 110 of the computing device 100 is executed, the switch management module 111 may provide a switch connection page 10 a to the user.
[0085] The switch connection page 10a includes a switch IP field, an access account field, an access password field, a network port field, and a connection field.
[0086] The switch connection page 10a can receive the login information of a switch input by the user through the above fields, and send the above login information to the switch management module 111 through the user through the connection field. The above login information includes the IP address, port identifier, account identifier and password of the switch.
[0087] Illustratively, taking switch 420 (first switch) as an example, the switch management module 111 is used to receive the login information of the switch 420 sent by the switch connection page 10a, and log in to the switch 420 according to the login information of the switch 420, so as to perform remote communication and network configuration on the switch 420.
[0088] For example, Figure 4 1 is a schematic diagram of a logical switch creation module of a software program of a computing device, such as Figure 4 As shown, when the software program 110 of the computing device 100 is executed, the logical switch creation module 112 may provide a logical switch creation page 10 b to the user.
[0089] The logical switch creation page 10b includes a manufacturer identification field, a model identification field, a function identification field, a switch logistics information field, an add field, a copy field, a delete field, and a create logical switch field.
[0090] The logical switch creation page 10b can receive the device information of a switch input by the user through the above fields, and send the device information of the switch to the logical switch creation module 112 through the user creating the logical switch field. The above device information includes the manufacturer identification, model identification, function identification of the switch, and the physical information of multiple ports in the switch 10.
[0091] Based on the physical information of multiple ports, users can add logical ports to the corresponding logical switch of the switch by adding fields. When multiple ports in the switch have the same physical information, users can also copy the logical ports with the same physical information by duplicating the fields, or delete a logical port that has been added by deleting the fields.
[0092] The logical switch creation module 112 is used to receive the device information of a switch sent by the logical switch creation page 10b, and establish a corresponding logical switch for the switch based on the device information of the switch. As mentioned above, each switch includes multiple physical ports, so the logical switch established based on the device information of the switch also includes multiple logical ports. Among them, the multiple logical ports correspond one to one with the multiple physical ports.
[0093] In some possible implementations, the logical switch creation module 112 is further configured to send the created logical switch to the configuration management module 114 so that the configuration management module 114 manages the logical switch.
[0094] For example, Figure 5 Shown is a schematic diagram of a network configuration module of a software program of a computing device, such as Figure 5 As shown, when the software program 110 of the computing device 100 is executed, the network configuration module 113 may provide a network configuration page 10c to the user.
[0095] The network configuration page 10c includes a create network field, a create uplink port group field, a create downlink port group field, a load configuration file field, and a create configuration file field.
[0096] When the user creates a network field, he can enter the network creation page 10c1 to configure the network of a switch. The network configuration subpage 10c1 is used to receive configuration information of at least one network input by the user, including a network identification field, a network description field, a network type field, a VLAN ID field, and a PVID field.
[0097] Users can use the Network Identification field to set the network identification of a network. The network identification is used to identify the identity information of the network. Users can use the Network Description field to describe the structure, composition, function, performance and security of the network. Users can use the Network Type field to set the network to an Ethernet network or a storage network. Users can use the VLANID field to set the VLAN ID of the network. Users can use the PVID field to set the PVID of the network.
[0098] In some possible implementations, after the user completes the configuration of a certain network, the network configuration of the network can be saved by creating a network field again.
[0099] When the user creates an uplink port group field or creates a downlink port group field, the user can enter the port configuration page 10c2 to configure the uplink port group and the downlink port group of a switch.
[0100] Next, the upstream port group and the downstream port group are explained through the following content.
[0101] The uplink port group includes at least one uplink port, and the uplink port group is used to connect at least one upper-layer switch or at least one uplink network.
[0102] The downstream port group includes at least one downstream port, and the downstream port group is used to connect multiple lower-layer switches, multiple servers or at least one downstream network.
[0103] The network configuration subpage 10c2 is used to receive configuration information of at least one port input by the user, including an optional port field, a selected port field, a port identification field, a selected port field, a port description field, a protocol type field, a port type field, an optional network field, a selected network field, and an advanced options field.
[0104] Next, the optional port field, selected port field, port identification field, selected port field, port description field, protocol type field, port type field, optional network field, selected network field, and advanced option field are explained through the following content.
[0105] The optional port field is used to provide the user with the logical switch established by the logical switch creation module 112 so that the user can select at least one logical port of the logical switch. In some possible implementations, the user can also determine the logical switch to be configured through the optional port field.
[0106] The Selected Port field is used to display the logical port of the above logical switch selected by the user. In some possible implementations, the user can also select or cancel at least one logical port by using the arrow keys in the Selectable Port field.
[0107] The port identification field is used to receive the port identification of at least one logical port input by the user. The port identification is used to represent the identity information of a certain uplink port group or a downlink port group.
[0108] The port description field is used to receive a port description of at least one logical port input by a user. The port description is used to indicate the specification, configuration and status information of a certain upstream port group or downstream port group.
[0109] The protocol type field is used to receive the protocol type of at least one logical port input by the user. The above protocol type is used to indicate the protocol type of a certain upstream port group or downstream port group, such as ETH or FcoE or FC.
[0110] The port type field is used to receive the port type of at least one logical port input by the user. The above protocol type is used to indicate the port type of a certain upstream port group or downstream port group, such as Access, Trunk or Hybrid.
[0111] The optional network field is used to provide the user with the network to which the upstream port group or the downstream port group is to be connected.
[0112] The selected network field is used to display the network selected by the user. In some possible implementations, the user can also select or cancel the network by using the arrow keys in the optional port field.
[0113] The advanced option field is used to provide the user with function options of a certain upstream port group or downstream port group, for example, the port anti-loopback function. The user can select whether to enable the port anti-loopback function of the upstream port group or downstream port group through the advanced option field.
[0114] Port Anti-Loopback refers to a network security measure that prevents network devices or services from receiving traffic from their own IP addresses. This measure can prevent malware or attackers from using loopback addresses to launch network attacks, such as denial of service attacks (DoS) or distributed denial of service attacks (DDoS).
[0115] In some possible implementations, after the user completes the settings of an upstream port group, the port configuration of the upstream port group can be saved through the upstream port group field, or, after the user completes the settings of a downstream port group, the port configuration of the downstream port group can be saved through the downstream port group field.
[0116] When the user creates a configuration file field, the network configuration page 10 c may send the configuration information of a certain network and multiple logical ports input by the user to the network configuration module 113 .
[0117] When the user needs to perform network configuration on the same type of logical switch, the user can also load an existing configuration file (first configuration file) through the load configuration file field, and modify the configuration information of the uplink port group and the downlink port group of the logical switch to be configured, and the network configuration of the network to which the uplink port group and the downlink port group are to be connected, based on the first configuration file. The network configuration module 113 generates a configuration file (second configuration file) for the switch according to the configuration information of the network and the configuration information of the multiple logical ports input by the user and the first configuration file.
[0118] The network configuration module 113 is used to receive the configuration information of a certain network and multiple logical ports sent by the network configuration page 10c, and generate a configuration file of the switch based on the above configuration information. In some possible implementations, the network configuration module 113 is also used to send the generated configuration file to the configuration management module 114 so that the configuration management module 114 manages the configuration file.
[0119] Schematically, taking switch 420 (the first switch) as an example, after the network configuration module 113 generates the configuration file of switch 420, it is also used to parse the configuration file of switch 420, determine the configuration instructions of switch 420, and transmit the configuration instructions to the switch management module 111 so that the switch management module 111 configures the network of switch 420.
[0120] For example, Figure 6 Shown is a schematic diagram of a network configuration module of a software program of a computing device, such as Figure 6 As shown, when the software program 110 of the computing device 100 is executed, the configuration management module 114 may provide a management page 10d to the user.
[0121] The management page 10d includes a logical switch management field and a configuration management field.
[0122] The logical switch management field is used to display multiple logical switches input by the configuration management module 114, so that the user can manage the multiple logical switches, for example, edit or delete the multiple logical switches.
[0123] The logical switch management field is used to display the configuration files of multiple logical switches input by the configuration management module 114, so that the user can manage the above multiple configuration files, such as modifying, copying and deleting the multiple configuration files.
[0124] The configuration management module 114 is used to receive the multiple logical switches sent by the logical switch creation module 112, and send the multiple logical switches to the management page 10d, so that the user can manage the logical switches.
[0125] The configuration management module 114 is further configured to receive multiple configuration files sent by the network configuration module 113 and send the multiple configuration files to the management page 10d so that the user can manage the configuration files.
[0126] Next, based on the above description, a network configuration method of a switch provided by an embodiment of the present application is introduced. It can be understood that the method is proposed based on the above description, and part or all of the contents of the method can refer to the above description.
[0127] See also Figure 7 , Figure 7 FIG. 1 is a flow chart of a network configuration method for a switch disclosed in the present application. Figure 7 As shown, the network configuration of the switch can be implemented through S710 to S730. It can be understood that when accessing the target service, the method is executed by the computing device 100.
[0128] S710: Output the switch configuration interface.
[0129] As mentioned above, the computing device 100 can provide a configuration interface 10 (configuration interface) to the user. Before performing the network configuration of the interactive machine, the computing device 100 receives the device information of a switch input by the user through the configuration interface 10 and establishes a corresponding logical switch for the switch based on the above device information.
[0130] After the logical switch is established, the computing device 100 provides the established logical switch to the user through the configuration interface 10 so that the user can configure the upstream port group and the downstream port group of the logical switch, as well as the networks to which the upstream port group and the downstream port group are connected.
[0131] The device information of the switch includes the manufacturer identification, model identification, function identification of the switch, and the physical information of multiple ports in the switch. As mentioned above, the physical information of multiple ports includes the port rate, working mode, connector type of a certain port, and may also include the port shape and size of the port.
[0132] Indicative, Figure 8 The diagram shown is a schematic diagram of establishing a logical switch. Figure 8 As shown, the computing device 100 can utilize the switch management module 111 to receive the device information of the access switch 420 input by the user through the configuration interface 10 , and establish a corresponding logical switch 200 ′ according to the device information of the access switch 420 .
[0133] Among them, multiple physical ports of the access switch 200 correspond one-to-one to the logical ports of the logical switch 200', for example, physical port 421 corresponds to logical port 421', physical port 422 corresponds to logical port 422', physical port 423 corresponds to logical port 423', and physical port 424 corresponds to logical port 424'.
[0134] It is understandable that the computing device 100 can establish a logical switch 200 ′ corresponding to the core switch 200 and a logical switch 310 ′ corresponding to the aggregation switch 310 in the same manner.
[0135] In some possible implementations, if the computing device 100 includes a logical switch of a certain type required by the user, such as a logical switch established based on a core switch, an aggregation switch, or an access switch, the user can also select the logical switch corresponding to the requirement in the configuration interface 10 according to his or her own needs, and configure multiple ports of the logical switch and the network to which the port is to be connected.
[0136] The logical switch corresponding to the type of switch is established through the configuration interface, so that the user can directly configure the network of at least one uplink port and multiple downlink ports of various types of switches through the configuration interface, reducing the difficulty of network configuration of the switch.
[0137] S720: Receive network configuration information inputted into the configuration interface.
[0138] The computing device can receive network configuration information of the logical switch input by the user through the configuration interface 10, wherein the network configuration information of the logical switch includes configuration information of the upstream port group, configuration information of the downstream port group, and configuration information of the network to which the upstream port group and the downstream port group are to be connected.
[0139] The computing device 100 can use the network configuration module 113 to obtain the configuration information of at least one network input by the user through the network configuration page 10c of the configuration interface 10, and establish an uplink network and a downlink network according to the configuration information of the network. The configuration information of each network includes the network identifier, network type, virtual local area network identifier and default virtual local area network identifier of the network.
[0140] The computing device 100 can use the network configuration module 113 to obtain the configuration information of the uplink port group of a certain switch input by the user through the network configuration page 10c of the configuration interface 10, and establish the uplink port group of the switch according to the configuration information of the uplink port group; the computing device 100 can also obtain the configuration information of the downlink port of a certain switch, and establish the downlink port group of the switch according to the configuration information of the uplink port group. The configuration information of the uplink port group includes the protocol type and port type of at least one uplink port, and the configuration information of the downlink port group includes the protocol type and port type of multiple downlink ports.
[0141] After the user establishes at least one network, as well as an uplink port group and a downlink port group of a switch through the network configuration page 10c of the configuration interface 10, the user can also connect the uplink port group, the downlink port group, and at least one network of a switch through the above network configuration page 10c.
[0142] The computing device 100 may determine the network configuration information of the switch based on the connection relationship between the upstream port group, the downstream port group, and at least one network.
[0143] It is worth noting that when the networks to which multiple downstream ports of the downstream port group are connected are the same network, in this application, the user can simultaneously select multiple downstream ports in the configuration interface and connect the multiple downstream ports to the same network.
[0144] The configuration interface provides the user with the uplink port group, the downlink port group, and the network to which the uplink port group and the downlink port group are to be connected of the logical switch, so that the user can configure the network of at least one uplink port and multiple downlink ports of the switch in batches by using the configuration interface 10. Thus, it is avoided that the staff needs to write corresponding configuration instructions for each port of the switch, which reduces the learning cost and improves the network configuration efficiency of the switch.
[0145] Indicative, Fig. 9 The diagram shows a schematic diagram of the network configuration of the switch. Fig. 9 As shown on the left side, the computing device 100 uses the network configuration module 113 to obtain the network 1 created by the user in the configuration interface 10 , as well as the configuration information of the uplink port group and the downlink port group.
[0146] The uplink port group includes: Figure 8 The logical port 421' of the logical switch 420' shown has a downstream port group including Figure 8 Logical ports 422', 423', 424' of the logical switch 420' are shown.
[0147] Specifically, the configuration information of network 1 includes: the network identifier is NetWork 001, the network type is Ethernet, the VLAN ID is 2 to 200, and the PVID is 2.
[0148] The configuration information of network 2 includes: the network ID is NetWork 001, the network type is Ethernet, the VLAN ID is 2 to 1000, and the PVID is 20.
[0149] The configuration information of logical port 421` includes: the port identifier is GigabitEthernet 0 / 0 / 49, the port protocol is ETH, the port type is Trunk, the port is connected to network 1, and the port anti-loopback is enabled in the advanced options.
[0150] The configuration information of logical port 422` includes: the port identifier is GigabitEthernet 0 / 0 / 48, the port protocol is ETH, the port type is Trunk, the port is connected to network 2, and the port anti-loopback is enabled in the advanced options.
[0151] The configuration information of the logical port 423' includes that the port identifier is GigabitEthernet 0 / 0 / 47, and the other configuration information is the same as that of the logical port 422'.
[0152] The configuration information of the logical port 423' includes that the port identifier is GigabitEthernet 0 / 0 / 46, and the other configuration information is the same as that of the logical port 422'.
[0153] The computing device 100 connects the upstream port group, network 1, and the downstream port group, network 2 through the network configuration module 113, and determines the network configuration information of the logical switch 421` based on the port configuration of the logical ports 421`, 422`, 423`, 424` and the network configuration of network 1 and network 2, as well as the connection relationship between the logical port 421` and the networks 1, 422`, 423`, 424` and network 2.
[0154] In some possible implementations, the user may also set multiple uplink port groups such as uplink port group 2 and uplink port group 3, multiple downlink port groups such as downlink port group 2 and downlink port group 3, and multiple networks such as network 2 and network 3 for a certain switch in the configuration page 10. The computing device 100 connects the uplink port group 2, the downlink port group 2 and the network 2, and the uplink port group 3, the downlink port group 3 and the network 3 through the network configuration module 113 to determine the network configuration information of the switch.
[0155] S730: Determine a configuration instruction of the switch based on the network configuration information.
[0156] Before the computing device 100 configures the network of the switch, the computing device 100 receives login information input by the user through the configuration interface 10, and logs in to the switch to be configured according to the login information, wherein the login information includes the IP address, port identifier, account identifier and password of the switch.
[0157] By way of example and not limitation, the computing device may communicate and connect with the switch using SSH (Secure Shell), or may communicate and connect with the switch using NETCONF (Network Configuration Protocol), and this application does not limit this.
[0158] To facilitate the network configuration of the switch, the computing device 100 may also generate a configuration file (a first configuration file) of the switch based on the network configuration information of the switch.
[0159] Illustratively, the computing device 100 may generate a first configuration file of the logical switch 420' through the network configuration information of the logical switch 420' obtained in step S740.
[0160] When performing network configuration of switch 420 , the computing device may parse the first configuration file of logical switch 420 , determine configuration instructions that can be recognized by switch 420 , and send the configuration instructions to switch 420 to configure the network of switch 420 .
[0161] Indicative, please continue to see Fig. 9 ,like Fig. 9 As shown on the right side, first, the computing device 100 utilizes the network configuration module 113 to parse the configuration file of the logical switch 420' to obtain the uplink port and downlink port configuration instructions.
[0162] Then, the computing device 100 uses the network configuration module 113 to send the configuration instructions of the uplink port and the downlink configuration instructions to the switch 421 to configure the uplink port and the downlink port of the switch 421 .
[0163] The uplink port group includes port 421, and the port configuration of the port includes: the port identifier is GigabitEthernet 0 / 0 / 49, the port protocol is ETH, the port type is Trunk, and the port supports port anti-loopback.
[0164] The network 1 to which port 421 is connected is set to have a network identifier of NetWork 001, a network type of Ethernet, a VLAN ID of 2 to 200, and a PVID of 2.
[0165] The downstream port group includes port 422, port 423, and port 424. The port configuration of port 422 includes: port identifier GigabitEthernet 0 / 0 / 48, port protocol ETH, port type Trunk, and port anti-loop support. The port identifier of port 423 is GigabitEthernet 0 / 0 / 47, and the port identifier of port 424 is GigabitEthernet 0 / 0 / 46. Port 423 and port 424 have the same port configuration.
[0166] The computing device 100 sets the network 2 to which the ports 422 , 423 and 424 are to be connected to, with the network identifier being NetWork 002 , the network type being Ethernet, the VLAN ID being 2 to 1000 and the PVID being 20 .
[0167] In some possible implementations, when a user needs to perform network configuration on logical switches of the same type, the computing device 100 may also parse the first configuration file of the logical switches of the same type, determine the configuration instructions of the multiple switches to be configured, and send the configuration instructions to the multiple switches to be configured, so as to configure the networks of the multiple switches. In this way, the networks of multiple switches with the same configuration are configured through the first configuration file, thereby improving the network configuration efficiency of the switches.
[0168] It is understandable that the computing device 100 uses the same method to Figure 1 The network of the core switch 200, aggregation switch 310, aggregation switch 320, access switch 410, access switch 430, access switch 520 and access switch 530 shown is configured.
[0169] When staff follow Figure 1 After the communication connection is established in the networking manner shown, the user can access the server 510 through the communication path among the core switch 200 , the aggregation switch 310 , the access switch 420 and the server 510 .
[0170] In some possible implementations, when a user needs to perform network configuration on a logical switch of the same type, first, the computing device 100 may also provide the user with a configuration file (first configuration file) of a logical switch established based on the same type of switch through the configuration interface 10.
[0171] Then, the computing device 100 obtains the configuration information of the network of the logical switch to be configured and the configuration information of multiple logical ports of the logical switch input by the user through the configuration interface 10, updates the existing first configuration file, obtains the updated second configuration file, and configures the network of the switch based on the second configuration file.
[0172] The present application provides a network configuration method and computing device for a switch. The method provides a user with a visual configuration interface so that the user can batch configure at least one upstream port in an upstream port group and multiple downstream ports in a downstream port group through the configuration interface to obtain network configuration information of the switch. The method does not require staff to write corresponding configuration instructions for each port, and can determine the configuration instructions of the switch according to the network configuration information, and batch configure the network of at least one upstream port and multiple downstream ports in the switch. The method can configure the network of multiple ports of the switch, simplify the network configuration process, improve the network configuration efficiency of the switch, and reduce the network configuration difficulty and operation and maintenance cost of the switch.
[0173] It is understandable that the size of the sequence number of each step in the above embodiment does not mean the order of execution, and the execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiment of the present application. In addition, in some possible implementations, each step in the above embodiment can be selectively executed according to actual conditions, and can be partially executed or fully executed, which is not limited here.
[0174] The above is an introduction to a network configuration method of a switch provided in an embodiment of the present application. Next, a computing device provided in an embodiment of the present application is introduced.
[0175] Fig.10 The structure diagram of the computing device provided by the embodiment of the present application is shown. Fig.10 As shown, an embodiment of the present application provides a computing device 100, including a processor 101 and a memory 102, wherein the memory 102 stores a computer program that can be executed on the processor 101, so that the processor 101 executes the method for processing the memory CE failure of the above-mentioned server.
[0176] In addition to the above methods, devices and electronic devices, the embodiments of the present application may also provide a computer program product, which includes computer program instructions, which, when executed by a processor, cause the processor to execute the steps of the XXX method of various embodiments of the present application described in the "Method" section of this specification. Among them, the computer program product can be written in any combination of one or more programming languages to perform computer program codes for performing the operations of the embodiments of the present application, and the programming languages include object-oriented programming languages, such as Java, C++, etc., and also include conventional procedural programming languages, such as "C" language or similar programming languages. Among them, the computer program code can be in source code form, object code form, executable file or some intermediate form, etc. The computer program code can be executed completely on the user computing device, partially on the user device, as an independent software package, partially on the user computing device, partially on the remote computing device, or completely on the remote computing device or server.
[0177] In addition, the embodiment of the present application may also provide a computer-readable storage medium on which computer program instructions are stored, and the computer program instructions, when executed by the processor, cause the processor to execute the steps in the XXX method according to various embodiments of the present disclosure described in the above "Method" section of this specification. The computer-readable storage medium may adopt any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. The readable storage medium may, for example, include but is not limited to electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices or devices, or any combination of the above. More specific examples of readable storage media (non-exhaustive list) include: an electrical connection with one or more wires, a portable disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. It should be noted that the content contained in the computer-readable medium may be appropriately increased or decreased according to the requirements of legislation and patent practice in the jurisdiction. For example, in some jurisdictions, according to legislation and patent practice, computer-readable media do not include electrical carrier signals and telecommunication signals.
[0178] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0179] It should be understood that the size of the serial numbers of the steps in the above embodiments does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.
[0180] The basic principles of the present application are described above in conjunction with specific embodiments. However, it should be noted that the advantages, strengths, effects, etc. mentioned in the present application are only examples and not limitations, and it cannot be considered that these advantages, strengths, effects, etc. are required by each embodiment of the present disclosure. In addition, the specific details disclosed above are only for the purpose of illustration and ease of understanding, rather than limitation, and the above details do not limit the present disclosure to the necessity of adopting the above specific details to be implemented.
[0181] The block diagrams of the devices, apparatuses, equipment, and systems involved in this disclosure are only illustrative examples and are not intended to require or imply that they must be connected, arranged, and configured in the manner shown in the block diagrams. As will be appreciated by those skilled in the art, these devices, apparatuses, equipment, and systems can be connected, arranged, and configured in any manner. Words such as "including," "comprising," "having," and the like are open words, referring to "including but not limited to," and can be used interchangeably therewith. The words "or" and "and" used herein refer to the words "and / or," and can be used interchangeably therewith, unless the context clearly indicates otherwise. The word "such as" used herein refers to the phrase "such as but not limited to," and can be used interchangeably therewith.
[0182] It should also be noted that in the apparatus, device and method of the present disclosure, each component or each step can be decomposed and / or recombined. Such decomposition and / or recombination should be regarded as equivalent solutions of the present disclosure.
[0183] The above description has been given for the purpose of illustration and description. In addition, this description is not intended to limit the embodiments of the present disclosure to the forms disclosed herein. Although multiple example aspects and embodiments have been discussed above, those skilled in the art will recognize certain variations, modifications, changes, additions and sub-combinations thereof.
[0184] It is to be understood that the various numerical numbers involved in the embodiments of the present application are only for the convenience of description and are not intended to limit the scope of the embodiments of the present application. The above-described specific implementation methods further describe the purpose, technical solutions and beneficial effects of the present invention in detail. It should be understood that the above description is only a specific implementation method of the present invention and is not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.
[0185] The specific implementation methods described above further illustrate the objectives, technical solutions and beneficial effects of the present invention in detail. It should be understood that the above description is only a specific implementation method of the present invention and is not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.
Claims
1. A network configuration method for a switch, characterized in that: include: Output the switch configuration interface; The configuration interface is used to configure the network configuration of the uplink port group and the downlink port group of the switch; Receiving network configuration information inputted for the configuration interface; Based on the network configuration information, the configuration instructions of the switch are determined; the configuration instructions include configuration instructions of the upstream port group and configuration instructions of the downstream port group, the configuration instructions of the upstream port group are used to configure the network of at least one upstream port in the upstream port group, and the configuration instructions of the downstream port group are used to configure the networks of multiple downstream ports in the downstream port group.
2. The method according to claim 1, characterized in that: The switch is one of a core switch, a convergence switch, and an access switch.
3. The method according to claim 1, characterized in that The network configuration information includes configuration information of the uplink port group, configuration information of the downlink port group, and configuration information of the network to which the uplink port group and the downlink port group are to be connected. The determining of the configuration instruction of the switch based on the network configuration information includes: Generate a first configuration file of the switch based on the configuration information of the uplink port group, the configuration information of the downlink port group, and the configuration information of the network to which the uplink port group and the downlink port group are to be connected; The first configuration file is parsed to determine configuration instructions of the switch.
4. The method according to claim 3, characterized in that The configuration information of the upstream port group includes the protocol type and port type of at least one upstream port, and the configuration information of the downstream port group includes the protocol type and port type of multiple downstream ports.
5. The method according to claim 3, characterized in that: The network configuration information includes a network identifier, a network type, a virtual local area network identifier, and a default virtual local area network identifier.
6. The method according to claim 3, characterized in that The method further comprises: Providing network configuration information of the switch to the user through the configuration interface; Acquire network configuration information of the switch input by a user, and generate a second configuration file of the switch based on the network configuration information of the switch; The second configuration file is parsed to determine configuration instructions of the switch.
7. The method according to claim 1, characterized in that The step of determining the configuration instruction of the switch based on the network configuration information further comprises: The configuration interface receives login information input by the user, and logs in to the switch according to the login information; the login information includes the IP address, port identifier, account identifier and password of the switch.
8. The method according to claim 1, characterized in that Based on the network configuration information, determining a configuration instruction of the switch, and then further comprising: The configuration instruction is sent to the switch so as to configure the network of the switch.
9. The method according to claim 8, characterized in that The method further comprises: The configuration instruction is sent to the plurality of switches so as to configure the network of the plurality of switches.
10. A computing device, characterized in that The computing device includes a processor and a memory; Wherein, the memory is used to store program instructions; The processor is configured to execute the program instructions so that the processor performs the method according to any one of claims 1 to 9.
Citation Information
Cited By
Network type identification method and device and electronic equipment
CN120658642A
A method, apparatus and electronic device for network type identification
CN120658642B
