CN114780118A - Virtual equipment updating method and device - Google Patents

Virtual equipment updating method and device Download PDF

Info

Publication number
CN114780118A
CN114780118A CN202210435719.2A CN202210435719A CN114780118A CN 114780118 A CN114780118 A CN 114780118A CN 202210435719 A CN202210435719 A CN 202210435719A CN 114780118 A CN114780118 A CN 114780118A
Authority
CN
China
Prior art keywords
data
target
configuration data
real
target configuration
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202210435719.2A
Other languages
Chinese (zh)
Inventor
张英彬
田海波
阳志明
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China Telecom Corp Ltd
Original Assignee
China Telecom Corp 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 China Telecom Corp Ltd filed Critical China Telecom Corp Ltd
Priority to CN202210435719.2A priority Critical patent/CN114780118A/en
Publication of CN114780118A publication Critical patent/CN114780118A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/65Updates
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/70Software maintenance or management
    • G06F8/71Version control; Configuration management

Abstract

The embodiment of the invention provides a virtual device updating method and a virtual device updating device, which relate to the technical field of data processing and are applied to monitoring devices, wherein the monitoring devices comprise virtual devices which are constructed based on target configuration data by adopting a digital twin technology and are used for reflecting the configuration condition of real devices, and the method comprises the following steps: acquiring an operation log generated by real equipment in real time, wherein the operation log is as follows: the method comprises the steps that the real equipment executes operation aiming at configuration data, and after an operation log of the real equipment is obtained each time, target operation data recorded in the operation log are extracted; comparing the target operation data with recorded target configuration data of the real equipment; and updating the recorded target configuration data based on the comparison result and the target operation data, and updating the constructed virtual equipment based on the updated target configuration data. The scheme provided by the embodiment of the invention can meet the real-time requirement of virtual equipment constructed based on a digital twin technology.

Description

Virtual equipment updating method and device
Technical Field
The present invention relates to the field of data processing technologies, and in particular, to a method and an apparatus for updating a virtual device.
Background
In order to monitor electronic equipment (referred to as real equipment) running in a real scene, monitoring equipment can acquire various kinds of configuration data of the real equipment based on a digital twin technology, and then construct virtual equipment corresponding to the real equipment in a virtual environment based on the acquired configuration data, so that the configuration condition of the real equipment is reflected through the virtual equipment, and therefore a user can monitor the real equipment through monitoring the virtual equipment.
For example, the real device may be a network element device, and the monitoring device may obtain various configuration data of the network element device, such as an IP address, a port number, and a network card traffic of the network element device, so as to construct a virtual network element device corresponding to the network element device in a virtual environment, and a user may monitor the network element device in a real scene by monitoring the virtual network element device.
In the process of operating the real device, the configuration condition of the real device may change, and in order to enable the constructed virtual device to reflect the configuration condition of the real device in real time, the monitoring device needs to acquire all configuration data of the real device in real time, that is, the full configuration data, and update the virtual device based on the full configuration data, so that the virtual device can reflect the configuration condition of the real device in real time. However, the data volume of the full configuration data of the real device is large, and the monitoring device needs to consume a long time to acquire and process the full configuration data, so that the real-time requirement of the virtual device constructed based on the digital twin technology is difficult to meet.
Disclosure of Invention
The embodiment of the invention aims to provide a virtual device updating method and device so as to meet the real-time requirement of a virtual device constructed based on a digital twin technology. The specific technical scheme is as follows:
in a first aspect, an embodiment of the present invention provides a virtual device updating method, which is applied to a monitoring device, where the monitoring device includes a virtual device that is constructed based on target configuration data by using a digital twin technology and is used for reflecting a configuration situation of a real device, and the method includes:
acquiring an operation log generated by real equipment in real time, wherein the operation log is as follows: the real device executes the operation on the configuration data, and the operation log records: operation data representing the operation on the configuration data;
extracting target operation data recorded in an operation log after the operation log of the real equipment is acquired each time;
comparing the target operation data with recorded target configuration data of the real equipment;
and updating the recorded target configuration data based on the comparison result and the target operation data, and updating the constructed virtual equipment based on the updated target configuration data.
In one embodiment of the invention, the method further comprises:
acquiring full configuration data representing the current configuration condition of the real equipment according to a preset period;
after acquiring the full configuration data each time, comparing the full configuration data with the recorded target configuration data;
and updating the recorded target configuration data based on the comparison result and the full configuration data, and updating the constructed virtual equipment based on the updated target configuration data.
In an embodiment of the present invention, the comparing the target operation data with the recorded target configuration data of the real device includes:
comparing the target operation data with recorded target configuration data of the real equipment based on a first data identifier and a second data identifier, wherein the first data identifier is as follows: the data identifier of each piece of data in the target operation data, where the second data identifier is: data identification of each piece of data contained in the target configuration data;
the updating the recorded target configuration data based on the comparison result and the target operation data comprises:
if the comparison result shows that a third data identifier exists, recording data in the target operation data corresponding to the third data identifier in target configuration data, wherein the third data identifier is: data identifiers contained in the first data identifier and not contained in the second data identifier;
if the comparison result shows that the first data in the target operation data is different from the second data in the target configuration data, updating the second data contained in the target configuration data into the first data, wherein the first data identification corresponding to the first data is the same as the second data identification corresponding to the second data;
and if the target operation data indicate that the data corresponding to the fourth data identifier is deleted in the real equipment, deleting the data corresponding to the fourth data identifier from the target configuration data.
In an embodiment of the present invention, before the comparing the target operation data with the recorded target configuration data of the real device, the method further includes:
and converting the target operation data into a uniform preset format.
In an embodiment of the present invention, the target operation data includes: data operation information representing: the converting the target operation data into a uniform preset format according to the category of the operation executed by the real device includes:
converting the data operation information into data adjustment information in a preset format based on a preset conversion relation, wherein the data adjustment information represents: a category of adjustment of the stored target configuration data by the real world device.
In a second aspect, an embodiment of the present invention provides a virtual device updating apparatus, which is applied to a monitoring device, where the monitoring device includes a virtual device that is constructed based on target configuration data by using a digital twin technology and is used to reflect a configuration situation of a real device, and the apparatus includes:
the log obtaining module is used for obtaining an operation log generated by real equipment in real time, wherein the operation log is as follows: the real device executes the operation on the configuration data, and the operation log records: operation data representing the operation on the configuration data;
the data extraction module is used for extracting target operation data recorded in the operation log after the operation log of the real equipment is obtained each time;
the first data comparison module is used for comparing the target operation data with recorded target configuration data of the real equipment;
and the first data updating module is used for updating the recorded target configuration data based on the comparison result and the target operation data and updating the constructed virtual equipment based on the updated target configuration data.
In one embodiment of the present invention, the apparatus further comprises:
the system comprises a full data acquisition module, a data storage module and a data processing module, wherein the full data acquisition module is used for acquiring full configuration data representing the current configuration condition of the real equipment according to a preset period;
the second data comparison module is used for comparing the full configuration data with the recorded target configuration data after the full configuration data is obtained each time;
and the second data updating module is used for updating the recorded target configuration data based on the comparison result and the full configuration data, and updating the constructed virtual equipment based on the updated target configuration data.
In an embodiment of the present invention, the first data comparing module is specifically configured to:
comparing the target operation data with recorded target configuration data of the real equipment based on a first data identifier and a second data identifier, wherein the first data identifier is as follows: the data identifier of each piece of data in the target operation data, where the second data identifier is: data identification of each piece of data contained in the target configuration data;
the first data updating module is specifically configured to:
if the comparison result shows that a third data identifier exists, recording data in the target operation data corresponding to the third data identifier in target configuration data, and updating the constructed virtual device based on the updated target configuration data, wherein the third data identifier is: data identifications contained in the first data identification and not contained in the second data identification;
if the comparison result shows that the first data in the target operation data is different from the second data in the target configuration data, updating the second data contained in the target configuration data into the first data, and updating the constructed virtual equipment based on the updated target configuration data, wherein a first data identifier corresponding to the first data is the same as a second data identifier corresponding to the second data;
and if the target operation data indicates that the data corresponding to the fourth data identifier is deleted from the real equipment, deleting the data corresponding to the fourth data identifier from the target configuration data, and updating the constructed virtual equipment based on the updated target configuration data.
In one embodiment of the present invention, the apparatus further comprises:
and the format conversion module is used for converting the target operation data into a uniform preset format.
In an embodiment of the present invention, the target operation data includes: data operation information representing: the format conversion module is specifically configured to:
converting the data operation information into data adjustment information in a preset format based on a preset conversion relation, wherein the data adjustment information represents: a category of adjustment made by the real world device to the stored target configuration data.
In a third aspect, an embodiment of the present invention provides an electronic device, including a processor, a communication interface, a memory, and a communication bus, where the processor, the communication interface, and the memory complete mutual communication through the communication bus;
a memory for storing a computer program;
a processor for implementing the method steps of any of the first aspect when executing a program stored in the memory.
In a fourth aspect, an embodiment of the present invention provides a computer-readable storage medium, in which a computer program is stored, and the computer program, when executed by a processor, implements the method steps described in any one of the first aspect.
In a fifth aspect, embodiments of the present invention also provide a computer program product comprising instructions, which when run on a computer, cause the computer to perform the method steps of any of the first aspects described above.
The embodiment of the invention has the following beneficial effects:
the embodiment of the invention provides a virtual device updating method which is applied to monitoring equipment, wherein the monitoring equipment comprises a virtual device which is constructed based on target configuration data and is used for reflecting the configuration condition of real equipment by adopting a digital twinning technology, the equipment for carrying out digital twinning processing continuously acquires an operation log generated by the real equipment, after the operation log of the real equipment is acquired each time, target operation data recorded in the operation log is extracted, the target operation data is compared with the recorded target configuration data of the real equipment, the recorded target configuration data is updated based on the comparison result and the target operation data, and the constructed virtual equipment is updated based on the updated target configuration data.
As can be seen from the above, if an operation on the configuration data is executed during the operation of the real device, an operation log is generated, which includes operation data representing the operation on the configuration data, and the execution of the operation may cause a change in the configuration data of the real device, so that the operation data may represent the change in the configuration data of the real device. Therefore, in the embodiment of the invention, the change condition of the configuration data of the real equipment can be determined through the operation log, so that the recorded target configuration data can be updated. And the operation log generated by the real equipment is acquired in real time, the target configuration data is continuously updated based on the operation log, the updated target configuration data can be matched with the actual configuration condition of the real equipment, the virtual equipment is updated based on the updated target configuration data, and the configuration condition of the virtual equipment and the configuration condition of the real equipment can be kept synchronous.
Furthermore, the operation log obtained in the present embodiment only includes operation data, and the operation data only represents processing performed by the real device with respect to the configuration data, that is, only represents a change situation of the configuration data of the real device, and does not include other configuration data that has not changed. Therefore, the embodiment of the invention can reduce the data quantity of the configuration data which needs to be acquired and processed in the process of carrying out digital twin processing, thereby meeting the real-time requirement of the virtual equipment constructed based on the digital twin technology.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the embodiments or the prior art descriptions will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and other drawings can be obtained by those skilled in the art according to the drawings.
Fig. 1 is a schematic flowchart of a first virtual device updating method according to an embodiment of the present invention;
fig. 2 is a schematic flowchart of a second virtual device updating method according to an embodiment of the present invention;
fig. 3 is a flowchart illustrating a third virtual device updating method according to an embodiment of the present invention;
fig. 4A is a schematic flowchart of a fourth virtual device updating method according to an embodiment of the present invention;
fig. 4B is a schematic diagram illustrating a result of a virtual device update system according to an embodiment of the present invention;
fig. 5 is a schematic structural diagram of a first virtual device updating apparatus according to an embodiment of the present invention;
fig. 6 is a schematic structural diagram of a second virtual device updating apparatus according to an embodiment of the present invention;
fig. 7 is a schematic structural diagram of a third virtual device updating apparatus according to an embodiment of the present invention;
fig. 8 is a schematic structural diagram of an electronic device according to an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived from the embodiments given herein by one of ordinary skill in the art, are within the scope of the invention.
In the prior art, there is a problem that the data size of configuration data to be acquired and processed in the process of performing digital twin processing is high, which results in low efficiency of digital twin processing.
The embodiment of the invention provides a virtual device updating method, which is applied to monitoring devices, wherein the monitoring devices comprise virtual devices which are constructed by adopting a digital twin technology based on target configuration data and are used for reflecting the configuration condition of real devices, and the method comprises the following steps:
acquiring an operation log generated by real equipment in real time, wherein the operation log is as follows: the real device executes an operation on the configuration data, and the operation log records: operation data representing the above-described operation on the configuration data;
extracting target operation data recorded in an operation log after the operation log of the real equipment is acquired each time;
comparing the target operation data with recorded target configuration data of the real equipment;
updating the recorded target configuration data based on the comparison result and the target operation data;
updating the constructed virtual device based on the updated target configuration data.
As can be seen from the above, if an operation on configuration data is performed during the operation of a real device, an operation log is generated, which includes operation data representing the operation on the configuration data, and the execution of the operation may cause a change in the configuration data of the real device, so that the operation data may represent the change in the configuration data of the real device. Therefore, in the embodiment of the invention, the change condition of the configuration data of the real equipment can be determined through the operation log, so that the recorded target configuration data can be updated. And the operation log generated by the real equipment is acquired in real time, the target configuration data is continuously updated based on the operation log, the updated target configuration data can be matched with the actual configuration condition of the real equipment, the virtual equipment is updated based on the updated target configuration data, and the configuration condition of the virtual equipment and the configuration condition of the real equipment can be kept synchronous.
Furthermore, the operation log obtained in this embodiment only includes operation data, and the operation data only represents processing performed by the real device with respect to the configuration data, that is, only includes changed incremental configuration data, and does not include other configuration data that has not changed. Therefore, the embodiment of the invention can reduce the data quantity of the configuration data which needs to be acquired and processed in the process of carrying out digital twin processing, thereby meeting the real-time requirement of the virtual equipment constructed based on the digital twin technology.
First, an execution subject of the embodiment of the present invention is described, where the execution subject of the embodiment is a monitoring device, and is used to perform digital twin processing and construct a virtual device corresponding to a real device. The monitoring device comprises a virtual device which is constructed based on target configuration data by adopting a digital twin technology and is used for reflecting the configuration condition of the real device, and the initial virtual device can be constructed based on the full configuration data after the monitoring device collects the full configuration data of the real device, or constructed based on the configuration data preset by a user. After the virtual device is constructed, the virtual device can be updated by the scheme provided by the embodiment of the invention. The monitoring device can be a server, a computer and other various devices with computing power. The virtual device may be constructed based on the existing digital twin technology, which is not limited in this embodiment.
Referring to fig. 1, a schematic flowchart of a first virtual device updating method according to an embodiment of the present invention is shown, where the method includes the following steps S101 to S104.
S101: and acquiring an operation log generated by the real equipment in real time.
Wherein, the operation log is: the real device executes an operation on the configuration data, and the operation log records: operation data representing the above-described operations on the configuration data.
Specifically, the number of the real devices may be one or more. Each operation log records: operation data indicating an operation performed by the real device with respect to the configuration data in a target time zone, the target time zone being: the real device generates a time period between the time of generating the preamble operation log and the time of generating the operation log, where the preamble operation log is: and according to the generation sequence of each operation log, the operation logs adjacent to the operation log preamble.
Specifically, in the operation process of the real device, if the configuration data of the real device changes due to the operation of the real device by the user or another device, the real device may generate an operation log to record the change, and the operation data recorded in each operation log generated by the real device indicates the time from the time of last generation of the operation log to the time of this generation of the operation log, and the operation performed on the real device by the user or another device may also indicate the change condition of the real device.
For example, if the real device is a network element device such as a routing device, a base station, an exchange, and the like, a user or another device may input an operation instruction for configuration data such as an IP address, a port number, and the like to the real device, so as to indicate operations such as updating, deleting, querying, adding, and the like of the configuration data, and if the user inputs the operation instruction to indicate a port number of a port newly added to the real device, the network element device may generate an operation log to indicate that the real device performs an operation of adding the port number. For another example, if the real device is a computer, and a user or another device may input an operation instruction to query the CPU information of the computer, the computer may generate an operation log to indicate that the real device performs an operation of querying the CPU information.
Specifically, the operation data may include data object information, data content information, and data operation information, where the data object information is used to indicate an operated data object, the data content information is a value of a data object before operation and/or a value of a data object after operation, and the data operation information is used to indicate a type of an operation performed on configuration data by a real device, and the type includes types of modification, deletion, addition, query, and locking.
For example, if the real device is a network element device, and the network element device updates an IP address, the data object information is used to indicate the IP address, and the data content information is: and the data operation information is used for indicating the type of the updating operation.
In another embodiment of the present invention, the real device may be preset, so that after the real device generates the operation log, the generated operation log is actively sent to the monitoring device, instead of sending the full configuration data, so that the real device can obtain the operation log in real time.
The real device can be preset manually by a user, the monitoring device can also send an operation log reporting instruction to the real device, and the real device generates an operation log each time after receiving the operation log reporting instruction and then sends the operation log to the monitoring device.
Specifically, the real device may send the operation log to the monitoring device based on a syslog (system log) mode, an SNMP (Simple Network Management Protocol) mode, or the like.
Or, the monitoring device may also periodically access the real device according to a preset acquisition period, query whether the real device generates a new operation log in a last preset acquisition period, and acquire the operation log if it is determined that the real device generates the new operation log.
In the execution process of the embodiment of the present invention, if the monitoring device does not receive the operation log sent by the real device within the preset time duration, the real device may be accessed to query whether the real device generates a new operation log, and if it is determined that the real device generates a new operation log, the operation log may be obtained.
S102: and extracting target operation data recorded in the operation log after the operation log of the real equipment is acquired each time.
In an embodiment of the present invention, the operation log may be traversed, and the target operation data may be extracted from the operation log. The target operation data may be all or part of data included in the operation log, and the part of data may be data of a part of preset data objects in the operation log. For example, the real device may be a computer, the preset data object may be memory information, the real device may be a network element device, and the preset data object may be an IP address.
Specifically, the target operation data may be extracted from the operation log based on the operation data extraction template. The target operation data can be extracted based on a regular expression matching mode or other matching modes.
The operation data extraction templates corresponding to different real devices are different because the formats of the recorded operation data in the operation logs generated by different real devices are often different. The operation data extraction template may record a separation character for separating each piece of data in the operation log, so as to instruct the monitoring device to extract each piece of data based on the separation character in the process of traversing the operation log. For example, the separator characters may be "/", "and the like.
The operation data extraction template may also record a preset data object corresponding to the target operation data, and the monitoring device may extract data related to the preset data object from the operation log based on the operation data extraction template, as the target operation data.
For example, if the separation character recorded in the operation log generated by the real device is "/", the operation data extraction template may instruct the monitoring device of this embodiment to traverse the operation log, and extract data between every two characters "/", which are respectively used as each piece of data.
In addition, if the real device is a network element device and the preset data object recorded in the operation data extraction template is an IP address, data related to the IP address can be extracted from the operation log based on the operation data extraction template to serve as target operation data.
In an embodiment of the present invention, no matter which real device generates the operation log, the target operation data can be extracted based on the operation data extraction template by traversing the operation log, and the process of extracting the target operation data is similar, and the difference is that the operation data extraction template used is different. Therefore, the working personnel only need to write a set of unified codes and set different operation data extraction templates for different real devices, when the target operation data is extracted, the unified codes are called, and the different operation data extraction templates are configured and loaded, so that the target operation data extraction of different real devices can be realized, the codes for extracting the target operation data can be flexibly multiplexed in different real devices, and the flexible configuration of the target operation data extraction process is realized.
S103: and comparing the target operation data with the recorded target configuration data of the real equipment.
The target configuration data is used for constructing virtual equipment corresponding to the real equipment. The target configuration data may be preset configuration data, may also be obtained by continuously updating stored configuration data based on each acquired operation log, and may also be full configuration data that is acquired and stored by the monitoring device from the real device and represents a current configuration condition of the real device.
Specifically, the monitoring device in the embodiment of the present invention may execute steps S102 to S104 each time the monitoring device acquires the operation log generated by the real device, update the target configuration data based on the target operation data recorded in the operation log, and update the virtual device. Since the target configuration data always matches the configuration data change situation of the real device represented by the operation log generated by the real device, it can be considered that the target configuration data can represent the configuration situation of the real device.
In addition, the target configuration data may be stored in a database.
In an embodiment of the present invention, each piece of data in the target operation data may traverse the target configuration data, and directly compare the piece of data with each piece of data included in the target configuration data, so as to determine whether the target configuration data includes data that is the same as the piece of data, and if the comparison result is that the target configuration data does not include the data, it indicates that the configuration data of the real device has changed, and step S104 needs to be executed to update the target configuration data.
Otherwise, if the comparison result is that the target configuration data includes the piece of data, it indicates that the operation performed by the real device does not change the configuration condition of the real device, for example, the operation may be an operation that does not affect the value of the configuration data, such as query data and lock data. The piece of data is the same as the data contained in the target configuration data and no update is required to the target configuration data.
Specifically, the step S103 can be implemented by the step S103A shown in fig. 3 below, and will not be described in detail here.
S104: and updating the recorded target configuration data based on the comparison result and the target operation data, and updating the constructed virtual equipment based on the updated target configuration data.
Specifically, for each piece of data in the target operation data, if the comparison result indicates that the piece of data is not included in the target operation data, it indicates that the piece of data is newly added to the real device, and the piece of data may be added to the target configuration data.
If the comparison result indicates that the target configuration data includes data that corresponds to the same data object but has a different value from the data object, the data is changed configuration data in real equipment, and the value of the data of the same data object corresponding to the data object included in the target configuration data can be updated to the value of the data.
If the target operation data indicates that the configuration data corresponding to the partial data object is deleted, the data corresponding to the data object is deleted from the target configuration data.
Furthermore, when the target configuration data is stored in the database, data to be added to the target configuration data in the target operation data may be written into the newly added warehousing queue, and then the monitoring device may write the data in the newly added warehousing queue into the database as the target configuration data.
In addition, the data to be deleted from the target configuration data in the target operation data may be written into the deletion warehousing queue, and the monitoring device may delete the data matched with the data included in the deletion warehousing queue in the database, that is, delete the data from the target configuration data.
Furthermore, the data used for updating the target configuration data in the target operation data may be written into the modification warehousing queue, and the monitoring device may modify the data stored in the database based on the data included in the modification warehousing queue, that is, modify the target configuration data.
In an embodiment of the present invention, the target operation data and the target configuration data may be compared based on a data comparison model, where the data comparison model is a specific implementation of a comparison manner between the target operation data and the target configuration data.
In another embodiment of the present invention, in the case where the above step S103 is implemented by the step S103A shown in fig. 3, the above step S104 can be implemented by the steps S104A-S104C shown in fig. 3.
In addition, the established virtual device may be updated in a manner included in the existing digital twin technology, which is not described in detail in this embodiment.
As can be seen from the above, if an operation on the configuration data is executed during the operation of the real device, an operation log is generated, which includes operation data representing the operation on the configuration data, and the execution of the operation may cause a change in the configuration data of the real device, so that the operation data may represent the change in the configuration data of the real device. Therefore, the change condition of the real equipment configuration data can be determined through the operation log in the embodiment of the invention, so that the recorded target configuration data can be updated. And the operation log generated by the real equipment is acquired in real time, the target configuration data is continuously updated based on the operation log, the updated target configuration data can be matched with the actual configuration condition of the real equipment, the virtual equipment is updated based on the updated target configuration data, and the configuration condition of the virtual equipment and the configuration condition of the real equipment can be kept synchronous.
Furthermore, the operation log obtained in the present embodiment only includes operation data, and the operation data only represents processing performed by the real device with respect to the configuration data, that is, only represents a change situation of the configuration data of the real device, and does not include other configuration data that has not changed. Therefore, the embodiment of the invention can reduce the data volume of the configuration data which needs to be acquired and processed in the process of digital twin processing, thereby meeting the real-time requirement of the virtual equipment constructed based on the digital twin technology.
In an embodiment of the present invention, although the real device executes the operation, but the operation may fail, that is, the operation does not change the real device, the real device may also generate an operation log for the failed operation, but the operation log may not be processed in this embodiment.
Specifically, operation result information indicating an operation result may be recorded in the operation log, and if it is determined that the operation result information indicates that the operation has failed after the operation result information included in the operation log is read, the subsequent steps S102 to S104 are not executed again.
In addition, in the process of executing the embodiment of the present invention, failures such as failure in obtaining the operation log, failure in extracting the target operation data, and error in data recorded in the operation log may occur, so that the target configuration data maintained by the embodiment of the present invention is different from the current actual configuration data of the real device. Then, after the virtual device is updated based on the target configuration data, the obtained updated virtual device cannot reflect the configuration condition of the real device. If the fault is not solved, the target configuration data is continuously updated based on the incremental configuration data contained in the operation log, so that the problem of fault accumulation is caused. For this reason, the embodiment of the present invention can be prevented from malfunctioning by the embodiment shown in fig. 2.
Referring to fig. 2, a schematic flow chart of a second virtual device updating method according to an embodiment of the present invention further includes the following steps S105 to S107, compared with the embodiment shown in fig. 1.
S105: and acquiring full configuration data representing the current configuration condition of the real equipment according to a preset period.
Specifically, the total configuration data includes all configuration data of the real device, and may be considered as real-time accurate configuration data of the real device. Compared with the operation log, the data size of the full configuration data is larger, and the occurrence frequency of faults is often lower, so that the preset period can be set to a larger value to reduce the frequency of acquiring the full configuration data by the monitoring equipment. For example, the preset period may be 1 day, 2 days, etc.
The monitoring device may send a full virtual device update request to the real device to request the real device to send the full configuration data to the monitoring device. Or, the real device may be configured to actively send the full configuration data of the real device to the monitoring device according to a preset period, so that the monitoring device obtains the full configuration data.
S106: and after acquiring the full configuration data every time, comparing the full configuration data with the recorded target configuration data.
Specifically, the manner of comparing the full configuration data with the target configuration data is similar to the aforementioned step S103, and is not repeated here.
S107: and updating the recorded target configuration data based on the comparison result and the full configuration data, and updating the constructed virtual equipment based on the updated target configuration data.
Specifically, the method for updating the target configuration data is similar to the aforementioned step S104, and is not repeated here.
As can be seen from the above, in the embodiment of the present invention, the full configuration data of the real device is acquired according to the preset period, the full configuration data is accurate data capable of reflecting the current configuration situation of the real device, the target configuration data is updated based on the full configuration data, so that the target configuration data can reflect the current configuration situation of the real device, and then the virtual device is updated based on the target configuration data, so that the virtual device can be matched with the real device. Therefore, when the virtual equipment is updated based on the incremental data contained in the operation log and has faults, the faults are prevented from being accumulated, and the target configuration data can be matched with the current configuration situation of the real equipment.
Referring to fig. 3, a flowchart of a third virtual device updating method provided in the embodiment of the present invention is shown, and compared with the foregoing embodiment shown in fig. 1, the foregoing step S103 may be implemented by the following step S103A, and the foregoing step S104 may be implemented by the following steps S104A-S104C.
S103A: and comparing the target operation data with the recorded target configuration data of the real equipment based on the first data identification and the second data identification.
Wherein, the first data identifier is: the data identifier of each piece of data in the target operation data, where the second data identifier is: and data identification of each piece of data contained in the target configuration data.
Specifically, the first data identifier may be a set of partial data items in each piece of data included in the target operation data, and the first data identifiers of different pieces of data in the target operation data are different. The second data identifier may be a set of partial data items in each piece of data included in the target configuration data, where the partial data items are the same as the data items that are the first data identifiers, and the second data identifiers of different pieces of data in the target configuration data are different.
In order to keep the target configuration data and the target operation data synchronized, the set of second data identifiers corresponding to each piece of data in the updated target configuration data should include all the first data identifiers, and if the second data identifiers corresponding to the data in the target configuration data are the same as the first data identifiers corresponding to the data in the target operation data, values of the two pieces of data should also be the same. That is, if the above situation is not satisfied, the target configuration data needs to be updated based on the target operation data.
For example, the first data identifier may be a set of data object information and data operation information in each piece of data in the target operation data, and the second data identifier is also a set of data object information and data operation information in each piece of data in the target configuration data.
In an embodiment of the present invention, for each piece of data in the target operation data, based on the first data identifier of the data, the data whose corresponding second data identifier is the first data identifier may be searched from the target configuration data, and whether the searched data is the same as the data in the entry target operation data is compared.
S104A: and if the comparison result shows that the third data identifier exists, recording data in the target operation data corresponding to the third data identifier in the target configuration data, and updating the constructed virtual equipment based on the updated target configuration data.
Wherein the third data identifier is: and a data identifier included in the first data identifier and not included in the second data identifier.
Specifically, if there is a third data identifier, which indicates that the target operation data includes data corresponding to the third data identifier, but the target configuration data does not include the data, that is, the data needs to be added to the target configuration data, the data in the target operation data corresponding to the third data identifier may be recorded in the target configuration data as a part of the target configuration data.
S104B: and if the comparison result shows that the first data in the target operation data is different from the second data in the target configuration data, updating the second data contained in the target configuration data into the first data, and updating the constructed virtual equipment based on the updated target configuration data.
And the first data identifier corresponding to the first data is the same as the second data identifier corresponding to the second data.
Specifically, since the first data identifier corresponding to the first data is the same as the second data identifier corresponding to the second data, theoretically, the second data in the target configuration data is the same as the first data in the target operation data, so that the target configuration data and the target operation data can be kept synchronous. However, in the case that the first data is different from the second data, the second data needs to be updated to the first data, so that the target configuration data and the change situation of the real-world device, which is kept represented by the operation log obtained in real time, are kept synchronous.
S104C: and if the target operation data indicates that the data corresponding to the fourth data identifier is deleted from the real device, deleting the data corresponding to the fourth data identifier from the target configuration data, and updating the constructed virtual device based on the updated target configuration data.
Specifically, if the data operation information in the data corresponding to the fourth data identifier included in the target operation data indicates deletion of the data, it may be determined that the target operation data indicates deletion of the data corresponding to the fourth data identifier in the real device. That is, the data corresponding to the fourth data identifier in the real-world device is deleted in the target time period, and in order to keep the target configuration data synchronized with the target operation data, the data corresponding to the fourth data identifier needs to be deleted in the target configuration data.
As can be seen from the above, in order to keep the target configuration data and the target operation data synchronized, if the first data identifier is the same as the second data identifier, the data included in the target operation data corresponding to the first data identifier and the data included in the target configuration data corresponding to the second data identifier should be the same. If the two are different, it may be determined that the target configuration data needs to be updated, and therefore, based on the embodiment, the target configuration data may be updated based on the first data identifier and the second data identifier.
Referring to fig. 4A, a schematic flow chart of a fourth virtual device updating method according to an embodiment of the present invention further includes, before the step S103, the following step S108, compared with the embodiment shown in fig. 1.
S108: and converting the target operation data into a uniform preset format.
Specifically, because the operation logs generated by different real devices have different formats and the formats of the target operation data extracted from the operation logs are also different, in the case that a plurality of real devices exist, the monitoring device needs to store the target configuration data of the plurality of real devices, and the target configuration data corresponding to different real devices are obtained based on the target operation data of the different real devices, so that the formats of the target configuration data corresponding to different real devices are different, and the pressure of the monitoring device in the data processing process of storing and managing the target configuration data of various different formats is large.
For this purpose, the target operation data may be converted into a unified preset format, where the target operation data may include multiple different data such as data object information, data operation information, and data content, and the preset format may be a format of one or more data therein, that is, format conversion may be performed on one or more data in the target operation data.
In an embodiment of the present invention, format conversion of the target operation data may be performed based on a format conversion model, where the format conversion model is a specific implementation of a format conversion manner, and specifically, the format conversion model may determine, based on a matching tree algorithm or other matching algorithms, data that matches the target operation data that has not undergone format conversion, and use the data as the target operation data after format conversion.
Specifically, in the case where the target operation data includes data operation information, the step S108 may be implemented by the following step a.
The data operation information indicates: the categories of operations performed by the real world devices described above.
Step A: and converting the data operation information into data adjustment information in a preset format based on a preset conversion relation.
Wherein the data adjustment information indicates: the preset conversion mode includes at least one of the following modes (a) - (five).
The method (one): and converting the new operation information into new data information.
Wherein the new operation information indicates: newly adding configuration data in the real device, wherein the information of the newly added data indicates: and adding new data in the target configuration data.
Specifically, since the new operation information indicates new configuration data in the real device, new data needs to be added to the target configuration data in order to keep the recorded target configuration data matched with the actual configuration data of the real device, and thus, the new operation information can be converted into new data information.
The second mode: and converting the deletion operation information into deletion data information or modification data information.
Wherein the deletion operation information indicates: deleting configuration information in the real device, the deletion data information indicating: deleting data in the target configuration data, wherein the modification data information indicates: and modifying the target configuration data.
Specifically, since the deletion operation information indicates deletion of configuration data in the real device, in order to keep the recorded target configuration data matched with the actual configuration data of the real device, it is necessary to delete the data in the target configuration data or modify the data to a null value or the like, and therefore, the deletion operation information may be converted into deletion data information or modification data information.
Mode (iii): and converting the updating operation information into modified data information.
Wherein the update operation information indicates: updating the configuration data in the real world device.
Specifically, since the update operation information indicates that the configuration data in the real device is updated, the target configuration data needs to be modified correspondingly in order to keep the recorded target configuration data matched with the actual configuration data of the real device, and therefore, the update operation information can be converted into modified data information.
Mode (iv): the locking operation information is converted into holding data information.
Wherein the locking operation information indicates: restricting modification of configuration data in the real world device, the retention data information indicating: the target configuration data is not adjusted.
Specifically, the limitation on the modification of the configuration data is to limit the user and other data from operating the configuration data in the real device, and since only the operation on the configuration data of the real device is limited and the configuration data of the real device itself does not change, it is not necessary to adjust the recorded target configuration data accordingly, so that the locking operation information can be converted into the holding data information.
Mode (v): and converting the query operation information into the holding data information.
Wherein the query operation information indicates: and inquiring configuration data in the real equipment.
Specifically, in the process of querying configuration data in real equipment, the configuration data of the real equipment does not change, so that the recorded target configuration data does not need to be adjusted correspondingly, and query operation information can be converted into data holding information.
As can be seen from the above, in the embodiment of the present invention, before comparing the target operation data with the target configuration data, the target operation data may be converted into a uniform preset format, so that format differences of the target operation data generated by different real devices may be eliminated, formats of the target configuration data are kept uniform, and the monitoring device is convenient to use and manage the target configuration data.
In an embodiment of the present invention, the virtual device updating method may be implemented by a virtual device updating system, and refer to fig. 4B, which is a schematic structural diagram of a virtual device updating system according to an embodiment of the present invention.
Specifically, a part enclosed by a dashed box included in fig. 4B is the virtual device update system, the 5G network element device in this embodiment is only an embodiment of a real device, and the real device is not limited in the present invention.
It can be seen from the figure that the system comprises a log acquisition module, a data extraction module, a data conversion module, a data comparison and storage module, a model analysis and adaptation module, a data regular acquisition module and a twin database for storing target configuration data.
The log collection module is used for collecting operation logs from the 5G network element equipment.
The data extraction module is configured to extract target operation data from the operation log, and specifically, the target operation data may be extracted based on a data extraction template included in the model analysis adaptation module.
The data conversion module is configured to perform format conversion on the target operation data extracted by the data extraction module, and specifically, may perform format conversion based on a format conversion model included in the model parsing adaptation module.
The data comparison and storage module is used for comparing the target operation data with the target configuration data, updating the target configuration data stored in the twin database based on the comparison result, and updating the virtual equipment based on the updated target configuration data. Specifically, the data comparison may be performed based on a data comparison model included in the model analysis adaptation module.
The model analysis and adaptation module is used for storing, updating and managing the data extraction template, the format conversion model and the data comparison model and providing the data extraction template, the format conversion model and the data comparison model for other modules to use.
The data regular acquisition module is used for acquiring full configuration data from the 5G network element equipment according to a preset period, and updating target configuration data stored in the twin database after format conversion of the data conversion module is compared with data of the data comparison and storage module.
Corresponding to the foregoing virtual device updating method, an embodiment of the present invention further provides a virtual device updating apparatus.
Referring to fig. 5, a schematic structural diagram of a first virtual device updating apparatus provided in an embodiment of the present invention is applied to a monitoring device, where the monitoring device includes a virtual device that is constructed based on target configuration data by using a digital twin technology and is used for reflecting a configuration situation of a real device, and the apparatus includes the following modules 501 and 504.
A log obtaining module 501, configured to obtain an operation log generated by a real device in real time, where the operation log is: the real device executes the operation on the configuration data, and the operation log records: operation data representing the operation on the configuration data;
a data extraction module 502, configured to extract target operation data recorded in an operation log after the operation log of the real device is obtained each time;
a first data comparison module 503, configured to compare the target operation data with recorded target configuration data of the real device;
a first device updating module 504, configured to update the recorded target configuration data based on the comparison result and the target operation data, and update the constructed virtual device based on the updated target configuration data.
As can be seen from the above, if an operation on the configuration data is executed during the operation of the real device, an operation log is generated, which includes operation data representing the operation on the configuration data, and the execution of the operation may cause a change in the configuration data of the real device, so that the operation data may represent the change in the configuration data of the real device. Therefore, the change condition of the real equipment configuration data can be determined through the operation log in the embodiment of the invention, so that the recorded target configuration data can be updated. And the operation log generated by the real equipment is acquired in real time, the target configuration data is continuously updated based on the operation log, the updated target configuration data can be matched with the actual configuration condition of the real equipment, the virtual equipment is updated based on the updated target configuration data, and the configuration condition of the virtual equipment and the configuration condition of the real equipment can be kept synchronous.
Furthermore, the operation log obtained in the present embodiment only includes operation data, and the operation data only represents processing performed by the real device with respect to the configuration data, that is, only represents a change situation of the configuration data of the real device, and does not include other configuration data that has not changed. Therefore, the embodiment of the invention can reduce the data volume of the configuration data which needs to be acquired and processed in the process of digital twin processing, thereby meeting the real-time requirement of the virtual equipment constructed based on the digital twin technology.
Referring to fig. 6, a schematic structural diagram of a second virtual device updating apparatus according to an embodiment of the present invention is shown, and compared with the embodiment shown in fig. 5, the apparatus further includes the following modules 505 and 507.
A total data obtaining module 505, configured to obtain total configuration data representing a current configuration situation of the real device according to a preset period;
a second data comparison module 506, configured to compare the full configuration data with the recorded target configuration data after the full configuration data is obtained each time;
the second device updating module 507 is configured to update the recorded target configuration data based on the comparison result and the full configuration data, and update the constructed virtual device based on the updated target configuration data.
As can be seen from the above, in the embodiment of the present invention, the full configuration data of the real device is collected according to the preset period, the full configuration data is accurate data capable of reflecting the current configuration situation of the real device, the target configuration data is updated based on the full configuration data, so that the target configuration data can reflect the current configuration situation of the real device, and then the virtual device is updated based on the target configuration data, so that the virtual device can be matched with the real device. Therefore, when the virtual equipment is updated based on the incremental data contained in the operation log and faults occur, fault accumulation is prevented, and the target configuration data can be matched with the current configuration condition of the real equipment.
In an embodiment of the present invention, the first data comparing module 503 is specifically configured to:
comparing the target operation data with recorded target configuration data of the real equipment based on a first data identifier and a second data identifier, wherein the first data identifier is as follows: the data identifier of each piece of data in the target operation data, where the second data identifier is: data identification of each piece of data contained in the target configuration data;
the first device update module 504 is specifically configured to:
if the comparison result shows that a third data identifier exists, recording data in the target operation data corresponding to the third data identifier in target configuration data, and updating the constructed virtual device based on the updated target configuration data, wherein the third data identifier is: data identifiers contained in the first data identifier and not contained in the second data identifier;
if the comparison result shows that the first data in the target operation data is different from the second data in the target configuration data, updating the second data contained in the target configuration data into the first data, and updating the constructed virtual equipment based on the updated target configuration data, wherein a first data identifier corresponding to the first data is the same as a second data identifier corresponding to the second data;
and if the target operation data indicates that the data corresponding to the fourth data identifier is deleted from the real equipment, deleting the data corresponding to the fourth data identifier from the target configuration data, and updating the constructed virtual equipment based on the updated target configuration data.
As can be seen from the above, in order to keep the target configuration data and the target operation data synchronized, if the first data identifier is the same as the second data identifier, the data included in the target operation data corresponding to the first data identifier and the data included in the target configuration data corresponding to the second data identifier should be the same. If the first data identifier and the second data identifier are different, it may be determined that the target configuration data needs to be updated, and therefore the target configuration data may be updated based on the first data identifier and the second data identifier based on the embodiment.
Referring to fig. 7, a schematic structural diagram of a third virtual device updating apparatus according to an embodiment of the present invention is shown, and compared with the implementation shown in fig. 5, the apparatus further includes:
a format conversion module 508, configured to convert the target operation data into a unified preset format.
In an embodiment of the present invention, the target operation data includes: data operation information representing: the format conversion module 508 is specifically configured to:
converting the data operation information into data adjustment information in a preset format based on a preset conversion relation, wherein the data adjustment information represents: a category of adjustment of the stored target configuration data by the real world device.
As can be seen from the above, in the embodiment of the present invention, before comparing the target operation data with the target configuration data, the target operation data may be converted into a unified preset format, so that format differences of the target operation data generated by different real devices may be eliminated, formats of the target configuration data are kept unified, and the monitoring device is convenient to use and manage the target configuration data.
An embodiment of the present invention further provides an electronic device, as shown in fig. 8, which includes a processor 801, a communication interface 802, a memory 803, and a communication bus 804, where the processor 801, the communication interface 802, and the memory 803 complete mutual communication through the communication bus 804,
a memory 803 for storing a computer program;
the processor 801 is configured to implement the method steps of any one of the virtual device update methods described above when executing the program stored in the memory 803.
When the electronic device provided by the embodiment of the present invention is applied to update a virtual device, if an operation on configuration data is executed in an operation process of a real device, an operation log may be generated, where the operation log includes operation data representing the operation on the configuration data, and the execution of the operation may cause a change in the configuration data of the real device, so that the operation data may represent a change in the configuration data of the real device. Therefore, the change condition of the real equipment configuration data can be determined through the operation log in the embodiment of the invention, so that the recorded target configuration data can be updated. And the operation log generated by the real equipment is acquired in real time, the target configuration data is continuously updated based on the operation log, the updated target configuration data can be matched with the actual configuration condition of the real equipment, the virtual equipment is updated based on the updated target configuration data, and the configuration condition of the virtual equipment and the configuration condition of the real equipment can be kept synchronous.
Furthermore, the operation log obtained in the present embodiment only includes operation data, and the operation data only represents processing performed by the real device with respect to the configuration data, that is, only represents a change situation of the configuration data of the real device, and does not include other configuration data that has not changed. Therefore, the embodiment of the invention can reduce the data quantity of the configuration data which needs to be acquired and processed in the process of carrying out digital twin processing, thereby meeting the real-time requirement of the virtual equipment constructed based on the digital twin technology.
The communication bus mentioned in the electronic device may be a Peripheral Component Interconnect (PCI) bus, an Extended Industry Standard Architecture (EISA) bus, or the like. The communication bus may be divided into an address bus, a data bus, a control bus, etc. For ease of illustration, only one thick line is shown, but this is not intended to represent only one bus or type of bus.
The communication interface is used for communication between the electronic equipment and other equipment.
The Memory may include a Random Access Memory (RAM) or a Non-Volatile Memory (NVM), such as at least one disk Memory. Optionally, the memory may also be at least one memory device located remotely from the processor.
The Processor may be a general-purpose Processor, including a Central Processing Unit (CPU), a Network Processor (NP), and the like; but also Digital Signal Processors (DSPs), Application Specific Integrated Circuits (ASICs), Field Programmable Gate Arrays (FPGAs) or other Programmable logic devices, discrete Gate or transistor logic devices, discrete hardware components.
In another embodiment of the present invention, a computer-readable storage medium is further provided, where a computer program is stored in the computer-readable storage medium, and when the computer program is executed by a processor, the computer program implements the steps of any one of the virtual device updating methods described above.
When the computer program stored in the computer-readable storage medium provided by the embodiment of the present invention is executed to update the virtual device, if the real device executes an operation on the configuration data during the operation process, an operation log is generated, where the operation log includes operation data indicating the operation on the configuration data, and the execution of the operation may cause a change in the configuration data of the real device, so that the operation data may reflect the change in the configuration data of the real device. Therefore, in the embodiment of the invention, the change condition of the configuration data of the real equipment can be determined through the operation log, so that the recorded target configuration data can be updated. And the operation log generated by the real equipment is acquired in real time, the target configuration data is continuously updated based on the operation log, the updated target configuration data can be matched with the actual configuration condition of the real equipment, the virtual equipment is updated based on the updated target configuration data, and the configuration condition of the virtual equipment and the configuration condition of the real equipment can be kept synchronous.
Furthermore, the operation log obtained in the present embodiment only includes operation data, and the operation data only represents processing performed by the real device with respect to the configuration data, that is, only represents a change situation of the configuration data of the real device, and does not include other configuration data that has not changed. Therefore, the embodiment of the invention can reduce the data quantity of the configuration data which needs to be acquired and processed in the process of carrying out digital twin processing, thereby meeting the real-time requirement of the virtual equipment constructed based on the digital twin technology.
In a further embodiment of the present invention, there is also provided a computer program product comprising instructions which, when run on a computer, cause the computer to perform the method steps of any of the virtual device update methods described in the previous embodiments.
When the computer program provided by the embodiment of the present invention is executed to update the virtual device, if the real device executes an operation on the configuration data during the running process, an operation log is generated, where the operation log includes operation data representing the operation on the configuration data, and the execution of the operation may cause a change in the configuration data of the real device, so that the operation data may represent a change in the configuration data of the real device. Therefore, the change condition of the real equipment configuration data can be determined through the operation log in the embodiment of the invention, so that the recorded target configuration data can be updated. And the operation log generated by the real equipment is acquired in real time, the target configuration data is continuously updated based on the operation log, the updated target configuration data can be matched with the actual configuration condition of the real equipment, the virtual equipment is updated based on the updated target configuration data, and the configuration condition of the virtual equipment and the configuration condition of the real equipment can be kept synchronous.
Furthermore, the operation log obtained in the present embodiment only includes operation data, and the operation data only represents processing performed by the real device with respect to the configuration data, that is, only represents a change situation of the configuration data of the real device, and does not include other configuration data that has not changed. Therefore, the embodiment of the invention can reduce the data quantity of the configuration data which needs to be acquired and processed in the process of carrying out digital twin processing, thereby meeting the real-time requirement of the virtual equipment constructed based on the digital twin technology.
In the above embodiments, the implementation may be wholly or partially realized by software, hardware, firmware, or any combination thereof. When implemented in software, it may be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When loaded and executed on a computer, cause the processes or functions described in accordance with the embodiments of the invention to be performed in whole or in part. The computer may be a general purpose computer, a special purpose computer, a network of computers, or other programmable device. The computer instructions may be stored in a computer readable storage medium or transmitted from one computer readable storage medium to another, for example, from one website site, computer, server, or data center to another website site, computer, server, or data center via wired (e.g., coaxial cable, fiber optic, Digital Subscriber Line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.). The computer-readable storage medium can be any available medium that can be accessed by a computer or a data storage device, such as a server, a data center, etc., that includes one or more available media. The usable medium may be a magnetic medium (e.g., floppy Disk, hard Disk, magnetic tape), an optical medium (e.g., DVD), or a semiconductor medium (e.g., Solid State Disk (SSD)), among others.
It should be noted that, in this document, relational terms such as first and second, and the like are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
All the embodiments in the present specification are described in a related manner, and the same and similar parts among the embodiments may be referred to each other, and each embodiment focuses on the differences from the other embodiments. In particular, for the apparatus, the electronic device, the storage medium, and the computer program product embodiment, since they are substantially similar to the method embodiment, the description is relatively simple, and reference may be made to the partial description of the method embodiment for relevant points.
The above description is only for the preferred embodiment of the present invention, and is not intended to limit the scope of the present invention. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention shall fall within the protection scope of the present invention.

Claims (12)

1. A virtual device updating method is applied to a monitoring device, wherein the monitoring device comprises a virtual device which is constructed based on target configuration data by adopting a digital twin technology and is used for reflecting the configuration situation of a real device, and the method comprises the following steps:
acquiring an operation log generated by real equipment in real time, wherein the operation log is as follows: the real device executes the operation on the configuration data, and the operation log records: operation data representing the operation on the configuration data;
after an operation log of the real equipment is obtained each time, extracting target operation data recorded in the operation log;
comparing the target operation data with recorded target configuration data of the real equipment;
and updating the recorded target configuration data based on the comparison result and the target operation data, and updating the constructed virtual equipment based on the updated target configuration data.
2. The method of claim 1, further comprising:
acquiring full configuration data representing the current configuration condition of the real equipment according to a preset period;
after acquiring the full configuration data each time, comparing the full configuration data with the recorded target configuration data;
and updating the recorded target configuration data based on the comparison result and the full configuration data, and updating the constructed virtual equipment based on the updated target configuration data.
3. The method of claim 1, wherein the comparing the target operational data with the recorded target configuration data of the real world device comprises:
comparing the target operation data with recorded target configuration data of the real equipment based on a first data identifier and a second data identifier, wherein the first data identifier is as follows: the data identifier of each piece of data in the target operation data, where the second data identifier is: data identification of each piece of data contained in the target configuration data;
updating the recorded target configuration data based on the comparison result and the target operation data, including:
if the comparison result shows that a third data identifier exists, recording data in the target operation data corresponding to the third data identifier in target configuration data, wherein the third data identifier is: data identifications contained in the first data identification and not contained in the second data identification;
if the comparison result is that first data in the target operation data are different from second data in the target configuration data, updating the second data contained in the target configuration data into the first data, wherein a first data identifier corresponding to the first data is the same as a second data identifier corresponding to the second data;
and if the target operation data indicates that the data corresponding to the fourth data identifier is deleted in the real equipment, deleting the data corresponding to the fourth data identifier from the target configuration data.
4. The method according to any one of claims 1-3, further comprising, prior to the comparing the target operational data with the recorded target configuration data of the real world device:
and converting the target operation data into a uniform preset format.
5. The method of claim 4, wherein the target operation data comprises: data operation information representing: the converting the target operation data into a unified preset format according to the category of the operation executed by the real device includes:
converting the data operation information into data adjustment information in a preset format based on a preset conversion relation, wherein the data adjustment information represents: a category of adjustment of the stored target configuration data by the real world device.
6. A virtual device updating device is applied to monitoring equipment, wherein the monitoring equipment comprises virtual devices which are constructed based on target configuration data by adopting a digital twin technology and are used for reflecting the configuration situation of real equipment, and the device comprises:
the log obtaining module is used for obtaining an operation log generated by real equipment in real time, wherein the operation log is as follows: the real device executes the operation on the configuration data, and the operation log records: operation data representing the operation on the configuration data;
the data extraction module is used for extracting target operation data recorded in the operation log after the operation log of the real equipment is obtained each time;
the first data comparison module is used for comparing the target operation data with recorded target configuration data of the real equipment;
and the first data updating module is used for updating the recorded target configuration data based on the comparison result and the target operation data and updating the constructed virtual equipment based on the updated target configuration data.
7. The apparatus of claim 6, further comprising:
the system comprises a full data acquisition module, a data processing module and a data processing module, wherein the full data acquisition module is used for acquiring full configuration data representing the current configuration condition of the real equipment according to a preset period;
the second data comparison module is used for comparing the full configuration data with the recorded target configuration data after the full configuration data is obtained each time;
and the second data updating module is used for updating the recorded target configuration data based on the comparison result and the full configuration data, and updating the constructed virtual equipment based on the updated target configuration data.
8. The apparatus of claim 6, wherein the first data comparison module is specifically configured to:
comparing the target operation data with recorded target configuration data of the real equipment based on a first data identifier and a second data identifier, wherein the first data identifier is as follows: the data identifier of each piece of data in the target operation data, where the second data identifier is: data identification of each piece of data contained in the target configuration data;
the first data updating module is specifically configured to:
if the comparison result shows that a third data identifier exists, recording data in the target operation data corresponding to the third data identifier in target configuration data, and updating the constructed virtual device based on the updated target configuration data, wherein the third data identifier is: data identifications contained in the first data identification and not contained in the second data identification;
if the comparison result shows that the first data in the target operation data is different from the second data in the target configuration data, updating the second data contained in the target configuration data into the first data, and updating the constructed virtual equipment based on the updated target configuration data, wherein a first data identifier corresponding to the first data is the same as a second data identifier corresponding to the second data;
and if the target operation data indicates that the data corresponding to the fourth data identifier is deleted from the real equipment, deleting the data corresponding to the fourth data identifier from the target configuration data, and updating the constructed virtual equipment based on the updated target configuration data.
9. The apparatus according to any one of claims 6-8, further comprising:
and the format conversion module is used for converting the target operation data into a uniform preset format.
10. The apparatus of claim 9, wherein the target operation data comprises: data operation information representing: the format conversion module is specifically configured to:
converting the data operation information into data adjustment information in a preset format based on a preset conversion relation, wherein the data adjustment information represents: a category of adjustment made by the real world device to the stored target configuration data.
11. The electronic equipment is characterized by comprising a processor, a communication interface, a memory and a communication bus, wherein the processor and the communication interface are used for realizing the communication between the processor and the memory through the communication bus;
a memory for storing a computer program;
a processor for implementing the method steps of any one of claims 1 to 5 when executing a program stored in the memory.
12. A computer-readable storage medium, characterized in that a computer program is stored in the computer-readable storage medium, which computer program, when being executed by a processor, carries out the method steps of any one of the claims 1-5.
CN202210435719.2A 2022-04-24 2022-04-24 Virtual equipment updating method and device Pending CN114780118A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210435719.2A CN114780118A (en) 2022-04-24 2022-04-24 Virtual equipment updating method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210435719.2A CN114780118A (en) 2022-04-24 2022-04-24 Virtual equipment updating method and device

Publications (1)

Publication Number Publication Date
CN114780118A true CN114780118A (en) 2022-07-22

Family

ID=82433197

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210435719.2A Pending CN114780118A (en) 2022-04-24 2022-04-24 Virtual equipment updating method and device

Country Status (1)

Country Link
CN (1) CN114780118A (en)

Similar Documents

Publication Publication Date Title
US7849227B2 (en) Stream data processing method and computer systems
US10891297B2 (en) Method and system for implementing collection-wise processing in a log analytics system
US9262248B2 (en) Log configuration of distributed applications
US20110191394A1 (en) Method of processing log files in an information system, and log file processing system
US9311175B2 (en) Method and system for processing log information
US20100088197A1 (en) Systems and methods for generating remote system inventory capable of differential update reports
JP6996812B2 (en) How to process data blocks in a distributed database, programs, and devices
US10769104B2 (en) Block data storage system in an event historian
CN111061498B (en) Configuration information management system
CN112711520A (en) Method, device and equipment for processing abnormal log information and storage medium
CN109308290B (en) Efficient data cleaning and converting method based on CIM
CN111627552A (en) Medical streaming data blood relationship analysis and storage method and device
CN113704790A (en) Abnormal log information summarizing method and computer equipment
CN114201540A (en) Industrial multi-source data acquisition and storage system
CN110109906B (en) Data storage system and method
CN117251414B (en) Data storage and processing method based on heterogeneous technology
CN113535677A (en) Data analysis query management method and device, computer equipment and storage medium
KR101171551B1 (en) Event history memory device, event history tracking device, event history memory method, computer-readable recording medium recording event history memory program and computer-readable recording medium recording data structure
CN110309206B (en) Order information acquisition method and system
CN112612802A (en) Real-time data middlebox processing method, device and platform
CN114780118A (en) Virtual equipment updating method and device
CN106202585B (en) The more scene Multi-state data systems of electric power and management method
JP2003316811A (en) Inquiry optimization processing device in different kind of database integration system, method and program making computer execute the method
CN114039965B (en) High-speed data acquisition system and method based on edge computing technology
CN113609162B (en) Query method and device for operation records, server and storage medium

Legal Events

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