CN116795290A - Data synchronization method, baseboard management controller, electronic device and storage medium - Google Patents

Data synchronization method, baseboard management controller, electronic device and storage medium Download PDF

Info

Publication number
CN116795290A
CN116795290A CN202310779219.5A CN202310779219A CN116795290A CN 116795290 A CN116795290 A CN 116795290A CN 202310779219 A CN202310779219 A CN 202310779219A CN 116795290 A CN116795290 A CN 116795290A
Authority
CN
China
Prior art keywords
data
synchronous
synchronization
fru
synchronized
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
CN202310779219.5A
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.)
Suzhou Inspur Intelligent Technology Co Ltd
Original Assignee
Suzhou Inspur Intelligent Technology 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 Suzhou Inspur Intelligent Technology Co Ltd filed Critical Suzhou Inspur Intelligent Technology Co Ltd
Priority to CN202310779219.5A priority Critical patent/CN116795290A/en
Publication of CN116795290A publication Critical patent/CN116795290A/en
Pending legal-status Critical Current

Links

Landscapes

  • Hardware Redundancy (AREA)

Abstract

The invention discloses a data synchronization method, a baseboard management controller, electronic equipment and a storage medium, which belong to the technical field of computers, wherein the data synchronization method is applied to a baseboard management controller BMC of a transmitting end, the BMC comprises a field replaceable unit FRU management module and a data synchronization module, and the data synchronization method comprises the following steps: the FRU management module acquires data to be synchronized and determines the type of the data to be synchronized; the FRU management module processes the data to be synchronized according to the type of the data to be synchronized; the FRU management module determines synchronous data from the processed data to be synchronized under the condition of running to the data synchronization logic, and sends the synchronous data to the data synchronization module; and the data synchronization module is used for scheduling the synchronous data, determining a transmission link of the synchronous data and transmitting the synchronous data to the substrate management controller of the receiving end through the transmission link. The invention can realize low-delay and reliable synchronization of data among different BMCs.

Description

Data synchronization method, baseboard management controller, electronic device and storage medium
Technical Field
The present invention relates to the field of computer technologies, and in particular, to a data synchronization method, a baseboard management controller, an electronic device, and a storage medium.
Background
The hardware design of the storage server often adopts a multi-controller redundancy mode, and the data synchronization among the multi-controllers is an important means for guaranteeing the stability and reliability of the storage system. In a multi-control storage system, a plurality of baseboard management controllers (Baseboard Manager Controller, BMCs) are generally responsible for managing hardware data in a server, and data synchronization is required between the plurality of BMCs. In the prior art, in the process of actually performing data synchronization, due to the influence of factors such as the data types of field replaceable units (Field Replace Unit, FRUs), the number difference of FRUs, the number of controllers and the like, the synchronous data quantity between BMCs is multiplied, and in addition, a low-speed physical bus is adopted in a synchronous link to perform data synchronization, so that the data synchronization delay is negatively influenced.
Disclosure of Invention
The invention provides a data synchronization method, which is used for solving the defects that in the prior art, due to the influence of factors such as the data type of FRU, the quantity difference of FRU, the quantity of controllers and the like in the actual data synchronization process, the synchronous data quantity between BMCs is multiplied, and in addition, a low-speed physical bus is adopted in a synchronous link for data synchronization, and the data synchronization delay is negatively influenced.
In a first aspect, the present invention provides a data synchronization method, applied to a baseboard management controller of a transmitting end, where the baseboard management controller includes a field replaceable unit FRU management module and a data synchronization module, and the data synchronization method includes:
the FRU management module acquires data to be synchronized and determines the type of the data to be synchronized;
the FRU management module processes the data to be synchronized according to the type of the data to be synchronized;
the FRU management module determines synchronous data from the processed data to be synchronized under the condition of running to the data synchronization logic, and sends the synchronous data to the data synchronization module;
and the data synchronization module is used for scheduling the synchronous data, determining a transmission link of the synchronous data and transmitting the synchronous data to a baseboard management controller of a receiving end through the transmission link.
In some embodiments, the types include static data and dynamic data;
the FRU management module processes the data to be synchronized according to the type of the data to be synchronized, and comprises the following steps:
the FRU management module stores the static data in a memory of the FRU management module, and a static data synchronization status word is reserved in the FRU management module and used for indicating whether the static data are synchronized or not;
And the FRU management module performs stripe region division, numbering and check bit addition on the dynamic data, and establishes synchronous copies of the dynamic data in the memory of the FRU management module.
In some embodiments, the FRU management module, when running to data synchronization logic, determines synchronization data from the processed data to be synchronized, including:
the FRU management module determines whether static data synchronous status words are static synchronous data or not from the processed static data under the condition of running to data synchronous logic;
the FRU management module encapsulates the static synchronous data according to a static data frame format, and takes the encapsulated static synchronous data as the synchronous data, wherein the static data frame format comprises a data separation field, a static data synchronous state word and a static data segment.
In some embodiments, the FRU management module, when running to data synchronization logic, determines synchronization data from the processed data to be synchronized, including:
the FRU management module determines whether synchronous copies of dynamic data exist in a local memory under the condition of running to data synchronous logic;
If synchronous copies of the dynamic data exist in the local memory, determining dynamic synchronous data which changes compared with the existing synchronous copies from the processed dynamic data, and taking the dynamic synchronous data as the synchronous data;
and if the synchronous copy of the dynamic data does not exist in the local memory, the processed dynamic data is used as the synchronous data.
In some embodiments, the data synchronization module schedules the synchronization data, determines a transmission link of the synchronization data, and transmits the synchronization data to a baseboard management controller of a receiving end through the transmission link, including:
determining a sending interface of the synchronous data according to the requirement of the FRU management module on the real-time property of the data, wherein the sending interface comprises a synchronous interface or an asynchronous interface;
when the synchronous interface is called to send the synchronous data, a priority field is added in a data head frame of the synchronous data, the value of the priority field is determined by inquiring a priority level table based on the serial number of the FRU management module, and the priority level table is pre-established in the data synchronous module according to the instantaneity and the data quantity of each FRU management module;
And scheduling the synchronous data according to the priority field, determining a transmission link of the synchronous data, and transmitting the synchronous data to a baseboard management controller of a receiving end through the transmission link.
In some embodiments, the method further comprises:
when the asynchronous interface is called to send the synchronous data, the synchronous data are summarized in a sending data pool of the data synchronous module, an asynchronous data sending thread of the data synchronous module reads a plurality of data packets in the sending data pool at one time, the priority ordering is carried out on the plurality of data packets, and a physical link is called according to the ordering result to send the read data packets in sequence.
In some embodiments, the determining the transmission link of the synchronization data includes:
under the condition that the main link and the standby link are normal, determining the standby link as a transmission link of the synchronous data;
and under the condition that any link is abnormal, determining the transmission link of the synchronous data in a fair competition mode.
In a second aspect, the present invention also provides a baseboard management controller, including: a field replaceable unit FRU management module and a data synchronization module,
The FRU management module is used for acquiring data to be synchronized and determining the type of the data to be synchronized; processing the data to be synchronized according to the type of the data to be synchronized; under the condition of running to a data synchronization logic, determining synchronous data from the processed data to be synchronized, and sending the synchronous data to the data synchronization module;
the data synchronization module is used for scheduling the synchronous data, determining a transmission link of the synchronous data, and transmitting the synchronous data to a baseboard management controller of a receiving end through the transmission link.
In a third aspect, the present invention also provides an electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, the processor implementing any one of the data synchronization methods described above when executing the program.
In a fourth aspect, the present invention also provides a non-transitory computer readable storage medium having stored thereon a computer program which, when executed by a processor, implements a data synchronization method as described in any of the above.
The invention provides a data synchronization method, a substrate management controller, electronic equipment and a storage medium, wherein FRU management module is used for acquiring data to be synchronized, determining the type of the data to be synchronized, processing the data to be synchronized according to the type of the data to be synchronized, determining the synchronization data from the processed data to be synchronized under the condition of running to data synchronization logic, and transmitting the synchronization data to a data synchronization module; the data synchronization module is used for scheduling the synchronous data, a transmission link of the synchronous data is determined, and the synchronous data is transmitted to the baseboard management controller of the receiving end through the transmission link, so that low-delay and reliable synchronization of the data among different BMCs can be realized, and the real-time performance of the data synchronization is improved.
Drawings
In order to more clearly illustrate the invention or the technical solutions of the prior art, the following description will briefly explain the drawings used in the embodiments or the description of the prior art, and it is obvious that the drawings in the following description are some embodiments of the invention, and other drawings can be obtained according to the drawings without inventive effort for a person skilled in the art.
FIG. 1 is a block diagram of a prior art two-control hardware architecture of a storage server;
FIG. 2 is a schematic flow chart of a data synchronization method according to an embodiment of the present invention;
FIG. 3 is an example of processed static and dynamic data provided by an embodiment of the present invention;
fig. 4 is a schematic flow diagram of a baseboard management controller for scheduling synchronous data, determining a transmission link of the synchronous data, and transmitting the synchronous data to a receiving end through the transmission link according to an embodiment of the present invention;
FIG. 5 is a schematic diagram of a baseboard management controller according to an embodiment of the present invention;
FIG. 6 is a second flowchart of a data synchronization method according to an embodiment of the present invention;
FIG. 7 is a second schematic diagram of a baseboard management controller according to an embodiment of the present invention;
Fig. 8 is a schematic structural diagram of an electronic device provided by the present invention.
Detailed Description
For the purpose of making the objects, technical solutions and advantages of the present invention more apparent, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings, and it is apparent that the described embodiments are some embodiments of the present invention, not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
For each storage server, two or four controller hardware are often combined in a chassis with the height of 2U or 4U, and mirror image redundancy and backup are arranged among the controllers in the chassis for data access, operation and storage, so that safe and reliable operation of the servers is guaranteed.
In the same frame, each controller is regarded as a data synchronization node, and a plurality of controllers jointly form a data synchronization network, and hardware management data flows on nodes in the synchronization network.
FIG. 1 is a block diagram of a prior art two-control hardware architecture of a storage server. As shown in fig. 1, two controllers in the storage server are a controller a and a controller B, complex programmable logic devices (Complex Programmable Logic Device, CPLDs) and BMCs are respectively arranged in the controller a and the controller B, the two CPLDs coordinate data synchronization between the two BMCs through a general purpose input/Output (GPIO) heartbeat signal, and the two BMCs are in communication connection through an I2C synchronization main link and an I2C synchronization standby link.
Fig. 2 is a schematic flow chart of a data synchronization method according to an embodiment of the present invention. As shown in fig. 2, there is provided a data synchronization method applied to a baseboard management controller of a transmitting end, the baseboard management controller including a field replaceable unit FRU management module and a data synchronization module, the data synchronization method including the steps of: step 210, step 220, step 230 and step 240. The method flow steps are only one possible implementation of the invention.
The baseboard management controller BMC is usually a separate computer board, and is installed on a server motherboard to manage server hardware. The BMC may also monitor the health of the server, such as temperature, voltage, fan speed, etc. In addition, the BMC may also provide remote management functions through a remote management interface, such as a Smart platform management interface (Intelligent Platform Management Interface, IPMI), to allow an administrator to remotely monitor and manage servers.
The field replaceable unit FRU refers to a component that can be replaced in the field while the electronic device is being repaired and serviced. These components are typically wearing parts or parts that need to be replaced frequently, such as batteries, hard disks, fans, etc. FRUs can help reduce maintenance costs and maintenance time for equipment because they can be easily replaced in the field without the need to send the entire equipment back to the manufacturer for repair.
Step 210, the FRU management module acquires the data to be synchronized and determines the type of the data to be synchronized.
Wherein the data to be synchronized includes, but is not limited to, the following: server hardware status data such as central processing unit (Central Processing Unit, CPU) temperature, fan speed, voltage, etc.; a system event log comprising system crashes, power supply anomalies, temperature anomalies and the like; user rights and configuration information such as user account, password, network configuration, etc.; remote control commands such as restarting the server, modifying BIOS settings, etc.
Optionally, the data to be synchronized may be classified by identifying information such as format, content, keywords, etc. of the data, and may be classified into text data and image data according to the format, and may be classified into static data and dynamic data according to the temporal state.
It can be understood that the type of the data to be synchronized is determined by acquiring the data to be synchronized, so that the data to be synchronized of different types can be classified and processed conveniently, and the data synchronization is performed in a proper mode based on the type of the data to be synchronized.
And 220, the FRU management module processes the data to be synchronized according to the type of the data to be synchronized.
It can be understood that for different types of data to be synchronized, different processing modes are adopted for processing, such as adding a synchronization state identifier or a serial number, so that the subsequent quick and efficient determination of the synchronization data from the processed data to be synchronized is facilitated, and the accuracy and reliability of the synchronization data are improved.
And 230, determining synchronous data from the processed data to be synchronized by the FRU management module under the condition of running to the data synchronization logic, and sending the synchronous data to the data synchronization module.
It can be understood that the data to be synchronized is selected from the processed data to be synchronized and sent to the data synchronization module, and the data which is synchronized and the data which is not subjected to state change are filtered from the processed data to be synchronized, so that the accuracy and the reliability of the synchronized data can be further improved, and the efficiency of data synchronization is improved.
Step 240, a data synchronization module schedules the synchronous data, determines a transmission link of the synchronous data, and transmits the synchronous data to a baseboard management controller of the receiving end through the transmission link.
For scheduling and transmitting synchronous data, the following aspects are generally considered:
1) Priority of data: for different types of data, different priorities may exist, and a transmission sequence needs to be determined according to the priorities, so that low-priority data is prevented from being blocked by high-priority data;
2) Network bandwidth and delay: network bandwidth and delay are also important factors for determining the data transmission sequence, and the time for transmitting the data needs to be determined according to the network conditions, the data quantity and other factors;
3) Synchronization accuracy: the accuracy of the synchronization data also needs to be considered, and if high accuracy synchronization is required, higher bandwidth, lower latency network devices may need to be used, as well as finer scheduling algorithms;
4) Data retransmission and loss handling: during data transmission, retransmission and loss may occur, and a corresponding mechanism is required to deal with these problems.
By comprehensively considering the factors, a corresponding scheduling algorithm can be designed to schedule the synchronous data and determine the transmission link of the synchronous data so as to realize the efficient, accurate and stable transmission of the synchronous data.
In the embodiment of the invention, the FRU management module is used for acquiring the data to be synchronized, determining the type of the data to be synchronized, processing the data to be synchronized according to the type of the data to be synchronized, determining the synchronous data from the processed data to be synchronized under the condition of running to the data synchronization logic, and transmitting the synchronous data to the data synchronization module; the data synchronization module is used for scheduling the synchronous data, a transmission link of the synchronous data is determined, and the synchronous data is transmitted to the baseboard management controller of the receiving end through the transmission link, so that the time delay of data synchronization among different BMCs can be reduced, and the instantaneity and the accuracy of the synchronous data are improved.
It should be noted that each embodiment of the present invention may be freely combined, exchanged in order, or separately executed, and does not need to rely on or rely on a fixed execution sequence.
In some embodiments, the types include static data and dynamic data;
the FRU management module processes the data to be synchronized according to the type of the data to be synchronized, and comprises the following steps:
the FRU management module stores the static data in the memory of the FRU management module, and a static data synchronization status word is reserved in the FRU management module and used for indicating whether the static data are synchronized or not;
the FRU management module performs stripe region division and numbering on the dynamic data, and adds check bits, and synchronous copies of the dynamic data are established in the memory of the FRU management module.
Wherein, the static data refers to data which does not change along with time, and includes data which is not modified after the measurement is completed, such as user account, network configuration, etc.; the dynamic data refers to data that changes with time, i.e. data monitored by the FRU management module in real time, such as CPU temperature, fan speed, voltage, etc.
Wherein, the static data synchronous status word is "yes" or "no", the "yes" indicates that the static data is synchronous, and the "no" indicates that the static data is not synchronous.
Under the condition that the total dynamic data amount is certain, dividing the whole data area according to the data length, adding numbers and checks to each area, wherein the dividing basis is the bandwidth of a data transmission channel, and the data amount of the stripe is ensured to be smaller than the data amount which can be loaded by the maximum transmission packet as far as possible.
Fig. 3 is an example of processed static data and dynamic data provided by an embodiment of the present invention. As shown in fig. 3, the processed static data may be "[ data separation character 5 bytes ]; [ data synchronization State_No ]; static data "or" [ data separation character 5 bytes ]; [ data synchronization status_yes ]; the dynamic data is divided into a plurality of stripes, including a data field 1, a data field 2, a data field 3, a data field N, and each stripe has a corresponding number and check field.
It can be understood that the FRU management module stores the static data in the memory of the FRU management module, and reserves the static data synchronization status word in the FRU management module, so as to determine whether to carry the static data according to the static data synchronization status word when the static data is sent; the FRU management module is used for dividing and numbering the stripe regions of the dynamic data and adding check bits, and synchronous copies of the dynamic data are established in the memory of the FRU management module, so that the dynamic data of different stripes can be conveniently compared with the data in the synchronous copies, and the data regions needing to be synchronized are determined according to the state changes of the different stripes, so that the data synchronization efficiency is improved, and the data synchronization delay is reduced.
In some embodiments, the FRU management module, when running to the data synchronization logic, determines synchronization data from the processed data to be synchronized, comprising:
under the condition that the FRU management module runs to the data synchronization logic, determining whether the static data synchronization status word is the static synchronization data or not from the processed static data;
the FRU management module encapsulates the static synchronous data according to a static data frame format, and takes the encapsulated static synchronous data as synchronous data, wherein the static data frame format comprises a data separation field, a static data synchronous state word and a static data segment.
Illustratively, the encapsulated static synchronization data is "[ data separation character 5 bytes ]; [ data synchronization State_No ]; static data).
It can be understood that under the condition that the FRU management module runs to the data synchronization logic, the FRU management module determines whether the static data synchronization status word is the static synchronization data or not from the processed static data, encapsulates the static synchronization data according to the static data frame format, uses the encapsulated static synchronization data as the synchronization data, and further facilitates screening out the static data which is not synchronized, uses the encapsulated static synchronization data as the synchronization data for synchronization processing, and avoids repeated synchronization of the synchronized static data.
In some embodiments, the FRU management module, when running to the data synchronization logic, determines synchronization data from the processed data to be synchronized, comprising:
under the condition of running to the data synchronization logic, the FRU management module determines whether synchronous copies of dynamic data exist in the local memory;
if synchronous copies of the dynamic data exist in the local memory, determining dynamic synchronous data which changes compared with the existing synchronous copies from the processed dynamic data, and taking the dynamic synchronous data as synchronous data;
and if the synchronous copy of the dynamic data does not exist in the local memory, the processed dynamic data is used as synchronous data.
It should be noted that, the synchronous copy of the dynamic data refers to that in the storage system, in order to realize reliability and high availability of the data, the data is backed up on a plurality of nodes, so that when the primary node fails, the primary node can be automatically switched to the standby node, and continuous operation of the system is ensured. The data on the standby nodes are synchronous copies, and the data on the standby nodes are synchronous with the data on the main nodes, so that the consistency of the data is ensured. When the data on the master node changes, the synchronous copies are updated correspondingly, so that the synchronism of the data is ensured.
Optionally, when the FRU management module continues to operate and the dynamic data is changed and updated, the processed dynamic data is obtained, and when the processed dynamic data is compared with the synchronous copy of the dynamic data existing in the local memory, some algorithms, such as hash value comparison or comparison, can be used to record the number of the changed data area if the field values of the two objects are the same.
It can be understood that by determining whether a synchronous copy of the dynamic data already exists in the local memory, if so, the processed dynamic data is compared with the synchronous copy, so that the changed dynamic synchronous data can be conveniently determined, the dynamic synchronous data is used as synchronous data, and if not, the processed dynamic data is used as synchronous data, so that the reliability and accuracy of the synchronous data can be improved.
Fig. 4 is a schematic flow chart of a baseboard management controller for scheduling synchronous data, determining a transmission link of the synchronous data, and transmitting the synchronous data to a receiving end through the transmission link according to an embodiment of the present invention. As shown in fig. 4, in some embodiments, the data synchronization module in step 240 schedules the synchronization data, determines a transmission link of the synchronization data, and transmits the synchronization data to the baseboard management controller of the receiving end through the transmission link, including:
Step 241, determining a sending interface of synchronous data according to the real-time requirement of the FRU management module, where the sending interface includes a synchronous interface or an asynchronous interface.
Fig. 5 is a schematic diagram of a baseboard management controller according to an embodiment of the present invention. As shown in fig. 5, the BMC includes a FRU management module and a data synchronization module. The FRU management module is used for acquiring data to be synchronized from different service modules, and calling a sending interface according to the requirement on the real-time property of the data to determine the sending interface (namely a synchronous interface or an asynchronous interface) of the synchronous data. The data synchronization module comprises a synchronization interface, an asynchronous interface and a sending data pool, if the synchronization interface is selected for data sending, the data synchronization module can schedule the synchronization data to determine a sending link (namely a main link or a standby link) of the synchronization data, if the asynchronous interface is selected for data sending, the synchronization data can be summarized in the sending data pool first, and then the physical link is called for sending the synchronization data.
The synchronous interface is to wait for receiving a response after sending the request and then perform the next operation, which requires waiting time, but ensures the accuracy of the data.
The asynchronous interface is to directly perform the next operation without waiting for a response after sending the request, which can save time, but may cause inaccurate data.
Optionally, different FRU management modules select different interfaces to complete data synchronization according to the real-time property of the data, select asynchronous interfaces with low real-time property and select synchronous interfaces with high real-time property.
It will be appreciated that determining the sending interface of the synchronization data is to ensure real-time and accuracy of the data, and the selection of which interface to use depends on the specific requirements and application scenario.
In step 242, when the synchronization interface is called to send the synchronization data, a priority field is added to the header frame of the synchronization data, the value of the priority field is determined by querying a priority table based on the serial number of the FRU management module, and the priority table is pre-established in the data synchronization module according to the real-time performance and the data volume of each FRU management module.
Step 243, scheduling the synchronous data according to the priority field, determining a transmission link of the synchronous data, and transmitting the synchronous data to the baseboard management controller of the receiving end through the transmission link.
Optionally, the sending link may be a main link or a standby link, and the scheduling algorithm may be used to schedule the synchronous data according to the idle condition of the link, so as to determine the sending link of the synchronous data.
It can be understood that according to the requirement of the FRU management module on the real-time performance of the data, the sending interface of the synchronous data is determined, when the synchronous interface is called to send the synchronous data, the priority field is added in the data header frame of the synchronous data, the synchronous data is scheduled according to the priority field, the sending link of the synchronous data is determined, and the synchronous data is sent to the baseboard management controller of the receiving end through the sending link, so that the time delay of the data synchronization can be reduced, the efficiency of the data synchronization can be improved, and the real-time performance and the accuracy of the synchronous data can be ensured.
In some embodiments, the method further comprises:
when the asynchronous interface is called to send synchronous data, the synchronous data are summarized in a sending data pool of the data synchronous module, an asynchronous data sending thread of the data synchronous module reads a plurality of data packets in the sending data pool at one time, priority ordering is carried out on the plurality of data packets, and a physical link is called according to an ordering result to send the read data packets in sequence.
Alternatively, when the standby link is idle and can work normally, the standby link may be used to send synchronous data, and then the high-priority data packet is sent first, and then the low-priority data packet is sent.
It can be understood that when the asynchronous interface is called to send synchronous data, the synchronous data is summarized in a sending data pool of the data synchronous module, an asynchronous data sending thread of the data synchronous module reads a plurality of data packets in the sending data pool at one time, prioritizes the plurality of data packets, calls a physical link according to the sequencing result to send the read data packets in sequence, so that the standby link is convenient to fully utilize, and the real-time performance of data synchronization can be effectively improved.
In some embodiments, determining a transmit link for synchronization data includes:
under the condition that the main link and the standby link are normal, determining the standby link as a transmission link of synchronous data;
and under the condition that any link is abnormal, determining the transmission link of the synchronous data by adopting a fair competition mode.
It can be understood that under the condition that the main link and the standby link are normal, the standby link is determined to be used as the transmission link of the synchronous data, and under the condition that any one link is abnormal, the transmission link of the synchronous data is determined in a fair competition mode, so that the standby link can be fully utilized, the delay of data synchronization is reduced, and the instantaneity of the data synchronization is improved.
Fig. 6 is a second flowchart of a data synchronization method according to an embodiment of the invention. As shown in fig. 6, there is provided a data synchronization method applied to a baseboard management controller of a receiving end, the data synchronization method including:
Step 610, receiving synchronization data;
step 620, checking whether the data separation field of the synchronous data is accurate, reading the synchronous status word of the static data, and if the synchronous status word of the static data is negative, reading the static data segment and storing the static data segment in the local control data memory;
or checking whether the check number and check bit of the synchronous data are accurate, confirming that the data transmission process is correct, extracting the dynamic data according to the number, and storing the dynamic data into a local control data memory.
In the embodiment of the invention, whether the data separation field of the synchronous data is accurate or not is checked by receiving the synchronous data, and the static data synchronous state word is read, and the static data segment is read and stored in the local control data memory under the condition that the static data synchronous state word is not, or whether the check number and the check bit of the synchronous data are accurate or not is checked, the data transmission process is confirmed, the dynamic data are extracted according to the number and stored in the local control data memory, and the accuracy and the reliability of the synchronous data can be further improved.
The following describes the baseboard management controller provided by the embodiment of the present invention, and the baseboard management controller described below and the data synchronization method described above may be referred to correspondingly.
Fig. 7 is a second schematic diagram of a baseboard management controller according to an embodiment of the invention, as shown in fig. 7, the baseboard management controller 700 includes:
the FRU management module 710 is configured to obtain data to be synchronized, and determine a type of the data to be synchronized; processing the data to be synchronized according to the type of the data to be synchronized; under the condition of running to the data synchronization logic, determining synchronous data from the processed data to be synchronized, and transmitting the synchronous data to a data synchronization module;
the data synchronization module 720 is configured to schedule the synchronization data, determine a transmission link of the synchronization data, and transmit the synchronization data to the baseboard management controller of the receiving end through the transmission link.
Optionally, the types include static data and dynamic data;
the FRU management module processes the data to be synchronized according to the type of the data to be synchronized, and comprises the following steps:
the FRU management module stores the static data in the memory of the FRU management module, and a static data synchronization status word is reserved in the FRU management module and used for indicating whether the static data are synchronized or not;
the FRU management module performs stripe region division and numbering on the dynamic data, and adds check bits, and synchronous copies of the dynamic data are established in the memory of the FRU management module.
Optionally, the FRU management module, when running to the data synchronization logic, determines synchronization data from the processed data to be synchronized, including:
under the condition that the FRU management module runs to the data synchronization logic, determining whether the static data synchronization status word is the static synchronization data or not from the processed static data;
the FRU management module encapsulates the static synchronous data according to a static data frame format, and takes the encapsulated static synchronous data as synchronous data, wherein the static data frame format comprises a data separation field, a static data synchronous state word and a static data segment.
Optionally, the FRU management module, when running to the data synchronization logic, determines synchronization data from the processed data to be synchronized, including:
under the condition of running to the data synchronization logic, the FRU management module determines whether synchronous copies of dynamic data exist in the local memory;
if synchronous copies of the dynamic data exist in the local memory, determining dynamic synchronous data which changes compared with the existing synchronous copies from the processed dynamic data, and taking the dynamic synchronous data as synchronous data;
and if the synchronous copy of the dynamic data does not exist in the local memory, the processed dynamic data is used as synchronous data.
Optionally, the data synchronization module schedules the synchronization data, determines a transmission link of the synchronization data, and transmits the synchronization data to the baseboard management controller of the receiving end through the transmission link, including:
determining a sending interface of synchronous data according to the real-time requirement of the FRU management module on the data, wherein the sending interface comprises a synchronous interface or an asynchronous interface;
when the synchronous interface is called to send synchronous data, a priority field is added in a data head frame of the synchronous data, the value of the priority field is determined by inquiring a priority level table based on the serial number of the FRU management module, and the priority level table is pre-established in the data synchronous module according to the instantaneity and the data quantity of each FRU management module;
and scheduling the synchronous data according to the priority field, determining a transmission link of the synchronous data, and transmitting the synchronous data to a baseboard management controller of the receiving end through the transmission link.
Optionally, the baseboard management controller further includes:
and the data transmitting module is used for summarizing the synchronous data in a transmitting data pool of the data synchronous module when the asynchronous interface is called to transmit the synchronous data, the asynchronous data transmitting thread of the data synchronous module reads a plurality of data packets in the transmitting data pool at one time, prioritizes the plurality of data packets, and calls a physical link according to the sequencing result to sequentially transmit the read data packets.
Optionally, determining the transmission link of the synchronization data includes:
under the condition that the main link and the standby link are normal, determining the standby link as a transmission link of synchronous data;
and under the condition that any link is abnormal, determining the transmission link of the synchronous data by adopting a fair competition mode.
It should be noted that, the baseboard management controller provided in the embodiment of the present invention can implement all the method steps implemented in the embodiment of the data synchronization method, and can achieve the same technical effects, and the same parts and beneficial effects as those of the embodiment of the method in the embodiment are not described in detail herein.
Fig. 8 illustrates a physical structure diagram of an electronic device, as shown in fig. 8, which may include: processor 810, communication interface (Communications Interface) 820, memory 830, and communication bus 840, wherein processor 810, communication interface 820, memory 830 accomplish communication with each other through communication bus 840. The processor 810 may call logic instructions in the memory 830 to perform a data synchronization method applied to a baseboard management controller of a transmitting side, the baseboard management controller including a Field Replaceable Unit (FRU) management module and a data synchronization module, the method comprising: the FRU management module acquires data to be synchronized and determines the type of the data to be synchronized; the FRU management module processes the data to be synchronized according to the type of the data to be synchronized; the FRU management module determines synchronous data from the processed data to be synchronized under the condition of running to the data synchronization logic, and sends the synchronous data to the data synchronization module; and the data synchronization module is used for scheduling the synchronous data, determining a transmission link of the synchronous data and transmitting the synchronous data to the substrate management controller of the receiving end through the transmission link.
Further, the logic instructions in the memory 830 described above may be implemented in the form of software functional units and may be stored in a computer-readable storage medium when sold or used as a stand-alone product. Based on this understanding, the technical solution of the present invention may be embodied essentially or in a part contributing to the prior art or in a part of the technical solution, in the form of a software product stored in a storage medium, comprising several instructions for causing a computer device (which may be a personal computer, a server, a network device, etc.) to perform all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
In another aspect, the present invention also provides a computer program product, the computer program product including a computer program, the computer program being storable on a non-transitory computer readable storage medium, the computer program, when executed by a processor, being capable of executing a data synchronization method provided by the methods described above, the method being applied to a baseboard management controller of a transmitting end, the baseboard management controller including a field replaceable unit FRU management module and a data synchronization module, the method comprising: the FRU management module acquires data to be synchronized and determines the type of the data to be synchronized; the FRU management module processes the data to be synchronized according to the type of the data to be synchronized; the FRU management module determines synchronous data from the processed data to be synchronized under the condition of running to the data synchronization logic, and sends the synchronous data to the data synchronization module; and the data synchronization module is used for scheduling the synchronous data, determining a transmission link of the synchronous data and transmitting the synchronous data to the substrate management controller of the receiving end through the transmission link.
In yet another aspect, the present invention also provides a non-transitory computer readable storage medium having stored thereon a computer program which, when executed by a processor, is implemented to perform the data synchronization method provided by the above methods, the method being applied to a baseboard management controller of a transmitting end, the baseboard management controller including a field replaceable unit FRU management module and a data synchronization module, the method comprising: the FRU management module acquires data to be synchronized and determines the type of the data to be synchronized; the FRU management module processes the data to be synchronized according to the type of the data to be synchronized; the FRU management module determines synchronous data from the processed data to be synchronized under the condition of running to the data synchronization logic, and sends the synchronous data to the data synchronization module; and the data synchronization module is used for scheduling the synchronous data, determining a transmission link of the synchronous data and transmitting the synchronous data to the substrate management controller of the receiving end through the transmission link.
The apparatus embodiments described above are merely illustrative, wherein the elements illustrated as separate elements may or may not be physically separate, and the elements shown as elements may or may not be physical elements, may be located in one place, or may be distributed over a plurality of network elements. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment. Those of ordinary skill in the art will understand and implement the present invention without undue burden.
From the above description of the embodiments, it will be apparent to those skilled in the art that the embodiments may be implemented by means of software plus necessary general hardware platforms, or of course may be implemented by means of hardware. Based on this understanding, the foregoing technical solution may be embodied essentially or in a part contributing to the prior art in the form of a software product, which may be stored in a computer readable storage medium, such as ROM/RAM, a magnetic disk, an optical disk, etc., including several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute the method described in the respective embodiments or some parts of the embodiments.
Finally, it should be noted that: the above embodiments are only for illustrating the technical solution of the present invention, and are not limiting; although the invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical scheme described in the foregoing embodiments can be modified or some technical features thereof can be replaced by equivalents; such modifications and substitutions do not depart from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims (10)

1. The data synchronization method is characterized by being applied to a baseboard management controller of a transmitting end, wherein the baseboard management controller comprises a Field Replaceable Unit (FRU) management module and a data synchronization module, and the data synchronization method comprises the following steps:
the FRU management module acquires data to be synchronized and determines the type of the data to be synchronized;
the FRU management module processes the data to be synchronized according to the type of the data to be synchronized;
the FRU management module determines synchronous data from the processed data to be synchronized under the condition of running to the data synchronization logic, and sends the synchronous data to the data synchronization module;
and the data synchronization module is used for scheduling the synchronous data, determining a transmission link of the synchronous data and transmitting the synchronous data to a baseboard management controller of a receiving end through the transmission link.
2. The data synchronization method of claim 1, wherein the types include static data and dynamic data;
the FRU management module processes the data to be synchronized according to the type of the data to be synchronized, and comprises the following steps:
the FRU management module stores the static data in a memory of the FRU management module, and a static data synchronization status word is reserved in the FRU management module and used for indicating whether the static data are synchronized or not;
And the FRU management module performs stripe region division, numbering and check bit addition on the dynamic data, and establishes synchronous copies of the dynamic data in the memory of the FRU management module.
3. The data synchronization method of claim 2, wherein the FRU management module, when running to data synchronization logic, determines synchronization data from the processed data to be synchronized, comprising:
the FRU management module determines whether static data synchronous status words are static synchronous data or not from the processed static data under the condition of running to data synchronous logic;
the FRU management module encapsulates the static synchronous data according to a static data frame format, and takes the encapsulated static synchronous data as the synchronous data, wherein the static data frame format comprises a data separation field, a static data synchronous state word and a static data segment.
4. The data synchronization method of claim 2, wherein the FRU management module, when running to data synchronization logic, determines synchronization data from the processed data to be synchronized, comprising:
the FRU management module determines whether synchronous copies of dynamic data exist in a local memory under the condition of running to data synchronous logic;
If synchronous copies of the dynamic data exist in the local memory, determining dynamic synchronous data which changes compared with the existing synchronous copies from the processed dynamic data, and taking the dynamic synchronous data as the synchronous data;
and if the synchronous copy of the dynamic data does not exist in the local memory, the processed dynamic data is used as the synchronous data.
5. The method according to claim 1, wherein the data synchronization module schedules the synchronization data, determines a transmission link of the synchronization data, and transmits the synchronization data to a baseboard management controller of a receiving end through the transmission link, and includes:
determining a sending interface of the synchronous data according to the requirement of the FRU management module on the real-time property of the data, wherein the sending interface comprises a synchronous interface or an asynchronous interface;
when the synchronous interface is called to send the synchronous data, a priority field is added in a data head frame of the synchronous data, the value of the priority field is determined by inquiring a priority level table based on the serial number of the FRU management module, and the priority level table is pre-established in the data synchronous module according to the instantaneity and the data quantity of each FRU management module;
And scheduling the synchronous data according to the priority field, determining a transmission link of the synchronous data, and transmitting the synchronous data to a baseboard management controller of a receiving end through the transmission link.
6. The method of claim 5, further comprising:
when the asynchronous interface is called to send the synchronous data, the synchronous data are summarized in a sending data pool of the data synchronous module, an asynchronous data sending thread of the data synchronous module reads a plurality of data packets in the sending data pool at one time, the priority ordering is carried out on the plurality of data packets, and a physical link is called according to the ordering result to send the read data packets in sequence.
7. The method for synchronizing data according to claim 5, wherein said determining the transmission link of the synchronized data comprises:
under the condition that the main link and the standby link are normal, determining the standby link as a transmission link of the synchronous data;
and under the condition that any link is abnormal, determining the transmission link of the synchronous data in a fair competition mode.
8. A baseboard management controller, comprising: a field replaceable unit FRU management module and a data synchronization module,
The FRU management module is used for acquiring data to be synchronized and determining the type of the data to be synchronized; processing the data to be synchronized according to the type of the data to be synchronized; under the condition of running to a data synchronization logic, determining synchronous data from the processed data to be synchronized, and sending the synchronous data to the data synchronization module;
the data synchronization module is used for scheduling the synchronous data, determining a transmission link of the synchronous data, and transmitting the synchronous data to a baseboard management controller of a receiving end through the transmission link.
9. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the processor implements the data synchronization method of any one of claims 1 to 7 when the program is executed by the processor.
10. A non-transitory computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when executed by a processor, implements the data synchronization method according to any one of claims 1 to 7.
CN202310779219.5A 2023-06-28 2023-06-28 Data synchronization method, baseboard management controller, electronic device and storage medium Pending CN116795290A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310779219.5A CN116795290A (en) 2023-06-28 2023-06-28 Data synchronization method, baseboard management controller, electronic device and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310779219.5A CN116795290A (en) 2023-06-28 2023-06-28 Data synchronization method, baseboard management controller, electronic device and storage medium

