[go: up one dir, main page]

CN111726236B - A method, system, device and storage medium for generating state identification information - Google Patents

A method, system, device and storage medium for generating state identification information Download PDF

Info

Publication number
CN111726236B
CN111726236B CN201910205254.XA CN201910205254A CN111726236B CN 111726236 B CN111726236 B CN 111726236B CN 201910205254 A CN201910205254 A CN 201910205254A CN 111726236 B CN111726236 B CN 111726236B
Authority
CN
China
Prior art keywords
configuration
local
equipment
network
information
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201910205254.XA
Other languages
Chinese (zh)
Other versions
CN111726236A (en
Inventor
梅盛鑫
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Jingdong Technology Holding Co Ltd
Original Assignee
Jingdong Technology Holding Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Jingdong Technology Holding Co Ltd filed Critical Jingdong Technology Holding Co Ltd
Priority to CN201910205254.XA priority Critical patent/CN111726236B/en
Publication of CN111726236A publication Critical patent/CN111726236A/en
Application granted granted Critical
Publication of CN111726236B publication Critical patent/CN111726236B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

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

Landscapes

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

Abstract

本发明公开了一种状态识别信息生成方法、系统、装置及其存储介质,该方法包括:接收具有配置信息的配置指令,其中,所述配置信息包括进行本地设备配置的本地配置信息和进行所述本地设备网络架构配置的网络配置信息;根据所述本地配置信息和所述网络配置信息分别对所述本地设备以及其网络架构进行配置得到配置设备,根据所述配置设备的本地配置和网络架构生成状态识别信息,其中,所述状态识别信息为记录所述配置设备对应本地配置和网络架构的数据信息。通过对本地配置和网络架构数据信息的记录使网络中设备可以相互识别,解决了由于网络设备之间数据交互无法识别产生数据交互错误的技术问题。

The present invention discloses a method, system, device and storage medium for generating state identification information, the method comprising: receiving a configuration instruction with configuration information, wherein the configuration information comprises local configuration information for configuring a local device and network configuration information for configuring a network architecture of the local device; configuring the local device and its network architecture respectively according to the local configuration information and the network configuration information to obtain a configuration device, generating state identification information according to the local configuration and network architecture of the configuration device, wherein the state identification information is data information recording the local configuration and network architecture corresponding to the configuration device. By recording the local configuration and network architecture data information, the devices in the network can recognize each other, solving the technical problem of data interaction errors caused by the inability to recognize data interaction between network devices.

Description

State identification information generation method, system, device and storage medium thereof
Technical Field
The invention relates to the field of Internet, in particular to a method, a system, a device and a storage medium for generating state identification information.
Background
So far, the problem of data interaction errors often occurs when a network between devices is established. For example, in the container field (service discovery and data storage system) that is widely used, the interaction data of the container field cannot always acquire the data to be processed from each device data node in the network, and especially in the later data interaction process, the data acquisition is failed or a major error occurs due to the lack of a data acquisition path corresponding to the device data node.
For example, when the flow rule is configured, the value of the cookie is not specified, and then the default value is 0. When a large number of stream tables need to be generated to form a table, because all cookies therein are valued as 0, the stream tables therein are not classified, and during the searching process, the search results will generate a large number of stream table search results. In some extreme environments, since many field data of the flow table are the same, confusion may occur, and further, a situation that the newly generated flow table covers the original flow table may occur.
Specifically, for example, in the security group configuration, if cookies are different, the user first sends out a flow table, opens 80 ports, then the user issues a flow table with 50 to 100 ports, and the final result only leaves a flow table with 80 ports, and the 80-port network is in a normal connection state, but in practice, the configuration has a problem, because the ports should be opened 50 to 100 at this time. Otherwise, if the cookies in the flow table are the same, the original flow table is covered, and the subsequent user deletes the flow table with 80 ports, so that the network with 80 ports is not enabled. Thus, no matter whether cookies in the flow table are the same or not, interaction errors can occur. The inventor finds that at least the following problems exist in the prior art, and the technical problem that data interaction is wrong can occur because the equipment state in the network cannot be identified.
Disclosure of Invention
The invention provides a method for generating state identification information, which comprises the following steps:
Receiving a configuration instruction with configuration information, wherein the configuration information comprises local configuration information for configuring local equipment and network configuration information for configuring network architecture of the local equipment;
The local equipment and the network architecture thereof are respectively configured according to the local configuration information and the network configuration information to obtain configuration equipment, wherein the configuration equipment is the local equipment which accords with the configuration of the configuration information;
Generating state identification information according to the local configuration and the network architecture of the configuration equipment, wherein the state identification information is data information for recording the local configuration and the network architecture corresponding to the configuration equipment.
Optionally, after the step of configuring the local device and the network architecture thereof according to the local configuration information and the network configuration information to obtain a configured device, the method further includes:
Receiving a subscription instruction conforming to a preset rule;
subscribing network architectures corresponding to other devices in the network according to the subscription instruction;
Acquiring target equipment in a network, wherein the target equipment is other equipment with the same network architecture as the configuration equipment;
The target device in the network is monitored.
Optionally, after the step of monitoring the target device in the network, the method further includes:
and recording the data information of the local configuration corresponding to the target equipment in the state identification information of the local equipment.
Optionally, the state identification information is a code stream table, where a stream table identification code, local configuration data information and network architecture data information corresponding to a local device, and local configuration data information corresponding to the target device are recorded in the code stream table.
Optionally, the local configuration information is configuration information for creating a virtual machine.
Optionally, the network configuration information is configuration information for creating a VPC network architecture and/or configuration information for creating a network security group.
The invention also provides another method for generating the state identification information, which comprises the following steps:
Creating a configuration instruction with configuration information according to a user request, wherein the configuration information comprises local configuration information for configuring local equipment and network configuration information for configuring network architecture of the local equipment;
The configuration instruction is sent to local equipment so that the local equipment receives the configuration instruction with configuration information, wherein the configuration information comprises local configuration information for configuring the local equipment and network configuration information for configuring the network architecture of the local equipment, the local equipment and the network architecture thereof are respectively configured according to the local configuration information and the network configuration information to obtain configuration equipment, the configuration equipment is the local equipment configured according to the configuration information, and state identification information is generated according to the local configuration and the network architecture of the configuration equipment, wherein the state identification information is data information for recording the local configuration and the network architecture corresponding to the configuration equipment.
Optionally, after the step of configuring the local device and the network architecture thereof according to the local configuration information and the network configuration information to obtain a configured device, the method includes:
Creating a subscription instruction conforming to a preset rule according to a user request;
The method comprises the steps of sending a subscription instruction to local equipment, enabling the local equipment to receive the subscription instruction conforming to a preset rule, subscribing network architectures corresponding to other equipment in a network according to the subscription instruction, obtaining target equipment in the network, wherein the target equipment is other equipment with the same network architecture as the configuration equipment, and monitoring the target equipment in the network.
The application provides a state identification information generation system, which comprises a controller, an ETCD component and local equipment, wherein the controller is used for generating state identification information;
The controller is used for creating a configuration instruction with configuration information according to a user request and sending the configuration instruction to the local equipment, wherein the configuration information comprises local configuration information for configuring the local equipment and network configuration information for configuring the network architecture of the local equipment;
the ETCD component is used for acquiring the configuration instruction with configuration information sent by the controller from the local equipment, respectively configuring the local equipment and the network architecture thereof according to the local configuration information and the network configuration information to obtain configuration equipment, wherein the configuration equipment is the local equipment which accords with the configuration information configuration, and generating state identification information according to the local configuration of the configuration equipment and the network architecture, wherein the state identification information is data information for recording the local configuration and the network architecture corresponding to the configuration equipment.
Optionally, the system further comprises at least one other device;
the controller is also used for creating a subscription instruction according to a user request and sending the subscription instruction to the local equipment;
the ETCD component is further used for receiving a subscription instruction conforming to a preset rule, subscribing network architectures corresponding to other devices in a network according to the subscription instruction, acquiring target devices in the network, wherein the target devices are other devices with the same network architecture as the configuration device, and monitoring the target devices in the network.
Optionally, the data processing ETCD component is further configured to record data information corresponding to a local configuration of the target device in the state identification information of the local device.
The application provides a state identification information generating device, which comprises:
The device comprises a receiving module, a processing module and a processing module, wherein the receiving module is used for receiving a configuration instruction with configuration information, wherein the configuration information comprises local configuration information for configuring local equipment and network configuration information for configuring network architecture of the local equipment;
The configuration module is used for respectively configuring the local equipment and the network architecture thereof according to the local configuration information and the network configuration information to obtain configuration equipment, wherein the configuration equipment is the local equipment which accords with the configuration of the configuration information;
The generating module is used for generating state identification information according to the local configuration and the network architecture of the configuration equipment, wherein the state identification information is data information for recording the local configuration and the network architecture corresponding to the configuration equipment.
Optionally, the apparatus further comprises:
the receiving module is used for receiving a subscription instruction conforming to a preset rule;
the subscription module is used for subscribing network architectures corresponding to other devices in the network according to the subscription instruction;
the acquisition module is used for acquiring target equipment in a network, wherein the target equipment is other equipment with the same network architecture as the configuration equipment;
and the monitoring module is used for monitoring the target equipment in the network.
Optionally, the apparatus further comprises:
and the recording module is used for recording the data information corresponding to the local configuration of the target equipment in the state identification information of the local equipment.
Optionally, the application also provides another state identification information generating device, which comprises a processor and a memory;
The memory stores therein an application executable by the processor for causing the processor to execute the steps of the state identification information generation method.
Optionally, the program when executed by the processor implements the steps of the state identification information generation method.
As can be seen from the above, based on the above embodiments, the devices in the network can be mutually identified by recording the data information of the local configuration and the network architecture, so as to solve the technical problem that the data interaction errors are generated because the data interaction between the network devices cannot be identified.
Drawings
FIG. 1 is a schematic diagram of an application scenario 100 according to an embodiment of the present application;
FIG. 2 is a schematic diagram of an application scenario 200 according to an embodiment of the present application;
FIG. 3 is a schematic diagram of a flow 300 of a method for generating status identifying information according to an embodiment of the present application;
FIG. 4 is a schematic diagram of a process 400 of generating status identifying information according to an embodiment of the present application;
FIG. 5 is a schematic diagram of a process 500 for generating status identifying information according to an embodiment of the present application;
FIG. 6 is a schematic diagram of a flow 600 of a method for generating status identifying information according to an embodiment of the present application;
FIG. 7 is a schematic diagram of a flow 700 of a method for generating status identifying information according to an embodiment of the present application;
FIG. 8 is a diagram illustrating the encoded data structure of a code stream table according to an embodiment of the present application;
FIG. 9 is a schematic diagram of one-dimensional data structure of an ETCD key according to one embodiment of the present application;
FIG. 10 is a diagram of another dimension data structure of an ETCD key according to one embodiment of the application;
FIG. 11 is a schematic diagram of an architecture 800 of a status identifying information generating device according to an embodiment of the present application;
Fig. 12 is a schematic diagram of an architecture 900 of a status identifying information generating device according to an embodiment of the present application.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention will be further described in detail below by referring to the accompanying drawings and examples.
Fig. 1 is a schematic diagram of an application scenario 100 according to an embodiment of the present application. As shown in fig. 1, in the present embodiment, the controller 110 (i.e., open vSwitch controller, where Open vSwitch is an Open virtual switching standard). The user or the controller 110 generates configuration information through setting, where the configuration information includes local configuration information and network configuration information, the local configuration information is data information for performing self data configuration on the local device 120, and the network configuration information is data information for performing network architecture configuration on the local device 120. The configuration information generating corresponding configuration instructions are sent to the local device 120 or other devices 130 in the network, and the ETCD component 140 in fig. 1 performs corresponding local configuration or network architecture configuration on the configuration information received by the local device 120 and/or other devices 130, where it should be noted that the ETCD component 140 may be set to operate separately in a separate device, or may be installed to operate in one of the local devices or other devices in the network.
The ETCD component 140 is a service discovery and data storage system in the container domain.
Fig. 2 is a schematic diagram of an application scenario 200 according to an embodiment of the present application. As shown in fig. 2, based on the embodiment in fig. 1, in this embodiment, the thread of the present application is schematically shown, where a Web Server (Web Server) receives configuration information, generates data of the configuration information in an openflow manner, and meanwhile, the ETCD component 140 acquires the data of the configuration information to monitor and status monitor the ETCD component 140 to achieve the purpose of discovering services. In the virtual machine scenario, a virtual machine management module may be provided, and the virtual machine management module may be implemented by adopting Libvirt to control and manage the state of the local device 120 in the state monitor.
An OpenFlow, an online communication protocol, belongs to a data link layer, and can control the forwarding plane (forwarding plane) of an online switch or router, thereby changing the online path taken by an online data packet.
Libvirt are APIs, daemons and management tools for managing the open source of the virtualized platform.
The API (Application Programming Interface ) is a number of predefined functions that are designed to provide the application and developer with the ability to access a set of routines based on certain software or hardware without having to access source code or understand the details of the internal operating mechanisms.
Fig. 3 is a schematic diagram of a flow 300 of a method for generating status identifying information according to an embodiment of the present application, as shown in fig. 3, in an embodiment, the present application provides a method for generating status identifying information, which includes:
s101, receiving a configuration instruction with configuration information, wherein the configuration information comprises local configuration information for configuring local equipment and network configuration information for configuring network architecture of the local equipment;
In this step, a configuration instruction with configuration information is required to be received, wherein the configuration information is a preset configuration requirement. The configuration requirements may be set by the user or may be generated by a program in the controller. The configuration information includes two parts, one part is a configuration performed locally (i.e., a local configuration), and the other part is a configuration performed on a network architecture (i.e., a network architecture), and it should be noted that the local configuration and the network architecture configuration are both specific to one device, i.e., the local device. The local device is an abstract concept, not necessarily a stand-alone device, but also a virtual data node arranged under the network architecture.
S102, configuring the local equipment and the network architecture thereof according to the local configuration information and the network configuration information to obtain configuration equipment, wherein the configuration equipment is the local equipment which accords with the configuration of the configuration information;
The local device is configured in this step according to the local configuration information and the network configuration information. Correspondingly, the configuration of the local device refers to the configuration of the local device and the configuration of the network architecture thereof, and the local device becomes a configuration device conforming to the preset local configuration in the preset network architecture after the configuration is completed.
S103, generating state identification information according to the local configuration and the network architecture of the configuration equipment, wherein the state identification information is data information for recording the local configuration and the network architecture corresponding to the configuration equipment.
In this step, status identification information is generated according to the local configuration of the configuration device and network architecture data, and the status identification information records data information which can be called in the network to read the corresponding local configuration and network architecture.
In this embodiment, the local device in the network may be configured according to the configuration instruction by receiving the configuration instruction with the configuration information. The configuration local equipment comprises two layers of local configuration and network architecture configuration, and configuration equipment conforming to configuration information is obtained after the local equipment is configured according to the configuration information. And recording the configuration state of the configuration equipment to generate state identification information, wherein the state identification information also comprises data information of two layers of local configuration and network architecture. According to the state identification information, the state of the local equipment and the state of the network architecture of the local equipment can be obtained, the local equipment can be identified in the subsequent data interaction by utilizing the data information, confusion of the data interaction in the network can not be generated according to the identification of the local equipment, and therefore errors in the process of data interaction are avoided.
Fig. 4 is a schematic diagram of a flow 400 of a method for generating status identifying information according to an embodiment of the present application, as shown in fig. 4, in an embodiment, the present application provides a method for generating status identifying information, after the steps of configuring the local device and its network architecture according to the local configuration information and the network configuration information to obtain a configuration device, the method includes:
s201, receiving a subscription instruction conforming to a preset rule;
in this step, in the network architecture established by the configuration device, a subscription instruction may be received. The subscription instruction herein is an instruction to monitor other devices in the network structure.
S202, subscribing network architectures corresponding to other devices in a network according to the subscription instruction;
In this step, network architectures corresponding to other devices are subscribed in the network. It should be noted that the other devices may be one or more of the networks, some or all of the other devices, and the above determination is performed separately according to a preset in the subscription instruction.
S203, acquiring target equipment in a network, wherein the target equipment is other equipment with the same network architecture as the configuration equipment;
in this step, the same network architecture may mean that other devices and the local device belong to the same security group or the same cloud. Similarly, the other devices herein may be one or more.
S204, monitoring the target equipment in the network.
In this step, when it is determined that the target device and the local device in the network belong to the same network architecture, that is, the target device should belong to the same security group or the same cloud, the target device may be monitored in real time through the network.
In this embodiment, the target device and the local device may belong to the same security group or the same cloud, and the target device having the same network architecture in the same network is acquired through the subscription instruction. Then, other devices in the network are monitored.
In an embodiment, after the step of monitoring the target device in the network, the method further comprises:
and recording the data information of the local configuration corresponding to the target equipment in the state identification information of the local equipment.
In this embodiment, in order to enable the local device to provide the local configuration of the target device, the local configuration data information of the target device under monitoring may be recorded in the identification information state of the local device, so that the local configuration of the target device may be obtained from the network through the local device, and then a control instruction is sent to the local device, and then the local device performs further network call or control on the target device.
In an embodiment, the state identification information is a code stream table, where the state identification information is a code stream table, and a stream table identification code, local configuration data information and network architecture data information corresponding to a local device, and local configuration data information corresponding to the target device are recorded in the code stream table.
The embodiment provides a specific implementation mode of the code stream table form state identification information.
In an embodiment, the local configuration information is configuration information for creating a virtual machine.
The embodiment provides a specific implementation mode of creating a virtual machine configuration by using a local configuration.
In an embodiment, the network configuration information is configuration information for creating a VPC network architecture and/or configuration information for creating a network security group.
The embodiment provides an implementation manner of specific configuration of a network architecture.
Fig. 5 is a schematic diagram of a flow 500 of a method for generating status identifying information according to an embodiment of the present application, and as shown in fig. 5, the present application further provides a method for generating status identifying information, which includes:
s301, creating a configuration instruction with configuration information according to a user request, wherein the configuration information comprises local configuration information for configuring local equipment and network configuration information for configuring a network architecture of the local equipment;
In this step, the user may directly set the configuration information, or may automatically generate the configuration instruction according to a predetermined setting.
S302, the configuration instruction is sent to local equipment so that the local equipment receives the configuration instruction with configuration information, wherein the configuration information comprises local configuration information for configuring the local equipment and network configuration information for configuring the network architecture of the local equipment, the local equipment and the network architecture thereof are configured according to the local configuration information and the network configuration information to obtain configuration equipment, the configuration equipment is the local equipment which accords with the configuration information, and state identification information is generated according to the local configuration and the network architecture of the configuration equipment, wherein the state identification information is data information for recording the local configuration and the network architecture corresponding to the configuration equipment.
In this step, the configuration information and the configuration instruction are transmitted to the local device in this step, and the local device generates the state identification information according to the steps in the above-described embodiments.
The embodiment provides a specific implementation mode for generating the configuration instruction with the configuration information, and a user generates the configuration instruction with the configuration information according to the preset configuration instruction and sends the configuration instruction to the local equipment. The local equipment configures the local equipment and the network architecture thereof according to the local configuration information and the network configuration information to obtain configuration equipment, wherein the configuration equipment is the local equipment which accords with the configuration information configuration, and generates state identification information according to the local configuration of the configuration equipment and the network architecture, and the state identification information is data information which records the local configuration and the network architecture corresponding to the configuration equipment.
Fig. 6 is a schematic diagram of a flow 600 of a method for generating status identifying information according to an embodiment of the present application, as shown in fig. 6, in an embodiment, after the steps of configuring the local device and its network architecture according to the local configuration information and the network configuration information to obtain a configured device, the method includes:
S401, creating a subscription instruction conforming to a preset rule according to a user request;
In this step, a specific implementation manner of creating a subscription instruction is provided, where the subscription instruction may be a setting performed by a user, or may be a subscription instruction automatically generated according to a preset setting.
S402, sending the subscription instruction to the local equipment so that the local equipment receives the subscription instruction conforming to a preset rule, subscribing network architectures corresponding to other equipment in a network according to the subscription instruction, acquiring target equipment in the network, wherein the target equipment is other equipment with the same network architecture as the configuration equipment, and monitoring the target equipment in the network.
In this step, an embodiment is provided in which a subscription instruction is created and then sent to the local device to cause the local device to perform a subsequent step.
The embodiment provides a subscription instruction, wherein the subscription instruction is used for enabling a local device to receive a subscription instruction conforming to a preset rule, subscribing state identification information of other devices in a network according to the subscription instruction, acquiring target devices in the subscription instruction according to the state identification information of the other devices, wherein the target devices are other devices with the same network architecture data information as the local device, and monitoring specific implementation modes of the target devices in the network.
Working process and basic principle:
In order to better illustrate the technical solution of the present invention, the following description will take the creation of a virtual machine as an example, and it should be noted that the embodiment of creating a virtual machine is only for better illustrating the present invention, and is not a specific limitation of the present invention.
Fig. 7 is a schematic diagram of a flow 700 of a method for generating status identifying information according to an embodiment of the present application, as shown in fig. 7, in an embodiment, the method includes:
S501, receiving a configuration instruction with configuration information, wherein the configuration information comprises local configuration information for configuring local equipment and network configuration information for configuring network architecture of the local equipment;
The ETCD mechanism commonly applied in the container network field can be utilized for service discovery, and the virtual network adopts an ETCD component for service discovery. Specifically, the controller writes the local configuration information and the network configuration information to be created in the form of two-dimensional codes into the ETCD key. Wherein the local configuration information is one dimension in the data structure, the network configuration information is also recorded in the data structure of the other dimension, by adopting the method, the problem that the lightweight service discovery mechanism caused by ETCD cannot be realized due to the fact that the ETCD key is too simple to set and only a single key value is stored and one dimension of data is lacking can be avoided. The specific operation will be described in detail hereinafter, and will not be described in detail here.
The local configuration information may be understood as information for creating a virtual machine, including IP-address (IP address), mac (MEDIA ACCESS Control, medium access Control), host IP-address (IP address), virtual machine back-end device name, etc., where the configuration information corresponding to the network architecture of the created network vpc is written into a first dimension of the ETCD key, for example, the first dimension of/ovs/v 1/nodes/12.12.12.1/vms/1000/192.168.100.10,ETCD key includes the IP address of the host.
Vni, VXLAN Network Identifier, VXLAN network identifier.
Vpc, virtual Private Cloud, a private cloud, is a concept defined for the public cloud's underlying network (classical network).
The local network configuration information may be understood as configuration information for creating a vpc network architecture and/or configuration information for a network security group. The configuration information corresponding to the network vpc network architecture creation includes subnet, gateway, vni (VXLAN network identifier), etc., for example, vpc with vni being 1000 is to be created, and the configuration information is written into a first dimension of the ETCD key, for example,/ovs/v 1/nodes/12.12.12.1/vpcs/1000, where the first dimension of the ETCD key includes the IP address of the host.
S502, configuring the local equipment and the network architecture thereof according to the local configuration information and the network configuration information to obtain configuration equipment, wherein the configuration equipment is the local equipment which accords with the configuration of the configuration information;
the local device is configured according to the ETCD key in the above step, that is, a network architecture of the virtual machine and the local device is created.
S503, receiving a subscription instruction conforming to a preset rule;
The controller creates a subscription instruction according to a preset rule, and sends the created subscription instruction to the local device. The local device receives a subscription instruction, the subscription instruction having the purpose of subscribing the local device to other devices in the network.
S504, subscribing the network architecture corresponding to other devices in the network according to the subscription instruction;
other devices also record corresponding network architecture data information.
S505, obtaining target equipment in a network, wherein the target equipment is other equipment with the same network architecture as the configuration equipment;
The network architecture data information in this step may be understood that the vpc network architecture or security Group SG (i.e. security Group) of the local device is the same as that of other devices, and other devices consistent with the above description are target devices, which may be one or more of the other devices.
S506, monitoring the target equipment in the network.
This step is to monitor the target device, and it should be noted that only other devices belonging to the same vpc network architecture or security group can be monitored.
Such as subscription key:/ETCDCTL WATCH-prefix/ovs/v 1/vpcs/1000, the local device is already monitoring the target device with vni 1000 vpc.
S507, recording the data information of the local configuration corresponding to the target device in the state identification information of the local device.
The state identification information records not only local configuration data information and network architecture data information of the local device. Data information of the local configuration of the target device may also be recorded.
For example, the controller writes the virtual machine configuration information and vpc configuration information of the local device stored on the ETCD key, that is, the data information of the local configuration and the network architecture, into the second dimension of the ETCD key.
If the local configuration data information of the local device is/ovs/v 1/vpcs/1000, the local configuration data information is/ovs/v 1/vpcs/1000, and can be stored as/ovs/v 1/vpcs/1000/vms/192.168.100.10 on the local device, and the local configuration data information corresponding to the target device can be automatically recorded in the state identification information of the local device. The target device may then create a virtual machine by the method described above, thereby generating corresponding state identification information.
Fig. 8 is a schematic diagram of an encoded data structure of a code stream table according to an embodiment of the present application, and as shown in fig. 8, a specific design scheme of status identification information in the form of a code stream table is provided below.
The cookie value is 64-bit width, which is expressed as 16-system number 0xFFFFFFFFFFFFFF, corresponding to cookie [0..63], and the following division design is carried out on cookies related to vpc networking:
The system stream table (namely stream table identification code) is characterized in that 60-63 bits are expressed as 0x0 of 16 system, 16-19 bits are expressed as tableid, and 0-15 bits are expressed as stream table serial numbers in the same table.
The vpc granularity flow table (i.e. network architecture data information) has 60-63 bits of 0x1, 36-59 bits of 16 scale of vni, 32-35 bits of 0 reserved bit and 0-31 bits of the rest low bits of 0.
In vm granularity flow table 1 (i.e. local configuration data information), 60-63 bits are 0x2 of 16 system, 36-59 bits are vni, 32-35 bits are 0 as reserved bits, and the remaining 0-31 bits are the virtual machine IP address on the host. (host herein can be understood as a local device)
And in the vm granularity flow table 2 (namely local configuration data information corresponding to the target device), 60-63 bits of the vm granularity flow table are expressed as 0x3 of 16 system, 36-59 bits of the vm granularity flow table are expressed as vni, 32-35 bits of the vm granularity flow table are expressed as reserved bits and are set as 0, and the remaining 0-31 bits of the lower bits of the vm granularity flow table are expressed as virtual machine IP addresses on other hosts belonging to the same vpc. (other hosts may be understood herein as other devices)
The security group related flow table (i.e. network architecture data information) has 60-63 bits of 0x4, 36-59 bits of vni, 24-35 bits of security group id, 8-23 bits of security group rule priority, and the rest 0-7 bits of security group rule id.
Following the cookie design above, an algorithm for generating a corresponding cookie is given below.
Cookie configuration of the system flow table;
table ID XX;
Stream table index XX
The digits occupied by the table ID;
the configuration of the cookie includes a table ID and a flow table index, as well as the associated configuration.
Thus, the following flow table can be formed for issuing
The cookie of the vpc granularity flow table,
The flow table starts to configure values;
vni configuration;
vpc starting configuration;
The cookie also requires configuration of vni configuration and flow table start configuration;
Thus, the following flow table can be formed for issuing
"The cookie itself is configured with,
The cookie of vm particle size stream table 1;
Initial configuration of a flow table;
vni configuration
Virtual machine IP configuration;
configuring IP data types of the virtual machine;
Generating a corresponding cookie
Thus, the following flow table can be formed for issuing
The target device granularity flows the cookies of table 2,
Initial configuration of a flow table;
vni configuration;
IP setting of the target equipment;
a corresponding cookie is generated.
Thus, the following flow table can be formed for issuing
Cookies configured as described above;
The cookie of the security group related flow table,
Configuring a safety group;
Thus, the following flow table can be formed for issuing
Configuring cookies of a security group;
Through the design of the cookies, each field forming the cookies can be reversely calculated by the operation of bit,
The batch operation can also be performed on the stream tables, for example, to delete the stream tables with a certain vpc granularity, and the stream tables can be deleted in batch by extracting the vni field from the cookie through bit operation.
Collision or coverage of the flow table can also be avoided according to the design of the cookie.
For example, when a security group rule is added, a scenario can occur that a user issues a rule to open 80 ports first, then adds a rule to open 50-100 ports (ranges), at this time, rule id is added with 1, 1 rule with different cookies is generated to open 80 ports, so that collision of a flow table is effectively avoided, coverage of an original flow table is also avoided, and the user deletes the rule of 180 ports, so that 80 ports cannot be accessed.
FIG. 9 is a schematic diagram of an ETCD key one-dimensional data structure according to an embodiment of the present application, and as shown in FIG. 9, the following provides a design of a first dimension of a specific data structure of the ETCD key:
ETCD key is designed into two dimensions, namely a node dimension and a vpc dimension, wherein the value of the two dimensions has a cross-correlation relationship.
The key of node dimension mainly refers to information on the local device, including vm information and vpc information, vm mainly refers to which vm is included on the local device, vpc information refers to which vpc is included on the host, and vpc is identified by vni, which is shown in the following figure.
According to the architecture of the above diagram, the following keys with cross-correlation can be designed:
identifying which virtual machines a node contains;
identifying which vpc a node contains
Which vpc of which node a certain virtual machine belongs to is identified.
FIG. 10 is a schematic diagram of another dimension data structure of an ETCD key according to an embodiment of the present application, as shown in FIG. 9, and the following provides a design of a second dimension of a specific data structure of the ETCD key:
The key of the vpc (identified by vni) dimension, comprising vm information and SG security group information, indicates which vm the vpc comprises, which security groups comprise, respectively, wherein the security groups comprise vm information and rule information,
According to the architecture of the above diagram, the following keys with cross-correlation can be designed:
identifying which virtual machines are under a vpc;
identifying which security groups a vpc contains;
identifying which vm is included under a security group
Identifying which security group of which vpc a vm belongs to
Identifying which rules a security group has
Identifying to which security group a rule belongs
By the design of the etcd two-dimensional key above, a search can be made,
Which vpcs are on a certain host;
which vm exists on a host;
Which vms a certain vpc contains;
which vpc of which host a certain vm belongs to;
some vpc contains which security groups;
Which vm a certain security group contains;
Which security group of which vpc a certain vm belongs to;
Which security group of which vpc a certain vm belongs to which host;
which rules a certain security group has;
a rule belongs to which safety group;
thus, in a virtual network, a similar rabbitMQ-based mechanism for service discovery can be implemented.
The above method may be applied to other operations such as deleting a virtual machine, adding a virtual machine to a security group, removing a virtual machine from the security group, adding a security group rule, deleting a security group rule, and the like.
In one embodiment, the application also provides a state identification information generation system, which comprises a controller, an ETCD component and a local device;
The controller is used for creating a configuration instruction with configuration information according to a user request and sending the configuration instruction to the local equipment, wherein the configuration information comprises local configuration information for configuring the local equipment and network configuration information for configuring the network architecture of the local equipment;
the ETCD component is used for acquiring the configuration instruction with configuration information sent by the controller from the local equipment, respectively configuring the local equipment and the network architecture thereof according to the local configuration information and the network configuration information to obtain configuration equipment, wherein the configuration equipment is the local equipment which accords with the configuration information configuration, and generating state identification information according to the local configuration of the configuration equipment and the network architecture, wherein the state identification information is data information for recording the local configuration and the network architecture corresponding to the configuration equipment.
In one embodiment, the system further comprises at least one other device;
the controller is also used for creating a subscription instruction according to a user request and sending the subscription instruction to the local equipment;
the ETCD component is further used for receiving a subscription instruction conforming to a preset rule, subscribing network architectures corresponding to other devices in a network according to the subscription instruction, acquiring target devices in the network, wherein the target devices are other devices with the same network architecture as the configuration device, and monitoring the target devices in the network.
In an embodiment, the data processing ETCD component is further configured to record data information corresponding to a local configuration of the target device in the state identification information of the local device.
Fig. 11 is a schematic diagram of an architecture 800 of a status identifying information generating device according to an embodiment of the present application, as shown in fig. 11, in an embodiment, the present application further provides a status identifying information generating device, which includes:
A receiving module 101, configured to receive a configuration instruction with configuration information, where the configuration information includes local configuration information for configuring a local device and network configuration information for configuring a network architecture of the local device;
A configuration module 102, configured to configure the local device and its network architecture according to the local configuration information and the network configuration information to obtain a configuration device, where the configuration device is a local device configured according to the configuration information;
and the generating module 103 is configured to generate state identification information according to the local configuration and the network architecture of the configuration device, where the state identification information is data information for recording the local configuration and the network architecture corresponding to the configuration device.
Fig. 12 is a schematic diagram of an architecture 900 of a status identifying information generating device according to an embodiment of the present application. As shown in fig. 12, in an embodiment, the apparatus further includes:
the receiving module 101 is configured to receive a subscription instruction conforming to a predetermined rule;
a subscription module 202, configured to subscribe to a network architecture corresponding to other devices in the network according to the subscription instruction;
An obtaining module 203, configured to obtain a target device in a network, where the target device is another device having the same network architecture as the configuration device;
A monitoring module 204, configured to monitor the target device in the network.
In one embodiment, the apparatus further comprises:
a recording module 301, configured to record data information corresponding to a local configuration of the target device in the state identification information of the local device.
In one embodiment, the application also provides a state identification information generating device, which comprises a processor and a memory;
The memory stores an application executable by the processor for causing the processor to perform the step of generating the state identification information.
In an embodiment, the present application further provides a computer-readable storage medium having stored thereon a computer program which when executed by a processor implements the state identification information generating step.
The foregoing description of the preferred embodiments of the invention is not intended to be limiting, but rather to enable any modification, equivalent replacement, improvement or the like to be made within the spirit and principles of the invention.

Claims (13)

1. A method for generating status identifying information, the method comprising:
Receiving a configuration instruction with configuration information, wherein the configuration information comprises local configuration information for configuring local equipment and network configuration information for configuring network architecture of the local equipment;
The local equipment and the network architecture thereof are respectively configured according to the local configuration information and the network configuration information to obtain configuration equipment, wherein the configuration equipment is the local equipment which accords with the configuration of the configuration information;
Generating state identification information according to the local configuration and the network architecture of the configuration equipment, wherein the state identification information is data information for recording the local configuration and the network architecture corresponding to the configuration equipment;
After the step of configuring the local device and the network architecture thereof according to the local configuration information and the network configuration information to obtain the configuration device, the method further includes:
Monitoring target equipment in a network, wherein the target equipment is other equipment with the same network architecture as the configuration equipment;
and recording the data information of the local configuration corresponding to the target equipment in the state identification information of the local equipment.
2. The status identifying information generating method according to claim 1, wherein the monitoring the target device in the network comprises:
Receiving a subscription instruction conforming to a preset rule;
subscribing network architectures corresponding to other devices in the network according to the subscription instruction;
acquiring target equipment in a network;
The target device in the network is monitored.
3. The method according to claim 1, wherein the state identification information is a code stream table, and wherein a stream table identification code, local configuration data information and network architecture data information corresponding to a local device, and local configuration data information corresponding to the target device are recorded in the code stream table.
4. A state identification information generation method according to any one of claims 1 to 3, wherein the local configuration information is configuration information for creating a virtual machine.
5. The method according to claim 4, wherein the network configuration information is configuration information for creating a VPC network architecture and/or configuration information for creating a network security group.
6. A method for generating status identifying information, the method comprising:
Creating a configuration instruction with configuration information according to a user request, wherein the configuration information comprises local configuration information for configuring local equipment and network configuration information for configuring network architecture of the local equipment;
The configuration instruction is sent to local equipment so that the local equipment receives the configuration instruction with configuration information, wherein the configuration information comprises local configuration information for configuring the local equipment and network configuration information for configuring the network architecture of the local equipment, the local equipment and the network architecture thereof are respectively configured according to the local configuration information and the network configuration information to obtain configuration equipment, the configuration equipment is the local equipment configured according to the configuration information, state identification information is generated according to the local configuration and the network architecture of the configuration equipment, the state identification information is data information for recording the local configuration and the network architecture corresponding to the configuration equipment, and the state identification information is used for identifying the configuration equipment during data interaction;
After the step of configuring the local device and the network architecture thereof according to the local configuration information and the network configuration information to obtain the configuration device, the method further includes:
Monitoring target equipment in a network, wherein the target equipment is other equipment with the same network architecture as the configuration equipment;
and recording the data information of the local configuration corresponding to the target equipment in the state identification information of the local equipment.
7. The status identifying information generating method of claim 6 wherein the monitoring the target device in the network comprises:
Creating a subscription instruction conforming to a preset rule according to a user request;
The method comprises the steps of sending the subscription instruction to the local equipment so that the local equipment receives the subscription instruction conforming to a preset rule, subscribing network architectures corresponding to other equipment in a network according to the subscription instruction, obtaining target equipment in the network, and monitoring the target equipment in the network.
8. A state identification information generation system is characterized by comprising a controller, an ETCD component and a local device;
The controller is used for creating a configuration instruction with configuration information according to a user request and sending the configuration instruction to the local equipment, wherein the configuration information comprises local configuration information for configuring the local equipment and network configuration information for configuring the network architecture of the local equipment;
The ETCD component is used for acquiring the configuration instruction with configuration information sent by the controller from the local equipment, respectively configuring the local equipment and the network architecture thereof according to the local configuration information and the network configuration information to obtain configuration equipment, wherein the configuration equipment is the local equipment conforming to the configuration information configuration, and generating state identification information according to the local configuration of the configuration equipment and the network architecture, wherein the state identification information is data information for recording the local configuration and the network architecture corresponding to the configuration equipment, and the state identification information is used for identifying the configuration equipment during data interaction;
the system also comprises at least one other device;
the ETCD component is also used for monitoring target equipment in a network, wherein the target equipment is other equipment with the same network architecture as the configuration equipment, and data information corresponding to local configuration of the target equipment is recorded in the state identification information of the local equipment.
9. The status identifying information generating system of claim 8 wherein,
The controller is also used for creating a subscription instruction according to a user request and sending the subscription instruction to the local equipment;
the ETCD component is further used for receiving a subscription instruction conforming to a preset rule, subscribing network architectures corresponding to other devices in the network according to the subscription instruction, acquiring target devices in the network, and monitoring the target devices in the network.
10. A state identification information generation apparatus, characterized in that the apparatus comprises:
The device comprises a receiving module, a processing module and a processing module, wherein the receiving module is used for receiving a configuration instruction with configuration information, wherein the configuration information comprises local configuration information for configuring local equipment and network configuration information for configuring network architecture of the local equipment;
The configuration module is used for respectively configuring the local equipment and the network architecture thereof according to the local configuration information and the network configuration information to obtain configuration equipment, wherein the configuration equipment is the local equipment which accords with the configuration of the configuration information;
the generating module is used for generating state identification information according to the local configuration and the network architecture of the configuration equipment, wherein the state identification information is data information for recording the local configuration and the network architecture corresponding to the configuration equipment;
Wherein the apparatus further comprises:
the monitoring module is used for monitoring target equipment in a network, wherein the target equipment is other equipment with the same network architecture as the configuration equipment;
and the recording module is used for recording the data information corresponding to the local configuration of the target equipment in the state identification information of the local equipment.
11. The state identification information generation apparatus according to claim 10, characterized in that the apparatus further comprises:
the receiving module is used for receiving a subscription instruction conforming to a preset rule;
the subscription module is used for subscribing network architectures corresponding to other devices in the network according to the subscription instruction;
the acquisition module is used for acquiring target equipment in the network;
and the monitoring module is used for monitoring the target equipment in the network.
12. A status identifying information generating device is characterized in that the device comprises a processor and a memory;
the memory has stored therein an application executable by the processor for causing the processor to perform the steps of the state identification information generation method according to any one of claims 1 to 5.
13. A computer-readable storage medium, on which a computer program is stored, characterized in that the program, when being executed by a processor, implements the steps of the state identification information generation method of any one of claims 1 to 5.
CN201910205254.XA 2019-03-18 2019-03-18 A method, system, device and storage medium for generating state identification information Active CN111726236B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910205254.XA CN111726236B (en) 2019-03-18 2019-03-18 A method, system, device and storage medium for generating state identification information

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910205254.XA CN111726236B (en) 2019-03-18 2019-03-18 A method, system, device and storage medium for generating state identification information

Publications (2)

Publication Number Publication Date
CN111726236A CN111726236A (en) 2020-09-29
CN111726236B true CN111726236B (en) 2025-01-10

Family

ID=72563182

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910205254.XA Active CN111726236B (en) 2019-03-18 2019-03-18 A method, system, device and storage medium for generating state identification information

Country Status (1)

Country Link
CN (1) CN111726236B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN120880980A (en) * 2025-09-25 2025-10-31 中移(苏州)软件技术有限公司 Stream table generation method, device, equipment, storage medium and product

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106230954A (en) * 2016-08-05 2016-12-14 广州市久邦数码科技有限公司 A kind of virtual management platform
CN108322325A (en) * 2017-06-27 2018-07-24 新华三云计算技术有限公司 A kind of virtual machine management method and device

Family Cites Families (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8935692B2 (en) * 2008-05-22 2015-01-13 Red Hat, Inc. Self-management of virtual machines in cloud-based networks
FI20135058A7 (en) * 2013-01-21 2014-07-22 Tellabs Oy A method and a controller system for controlling a software-defined network
CN103607430B (en) * 2013-10-30 2018-04-27 中兴通讯股份有限公司 A kind of method and system of network processes and the network control center
US10623258B2 (en) * 2015-06-22 2020-04-14 Arista Networks, Inc. Data analytics on internal state
CN107528870B (en) * 2016-06-22 2019-08-23 腾讯科技(深圳)有限公司 A kind of collecting method and its equipment
CN106790660B (en) * 2017-01-18 2018-05-22 咪咕视讯科技有限公司 A kind of dispositions method and device for realizing distributed memory system
CN108449197B (en) * 2018-01-03 2020-11-20 北京大学 A method for building multi-cloud environment network based on software-defined network
CN108599998B (en) * 2018-04-04 2021-11-02 刘昱 Network management and control method and device and computer readable storage medium
CN109245928B (en) * 2018-09-12 2021-08-31 广州视源电子科技股份有限公司 Method and device for setting configuration information, and terminal management system

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106230954A (en) * 2016-08-05 2016-12-14 广州市久邦数码科技有限公司 A kind of virtual management platform
CN108322325A (en) * 2017-06-27 2018-07-24 新华三云计算技术有限公司 A kind of virtual machine management method and device

Also Published As

Publication number Publication date
CN111726236A (en) 2020-09-29

Similar Documents

Publication Publication Date Title
US11924072B2 (en) Technologies for annotating process and user information for network flows
JP6335363B2 (en) Provision of virtual security appliance architecture for virtual cloud infrastructure
US7826393B2 (en) Management computer and computer system for setting port configuration information
CN111464566B (en) Medium, device, system and method for network manager computer
EP3675419A1 (en) Method and apparatus for detecting network fault
US20120294192A1 (en) Method and apparatus of connectivity discovery between network switch and server based on vlan identifiers
CN109981493B (en) A method and apparatus for configuring a virtual machine network
CN109962832A (en) Message processing method and device
WO2017152396A1 (en) Flow table processing method and device
US10050859B2 (en) Apparatus for processing network packet using service function chaining and method for controlling the same
JP6248938B2 (en) Communication system, virtual network management apparatus, virtual network management method and program
CN107404470A (en) Connection control method and device
WO2015101119A1 (en) Flow table matching method and apparatus, and openflow exchanging system
US9166947B1 (en) Maintaining private connections during network interface reconfiguration
KR20200061531A (en) System for secure software defined networking(sdn) based on block-chain and the method thereof
CN116938564A (en) Collect and process context properties on the host
CN112887229B (en) Session information synchronization method and device
US20210099343A1 (en) Multi-cluster management plane for network devices
RU2602333C2 (en) Network system, packet processing method and storage medium
CN106878106B (en) Reachability detection method and device
CN111726236B (en) A method, system, device and storage medium for generating state identification information
CN119583443A (en) Message forwarding method, device, computer equipment and readable storage medium
WO2015135312A1 (en) Method and device for realizing sdn communication management
US11526372B2 (en) Hypervisor restart handling mechanism using random session numbers
CN117914649B (en) Network communication system, method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
CB02 Change of applicant information
CB02 Change of applicant information

Address after: Room 221, 2 / F, block C, 18 Kechuang 11th Street, Daxing District, Beijing, 100176

Applicant after: Jingdong Technology Holding Co.,Ltd.

Address before: Room 221, 2nd floor, Block C, 18 Kechuang 11th Street, Daxing Economic and Technological Development Zone, Beijing, 100176

Applicant before: JINGDONG DIGITAL TECHNOLOGY HOLDINGS Co.,Ltd.

SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant