CN114661231A - Storage synchronization method and device for parameter change records of power grid monitoring master station system - Google Patents

Storage synchronization method and device for parameter change records of power grid monitoring master station system Download PDF

Info

Publication number
CN114661231A
CN114661231A CN202210151351.7A CN202210151351A CN114661231A CN 114661231 A CN114661231 A CN 114661231A CN 202210151351 A CN202210151351 A CN 202210151351A CN 114661231 A CN114661231 A CN 114661231A
Authority
CN
China
Prior art keywords
block
information
parameter change
hash value
equipment
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.)
Granted
Application number
CN202210151351.7A
Other languages
Chinese (zh)
Other versions
CN114661231B (en
Inventor
刘德贺
江伟
张高峰
马光
解凯
胡荣
张喜铭
方文崇
梁寿愚
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China Southern Power Grid Co Ltd
NR Electric Co Ltd
NR Engineering Co Ltd
Original Assignee
China Southern Power Grid Co Ltd
NR Electric Co Ltd
NR Engineering Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by China Southern Power Grid Co Ltd, NR Electric Co Ltd, NR Engineering Co Ltd filed Critical China Southern Power Grid Co Ltd
Priority to CN202210151351.7A priority Critical patent/CN114661231B/en
Publication of CN114661231A publication Critical patent/CN114661231A/en
Application granted granted Critical
Publication of CN114661231B publication Critical patent/CN114661231B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/0614Improving the reliability of storage systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/22Indexing; Data structures therefor; Storage structures
    • G06F16/2228Indexing structures
    • G06F16/2246Trees, e.g. B+trees
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/22Indexing; Data structures therefor; Storage structures
    • G06F16/2228Indexing structures
    • G06F16/2255Hash tables
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/23Updating
    • G06F16/2365Ensuring data consistency and integrity
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/27Replication, distribution or synchronisation of data between databases or within a distributed database system; Distributed database system architectures therefor
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0629Configuration or reconfiguration of storage systems
    • G06F3/0637Permissions
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0668Interfaces specially adapted for storage systems adopting a particular infrastructure
    • G06F3/067Distributed or networked storage systems, e.g. storage area networks [SAN], network attached storage [NAS]
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y04INFORMATION OR COMMUNICATION TECHNOLOGIES HAVING AN IMPACT ON OTHER TECHNOLOGY AREAS
    • Y04SSYSTEMS INTEGRATING TECHNOLOGIES RELATED TO POWER NETWORK OPERATION, COMMUNICATION OR INFORMATION TECHNOLOGIES FOR IMPROVING THE ELECTRICAL POWER GENERATION, TRANSMISSION, DISTRIBUTION, MANAGEMENT OR USAGE, i.e. SMART GRIDS
    • Y04S10/00Systems supporting electrical power generation, transmission or distribution
    • Y04S10/50Systems or methods supporting the power network operation or management, involving a certain degree of interaction with the load-side end user applications

Abstract

The invention discloses a storage synchronization method and a device for parameter change records of a power grid monitoring master station system, wherein the method comprises the following steps: receiving parameter change information of equipment operation sent by a client; analyzing the parameter change information to obtain a client user mark, and checking whether the user has the authority of modifying and setting the equipment parameters; after the user is confirmed to be qualified, identifying parameter change information, calculating hash values aiming at each group of change information, further calculating new hash values for the hash values of two adjacent groups, and finally calculating a root hash value of a binary tree according to a binary tree mode; taking the calculated root hash value as a part of the information of the block header; the service node N which completes the block head assembly broadcasts the whole block information, and after other service nodes receive the information, the validity of the block is verified; the invention solves the problem that data can not be updated in case of failure in centralized operation parameter change service of the power grid monitoring master station system.

Description

Storage synchronization method and device for parameter change records of power grid monitoring master station system
Technical Field
The invention relates to a storage synchronization method and a storage synchronization device for parameter change records of a power grid monitoring master station system, and belongs to the technical field of distributed power grid monitoring master station systems.
Background
In recent years, with the rapid development of information technologies such as cloud computing and block chaining, a system server of a power grid monitoring master station is gradually deployed in a distributed multi-node cluster mode, and meanwhile, operation monitoring personnel interact with the monitoring master station server through a client, wherein interactive data content comprises inquiry monitoring data, control equipment state, setting equipment operation parameters and the like. The setting and changing of the operation parameters relate to safe and stable operation of a power grid of a power system, and the consistency of storage and synchronization of the operation parameters of the power grid is guaranteed. The existing storage and synchronization method for operating parameter change generally adopts a centralized type, namely after a client initiates operating parameter change setting, a server receives a parameter setting request through a duty node, then matches and updates operating parameters in a unified model database of an outgoing network according to equipment codes in request information, and then completes parameter change records in the whole system synchronization depending on the synchronization of the unified model database.
The power grid monitoring master station system has the following defects by adopting centralized receiving and updating operation parameter change: (1) and when the main station service end duty node fails, the equipment parameter change request of the client cannot be received, and the operation parameter setting change fails. (2) The shift node has a switching condition, and when the shift node is switched from one node to another node, if the client initiates a request at the moment, the request may be discarded.
Disclosure of Invention
The invention aims to overcome the defects in the prior art, provides a storage and synchronization method and a storage and synchronization device for parameter change records of a power grid monitoring master station system, and overcomes the defects that the operation parameter change of power grid equipment fails or the operation parameter change request of the equipment is discarded due to centralized updating and synchronization in the prior art.
In order to achieve the purpose, the invention adopts the following technical scheme:
in a first aspect, the present invention provides a method for storing and synchronizing change records of system parameters of a power grid monitoring master station, which is applied to a service node of a power grid monitoring master station, and includes:
receiving parameter change information of equipment operation sent by a client; the client is used for receiving a request for initiating equipment operation parameter change by a user and organizing parameter change information;
analyzing the parameter change information to obtain a client user mark, checking the existence of a user according to a permission database, and checking whether the user has the permission for modifying and setting the equipment parameters;
after the user is confirmed to be qualified, identifying parameter change information, calculating hash values aiming at each group of change information, further calculating new hash values for the hash values of two adjacent groups, and finally calculating a root hash value of a binary tree according to a binary tree mode;
taking the calculated root hash value as a part of information of a block header, wherein the block header comprises a user mark, request time, a father block hash value, a random number and workload certification information;
the service node N which completes block head assembly broadcasts the whole block information, after other service nodes receive the block information, the validity of the block is verified, and if the block is valid, the block is added into a local latest block chain; and changing parameters in the local equipment library according to the parameter change record information in the block, replying confirmation information to the sending node N after the change is completed, and updating the change of the parameters in the local equipment library after the node N receives more than half of the node confirmation.
Further, the parameter change information includes: user identification, request time, unique equipment code, equipment parameter name, parameter value before equipment change and complete request information of the parameter value after equipment change.
Furthermore, the complete request information includes one or more groups of operation time, unique codes of the equipment, parameter names of the equipment, and change records of parameters before and after the equipment is changed.
Furthermore, any two service nodes in the power grid monitoring master station system can synchronize the parameter change record block chain, and the synchronization mode is divided into two conditions:
(3) if the two node parameter change block chains have different lengths and the long chain comprises a short chain, comparing the lengths of the local block chains of the two service nodes, and automatically synchronizing the block from the node with the block chain length to the node with the short block chain;
(4) if two node parameter change block chains are forked, namely, a part of parent blocks in the two block chains are the same, starting from the differential block with the first forked, two nodes broadcast differential block synchronization requests, and a block with more than half recovery confirmation is considered as a valid block, and the other invalid block is automatically synchronized by the valid block.
Further, the calculating hash values for each group of change information, further calculating new hash values for the hash values of two adjacent groups, and finally calculating a root hash value of a binary tree according to a binary tree mode includes:
adopting SHA256 hash algorithm for each group of change, generating hash value with fixed 256 bit length for each group of change information, and forming a leaf layer L1 of the binary tree;
inputting SHA256 hash algorithm to calculate a new hash value according to two adjacent hash values, copying one hash value if a single hash value exists, and inputting the hash algorithm to calculate the new hash value, thereby forming a second layer L2 of the binary tree;
and analogizing to finally calculate the root hash value of the highest layer of the binary tree.
Further, the method for acquiring the workload certification information includes:
calculating primary state estimation according to a data section of the request time and by combining a power grid structure of an equipment model base by adopting a state estimation calculation method special for a power grid monitoring master station;
taking the power value of the position corresponding to the random number in the circuit table in the calculation result as workload certification information; if the random number is greater than the number of the line equipment, performing modulo calculation on the number of the line equipment to obtain an integer less than the number of the line equipment, and then acquiring the power value of the position corresponding to the value in the line table.
Further, the service node N that completes block header assembly broadcasts the entire block information, and after other service nodes receive the block information, verifies the validity of the block, and if the block is valid, adds the block to the local latest block chain, including:
after the assembled service node issues the block information, other service nodes calculate a root hash value according to the received change record information in the block body, and compare the root hash value with the root hash value in the block header information to verify the validity of the parameter change information;
acquiring a data section according to the request time in the block head, calculating a state estimation value by combining a power grid structure of an equipment model library, further acquiring a numerical value in a random number position of a corresponding line table according to a random number in the block head, comparing the numerical value with workload certification information in the block head, and if the numerical values are consistent, considering that the workload certification is effective;
and comparing the hash value of the parent block in the block head with the hash value of the local parent block, if the hash value of the parent block in the block head is consistent with the hash value of the local parent block, linking the parameter change block received this time with the local block, and simultaneously replying confirmation information to a sending node assembled by the blocks.
In a second aspect, the present invention provides a storage synchronization device for a parameter change record of a power grid monitoring master station system, which is applied to a service node of a power grid monitoring master station, and includes:
a parameter change information receiving unit, configured to receive parameter change information of device operation sent by a client; the client is used for receiving a request for initiating equipment operation parameter change by a user and organizing parameter change information;
the parameter change information analysis and verification unit is used for analyzing the parameter change information, analyzing the client user mark, checking the existence of the user according to the permission database, and verifying whether the user has the permission for modifying and setting the equipment parameters;
the parameter change information identification unit is used for identifying the parameter change information after confirming that the user is qualified, calculating a hash value aiming at each group of change information, further calculating a new hash value for the hash values of two adjacent groups, and finally calculating a root hash value of a binary tree according to a binary tree mode;
the input unit is used for taking the calculated root hash value as a part of information of a block header, wherein the block header comprises a user mark, request time, a father block hash value, a random number and workload certification information;
the updating unit is used for completing the service node N assembled by the block head, broadcasting the whole block information, verifying the validity of the block after other service nodes receive the block information, and adding the block information into a local latest block chain if the block is valid; and changing parameters in the local equipment library according to the parameter change record information in the block, replying confirmation information to the sending node N after the change is completed, and updating the change of the parameters in the local equipment library after the node N receives more than half of the node confirmation.
In a third aspect, the invention provides a storage synchronization device for parameter change records of a power grid monitoring master station system, which comprises a processor and a storage medium;
the storage medium is used for storing instructions;
the processor is configured to operate in accordance with the instructions to perform the steps of the method according to any one of the preceding claims.
In a fourth aspect, the invention provides a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, performs the steps of the method of any one of the preceding claims.
Compared with the prior art, the invention has the following beneficial effects:
compared with the prior art, the storage synchronization method and the storage synchronization device for the parameter change records of the power grid monitoring master station system solve the problem that data cannot be updated during failure due to centralized operation parameter change service of the power grid monitoring master station system, avoid discarding operation parameter change requests during the switching process of on-duty nodes, and improve the reliability of operation parameter storage of the power grid monitoring master station system service end system. Meanwhile, the consistency of the operation parameters of the power grid system is ensured by the point-to-point synchronization method of the operation parameters of different nodes.
Drawings
FIG. 1 is a flow chart of a method of storing a parameter change record according to the present invention;
FIG. 2 is a diagram illustrating an example of a computation process for changing root hashes in the present invention;
FIG. 3 is a block diagram of a change log of the present invention;
FIG. 4 is a diagram illustrating an example of changing the recording block chain length difference synchronization in the present invention;
FIG. 5 is a diagram of an example of modified record blockchain conflict synchronization in the present invention.
Detailed Description
The invention is further described below with reference to the accompanying drawings. The following examples are only for illustrating the technical solutions of the present invention more clearly, and the protection scope of the present invention is not limited thereby.
Example 1
The embodiment introduces a storage synchronization method and a storage synchronization device for parameter change records of a power grid monitoring master station system, and the method comprises the following steps:
be applied to electric wire netting control master station end service node, include:
receiving parameter change information of equipment operation sent by a client; the client is used for receiving a request for initiating equipment operation parameter change by a user and organizing parameter change information;
analyzing the parameter change information to obtain a client user mark, checking the existence of a user according to a permission database, and checking whether the user has the permission for modifying and setting the equipment parameters;
after the user is confirmed to be qualified, identifying parameter change information, calculating hash values aiming at each group of change information, further calculating new hash values for the hash values of two adjacent groups, and finally calculating a root hash value of a binary tree according to a binary tree mode;
taking the calculated root hash value as a part of information of a block header, wherein the block header comprises a user mark, request time, a father block hash value, a random number and workload certification information;
the service node N which completes block head assembly broadcasts the whole block information, after other service nodes receive the block information, the validity of the block is verified, and if the block is valid, the block is added into a local latest block chain; and changing parameters in the local equipment library according to the parameter change record information in the block, replying confirmation information to the sending node N after the change is completed, and updating the change of the parameters in the local equipment library after the node N receives more than half of the node confirmation.
In the method for storing and synchronizing the system parameter change records of the power grid monitoring master station, the device operation parameter change records are stored in a block mode, and the device operation parameter changes are organized in a block mode and stored in a block chain mode in a distributed power grid monitoring master station server. The storage process of the parameter change record is shown in fig. 1, and the application process specifically involves the following steps:
step 1, a client user initiates an equipment operation parameter change request, and organizes complete request information including user identification, request time, an equipment unique code, an equipment parameter name, a parameter before equipment change and a parameter after equipment change, wherein the request information can include one or more groups of parameter change records consisting of operation time, an equipment unique code, an equipment parameter name, a parameter before equipment change and a parameter after equipment change. And the client broadcasts the organized request information to each service node of the power grid monitoring master station.
Step 2, after each service node of the power grid monitoring master station receives a request of the client, firstly analyzing a user mark of the client, checking the existence of the user according to the permission database, and checking whether the user has the permission of modifying and changing the equipment parameters.
And 3, after the service node of the master station side confirms that the parameter change request user is qualified, further identifying change information such as each group of operation time, unique equipment code, equipment parameter name, parameters before equipment change, parameters after equipment change and the like, calculating hash values aiming at each group of change information, further calculating new hash values for the hash values of two adjacent groups, calculating the hash values layer by layer according to a binary tree mode, and finally calculating a root hash value of a binary tree. The process of specifically calculating the root hash value is shown in fig. 2: firstly, an SHA256 hash algorithm is adopted for each change record (the hash algorithm is a method for creating small digital codes from any kind of data, wherein the SHA256 hash algorithm can generate a hash value with a length of 256 bits for any length of information), a hash value with a fixed length of 256 bits is generated for each piece of change record information, a leaf layer L1 of a binary tree is formed, then a new hash value is calculated by inputting the SHA256 hash algorithm according to two adjacent groups of hash values, if a single hash value exists, a copy is copied by the self, and then the new hash value is calculated by inputting the hash algorithm, so that a second layer L2 of the binary tree is formed. And analogizing to finally calculate the hash value of the highest layer of the binary tree, namely the root hash value. The root hash value calculated in this way can guarantee the order of the change information, and any fake change or illegal operation for adjusting the change order can be identified.
And step 4, the service node of the master station end takes the calculated root hash value as a part of information of the block head, and the block head comprises user identification, request time, a father block hash value, a random number and workload certification information, as shown in fig. 3. Wherein the random number and the workload certification information are for the other nodes to authenticate the validity of the workload of the block. Method and process of workload certification: and (2) a special state estimation calculation method for the power grid monitoring master station system is adopted (the state estimation calculation can obtain the state estimation value of each device after matrix calculation according to the section data of the power grid device and a power grid model). And acquiring a data section of corresponding time according to the request time, calculating a state estimation process by combining with a power grid structure of the equipment model base, and then taking a power value of a position corresponding to the random number in the line table in a calculation result as workload certification information. If the random number is greater than the number of the line equipment, performing modulo operation on the number of the line equipment to obtain an integer less than the number of the line equipment, and then acquiring a power value of a position corresponding to the value in the line table to be used as a workload certificate to be placed in a block head.
And step 5, the service node (node N for short) at the master station end completes the assembly of the block header, and constructs the parameter change record and the block header together into a complete parameter change record block, wherein the structural information of one block is shown in fig. 3. After the block assembly is completed, the node broadcasts the whole block information, after other service nodes receive the block information, the validity of the block is verified, and if the block is valid, the block is linked with the local block chain. And completing the change of the parameters in the local equipment library according to the parameter change information in the block, and after the change is completed, replying confirmation information with the sending node N, and after the node N receives more than half of the node confirmation, updating the change of the parameters in the local equipment library. The specific procedure of the broadcast processing mechanism of the node N is described as follows: (1) the node N issues block information, and other service nodes calculate a root hash value according to the received change record information in the block body by the method in the step 3, and compare the root hash value with the root hash value in the block header information to verify the validity of the parameter change information; (2) the other service nodes further obtain a data section according to the request time in the block head and calculate a primary state estimated value by combining the power grid structure of the equipment model base, further obtain the numerical value of the corresponding position of the corresponding line table and the random number according to the random number in the block head, and compare the numerical value with the workload certification information provided in the block head, if the numerical values are consistent, the workload certification is effective, namely the block is effective; (3) and finally, the other service nodes compare the parent block hash value in the block head with the local parent block hash value, if the parent block hash value is consistent with the local parent block hash value, the latest block received this time is linked with the local block, and meanwhile, a confirmation message is replied to the sending node N.
The invention provides a storage synchronization method for parameter change records of a distributed power grid monitoring master station system, wherein the synchronization method for the operation parameter change records of equipment comprises the following steps: any two service nodes of the distributed power grid monitoring master station system can synchronize parameter change block chains. The synchronization mode is as follows:
(1) if the lengths of the local blockchains of the two serving nodes are different and the long block contains a short blockchain, the node with the short blockchain automatically synchronizes the missing block from the node with the long blockchain. As shown in fig. 4, the parameter change blockchain in the node a sequentially includes (block 1, block 2, block 3), the parameter change blockchain in the node B sequentially includes (block 1, block 2, block 3, block 4), the blockchain length of the node B is longer than that of the node a, and the blockchain of the node a is included, the blockchain of the node a automatically follows the synchronization block 4 of the node B;
(2) if the two node parameter change block chains are forked, namely, a part of parent blocks in the two block chains are the same, starting from the first forked block, the two nodes broadcast a block synchronization request, and the block with more than half recovery confirmation is regarded as a valid block, and the other invalid block is automatically synchronized by the valid block. As shown in fig. 5, the parameter change blockchain in the node C sequentially includes (block 1, block 2, block 3, block 5), the parameter change blockchain in the node D sequentially includes (block 1, block 2, block 3, block 4), and if the two blockchains in the node C and the node D have a conflict in the 4 th block, the node C and the node D distribute and transmit broadcast information to confirm the 4 th block, and if more than half of the nodes confirm that the block 5 is valid, the node D synchronizes the block 5 from the node C to the local blockchain.
By the synchronization method, the same parameter change block chains of all service nodes in the whole network can be ensured. Therefore, the consistency of the running parameters of the power grid monitoring system equipment is ensured, and meanwhile, the parameter change records are synchronized point to point between any two service nodes, so that the problems of single node failure of centralized updating and the loss of parameter change setting in the process of main-standby switching can be solved.
Example 2
This embodiment provides a storage synchronizer of power grid monitoring master station system parameter change record, is applied to power grid monitoring master station end service node, includes:
a parameter change information receiving unit, configured to receive parameter change information of device operation sent by a client; the client is used for receiving a request for initiating equipment operation parameter change by a user and organizing parameter change information;
the parameter change information analysis and verification unit is used for analyzing the parameter change information, analyzing the client user mark, checking the existence of the user according to the permission database, and verifying whether the user has the permission for modifying and setting the equipment parameters;
the parameter change information identification unit is used for identifying the parameter change information after confirming that the user is qualified, calculating a hash value aiming at each group of change information, further calculating a new hash value for the hash values of two adjacent groups, and finally calculating a root hash value of a binary tree according to a binary tree mode;
the input unit is used for taking the calculated root hash value as a part of information of a block header, wherein the block header comprises a user mark, request time, a father block hash value, a random number and workload certification information;
the updating unit is used for completing the service node N assembled by the block head, broadcasting the whole block information, verifying the validity of the block after other service nodes receive the block information, and adding the block information into a local latest block chain if the block is valid; and changing parameters in the local equipment library according to the parameter change record information in the block, replying confirmation information to the sending node N after the change is completed, and updating the change of the parameters in the local equipment library after the node N receives more than half of the node confirmation.
Example 3
The embodiment provides a storage synchronization device for parameter change records of a power grid monitoring master station system, which comprises a processor and a storage medium;
the storage medium is used for storing instructions;
the processor is configured to operate in accordance with the instructions to perform the steps of the method according to any of embodiment 1.
Example 4
The present embodiment provides a computer-readable storage medium, on which a computer program is stored, which program, when being executed by a processor, carries out the steps of the method of any of the embodiment 1.
The above description is only a preferred embodiment of the present invention, and it should be noted that, for those skilled in the art, several modifications and variations can be made without departing from the technical principle of the present invention, and these modifications and variations should also be regarded as the protection scope of the present invention.

Claims (10)

1. A storage synchronization method for parameter change records of a power grid monitoring master station system is characterized by being applied to a service node of a power grid monitoring master station side and comprising the following steps:
receiving parameter change information of equipment operation sent by a client; the client is used for receiving a request for initiating equipment operation parameter change by a user and organizing parameter change information;
analyzing the parameter change information to obtain a client user mark, checking the existence of a user according to a permission database, and checking whether the user has the permission for modifying and setting the equipment parameters;
after the user is confirmed to be qualified, identifying parameter change information, calculating hash values aiming at each group of change information, further calculating new hash values for the hash values of two adjacent groups, and finally calculating a root hash value of a binary tree according to a binary tree mode;
taking the calculated root hash value as a part of information of a block header, wherein the block header comprises a user mark, request time, a father block hash value, a random number and workload certification information;
the service node N which completes block head assembly broadcasts the whole block information, after other service nodes receive the block information, the validity of the block is verified, and if the block is valid, the block is added into a local latest block chain; and changing the parameters in the local equipment library according to the parameter change record information in the block, replying confirmation information to the sending node N after the change is completed, and updating the change of the parameters in the local equipment library after the node N receives more than half of the node confirmation.
2. The storage and synchronization method for the parameter change records of the power grid monitoring master station system according to claim 1, characterized in that: the parameter change information includes: user identification, request time, unique equipment code, equipment parameter name, parameter value before equipment change and complete request information of the parameter value after equipment change.
3. The storage and synchronization method for the parameter change records of the power grid monitoring master station system according to claim 2, characterized in that: the complete request information comprises one or more groups of operation time, equipment unique codes, equipment parameter names and change records of parameters before and after equipment change.
4. The storage and synchronization method for the parameter change records of the power grid monitoring master station system according to claim 1, characterized in that: any two service nodes in the power grid monitoring master station system can synchronize parameter change record block chains, and the synchronization mode is divided into two conditions:
(1) if the two node parameter change block chains have different lengths and the long chain comprises a short chain, comparing the lengths of the local block chains of the two service nodes, and automatically synchronizing the block from the node with the block chain length to the node with the short block chain;
(2) if two node parameter change block chains are forked, namely, if some parent blocks in the two block chains are the same, starting from the differential block with the forked first, two nodes broadcast a differential block synchronization request, if more than half of the recovery confirmed blocks are obtained, the blocks are regarded as valid blocks, and the other invalid blocks are automatically synchronized by the valid blocks.
5. The storage and synchronization method for the parameter change records of the power grid monitoring master station system according to claim 1, characterized in that: the calculating hash values for each group of change information, further calculating new hash values for the hash values of two adjacent groups, and finally calculating a root hash value of a binary tree according to a binary tree mode includes:
adopting SHA256 hash algorithm for each group of change, generating hash value with fixed 256 bit length for each group of change information, and forming a leaf layer L1 of the binary tree;
inputting SHA256 hash algorithm to calculate a new hash value according to two adjacent hash values, copying one hash value if a single hash value exists, and inputting the hash algorithm to calculate the new hash value, thereby forming a second layer L2 of the binary tree;
and analogizing to finally calculate the root hash value of the highest layer of the binary tree.
6. The storage and synchronization method for the parameter change records of the power grid monitoring master station system according to claim 1, characterized in that: the method for acquiring the workload certification information comprises the following steps:
calculating primary state estimation according to a data section of the request time and by combining a power grid structure of an equipment model base by adopting a state estimation calculation method special for a power grid monitoring master station;
taking the power value of the position corresponding to the random number in the circuit table in the calculation result as workload certification information; if the random number is greater than the number of the line equipment, performing modulo calculation on the number of the line equipment to obtain an integer less than the number of the line equipment, and then acquiring the power value of the position corresponding to the value in the line table.
7. The storage and synchronization method for the parameter change records of the power grid monitoring master station system according to claim 1, characterized in that: the service node N which completes the block head assembly broadcasts the whole block information, after other service nodes receive the block information, the validity of the block is verified, if the block is valid, the block is added into a local latest block chain, and the method comprises the following steps:
after the assembled service node issues the block information, other service nodes calculate a root hash value according to the received change record information in the block body, and compare the root hash value with the root hash value in the block header information to verify the validity of the parameter change information;
acquiring a data section according to the request time in the block head, calculating a state estimation value by combining a power grid structure of an equipment model library, further acquiring a numerical value in a random number position of a corresponding line table according to a random number in the block head, comparing the numerical value with workload certification information in the block head, and if the numerical values are consistent, considering that the workload certification is effective;
and comparing the parent block hash value in the block head with the local parent block hash value, if the parent block hash value in the block head is consistent with the local parent block hash value, linking the parameter change block received this time with the local block, and simultaneously replying confirmation information to a sending node assembled by the blocks.
8. Storage synchronizer of electric wire netting control master station system parameter change record, its characterized in that is applied to electric wire netting control master station end service node, includes:
a parameter change information receiving unit, configured to receive parameter change information of device operation sent by a client; the client is used for receiving a request for initiating equipment operation parameter change by a user and organizing parameter change information;
the parameter change information analysis and verification unit is used for analyzing the parameter change information, analyzing the client user mark, checking the existence of the user according to the permission database, and verifying whether the user has the permission for modifying and setting the equipment parameters;
the parameter change information identification unit is used for identifying the parameter change information after confirming that the user is qualified, calculating a hash value aiming at each group of change information, further calculating a new hash value for the hash values of two adjacent groups, and finally calculating a root hash value of a binary tree according to a binary tree mode;
the input unit is used for taking the calculated root hash value as a part of information of a block header, wherein the block header comprises a user mark, request time, a father block hash value, a random number and workload certification information;
the updating unit is used for broadcasting the information of the whole block by the service node N which completes the assembly of the block head, verifying the validity of the block after other service nodes receive the information, and adding the block into a local latest block chain if the block is valid; and changing parameters in the local equipment library according to the parameter change record information in the block, replying confirmation information to the sending node N after the change is completed, and updating the change of the parameters in the local equipment library after the node N receives more than half of the node confirmation.
9. Storage synchronizer of power grid monitoring master station system parameter change record, its characterized in that: comprising a processor and a storage medium;
the storage medium is to store instructions;
the processor is configured to operate in accordance with the instructions to perform the steps of the method according to any one of claims 1 to 7.
10. A computer-readable storage medium having stored thereon a computer program, characterized in that: the program when executed by a processor implements the steps of the method of any one of claims 1 to 7.
CN202210151351.7A 2022-02-18 2022-02-18 Storage synchronization method and device for parameter change records of power grid monitoring master station system Active CN114661231B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210151351.7A CN114661231B (en) 2022-02-18 2022-02-18 Storage synchronization method and device for parameter change records of power grid monitoring master station system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210151351.7A CN114661231B (en) 2022-02-18 2022-02-18 Storage synchronization method and device for parameter change records of power grid monitoring master station system

Publications (2)

Publication Number Publication Date
CN114661231A true CN114661231A (en) 2022-06-24
CN114661231B CN114661231B (en) 2023-08-11

Family

ID=82027530

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210151351.7A Active CN114661231B (en) 2022-02-18 2022-02-18 Storage synchronization method and device for parameter change records of power grid monitoring master station system

Country Status (1)

Country Link
CN (1) CN114661231B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2024066005A1 (en) * 2022-09-30 2024-04-04 蚂蚁区块链科技(上海)有限公司 Method and apparatus for replaying blockchain transaction

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105959307A (en) * 2016-06-30 2016-09-21 中国科学院计算技术研究所 Existence certification and authentication service method and system based on block chain technology
WO2018032372A1 (en) * 2016-08-13 2018-02-22 深圳市樊溪电子有限公司 Trusted power grid transaction platform based on block chain technology
CN107870996A (en) * 2017-11-02 2018-04-03 国家电网公司 Electricity transaction management-control method and device based on block chain
CN110928690A (en) * 2019-12-07 2020-03-27 上海科乐宜信息科技有限公司 Method for synchronizing and verifying block chain data in 5G network environment
CN112231754A (en) * 2020-10-21 2021-01-15 南方电网科学研究院有限责任公司 Method, system and storage medium for monitoring configuration information of power edge computing node
WO2021072981A1 (en) * 2019-10-17 2021-04-22 广东绿腾新能源服务有限公司 Blockchain-based energy data linking method and apparatus
CN113036756A (en) * 2021-03-15 2021-06-25 四川电力设计咨询有限责任公司 Networking system and method for decentralized networking of micro-grid

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105959307A (en) * 2016-06-30 2016-09-21 中国科学院计算技术研究所 Existence certification and authentication service method and system based on block chain technology
WO2018032372A1 (en) * 2016-08-13 2018-02-22 深圳市樊溪电子有限公司 Trusted power grid transaction platform based on block chain technology
CN107870996A (en) * 2017-11-02 2018-04-03 国家电网公司 Electricity transaction management-control method and device based on block chain
WO2021072981A1 (en) * 2019-10-17 2021-04-22 广东绿腾新能源服务有限公司 Blockchain-based energy data linking method and apparatus
CN110928690A (en) * 2019-12-07 2020-03-27 上海科乐宜信息科技有限公司 Method for synchronizing and verifying block chain data in 5G network environment
CN112231754A (en) * 2020-10-21 2021-01-15 南方电网科学研究院有限责任公司 Method, system and storage medium for monitoring configuration information of power edge computing node
CN113036756A (en) * 2021-03-15 2021-06-25 四川电力设计咨询有限责任公司 Networking system and method for decentralized networking of micro-grid

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2024066005A1 (en) * 2022-09-30 2024-04-04 蚂蚁区块链科技(上海)有限公司 Method and apparatus for replaying blockchain transaction

Also Published As

Publication number Publication date
CN114661231B (en) 2023-08-11

Similar Documents

Publication Publication Date Title
CN108282474B (en) Block chain based digital asset transaction consistency maintenance method
CN110825420B (en) Method, device, equipment and storage medium for updating configuration parameters of distributed cluster
CN110784495B (en) Block chain-based discovery and configuration information management method for big data cluster system
CN109522363B (en) Cloud platform synchronization method, system, equipment and storage medium based on block chain
JP5548829B2 (en) Computer system, data management method, and data management program
CN111614733B (en) Deployment method, device and storage medium of distributed multi-fragmentation cluster
WO2014101424A1 (en) Method and system for synchronizing distributed database
CN111523150B (en) Document editing method, device and system based on block chain
CN110730081B (en) Block chain network-based certificate revocation method, related equipment and medium
CN110324331B (en) Block chain-based identity authentication method for safety and stability control terminal of power system
CN114465817B (en) Digital certificate system and method based on TEE predictor clusters and blockchain
CN109783193A (en) A kind of mirror image file management method that can be multiplexed in multiple domain cloud platform
CN110545207B (en) Synchronous automatic intelligent DNS system and configuration method
CN113824563A (en) Cross-domain identity authentication method based on block chain certificate
CN111625598A (en) Engineering cooperation block chain data structure and application method
CN111327586A (en) Time stamping of data in offline nodes
CN111314060A (en) Key updating method, device and storage medium
CN113411376A (en) Sensor data processing method and device based on block chain fragmentation storage
CN113127562A (en) Low-redundancy block chain data storage and retrieval method and system
CN115695449A (en) Block chain digital collection source file cross-platform synchronization and transfer method
CN114661231A (en) Storage synchronization method and device for parameter change records of power grid monitoring master station system
CN114490685A (en) DNS data query updating method and system based on block chain and verifiable calculation
CN114491656A (en) Method and apparatus in a blockchain network
CN116955355A (en) Block data processing method and device and electronic equipment
CN102761520B (en) Method and system for processing authentication information

Legal Events

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