Publications (1)

Publication Number Publication Date
CN116795290A true CN116795290A (en) 2023-09-22

Family

ID=88041306

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310779219.5A Pending CN116795290A (en) 2023-06-28 2023-06-28 Data synchronization method, baseboard management controller, electronic device and storage medium

Country Status (1)

Country Link
CN (1) CN116795290A (en)

Similar Documents

Publication Publication Date Title
US8046520B2 (en) Compound computer system and method for sharing PCI devices thereof
US10042583B2 (en) Device management method, device, and device management controller
US20070286184A1 (en) Cluster system, load distribution method, optimization client program, and arbitration server program
CN107729213B (en) Background task monitoring method and device
BR112019027654A2 (en) train network node and canopen-based train network node monitoring method
CN110300188B (en) Data transmission system, method and device
CN109921942B (en) Cloud platform switching control method, device and system and electronic equipment
CN111880906A (en) Virtual machine high-availability management method, system and storage medium
CN111581043A (en) Server power consumption monitoring method and device and server
CN111400041A (en) Server configuration file management method and device and computer readable storage medium
CN115964153A (en) Asynchronous task processing method, device, equipment and storage medium
CN114844809A (en) Multi-factor arbitration method and device based on network heartbeat and kernel disk heartbeat
CN117453036A (en) Method, system and device for adjusting power consumption of equipment in server
CN113658351A (en) Product production method and device, electronic equipment and storage medium
US11314670B2 (en) Method, apparatus, and device for transmitting file based on BMC, and medium
CN109510730A (en) Distributed system and its monitoring method, device, electronic equipment and storage medium
CN116795290A (en) Data synchronization method, baseboard management controller, electronic device and storage medium
CN109491867A (en) A kind of communication automatic recovery method and device
CN115904888A (en) Alarm method, computing device and storage medium
CN115102862A (en) Automatic synchronization method and device for SDN equipment
CN111159088A (en) IIC bus communication method and system based on heterogeneous multi-core processor
CN117614805B (en) Data processing system for monitoring state of data center
CN113190183B (en) Storage cluster device and equipment mounting method
CN110752939A (en) Service process fault processing method, notification method and device
US10897390B2 (en) Takeover method of process, cluster construction program and cluster construction apparatus

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