WO2020253111A1 - Automatic expansion method and apparatus for blockchain node, and operation and maintenance terminal and storage medium - Google Patents

Automatic expansion method and apparatus for blockchain node, and operation and maintenance terminal and storage medium Download PDF

Info

Publication number
WO2020253111A1
WO2020253111A1 PCT/CN2019/120904 CN2019120904W WO2020253111A1 WO 2020253111 A1 WO2020253111 A1 WO 2020253111A1 CN 2019120904 W CN2019120904 W CN 2019120904W WO 2020253111 A1 WO2020253111 A1 WO 2020253111A1
Authority
WO
WIPO (PCT)
Prior art keywords
disk
capacity
node
remaining
remaining capacity
Prior art date
Application number
PCT/CN2019/120904
Other languages
French (fr)
Chinese (zh)
Inventor
张青亮
Original Assignee
深圳壹账通智能科技有限公司
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 深圳壹账通智能科技有限公司 filed Critical 深圳壹账通智能科技有限公司
Publication of WO2020253111A1 publication Critical patent/WO2020253111A1/en

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/0608Saving storage space on storage systems
    • 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/0638Organizing or formatting or addressing of data
    • 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]

Definitions

  • This application relates to the field of blockchain, and in particular to methods, devices, operation and maintenance terminals, and computer-readable storage media for automatic expansion of blockchain nodes.
  • the main purpose of this application is to provide an automatic expansion method, device, operation and maintenance terminal, and computer-readable storage medium for blockchain nodes, aiming to solve the current inability to effectively set the data capacity of each chain node, resulting in disk space utilization Technical problems with low rates.
  • this application provides an automatic expansion method of blockchain nodes, which includes the following steps:
  • the steps to expand the target disk capacity include:
  • the remaining disk capacity value ⁇ after the preset time is less than the preset capacity setting value ⁇
  • the current disk remaining capacity value ⁇ of the node is obtained, and the current disk remaining capacity value ⁇ of the node is set to the preset capacity value.
  • the remaining disk capacity value ⁇ after the preset time is greater than or equal to the preset capacity setting value ⁇
  • the remaining disk capacity value ⁇ after the preset time is used as the target disk capacity expansion ⁇ of the node.
  • this application also provides an automatic expansion device for blockchain nodes, the device including:
  • the acquisition module is used to acquire the remaining disk capacity change data of the nodes in the blockchain
  • the obtaining module is further configured to obtain the disk capacity prediction function corresponding to the node according to the disk remaining capacity change data, and obtain the disk capacity value of the node after a preset time according to the disk capacity prediction function;
  • the expansion module is used to determine the target expansion capacity of the disk according to the remaining disk capacity value of the node after a preset time, so as to expand the node according to the target expansion capacity of the disk; wherein the expansion module includes:
  • the judging unit is used to judge whether the remaining capacity value ⁇ of the disk after the preset time is less than the preset capacity setting value ⁇ ;
  • the setting unit is configured to use the disk remaining capacity value ⁇ after the preset time as the target disk capacity expansion ⁇ of the node when the remaining disk capacity value ⁇ after the preset time is greater than or equal to the preset capacity setting value ⁇ .
  • the present application also provides an operation and maintenance terminal, the operation and maintenance terminal includes: a communication module, a memory, a processor, and a computer that is stored on the memory and can run on the processor. Reading instructions, when the computer-readable instructions are executed by the processor, the steps of the automatic expansion method for blockchain nodes as described above are realized.
  • the present application also provides a computer-readable storage medium having computer-readable instructions stored on the computer-readable storage medium, and when the computer-readable instructions are executed by a processor, the above Steps of the automatic expansion method for blockchain nodes.
  • Figure 1 is a schematic structural diagram of a hardware operating environment involved in a solution of an embodiment of the present application
  • FIG. 2 is a schematic flowchart of the first embodiment of the automatic expansion method for blockchain nodes according to the application;
  • step S20 is a schematic flowchart of step S20 in the second embodiment of the automatic expansion method for blockchain nodes of this application;
  • FIG. 4 is a schematic diagram of functional modules of an embodiment of an automatic expansion device for blockchain nodes of this application.
  • the operation and maintenance terminal may be a server or a device terminal, such as a computer.
  • the operation and maintenance terminal may include a communication module 10, a memory 20, a processor 30 and other components.
  • the processor 30 is respectively connected to the memory 20 and the communication module 10, and computer-readable instructions are stored on the memory 20, and the computer-readable instructions are simultaneously used by the processor 30.
  • the computer-readable instructions implement the steps of the following method embodiments when executed.
  • the communication module 10 can be connected to external communication equipment via a network.
  • the communication module 10 can receive requests sent by external communication devices, and can also send requests, instructions and information to the external communication devices.
  • the external communication device may be other devices or other operation and maintenance terminals, such as other servers.
  • the memory 20 can be used to store software programs and various data.
  • the memory 20 may mainly include a storage program area and a storage data area, where the storage program area may store an operating system, at least one application program required by a function (for example, obtain the disk capacity change data of a blockchain node), etc.; the storage data area may Including the database, the data storage area can store data or information created according to the use of the operation and maintenance terminal.
  • the memory 20 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one magnetic disk storage device, a flash memory device, or other volatile solid-state storage devices.
  • the processor 30 is the control center of the operation and maintenance terminal, which uses various interfaces and lines to connect various parts of the entire operation and maintenance terminal, and runs or executes software programs, computer-readable instructions and/or modules stored in the memory 20, and The data stored in the memory 20 is called to perform various functions and processing data of the operation and maintenance terminal, thereby overall monitoring of the operation and maintenance terminal.
  • the processor 30 may include one or more processing units; optionally, the processor 30 may integrate an application processor and a modem processor, where the application processor mainly processes the operating system, user interface, and application programs, etc.
  • the adjustment processor mainly deals with wireless communication. It can be understood that the above modem processor may not be integrated into the processor 30.
  • the above-mentioned operation and maintenance terminal may also include a circuit control module for connecting with a power source to ensure the normal operation of other components.
  • the above-mentioned operation and maintenance terminal may also include a display module for extracting data in the memory 20 and displaying the system interface of the operation and maintenance terminal, the interaction interface with the user, and the disk capacity change of the blockchain.
  • the operation and maintenance terminal structure shown in FIG. 1 does not constitute a limitation on the operation and maintenance terminal, and may include more or less components than shown in the figure, or a combination of certain components, or different components Layout.
  • the method includes:
  • Step S10 Obtain the remaining disk capacity change data of the node in the blockchain
  • the capacity change data may include the occupied disk capacity corresponding to different historical time points and the remaining capacity of the disk that can be occupied by the node.
  • the remaining disk capacity change data can be obtained by obtaining the recorded remaining disk capacity at different historical time points.
  • Step S20 Obtain the disk capacity prediction function corresponding to the node according to the disk remaining capacity change data, and obtain the disk remaining capacity value of the node after a preset time according to the disk capacity prediction function;
  • a preset statistical method may be used.
  • the statistical method may be to use a neural network to regress the remaining capacity change data of the disk, for example, linear regression or adaptive regression.
  • the disk capacity prediction function is obtained based on the historical change trend represented by the remaining disk capacity change data during a certain period of time in the past, which fits the previous capacity changes.
  • This solution uses the change data obtained in the past. To form a prediction function, it is used to estimate the remaining disk capacity value of the node at a certain time or multiple times later.
  • the disk capacity prediction function can be obtained with reference to the remaining disk capacity change data 6 hours before the current time.
  • Step S30 Determine the target expansion capacity of the disk according to the remaining disk capacity value of the node after a preset time, so as to expand the node according to the target expansion capacity of the disk.
  • Disk target expansion capacity refers to the idle disk capacity that the node needs to occupy after a preset time, or the remaining disk capacity value that needs to be reached after expansion.
  • the target disk expansion capacity can be obtained according to the disk capacity prediction function to obtain the node after the preset time
  • the remaining capacity value of the disk can be determined.
  • the preset value can be set to compare with the remaining capacity value of the disk after a preset time, or the remaining capacity value of the disk after the preset time can be brought into the formula for calculation and determination. Expanding the capacity of the node can be directly expanding the running container of the blockchain node through the thermal expansion technology, without affecting normal use.
  • the step of expanding the node according to the target expansion capacity of the disk in the above step S30 may be: before the preset time is reached, the remaining space of the disk occupied by the node is expanded to the target expansion capacity of the disk by means of hot expansion.
  • the remaining disk capacity change data of the node in the blockchain is obtained; the disk capacity prediction function corresponding to the node is obtained according to the remaining disk capacity change data, and the preset time interval is obtained according to the disk capacity prediction function.
  • the disk capacity prediction function obtained predicts the remaining disk capacity value of the node after the preset time, and then determines the target expansion capacity of the disk to be expanded according to the remaining disk capacity value, so as to expand according to the target expansion capacity of the disk.
  • the disk remaining The capacity change data includes the time point and the corresponding remaining capacity value
  • the step S20 includes:
  • Step S21 selecting a starting time point from all time points of the remaining capacity change data of the disk, and using all time points before the starting time point and the corresponding remaining capacity value as training data, and setting the starting time point All time points after the time point and the corresponding remaining capacity value are used as sample data;
  • the process of obtaining a prediction function capable of predicting the value of the remaining capacity of the disk after a preset time according to the remaining capacity change data of the disk is further limited.
  • the accuracy of the disk capacity prediction function is related to the remaining disk capacity value of the node after the preset time and the accuracy of the target expansion capacity result of the disk. Therefore, it is necessary to perform the function before obtaining the final disk capacity prediction function.
  • Acquisition and training which involves the acquisition of training data and sample data. All disk remaining capacity change data can be divided according to time points. The time point before the selected starting time point and the corresponding remaining capacity values are training data, and the time point after the selected starting time point and the corresponding remaining capacity respectively The capacity value is used as sample data.
  • the starting time point of dividing the sample data and the training data is in the middle position in the time axis formed by the time points, or the position of the starting time point is such that the total capacity of the training data is greater than or equal to the total capacity of the sample data.
  • Step S22 Input the training data into a preset calculator for regression to obtain a reference prediction function related to the time point and the remaining capacity value;
  • the regression can be at least one of linear regression and adaptive regression, and finally get The change curve function of can be used as a reference prediction function, which reflects the law of the time point and the remaining capacity value of the disk, and is related to the time point and the remaining capacity value.
  • step S23 the reference prediction function is iterated through the sample data, so that the reference prediction function at the completion of the iteration is used as the disk capacity prediction function corresponding to the node after the iteration is completed.
  • the benchmark prediction function obtained through the training data meets the change of the disk capacity after the preset time can be verified by the sample data, and if the error is large, the benchmark prediction function can be revised and iterated to reduce the prediction error. It is understandable that the latest modified benchmark prediction function when the final iteration is completed is the disk capacity prediction function corresponding to the node.
  • This solution uses the combination of sample data, training data, and regression iterative operations to give a process of how to obtain the disk capacity prediction function, helping to finally obtain the prediction function that meets the actual disk capacity.
  • step S23 may include:
  • Step S231 using the reference prediction function to calculate the predicted remaining capacity value corresponding to the node at any point in the sample data;
  • one or several time points in the sample data can be used to calculate the predicted remaining capacity value through the reference prediction function.
  • the benchmark prediction function is a function related to the time point and the remaining capacity value. Therefore, as long as the time point is known, the remaining capacity value can be calculated by the function, and the function is obtained through the curve, not the actual situation, so The calculated remaining capacity value is the predicted remaining capacity value.
  • Step S232 Obtain the actual remaining capacity value corresponding to the time point when the predicted remaining capacity value is calculated from the sample data, and compare the predicted remaining capacity value with the actual remaining capacity value to obtain the remaining capacity error;
  • the sample data contains the changes in the remaining capacity value of the disk that have been recorded after the selected start time point, after obtaining the predicted remaining capacity value, the actual remaining capacity value at the same time point can be obtained from the sample data, and then the prediction The remaining capacity value is compared with the actual remaining capacity value, and the difference between the actual value and the predicted value is obtained as the remaining capacity error, so as to evaluate the accuracy of the benchmark prediction function based on the obtained remaining capacity error.
  • Step S233 determining whether the remaining capacity error meets a preset iteration termination condition; wherein, when the remaining capacity error meets the preset iteration termination condition, the iteration is terminated;
  • the foregoing preset iteration termination conditions can be set according to actual needs. For example, the number of calculation errors, the number of remaining capacity errors, and/or the number of iterations can be recorded. When the number or number is greater than or equal to a certain set value, it is considered Meet the iteration termination condition; and/or the calculated error is less than a certain extreme value, it is deemed to meet the iteration termination condition. When it is determined that the iteration termination condition is met, the benchmark prediction function of the latest iteration can be output, and the iteration can be stopped.
  • Step S234 When the remaining capacity error does not meet a preset iteration termination condition, update the reference prediction function according to the remaining capacity error.
  • the loss function of the benchmark prediction function can be calculated according to the remaining capacity error, and the parameters of the benchmark prediction function can be adjusted according to the loss function to realize the iteration of the benchmark prediction function until the iteration is completed. Updating the benchmark prediction function by setting the iteration termination condition can help improve the accuracy of the function prediction, which is closer to the disk space changes of actual blockchain nodes, and indirectly improves the accuracy of on-demand expansion.
  • the step of judging whether the remaining capacity error meets the preset iteration termination condition may include:
  • step S30 includes:
  • Step S31 judging whether the remaining capacity value ⁇ of the disk after a preset time is less than the preset capacity setting value ⁇ ;
  • the preset capacity setting value can be fixed.
  • the preset capacity setting value is greater than or equal to 0, and it can also gradually increase or decrease over time. In actual operation, it can be based on the data in different fields actually used by the blockchain. The characteristics of storage are determined. In each different time range, the remaining disk capacity value after the preset time can be compared with the preset capacity setting value belonging to the same time range to determine the target expansion capacity of the disk to which the final node needs to be expanded.
  • the remaining disk capacity value ⁇ after the preset time is greater than or equal to the preset capacity setting value ⁇
  • the remaining disk capacity value ⁇ after the preset time is used as the target disk capacity expansion ⁇ of the node. It is understandable that what is originally predicted based on the disk capacity prediction function is the final target expansion capacity of the disk, then it can be considered that the disk space is still sufficient after the preset time and there is no need to perform disk expansion operations.
  • the remaining disk capacity value is smaller than the preset disk capacity setting value after the preset time
  • the remaining capacity of the disk after expansion is always larger than the current value of the remaining space of the disk, which is more balanced and meets the data storage requirements of the node.
  • the method further includes: determining whether the target expansion capacity of the disk of the node is Is greater than the total remaining capacity of the hard disk where the node is located; when the target disk capacity of the node is greater than the total remaining capacity of the disk where the node is located, a warning message of insufficient hard disk capacity is issued; when the target disk capacity of the node is less than When it is equal to the total remaining capacity of the disk where the node is located, the step of expanding the node according to the target expansion capacity of the disk is executed.
  • the device may be a server, or an operation and maintenance terminal, such as a computer.
  • the device includes:
  • the obtaining module 10 is used to obtain the remaining disk capacity change data of the nodes in the blockchain;
  • the obtaining module 10 is further configured to obtain the disk capacity prediction function corresponding to the node according to the disk remaining capacity change data, and obtain the disk capacity value of the node after a preset time according to the disk capacity prediction function ;
  • the expansion module 20 is configured to determine the target expansion capacity of the disk according to the remaining disk capacity value of the node after a preset time, so as to expand the node according to the target expansion capacity of the disk.
  • the disk remaining capacity change data includes a time point and a corresponding remaining capacity value; the acquiring module includes:
  • the selecting unit is used to select a starting time point from all time points of the remaining capacity change data of the disk, to use all time points before the starting time point and the corresponding remaining capacity value as the training data, and the All time points after the start time point and the corresponding remaining capacity value are taken as sample data;
  • the regression unit is used to input the training data into a preset calculator for regression to obtain a reference prediction function related to the time point and the remaining capacity value;
  • the iterative unit is configured to iterate the reference prediction function through the sample data, so as to use the reference prediction function at the completion of the iteration as the disk capacity prediction function corresponding to the node after the iteration is completed.
  • the iteration unit includes:
  • the calculation subunit is configured to use the reference prediction function to calculate the predicted remaining capacity value corresponding to the node at any point in the sample data;
  • the comparison subunit is used to obtain the actual remaining capacity value corresponding to the time point when the predicted remaining capacity value is calculated from the sample data, and to compare the predicted remaining capacity value with the actual remaining capacity value to obtain the remaining capacity error;
  • the judging subunit is used to judge whether the remaining capacity error meets the preset iteration termination condition; and when the remaining capacity error meets the preset iteration termination condition, the iteration terminates;
  • the update subunit is configured to update the reference prediction function according to the remaining capacity error when the remaining capacity error does not meet a preset iteration termination condition.
  • the judging subunit may be used for:
  • the expansion module includes:
  • the judging unit is used to judge whether the remaining capacity value ⁇ of the disk after the preset time is less than the preset capacity setting value ⁇ ;
  • the expansion module further includes:
  • the setting unit is configured to use the disk remaining capacity value ⁇ after the preset time as the target disk capacity expansion ⁇ of the node when the remaining disk capacity value ⁇ after the preset time is greater than or equal to the preset capacity setting value ⁇ .
  • the device further includes:
  • a judging module for judging whether the target disk capacity of the node is greater than the total remaining capacity of the hard disk where the node is located; and when the target disk capacity of the node is less than or equal to the total remaining capacity of the disk where the node is located, Trigger the expansion module to perform the step of expanding the node according to the target expansion capacity of the disk;
  • the sending module is used to send a prompt message that the hard disk capacity is insufficient when the target expansion capacity of the disk of the node is greater than the total remaining capacity of the disk where the node is located.
  • This application also proposes a computer-readable storage medium, which may be a non-volatile readable storage medium on which computer-readable instructions are stored.
  • the computer-readable storage medium may be the memory 20 in the operation and maintenance terminal of FIG. 1, or may be ROM (Read-Only Memory)/RAM (Random Access Memory), magnetic disk , At least one of the optical discs, the computer-readable storage medium includes a number of instructions to make a terminal device with a processor (which can be a mobile phone, a computer, a server, or a network device, etc.) execute the various embodiments of the present application The method described.
  • a processor which can be a mobile phone, a computer, a server, or a network device, etc.

Abstract

An automatic expansion method and apparatus for a blockchain node, and an operation and maintenance terminal and a storage medium, applied to blockchain operation and maintenance. The method comprises: obtaining the remaining disk capacity change data of a node in a blockchain (S10); according to the remaining disk capacity change data, obtaining a disk capacity prediction function corresponding to the node, and obtaining the remaining disk capacity value of the node after a preset time according to the disk capacity prediction function (S20); and determining a target disk expansion capacity according to the remaining disk capacity value of the node after the preset time, so as to expand the node according to the target disk expansion capacity (S30). The remaining disk capacity value of the node after the preset time is estimated by means of the disk capacity prediction function, then the target disk expansion capacity is obtained, and accordingly, the effective expansion of the blockchain node according to requirements is implemented, thereby rationally utilizing the disk storage space, increasing the disk space utilization rate, and helping to reduce in the risk caused by manual intervention.

Description

区块链节点的自动扩容方法、装置、运维终端及存储介质Automatic expansion method, device, operation and maintenance terminal and storage medium of blockchain node
本申请要求于2019年6月19日提交中国专利局、申请号为201910532942.7、发明名称为“区块链节点的自动扩容方法、装置、运维终端及存储介质”的中国专利申请的优先权,其全部内容通过引用结合在申请中。This application requires the priority of a Chinese patent application submitted to the Chinese Patent Office on June 19, 2019, with the application number 201910532942.7, and the invention title of "Blockchain node automatic expansion method, device, operation and maintenance terminal and storage medium". The entire content is incorporated into the application by reference.
技术领域Technical field
本申请涉及区块链领域,尤其涉及区块链节点的自动扩容方法、装置、运维终端及计算机可读存储介质。This application relates to the field of blockchain, and in particular to methods, devices, operation and maintenance terminals, and computer-readable storage media for automatic expansion of blockchain nodes.
背景技术Background technique
随着比特币的出现,区块链技术出现在人们视野中,目前区块链技术被广泛运用在数据安全领域。而在区块链项目运维中,由于对每条区块链上节点的写入数据量无法准确评估,因此容易出现存储不足的情况。当出现区块链的节点存储不足时,需要人工介入补充存储资源和/或进行数据迁移,这无疑增加了服务成本,如果存储预备太多,将造成资源大大浪费。因此如何有效地设置每条链上节点的数据容量,以提高磁盘空间利用率是亟待解决的问题。With the advent of Bitcoin, blockchain technology has appeared in people's vision. At present, blockchain technology is widely used in the field of data security. In the operation and maintenance of blockchain projects, since the amount of data written to each node on the blockchain cannot be accurately evaluated, it is prone to insufficient storage. When the node storage of the blockchain is insufficient, manual intervention is required to supplement storage resources and/or perform data migration, which undoubtedly increases service costs. If storage is prepared too much, resources will be greatly wasted. Therefore, how to effectively set the data capacity of each node on the chain to improve disk space utilization is an urgent problem to be solved.
发明内容Summary of the invention
本申请的主要目的在于提供一种区块链节点的自动扩容方法、装置、运维终端及计算机可读存储介质,旨在解决目前无法有效设置每条链上节点的数据容量,以致磁盘空间利用率低的技术问题。The main purpose of this application is to provide an automatic expansion method, device, operation and maintenance terminal, and computer-readable storage medium for blockchain nodes, aiming to solve the current inability to effectively set the data capacity of each chain node, resulting in disk space utilization Technical problems with low rates.
为实现上述目的,本申请提供一种区块链节点的自动扩容方法,包括以下步骤:In order to achieve the above purpose, this application provides an automatic expansion method of blockchain nodes, which includes the following steps:
获取区块链中节点的磁盘剩余容量变化数据;Obtain the remaining disk capacity change data of the node in the blockchain;
根据所述磁盘剩余容量变化数据,获取所述节点对应的磁盘容量预测函数,并根据所述磁盘容量预测函数获取预设时间后所述节点的磁盘剩余容量值;Obtaining the disk capacity prediction function corresponding to the node according to the disk remaining capacity change data, and obtaining the disk remaining capacity value of the node after a preset time according to the disk capacity prediction function;
根据预设时间后所述节点的磁盘剩余容量值确定磁盘目标扩容容量,以按照所述磁盘目标扩容容量对所述节点进行扩容;所述根据预设时间后所述节点的磁盘剩余容量值确定磁盘目标扩容容量的步骤包括:Determine the target expansion capacity of the disk according to the remaining disk capacity value of the node after a preset time, so as to expand the node according to the target expansion capacity of the disk; the determining according to the remaining disk capacity value of the node after the preset time The steps to expand the target disk capacity include:
判断预设时间后的磁盘剩余容量值α是否小于预设容量设定值δ;Determine whether the remaining disk capacity value α after the preset time is less than the preset capacity setting value δ;
当预设时间后的磁盘剩余容量值α小于预设容量设定值δ时,获取所述节点的当前磁盘剩余容量值β,并将所述节点的当前磁盘剩余容量值β、预设容量设定值δ以及预设时间后的磁盘剩余容量值α输入至包括公式γ=β+δ-α的运算器中,得到所述节点的磁盘目标扩容容量γ;When the remaining disk capacity value α after the preset time is less than the preset capacity setting value δ, the current disk remaining capacity value β of the node is obtained, and the current disk remaining capacity value β of the node is set to the preset capacity value. The fixed value δ and the disk remaining capacity value α after the preset time are input into the arithmetic unit including the formula γ=β+δ-α to obtain the target disk capacity expansion γ of the node;
当预设时间后的磁盘剩余容量值α大于或等于预设容量设定值δ时,将预设时间后的磁盘剩余容量值α作为所述节点的磁盘目标扩容容量γ。When the remaining disk capacity value α after the preset time is greater than or equal to the preset capacity setting value δ, the remaining disk capacity value α after the preset time is used as the target disk capacity expansion γ of the node.
此外,为实现上述目的,本申请还提供一种区块链节点的自动扩容装置,所述装置包括:In addition, in order to achieve the above objective, this application also provides an automatic expansion device for blockchain nodes, the device including:
获取模块,用于获取区块链中节点的磁盘剩余容量变化数据;The acquisition module is used to acquire the remaining disk capacity change data of the nodes in the blockchain;
所述获取模块,还用于根据所述磁盘剩余容量变化数据,获取所述节点对应的磁盘容量预测函数,并根据所述磁盘容量预测函数获取预设时间后所述节点的磁盘剩余容量值;The obtaining module is further configured to obtain the disk capacity prediction function corresponding to the node according to the disk remaining capacity change data, and obtain the disk capacity value of the node after a preset time according to the disk capacity prediction function;
扩容模块,用于根据预设时间后所述节点的磁盘剩余容量值确定磁盘目标扩容容量,以按照所述磁盘目标扩容容量对所述节点进行扩容;其中,所述扩容模块包括:The expansion module is used to determine the target expansion capacity of the disk according to the remaining disk capacity value of the node after a preset time, so as to expand the node according to the target expansion capacity of the disk; wherein the expansion module includes:
判断单元,用于判断预设时间后的磁盘剩余容量值α是否小于预设容量设定值δ;The judging unit is used to judge whether the remaining capacity value α of the disk after the preset time is less than the preset capacity setting value δ;
运算单元,用于当预设时间后的磁盘剩余容量值α小于预设容量设定值δ时,获取所述节点的当前磁盘剩余容量值β,并将所述节点的当前磁盘剩余容量值β、预设容量设定值δ以及预设时间后的磁盘剩余容量值α输入至包括公式γ=β+δ-α的运算器中,得到所述节点的磁盘目标扩容容量γ;An arithmetic unit for obtaining the current remaining disk capacity value β of the node when the remaining disk capacity value α after a preset time is less than the preset capacity setting value δ, and calculating the current remaining disk capacity value β of the node , The preset capacity setting value δ and the disk remaining capacity value α after the preset time are input into the arithmetic unit including the formula γ=β+δ-α to obtain the target disk capacity expansion γ of the node;
设置单元,用于当预设时间后的磁盘剩余容量值α大于或等于预设容量设定值δ时,将预设时间后的磁盘剩余容量值α作为所述节点的磁盘目标扩容容量γ。The setting unit is configured to use the disk remaining capacity value α after the preset time as the target disk capacity expansion γ of the node when the remaining disk capacity value α after the preset time is greater than or equal to the preset capacity setting value δ.
此外,为实现上述目的,本申请还提供一种运维终端,所述运维终端包括:通信模块、存储器、处理器及存储在所述存储器上并可在所述处理器上运行的计算机可读指令,所述计算机可读指令被所述处理器执行时实 现如上所述的区块链节点的自动扩容方法的步骤。In addition, in order to achieve the above object, the present application also provides an operation and maintenance terminal, the operation and maintenance terminal includes: a communication module, a memory, a processor, and a computer that is stored on the memory and can run on the processor. Reading instructions, when the computer-readable instructions are executed by the processor, the steps of the automatic expansion method for blockchain nodes as described above are realized.
此外,为实现上述目的,本申请还提供一种计算机可读存储介质,所述计算机可读存储介质上存储有计算机可读指令,所述计算机可读指令被处理器执行时实现如上所述的区块链节点的自动扩容方法的步骤。In addition, in order to achieve the above object, the present application also provides a computer-readable storage medium having computer-readable instructions stored on the computer-readable storage medium, and when the computer-readable instructions are executed by a processor, the above Steps of the automatic expansion method for blockchain nodes.
本申请的一个或多个实施例的细节在下面的附图和描述中提出。本申请的其他特征和优点将从说明书、附图以及权利要求书变得明显。The details of one or more embodiments of the application are set forth in the following drawings and description. Other features and advantages of this application will become apparent from the description, drawings and claims.
附图说明Description of the drawings
图1是本申请实施例方案涉及的硬件运行环境的结构示意图;Figure 1 is a schematic structural diagram of a hardware operating environment involved in a solution of an embodiment of the present application;
图2为本申请区块链节点的自动扩容方法第一实施例的流程示意图;FIG. 2 is a schematic flowchart of the first embodiment of the automatic expansion method for blockchain nodes according to the application;
图3为本申请区块链节点的自动扩容方法第二实施例中步骤S20的流程示意图;3 is a schematic flowchart of step S20 in the second embodiment of the automatic expansion method for blockchain nodes of this application;
图4为本申请区块链节点的自动扩容装置一实施例的功能模块示意图。FIG. 4 is a schematic diagram of functional modules of an embodiment of an automatic expansion device for blockchain nodes of this application.
本申请目的的实现、功能特点及优点将结合实施例,参照附图做进一步说明。The realization, functional characteristics, and advantages of the purpose of this application will be further described in conjunction with the embodiments and with reference to the accompanying drawings.
具体实施方式Detailed ways
应当理解,此处所描述的具体实施例仅仅用以解释本申请,并不用于限定本申请。It should be understood that the specific embodiments described here are only used to explain the application, and are not used to limit the application.
请参看图1,图1为本申请所提供的运维终端的硬件结构示意图。所述运维终端可以是服务器,可以是设备终端,例如计算机,所述运维终端可以包括通信模块10、存储器20以及处理器30等部件。在所述运维终端中,所述处理器30分别与所述存储器20以及所述通信模块10连接,所述存储器20上存储有计算机可读指令,所述计算机可读指令同时被处理器30执行,所述计算机可读指令执行时实现下述方法实施例的步骤。Please refer to Figure 1, which is a schematic diagram of the hardware structure of the operation and maintenance terminal provided by this application. The operation and maintenance terminal may be a server or a device terminal, such as a computer. The operation and maintenance terminal may include a communication module 10, a memory 20, a processor 30 and other components. In the operation and maintenance terminal, the processor 30 is respectively connected to the memory 20 and the communication module 10, and computer-readable instructions are stored on the memory 20, and the computer-readable instructions are simultaneously used by the processor 30. When executed, the computer-readable instructions implement the steps of the following method embodiments when executed.
通信模块10,可通过网络与外部通讯设备连接。通信模块10可以接收外部通讯设备发出的请求,还可以发送请求、指令及信息至所述外部通讯设备。所述外部通讯设备可以是其他设备或其他运维终端,例如其他服务器等等。The communication module 10 can be connected to external communication equipment via a network. The communication module 10 can receive requests sent by external communication devices, and can also send requests, instructions and information to the external communication devices. The external communication device may be other devices or other operation and maintenance terminals, such as other servers.
存储器20,可用于存储软件程序以及各种数据。存储器20可主要包括存储程序区和存储数据区,其中,存储程序区可存储操作系统、至少一个 功能所需的应用程序(比如获取区块链节点的磁盘容量变化数据)等;存储数据区可包括数据库,存储数据区可存储根据运维终端的使用所创建的数据或信息等。此外,存储器20可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件、闪存器件、或其他易失性固态存储器件。The memory 20 can be used to store software programs and various data. The memory 20 may mainly include a storage program area and a storage data area, where the storage program area may store an operating system, at least one application program required by a function (for example, obtain the disk capacity change data of a blockchain node), etc.; the storage data area may Including the database, the data storage area can store data or information created according to the use of the operation and maintenance terminal. In addition, the memory 20 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one magnetic disk storage device, a flash memory device, or other volatile solid-state storage devices.
处理器30,是运维终端的控制中心,利用各种接口和线路连接整个运维终端的各个部分,通过运行或执行存储在存储器20内的软件程序、计算机可读指令和/或模块,以及调用存储在存储器20内的数据,执行运维终端的各种功能和处理数据,从而对运维终端进行整体监控。处理器30可包括一个或多个处理单元;可选地,处理器30可集成应用处理器和调制解调处理器,其中,应用处理器主要处理操作系统、用户界面和应用程序等,调制解调处理器主要处理无线通信。可以理解的是,上述调制解调处理器也可以不集成到处理器30中。The processor 30 is the control center of the operation and maintenance terminal, which uses various interfaces and lines to connect various parts of the entire operation and maintenance terminal, and runs or executes software programs, computer-readable instructions and/or modules stored in the memory 20, and The data stored in the memory 20 is called to perform various functions and processing data of the operation and maintenance terminal, thereby overall monitoring of the operation and maintenance terminal. The processor 30 may include one or more processing units; optionally, the processor 30 may integrate an application processor and a modem processor, where the application processor mainly processes the operating system, user interface, and application programs, etc. The adjustment processor mainly deals with wireless communication. It can be understood that the above modem processor may not be integrated into the processor 30.
尽管图1未示出,但上述运维终端还可以包括电路控制模块,用于与电源连接,保证其他部件的正常工作。上述运维终端还可以包括显示模块,用于提取存储器20中的数据,并显示出运维终端的系统界面、与用户的交互界面以及区块链的磁盘容量变化情况。本领域技术人员可以理解,图1中示出的运维终端结构并不构成对运维终端的限定,可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件布置。Although not shown in FIG. 1, the above-mentioned operation and maintenance terminal may also include a circuit control module for connecting with a power source to ensure the normal operation of other components. The above-mentioned operation and maintenance terminal may also include a display module for extracting data in the memory 20 and displaying the system interface of the operation and maintenance terminal, the interaction interface with the user, and the disk capacity change of the blockchain. Those skilled in the art can understand that the operation and maintenance terminal structure shown in FIG. 1 does not constitute a limitation on the operation and maintenance terminal, and may include more or less components than shown in the figure, or a combination of certain components, or different components Layout.
基于上述硬件结构,提出本申请方法各个实施例。Based on the foregoing hardware structure, various embodiments of the method of the present application are proposed.
参见图2,在本申请区块链节点的自动扩容方法的第一实施例中,所述方法包括:Referring to Figure 2, in the first embodiment of the automatic expansion method for blockchain nodes of this application, the method includes:
步骤S10,获取区块链中节点的磁盘剩余容量变化数据;Step S10: Obtain the remaining disk capacity change data of the node in the blockchain;
需要说明的是,去中心化的区块链技术中维护信息统一的账本数据量越大,每个节点所需的存储容量就越多,而节点的存储也依赖于磁盘的容量大小,因此可以获取区块链中每个节点对应占据磁盘的容量变化情况数据。其中容量变化情况数据可以包括不同历史时间点对应已占据磁盘容量情况以及该节点可占据磁盘的剩余容量,通过获取记录的不同历史时间点的磁盘剩余容量可以得到磁盘剩余容量变化数据。It should be noted that in decentralized blockchain technology, the larger the amount of data in the ledger that maintains unified information, the more storage capacity each node requires, and the storage of nodes also depends on the capacity of the disk, so it can Obtain the data of the capacity change of each node in the blockchain corresponding to the occupied disk. The capacity change data may include the occupied disk capacity corresponding to different historical time points and the remaining capacity of the disk that can be occupied by the node. The remaining disk capacity change data can be obtained by obtaining the recorded remaining disk capacity at different historical time points.
可选地,在确定剩余容量时,可以获取区块链中多个节点在历史时间点对应可占据磁盘的剩余空间值,然后去掉所有的值中的最大值和最小值, 求取平均值以作为该时间点的磁盘剩余容量,这样可以避免某个节点的磁盘故障而导致预测的预设时间点的磁盘剩余容量不准确的问题。Optionally, when determining the remaining capacity, you can obtain the remaining space value of multiple nodes in the blockchain that can occupy the disk at a historical time point, and then remove the maximum and minimum values among all the values, and calculate the average value to As the remaining capacity of the disk at this point in time, the problem of inaccurate prediction of the remaining capacity of the disk at the preset time point caused by a disk failure of a certain node can be avoided.
进一步地,还可以在统计历史时间点内节点的磁盘剩余容量时,计算各节点的磁盘剩余容量与求取的平均值的差值,并判断差值是否大于或等于预设阈值,若差值大于或等于预设阈值,表明实际区块链中对应节点的磁盘存在故障,存储容量与其他节点相比太大,可以发送故障报警提示消息给运维人员,起到了节点磁盘存储监管的作用。Further, it is also possible to calculate the difference between the remaining disk capacity of each node and the average value obtained when the remaining disk capacity of the node in the historical time point is counted, and to determine whether the difference is greater than or equal to the preset threshold, if the difference is If it is greater than or equal to the preset threshold, it indicates that the disk of the corresponding node in the actual blockchain is faulty. The storage capacity is too large compared to other nodes. Fault alarm messages can be sent to the operation and maintenance personnel, playing the role of node disk storage supervision.
步骤S20,根据所述磁盘剩余容量变化数据,获取所述节点对应的磁盘容量预测函数,并根据所述磁盘容量预测函数获取预设时间后所述节点的磁盘剩余容量值;Step S20: Obtain the disk capacity prediction function corresponding to the node according to the disk remaining capacity change data, and obtain the disk remaining capacity value of the node after a preset time according to the disk capacity prediction function;
在本实施例中,可以通过预设统计方法,该统计方法可以是利用神经网络对磁盘剩余容量变化数据进行回归化,例如可以是线性回归或自适应回归。或者,还可以参考其他机器学习算法,例如决策树或随机森林算法等等,得到能够用于预测区块链中该节点未来时间内磁盘剩余空间容量的预测函数。In this embodiment, a preset statistical method may be used. The statistical method may be to use a neural network to regress the remaining capacity change data of the disk, for example, linear regression or adaptive regression. Alternatively, you can also refer to other machine learning algorithms, such as decision trees or random forest algorithms, etc., to obtain a prediction function that can be used to predict the remaining disk space capacity of the node in the blockchain in the future.
可以理解的是,磁盘容量预测函数是根据过去某段时间内的磁盘剩余容量变化数据所代表的历史变化趋势所获取到的,贴合于之前的容量变化情况,本方案通过过去得到的变化数据来形成预测函数,用于预估之后某个时间或多个时间的节点的磁盘剩余容量值。可选地,其中磁盘容量预测函数可以参考当前时间6个小时以前的磁盘剩余容量变化数据进行获取。It is understandable that the disk capacity prediction function is obtained based on the historical change trend represented by the remaining disk capacity change data during a certain period of time in the past, which fits the previous capacity changes. This solution uses the change data obtained in the past. To form a prediction function, it is used to estimate the remaining disk capacity value of the node at a certain time or multiple times later. Optionally, the disk capacity prediction function can be obtained with reference to the remaining disk capacity change data 6 hours before the current time.
步骤S30,根据预设时间后所述节点的磁盘剩余容量值确定磁盘目标扩容容量,以按照所述磁盘目标扩容容量对所述节点进行扩容。Step S30: Determine the target expansion capacity of the disk according to the remaining disk capacity value of the node after a preset time, so as to expand the node according to the target expansion capacity of the disk.
其中磁盘目标扩容容量是指预设时间之后节点需要占据的空闲磁盘容量,或者扩容后需要达到的磁盘剩余容量值,磁盘目标扩容容量的获取则可以依据磁盘容量预测函数得到的预设时间后节点的磁盘剩余容量值进行确定,例如可以设定预设值与预设时间后的磁盘剩余容量值进行比较确定,或者还可以将预设时间后的磁盘剩余容量值带入公式中进行计算确定。对节点进行扩容可以是通过热扩容技术直接对区块链节点运行中的容器进行扩展,不影响正常使用。Disk target expansion capacity refers to the idle disk capacity that the node needs to occupy after a preset time, or the remaining disk capacity value that needs to be reached after expansion. The target disk expansion capacity can be obtained according to the disk capacity prediction function to obtain the node after the preset time The remaining capacity value of the disk can be determined. For example, the preset value can be set to compare with the remaining capacity value of the disk after a preset time, or the remaining capacity value of the disk after the preset time can be brought into the formula for calculation and determination. Expanding the capacity of the node can be directly expanding the running container of the blockchain node through the thermal expansion technology, without affecting normal use.
进一步地,上述步骤S30中按照磁盘目标扩容容量对节点进行扩容的步骤可以是:在达到预设时间之前,通过热扩容的方式将节点占据磁盘的 剩余空间扩容至磁盘目标扩容容量。通过在预设时间之前进行节点磁盘剩余容量的调整,能够防止出现节点存储不足的情况,减少人工介入的次数,使区块链节点数据的存储能够得到保障。Further, the step of expanding the node according to the target expansion capacity of the disk in the above step S30 may be: before the preset time is reached, the remaining space of the disk occupied by the node is expanded to the target expansion capacity of the disk by means of hot expansion. By adjusting the remaining capacity of the node's disk before the preset time, it is possible to prevent insufficient node storage, reduce the number of manual interventions, and ensure the storage of blockchain node data.
本实施例通过获取区块链中节点的磁盘剩余容量变化数据;根据所述磁盘剩余容量变化数据,获取所述节点对应的磁盘容量预测函数,并根据所述磁盘容量预测函数获取预设时间后所述节点的磁盘剩余容量值;根据预设时间后所述节点的磁盘剩余容量值确定磁盘目标扩容容量,以按照所述磁盘目标扩容容量对所述节点进行扩容。其中通过得到的磁盘容量预测函数预测出了预设时间后节点的磁盘剩余容量值,进而根据磁盘剩余容量值确定了磁盘待扩容到的磁盘目标扩容容量,以按照磁盘目标扩容容量进行扩容,由此能够解决人工介入增加了服务成本,或者存储预备太多造成资源大大浪费的问题,实现了区块链节点的按需有效扩容,合理利用了磁盘存储空间,提高了磁盘空间利用率,帮助减少了人工干预带来的风险。In this embodiment, the remaining disk capacity change data of the node in the blockchain is obtained; the disk capacity prediction function corresponding to the node is obtained according to the remaining disk capacity change data, and the preset time interval is obtained according to the disk capacity prediction function. The value of the remaining disk capacity of the node; and determining the target expansion capacity of the disk according to the remaining disk capacity value of the node after a preset time, so as to expand the node according to the target expansion capacity of the disk. The disk capacity prediction function obtained predicts the remaining disk capacity value of the node after the preset time, and then determines the target expansion capacity of the disk to be expanded according to the remaining disk capacity value, so as to expand according to the target expansion capacity of the disk. This can solve the problem that manual intervention increases service costs, or too much storage preparation causes a huge waste of resources, realizes the effective expansion of blockchain nodes on demand, rationally uses disk storage space, improves disk space utilization, and helps reduce The risk of manual intervention is eliminated.
进一步地,基于本申请区块链节点的自动扩容方法的第一实施例提出本申请区块链节点的自动扩容方法的第二实施例,参见图3,在本实施例中,所述磁盘剩余容量变化数据包括时间点和对应的剩余容量值;Further, based on the first embodiment of the automatic expansion method of the blockchain node of the application, a second embodiment of the automatic expansion method of the blockchain node of the application is proposed. Referring to FIG. 3, in this embodiment, the disk remaining The capacity change data includes the time point and the corresponding remaining capacity value;
所述步骤S20包括:The step S20 includes:
步骤S21,从所述磁盘剩余容量变化数据的所有时间点中选取一起始时间点,以将所述起始时间点之前的所有时间点和对应的剩余容量值作为训练数据,将所述起始时间点之后的所有时间点和对应的剩余容量值作为样本数据;Step S21, selecting a starting time point from all time points of the remaining capacity change data of the disk, and using all time points before the starting time point and the corresponding remaining capacity value as training data, and setting the starting time point All time points after the time point and the corresponding remaining capacity value are used as sample data;
在本实施例中,对于如何根据磁盘剩余容量变化数据得到能够预测预设时间之后磁盘剩余容量值的预测函数的过程进行了进一步限定。需要强调的是,磁盘容量预测函数的准确性关系到了预设时间后所述节点的磁盘剩余容量值以及磁盘目标扩容容量结果的准确性,因此在获得最终的磁盘容量预测函数之前需要对函数进行获取和训练,这就涉及到了训练数据和样本数据的获取。可以按照时间点对所有磁盘剩余容量变化数据进行划分,选择的起始时间点之前的时间点和分别对应的剩余容量值为训练数据,选择的起始时间点之后的时间点和分别对应的剩余容量值作为样本数据。其中,划分样本数据和训练数据的起始时间点在时间点构成的时间轴中处于中间位置,或者起始时间点的位置使得训练数据的总容量大小大于或等于 样本数据的总容量大小。In this embodiment, the process of obtaining a prediction function capable of predicting the value of the remaining capacity of the disk after a preset time according to the remaining capacity change data of the disk is further limited. It should be emphasized that the accuracy of the disk capacity prediction function is related to the remaining disk capacity value of the node after the preset time and the accuracy of the target expansion capacity result of the disk. Therefore, it is necessary to perform the function before obtaining the final disk capacity prediction function. Acquisition and training, which involves the acquisition of training data and sample data. All disk remaining capacity change data can be divided according to time points. The time point before the selected starting time point and the corresponding remaining capacity values are training data, and the time point after the selected starting time point and the corresponding remaining capacity respectively The capacity value is used as sample data. Wherein, the starting time point of dividing the sample data and the training data is in the middle position in the time axis formed by the time points, or the position of the starting time point is such that the total capacity of the training data is greater than or equal to the total capacity of the sample data.
步骤S22,将所述训练数据输入至预设运算器中进行回归化,以得到时间点和剩余容量值相关的基准预测函数;Step S22: Input the training data into a preset calculator for regression to obtain a reference prediction function related to the time point and the remaining capacity value;
可以是根据训练数据中的时间点和对应的磁盘剩余容量值形成时间点和磁盘剩余容量值的二维坐标散点图,其中时间点为该二维坐标散点图的横坐标,散点图中每一个散点都有时间点和对应标记的磁盘剩余容量值。然后将这些散点进行回归化形成二维曲线图,并根据二维曲线图形成磁盘剩余容量值相关的变化曲线函数,其中回归化可以是线性回归和自适应回归中的至少一种,最后得到的变化曲线函数可以作为基准预测函数,其体现的是时间点和磁盘剩余容量值的规律,与时间点和剩余容量值相关。It can be based on the time point in the training data and the corresponding disk remaining capacity value to form a two-dimensional coordinate scatter plot of the time point and the disk remaining capacity value, where the time point is the abscissa of the two-dimensional coordinate scatter plot, scatter plot Each scatter point in has a time point and a corresponding marked disk remaining capacity value. Then, these scattered points are regressed to form a two-dimensional graph, and the change curve function related to the remaining capacity value of the disk is formed according to the two-dimensional graph. The regression can be at least one of linear regression and adaptive regression, and finally get The change curve function of can be used as a reference prediction function, which reflects the law of the time point and the remaining capacity value of the disk, and is related to the time point and the remaining capacity value.
步骤S23,通过所述样本数据对所述基准预测函数进行迭代,以在完成迭代后将迭代完成时的基准预测函数作为所述节点对应的磁盘容量预测函数。In step S23, the reference prediction function is iterated through the sample data, so that the reference prediction function at the completion of the iteration is used as the disk capacity prediction function corresponding to the node after the iteration is completed.
通过训练数据得到的基准预测函数是否符合预设时间后磁盘容量变化情况可以通过样本数据进行验证,如果误差较大还可以对基准预测函数进行修正迭代,减小预测误差。可以理解地是,最终迭代完成时最新一次修改的基准预测函数即是节点对应的磁盘容量预测函数。本方案通过样本数据、训练数据以及回归迭代操作的结合,给出了如何得到磁盘容量预测函数的过程,帮助最终得到符合实际磁盘剩余容量情况的预测函数。Whether the benchmark prediction function obtained through the training data meets the change of the disk capacity after the preset time can be verified by the sample data, and if the error is large, the benchmark prediction function can be revised and iterated to reduce the prediction error. It is understandable that the latest modified benchmark prediction function when the final iteration is completed is the disk capacity prediction function corresponding to the node. This solution uses the combination of sample data, training data, and regression iterative operations to give a process of how to obtain the disk capacity prediction function, helping to finally obtain the prediction function that meets the actual disk capacity.
可选地,上述步骤S23可以包括:Optionally, the foregoing step S23 may include:
步骤S231,利用所述基准预测函数计算样本数据中任一时间点内所述节点对应的预测剩余容量值;Step S231, using the reference prediction function to calculate the predicted remaining capacity value corresponding to the node at any point in the sample data;
在本实施例中,可以将样本数据中某个或某几个时间点通过基准预测函数计算出预测剩余容量值。可以理解的是,基准预测函数是时间点和剩余容量值相关的函数,因此只要知晓时间点,就可以通过函数计算得到剩余容量值,而函数是通过曲线获取的,并非实际情况下的,因此计算出的剩余容量值即是预测剩余容量值。In this embodiment, one or several time points in the sample data can be used to calculate the predicted remaining capacity value through the reference prediction function. It is understandable that the benchmark prediction function is a function related to the time point and the remaining capacity value. Therefore, as long as the time point is known, the remaining capacity value can be calculated by the function, and the function is obtained through the curve, not the actual situation, so The calculated remaining capacity value is the predicted remaining capacity value.
步骤S232,从样本数据中获取计算预测剩余容量值时的时间点所对应的实际剩余容量值,并将所述预测剩余容量值和所述实际剩余容量值进行比较,以得到剩余容量误差;Step S232: Obtain the actual remaining capacity value corresponding to the time point when the predicted remaining capacity value is calculated from the sample data, and compare the predicted remaining capacity value with the actual remaining capacity value to obtain the remaining capacity error;
由于样本数据中包含选择的起始时间点之后已经记录的磁盘剩余容量 值变化情况,因此可以在获得了预测剩余容量值之后,从样本数据中获得相同时间点的实际剩余容量值,然后将预测剩余容量值和实际剩余容量值进行比较,得到实际值和预测值之间的差值以作为剩余容量误差,从而根据得到的剩余容量误差评估基准预测函数的准确性。Since the sample data contains the changes in the remaining capacity value of the disk that have been recorded after the selected start time point, after obtaining the predicted remaining capacity value, the actual remaining capacity value at the same time point can be obtained from the sample data, and then the prediction The remaining capacity value is compared with the actual remaining capacity value, and the difference between the actual value and the predicted value is obtained as the remaining capacity error, so as to evaluate the accuracy of the benchmark prediction function based on the obtained remaining capacity error.
步骤S233,判断所述剩余容量误差是否符合预设迭代终止条件;其中,当所述剩余容量误差符合预设迭代终止条件时,迭代终止;Step S233, determining whether the remaining capacity error meets a preset iteration termination condition; wherein, when the remaining capacity error meets the preset iteration termination condition, the iteration is terminated;
上述预设迭代终止条件可以根据实际需要进行设置,例如可以记录计算误差时的次数,剩余容量误差的个数,和/或迭代次数,当次数或个数大于或等于某个设定值,认为符合迭代终止条件;和/或计算出的误差小于某个极值认为符合迭代终止条件。当确定符合迭代终止条件时,可以输出最新迭代的基准预测函数,并停止迭代。The foregoing preset iteration termination conditions can be set according to actual needs. For example, the number of calculation errors, the number of remaining capacity errors, and/or the number of iterations can be recorded. When the number or number is greater than or equal to a certain set value, it is considered Meet the iteration termination condition; and/or the calculated error is less than a certain extreme value, it is deemed to meet the iteration termination condition. When it is determined that the iteration termination condition is met, the benchmark prediction function of the latest iteration can be output, and the iteration can be stopped.
步骤S234,当所述剩余容量误差不符合预设迭代终止条件时,根据所述剩余容量误差更新所述基准预测函数。Step S234: When the remaining capacity error does not meet a preset iteration termination condition, update the reference prediction function according to the remaining capacity error.
当不符合迭代终止条件时,可以根据剩余容量误差计算基准预测函数的损失函数,并根据损失函数对基准预测函数的参数进行调整,以实现基准预测函数的迭代,直至迭代完成为止。通过设置迭代终止条件对基准预测函数进行更新,能够帮助提高函数预测的准确性,更为贴近实际区块链节点的磁盘空间变化情况,间接提高了按需扩容的准确性。When the iteration termination condition is not met, the loss function of the benchmark prediction function can be calculated according to the remaining capacity error, and the parameters of the benchmark prediction function can be adjusted according to the loss function to realize the iteration of the benchmark prediction function until the iteration is completed. Updating the benchmark prediction function by setting the iteration termination condition can help improve the accuracy of the function prediction, which is closer to the disk space changes of actual blockchain nodes, and indirectly improves the accuracy of on-demand expansion.
其中,迭代终止条件为剩余容量误差小于预设阈值时,判断剩余容量误差是否符合预设迭代终止条件的步骤可以包括:Wherein, when the iteration termination condition is that the remaining capacity error is less than the preset threshold, the step of judging whether the remaining capacity error meets the preset iteration termination condition may include:
判断所述剩余容量误差是否小于预设阈值;当所述剩余容量误差小于预设阈值时,确定所述剩余容量误差符合预设迭代终止条件;当所述剩余容量误差大于或等于预设阈值时,确定所述剩余容量误差不符合预设迭代终止条件。通过以剩余容量误差大小作为迭代终止的参考标准,能够使得最终得到的剩余空间预测函数与实际磁盘容量变化情况的误差在一定范围内,满足区块链节点的自动扩容要求。Determine whether the remaining capacity error is less than the preset threshold; when the remaining capacity error is less than the preset threshold, determine that the remaining capacity error meets the preset iteration termination condition; when the remaining capacity error is greater than or equal to the preset threshold , Determining that the remaining capacity error does not meet the preset iteration termination condition. By using the remaining capacity error as the reference standard for the termination of the iteration, the error between the final remaining space prediction function and the actual disk capacity change can be made within a certain range, and the automatic expansion requirements of the blockchain node can be met.
进一步地,基于本申请区块链节点的自动扩容方法的第一实施例提出本申请区块链节点的自动扩容方法的第三实施例,在本实施例中,所述步骤S30包括:Further, a third embodiment of the automatic expansion method of the blockchain node of the application is proposed based on the first embodiment of the automatic expansion method of the blockchain node of the application. In this embodiment, the step S30 includes:
步骤S31,判断预设时间后的磁盘剩余容量值α是否小于预设容量设定值δ;Step S31, judging whether the remaining capacity value α of the disk after a preset time is less than the preset capacity setting value δ;
预设容量设定值可以是固定的,该预设容量设定值大于等于0,也可以随着时间的变化逐渐增大或缩小,在实际操作时可以根据区块链实际运用的不同领域数据存储的特性决定。在每个不同的时间范围内,可以将预设时间之后磁盘剩余容量值与归属在相同时间范围的预设容量设定值进行比较以确定最终节点需要扩容到的磁盘目标扩容容量。The preset capacity setting value can be fixed. The preset capacity setting value is greater than or equal to 0, and it can also gradually increase or decrease over time. In actual operation, it can be based on the data in different fields actually used by the blockchain. The characteristics of storage are determined. In each different time range, the remaining disk capacity value after the preset time can be compared with the preset capacity setting value belonging to the same time range to determine the target expansion capacity of the disk to which the final node needs to be expanded.
其中,当预设时间后的磁盘剩余容量值α大于或等于预设容量设定值δ时,将预设时间后的磁盘剩余容量值α作为所述节点的磁盘目标扩容容量γ。可以理解的是,原本根据磁盘容量预测函数预测得到的即是最终磁盘目标扩容容量,那么可以认为预设时间后磁盘空间仍然够用,不需要执行磁盘扩容操作。Wherein, when the remaining disk capacity value α after the preset time is greater than or equal to the preset capacity setting value δ, the remaining disk capacity value α after the preset time is used as the target disk capacity expansion γ of the node. It is understandable that what is originally predicted based on the disk capacity prediction function is the final target expansion capacity of the disk, then it can be considered that the disk space is still sufficient after the preset time and there is no need to perform disk expansion operations.
步骤S32,当预设时间后的磁盘剩余容量值α小于预设容量设定值δ时,获取所述节点的当前磁盘剩余容量值β,并将所述节点的当前磁盘剩余容量值β、预设容量设定值δ以及预设时间后的磁盘剩余容量值α输入至包括公式γ=β+δ-α的运算器中,得到所述节点的磁盘目标扩容容量γ。In step S32, when the remaining disk capacity value α after the preset time is less than the preset capacity setting value δ, the current remaining disk capacity value β of the node is obtained, and the current remaining disk capacity value β of the node is preset It is assumed that the capacity setting value δ and the disk remaining capacity value α after a preset time are input into the arithmetic unit including the formula γ=β+δ-α to obtain the target disk capacity expansion γ of the node.
当预设时间之后磁盘剩余容量值比预设磁盘容量设定值小,可以按照运算器的公式结合预设磁盘容量设定值、当前磁盘剩余容量值和预设时间后的磁盘剩余容量值进行测算,得到最终节点需要扩容达到的磁盘剩余空间目标值即磁盘目标扩容容量。本实施例由于通过多种参数的联合运算,考虑了预设时间后磁盘的需求,使得扩容后的磁盘剩余容量始终比当前磁盘剩余空间值大,较为均衡且符合节点的数据存储要求,实现了区块链节点的按需扩容。When the remaining disk capacity value is smaller than the preset disk capacity setting value after the preset time, you can combine the preset disk capacity setting value, the current disk remaining capacity value and the disk remaining capacity value after the preset time according to the formula of the calculator. Calculate and obtain the target value of the remaining disk space that the final node needs to be expanded, that is, the target expansion capacity of the disk. In this embodiment, due to the joint operation of multiple parameters and the requirement of the disk after the preset time, the remaining capacity of the disk after expansion is always larger than the current value of the remaining space of the disk, which is more balanced and meets the data storage requirements of the node. On-demand expansion of blockchain nodes.
可选地,在其他实施例中,所述步骤S30中根据预设时间后所述节点的磁盘剩余容量值确定磁盘目标扩容容量的步骤之后,还包括:判断所述节点的磁盘目标扩容容量是否大于所述节点所在硬盘的总剩余容量;当所述节点的磁盘目标扩容容量大于所述节点所在磁盘的总剩余容量时,发出硬盘容量不足的提示信息;当所述节点的磁盘目标扩容容量小于或等于所述节点所在磁盘的总剩余容量时,执行按照所述磁盘目标扩容容量对所述节点进行扩容的步骤。Optionally, in other embodiments, after the step of determining the target expansion capacity of the disk according to the remaining disk capacity value of the node after a preset time in step S30, the method further includes: determining whether the target expansion capacity of the disk of the node is Is greater than the total remaining capacity of the hard disk where the node is located; when the target disk capacity of the node is greater than the total remaining capacity of the disk where the node is located, a warning message of insufficient hard disk capacity is issued; when the target disk capacity of the node is less than When it is equal to the total remaining capacity of the disk where the node is located, the step of expanding the node according to the target expansion capacity of the disk is executed.
需要说明的是,在本方案按需自动进行区块链节点扩容中并没有一次性分配给该节点全部的存储空间,因此还可以在每次得到目标扩容容量后,看磁盘总剩余容量与需要扩容所需的目标扩容容量的关系,当目标扩容容 量大于磁盘总剩余容量,表示节点对应磁盘的硬件存储空间不足,已经不是本身软件为节点划拨容量进行扩容可以解决的问题,需要触发以发送提示消息的方式通知运维人员对磁盘进行硬件扩容。因此本方案通过扩容空间的比较,区分是否需要进行人工介入,节点扩容十分灵活方便。It should be noted that in the automatic on-demand expansion of the blockchain node in this solution, all the storage space is not allocated to the node at one time, so you can also check the total remaining capacity of the disk and the needs after each target expansion capacity is obtained. The relationship between the target expansion capacity required for expansion, when the target expansion capacity is greater than the total remaining capacity of the disk, it means that the hardware storage space of the corresponding disk of the node is insufficient. It is no longer a problem that can be solved by the software allocated for the node capacity expansion. It needs to be triggered to send a reminder The message is used to notify the operation and maintenance personnel to perform hardware expansion of the disk. Therefore, this solution compares the expansion space to distinguish whether manual intervention is required, and node expansion is very flexible and convenient.
参见图4,本申请还提出一种区块链节点的自动扩容装置,所述装置可以是服务器,或运维终端,例如计算机,在一实施例中,所述装置包括:Referring to Figure 4, this application also proposes an automatic expansion device for blockchain nodes. The device may be a server, or an operation and maintenance terminal, such as a computer. In an embodiment, the device includes:
获取模块10,用于获取区块链中节点的磁盘剩余容量变化数据;The obtaining module 10 is used to obtain the remaining disk capacity change data of the nodes in the blockchain;
所述获取模块10,还用于根据所述磁盘剩余容量变化数据,获取所述节点对应的磁盘容量预测函数,并根据所述磁盘容量预测函数获取预设时间后所述节点的磁盘剩余容量值;The obtaining module 10 is further configured to obtain the disk capacity prediction function corresponding to the node according to the disk remaining capacity change data, and obtain the disk capacity value of the node after a preset time according to the disk capacity prediction function ;
扩容模块20,用于根据预设时间后所述节点的磁盘剩余容量值确定磁盘目标扩容容量,以按照所述磁盘目标扩容容量对所述节点进行扩容。The expansion module 20 is configured to determine the target expansion capacity of the disk according to the remaining disk capacity value of the node after a preset time, so as to expand the node according to the target expansion capacity of the disk.
进一步地,在另一实施例中,所述磁盘剩余容量变化数据包括时间点和对应的剩余容量值;所述获取模块包括:Further, in another embodiment, the disk remaining capacity change data includes a time point and a corresponding remaining capacity value; the acquiring module includes:
选取单元,用于从所述磁盘剩余容量变化数据的所有时间点中选取一起始时间点,以将所述起始时间点之前的所有时间点和对应的剩余容量值作为训练数据,将所述起始时间点之后的所有时间点和对应的剩余容量值作为样本数据;The selecting unit is used to select a starting time point from all time points of the remaining capacity change data of the disk, to use all time points before the starting time point and the corresponding remaining capacity value as the training data, and the All time points after the start time point and the corresponding remaining capacity value are taken as sample data;
回归单元,用于将所述训练数据输入至预设运算器中进行回归化,以得到时间点和剩余容量值相关的基准预测函数;The regression unit is used to input the training data into a preset calculator for regression to obtain a reference prediction function related to the time point and the remaining capacity value;
迭代单元,用于通过所述样本数据对所述基准预测函数进行迭代,以在完成迭代后将迭代完成时的基准预测函数作为所述节点对应的磁盘容量预测函数。The iterative unit is configured to iterate the reference prediction function through the sample data, so as to use the reference prediction function at the completion of the iteration as the disk capacity prediction function corresponding to the node after the iteration is completed.
进一步地,在又一实施例中,所述迭代单元包括:Further, in another embodiment, the iteration unit includes:
计算子单元,用于利用所述基准预测函数计算样本数据中任一时间点内所述节点对应的预测剩余容量值;The calculation subunit is configured to use the reference prediction function to calculate the predicted remaining capacity value corresponding to the node at any point in the sample data;
比较子单元,用于从样本数据中获取计算预测剩余容量值时的时间点所对应的实际剩余容量值,并将所述预测剩余容量值和所述实际剩余容量值进行比较,以得到剩余容量误差;The comparison subunit is used to obtain the actual remaining capacity value corresponding to the time point when the predicted remaining capacity value is calculated from the sample data, and to compare the predicted remaining capacity value with the actual remaining capacity value to obtain the remaining capacity error;
判断子单元,用于判断所述剩余容量误差是否符合预设迭代终止条件;并当所述剩余容量误差符合预设迭代终止条件时,迭代终止;The judging subunit is used to judge whether the remaining capacity error meets the preset iteration termination condition; and when the remaining capacity error meets the preset iteration termination condition, the iteration terminates;
更新子单元,用于当所述剩余容量误差不符合预设迭代终止条件时,根据所述剩余容量误差更新所述基准预测函数。The update subunit is configured to update the reference prediction function according to the remaining capacity error when the remaining capacity error does not meet a preset iteration termination condition.
进一步地,在又一实施例中,所述判断子单元可以用于:Further, in another embodiment, the judging subunit may be used for:
判断所述剩余容量误差是否小于预设阈值;当所述剩余容量误差小于预设阈值时,确定所述剩余容量误差符合预设迭代终止条件;当所述剩余容量误差大于或等于预设阈值时,确定所述剩余容量误差不符合预设迭代终止条件。Determine whether the remaining capacity error is less than the preset threshold; when the remaining capacity error is less than the preset threshold, determine that the remaining capacity error meets the preset iteration termination condition; when the remaining capacity error is greater than or equal to the preset threshold , Determining that the remaining capacity error does not meet the preset iteration termination condition.
进一步地,在又一实施例中,所述扩容模块包括:Further, in another embodiment, the expansion module includes:
判断单元,用于判断预设时间后的磁盘剩余容量值α是否小于预设容量设定值δ;The judging unit is used to judge whether the remaining capacity value α of the disk after the preset time is less than the preset capacity setting value δ;
运算单元,用于当预设时间后的磁盘剩余容量值α小于预设容量设定值δ时,获取所述节点的当前磁盘剩余容量值β,并将所述节点的当前磁盘剩余容量值β、预设容量设定值δ以及预设时间后的磁盘剩余容量值α输入至包括公式γ=β+δ-α的运算器中,得到所述节点的磁盘目标扩容容量γ。An arithmetic unit for obtaining the current remaining disk capacity value β of the node when the remaining disk capacity value α after a preset time is less than the preset capacity setting value δ, and calculating the current remaining disk capacity value β of the node , The preset capacity setting value δ and the disk remaining capacity value α after the preset time are input into the arithmetic unit including the formula γ=β+δ-α to obtain the target disk capacity expansion γ of the node.
进一步地,在又一实施例中,所述扩容模块还包括:Further, in another embodiment, the expansion module further includes:
设置单元,用于当预设时间后的磁盘剩余容量值α大于或等于预设容量设定值δ时,将预设时间后的磁盘剩余容量值α作为所述节点的磁盘目标扩容容量γ。The setting unit is configured to use the disk remaining capacity value α after the preset time as the target disk capacity expansion γ of the node when the remaining disk capacity value α after the preset time is greater than or equal to the preset capacity setting value δ.
进一步地,在又一实施例中,所述装置还包括:Further, in another embodiment, the device further includes:
判断模块,用于判断所述节点的磁盘目标扩容容量是否大于所述节点所在硬盘的总剩余容量;并当所述节点的磁盘目标扩容容量小于或等于所述节点所在磁盘的总剩余容量时,触发所述扩容模块执行按照所述磁盘目标扩容容量对所述节点进行扩容的步骤;A judging module for judging whether the target disk capacity of the node is greater than the total remaining capacity of the hard disk where the node is located; and when the target disk capacity of the node is less than or equal to the total remaining capacity of the disk where the node is located, Trigger the expansion module to perform the step of expanding the node according to the target expansion capacity of the disk;
发送模块,用于当所述节点的磁盘目标扩容容量大于所述节点所在磁盘的总剩余容量时,发出硬盘容量不足的提示信息。The sending module is used to send a prompt message that the hard disk capacity is insufficient when the target expansion capacity of the disk of the node is greater than the total remaining capacity of the disk where the node is located.
本申请还提出一种计算机可读存储介质,所述计算机可读存储介质可以为非易失性可读存储介质,其上存储有计算机可读指令。所述计算机可读存储介质可以是图1的运维终端中的存储器20,也可以是如ROM(Read-Only Memory,只读存储器)/RAM(Random Access Memory,随机存取存储器)、磁碟、光盘中的至少一种,所述计算机可读存储介质包括若干指令用以使得一台具有处理器的终端设备(可以是手机,计算机,服务器, 或者网络设备等)执行本申请各个实施例所述的方法。This application also proposes a computer-readable storage medium, which may be a non-volatile readable storage medium on which computer-readable instructions are stored. The computer-readable storage medium may be the memory 20 in the operation and maintenance terminal of FIG. 1, or may be ROM (Read-Only Memory)/RAM (Random Access Memory), magnetic disk , At least one of the optical discs, the computer-readable storage medium includes a number of instructions to make a terminal device with a processor (which can be a mobile phone, a computer, a server, or a network device, etc.) execute the various embodiments of the present application The method described.
需要说明的是,在本文中,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者服务端不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者服务端所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括该要素的过程、方法、物品或者服务端中还存在另外的相同要素。It should be noted that in this article, the terms "include", "include" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or server including a series of elements not only includes those elements , And also include other elements that are not explicitly listed, or elements inherent to this process, method, item, or server. Without more restrictions, the element defined by the sentence "including a..." does not exclude the existence of other identical elements in the process, method, article, or server that includes the element.
上述本申请实施例序号仅仅为了描述,不代表实施例的优劣。The serial numbers of the foregoing embodiments of the present application are only for description, and do not represent the advantages and disadvantages of the embodiments.
通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到上述实施例方法可借助软件加必需的通用硬件平台的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施方式。Through the description of the above embodiments, those skilled in the art can clearly understand that the method of the above embodiments can be implemented by means of software plus the necessary general hardware platform. Of course, it can also be implemented by hardware, but in many cases the former is better.的实施方式。
以上仅为本申请的可选实施例,并非因此限制本申请的专利范围,凡是利用本申请说明书及附图内容所作的等效结构或等效流程变换,或直接或间接运用在其他相关的技术领域,均同理包括在本申请的专利保护范围内。The above are only optional embodiments of this application, and do not limit the scope of this application. Any equivalent structure or equivalent process transformation made by using the description and drawings of this application, or directly or indirectly applied to other related technologies In the same way, all fields are included in the scope of patent protection of this application.

Claims (20)

  1. 一种区块链节点的自动扩容方法,其中,包括以下步骤:An automatic expansion method for blockchain nodes, which includes the following steps:
    获取区块链中节点的磁盘剩余容量变化数据;Obtain the remaining disk capacity change data of the node in the blockchain;
    根据所述磁盘剩余容量变化数据,获取所述节点对应的磁盘容量预测函数,并根据所述磁盘容量预测函数获取预设时间后所述节点的磁盘剩余容量值;Obtaining the disk capacity prediction function corresponding to the node according to the disk remaining capacity change data, and obtaining the disk remaining capacity value of the node after a preset time according to the disk capacity prediction function;
    根据预设时间后所述节点的磁盘剩余容量值确定磁盘目标扩容容量,以按照所述磁盘目标扩容容量对所述节点进行扩容;Determining the target expansion capacity of the disk according to the remaining disk capacity value of the node after a preset time, so as to expand the node according to the target expansion capacity of the disk;
    所述根据预设时间后所述节点的磁盘剩余容量值确定磁盘目标扩容容量的步骤包括:The step of determining the target expansion capacity of the disk according to the remaining disk capacity value of the node after a preset time includes:
    判断预设时间后的磁盘剩余容量值α是否小于预设容量设定值δ;Determine whether the remaining disk capacity value α after the preset time is less than the preset capacity setting value δ;
    当预设时间后的磁盘剩余容量值α小于预设容量设定值δ时,获取所述节点的当前磁盘剩余容量值β,并将所述节点的当前磁盘剩余容量值β、预设容量设定值δ以及预设时间后的磁盘剩余容量值α输入至包括公式γ=β+δ-α的运算器中,得到所述节点的磁盘目标扩容容量γ;When the remaining disk capacity value α after the preset time is less than the preset capacity setting value δ, the current disk remaining capacity value β of the node is obtained, and the current disk remaining capacity value β of the node is set to the preset capacity value. The fixed value δ and the disk remaining capacity value α after the preset time are input into the arithmetic unit including the formula γ=β+δ-α to obtain the target disk capacity expansion γ of the node;
    当预设时间后的磁盘剩余容量值α大于或等于预设容量设定值δ时,将预设时间后的磁盘剩余容量值α作为所述节点的磁盘目标扩容容量γ。When the remaining disk capacity value α after the preset time is greater than or equal to the preset capacity setting value δ, the remaining disk capacity value α after the preset time is used as the target disk capacity expansion γ of the node.
  2. 如权利要求1所述的区块链节点的自动扩容方法,其中,所述磁盘剩余容量变化数据包括时间点和对应的剩余容量值;The method for automatically expanding the capacity of a blockchain node according to claim 1, wherein the remaining capacity change data of the disk includes a time point and a corresponding remaining capacity value;
    所述根据所述磁盘剩余容量变化数据,获取所述节点对应的磁盘容量预测函数的步骤包括:The step of obtaining the disk capacity prediction function corresponding to the node according to the remaining disk capacity change data includes:
    从所述磁盘剩余容量变化数据的所有时间点中选取一起始时间点,以将所述起始时间点之前的所有时间点和对应的剩余容量值作为训练数据,将所述起始时间点之后的所有时间点和对应的剩余容量值作为样本数据;A starting time point is selected from all time points of the remaining capacity change data of the disk, and all time points before the starting time point and the corresponding remaining capacity value are used as training data, and after the starting time point All time points and the corresponding remaining capacity value as sample data;
    将所述训练数据输入至预设运算器中进行回归化,以得到时间点和剩余容量值相关的基准预测函数;Input the training data into a preset calculator for regression to obtain a reference prediction function related to the time point and the remaining capacity value;
    通过所述样本数据对所述基准预测函数进行迭代,以在完成迭代后将迭代完成时的基准预测函数作为所述节点对应的磁盘容量预测函数。The reference prediction function is iterated through the sample data, and the reference prediction function at the completion of the iteration is used as the disk capacity prediction function corresponding to the node after the iteration is completed.
  3. 如权利要求2所述的区块链节点的自动扩容方法,其中,所述通过所述样本数据对所述基准预测函数进行迭代的步骤包括:The method for automatically expanding a blockchain node according to claim 2, wherein the step of iterating the reference prediction function through the sample data comprises:
    利用所述基准预测函数计算样本数据中任一时间点内所述节点对应的预测剩余容量值;Using the reference prediction function to calculate the predicted remaining capacity value corresponding to the node at any point in the sample data;
    从样本数据中获取计算预测剩余容量值时的时间点所对应的实际剩余容量值,并将所述预测剩余容量值和所述实际剩余容量值进行比较,以得到剩余容量误差;Obtain the actual remaining capacity value corresponding to the time point when the predicted remaining capacity value is calculated from the sample data, and compare the predicted remaining capacity value with the actual remaining capacity value to obtain the remaining capacity error;
    判断所述剩余容量误差是否符合预设迭代终止条件;Determine whether the remaining capacity error meets the preset iteration termination condition;
    当所述剩余容量误差符合预设迭代终止条件时,迭代终止;When the remaining capacity error meets the preset iteration termination condition, the iteration terminates;
    当所述剩余容量误差不符合预设迭代终止条件时,根据所述剩余容量误差更新所述基准预测函数。When the remaining capacity error does not meet the preset iteration termination condition, the reference prediction function is updated according to the remaining capacity error.
  4. 如权利要求3所述的区块链节点的自动扩容方法,其中,所述判断所述剩余容量误差是否符合预设迭代终止条件的步骤包括:The method for automatic expansion of blockchain nodes according to claim 3, wherein the step of determining whether the remaining capacity error meets a preset iteration termination condition comprises:
    判断所述剩余容量误差是否小于预设阈值;Determining whether the remaining capacity error is less than a preset threshold;
    当所述剩余容量误差小于预设阈值时,确定所述剩余容量误差符合预设迭代终止条件;When the remaining capacity error is less than a preset threshold, determining that the remaining capacity error meets a preset iteration termination condition;
    当所述剩余容量误差大于或等于预设阈值时,确定所述剩余容量误差不符合预设迭代终止条件。When the remaining capacity error is greater than or equal to the preset threshold, it is determined that the remaining capacity error does not meet the preset iteration termination condition.
  5. 如权利要求1所述的区块链节点的自动扩容方法,其中,所述根据预设时间后所述节点的磁盘剩余容量值确定磁盘目标扩容容量的步骤之后,还包括:The method for automatic expansion of a blockchain node according to claim 1, wherein after the step of determining the target expansion capacity of the disk according to the remaining disk capacity value of the node after a preset time, the method further comprises:
    判断所述节点的磁盘目标扩容容量是否大于所述节点所在硬盘的总剩余容量;Determining whether the target expansion capacity of the disk of the node is greater than the total remaining capacity of the hard disk where the node is located;
    当所述节点的磁盘目标扩容容量大于所述节点所在磁盘的总剩余容量时,发出硬盘容量不足的提示信息;When the target expansion capacity of the disk of the node is greater than the total remaining capacity of the disk where the node is located, a prompt message of insufficient hard disk capacity is issued;
    当所述节点的磁盘目标扩容容量小于或等于所述节点所在磁盘的总剩余容量时,执行按照所述磁盘目标扩容容量对所述节点进行扩容的步骤。When the target disk capacity expansion of the node is less than or equal to the total remaining capacity of the disk where the node is located, the step of expanding the node according to the target disk capacity expansion is performed.
  6. 一种区块链节点的自动扩容装置,其中,所述装置包括:An automatic capacity expansion device for blockchain nodes, wherein the device includes:
    获取模块,用于获取区块链中节点的磁盘剩余容量变化数据;The acquisition module is used to acquire the remaining disk capacity change data of the nodes in the blockchain;
    所述获取模块,还用于根据所述磁盘剩余容量变化数据,获取所述节点对应的磁盘容量预测函数,并根据所述磁盘容量预测函数获取预设时间后所述节点的磁盘剩余容量值;The obtaining module is further configured to obtain the disk capacity prediction function corresponding to the node according to the disk remaining capacity change data, and obtain the disk capacity value of the node after a preset time according to the disk capacity prediction function;
    扩容模块,用于根据预设时间后所述节点的磁盘剩余容量值确定磁盘 目标扩容容量,以按照所述磁盘目标扩容容量对所述节点进行扩容;A capacity expansion module, configured to determine the target disk capacity expansion according to the remaining disk capacity value of the node after a preset time, so as to expand the node according to the target disk capacity expansion;
    其中,所述扩容模块包括:Wherein, the expansion module includes:
    判断单元,用于判断预设时间后的磁盘剩余容量值α是否小于预设容量设定值δ;The judging unit is used to judge whether the remaining capacity value α of the disk after the preset time is less than the preset capacity setting value δ;
    运算单元,用于当预设时间后的磁盘剩余容量值α小于预设容量设定值δ时,获取所述节点的当前磁盘剩余容量值β,并将所述节点的当前磁盘剩余容量值β、预设容量设定值δ以及预设时间后的磁盘剩余容量值α输入至包括公式γ=β+δ-α的运算器中,得到所述节点的磁盘目标扩容容量γ;An arithmetic unit for obtaining the current remaining disk capacity value β of the node when the remaining disk capacity value α after a preset time is less than the preset capacity setting value δ, and calculating the current remaining disk capacity value β of the node , The preset capacity setting value δ and the disk remaining capacity value α after the preset time are input into the arithmetic unit including the formula γ=β+δ-α to obtain the target disk capacity expansion γ of the node;
    设置单元,用于当预设时间后的磁盘剩余容量值α大于或等于预设容量设定值δ时,将预设时间后的磁盘剩余容量值α作为所述节点的磁盘目标扩容容量γ。The setting unit is configured to use the disk remaining capacity value α after the preset time as the target disk capacity expansion γ of the node when the remaining disk capacity value α after the preset time is greater than or equal to the preset capacity setting value δ.
  7. 如权利要求6所述的区块链节点的自动扩容装置,其中,所述磁盘剩余容量变化数据包括时间点和对应的剩余容量值;所述获取模块包括:7. The automatic capacity expansion device of a blockchain node according to claim 6, wherein the remaining disk capacity change data includes a time point and a corresponding remaining capacity value; the acquiring module includes:
    选取单元,用于从所述磁盘剩余容量变化数据的所有时间点中选取一起始时间点,以将所述起始时间点之前的所有时间点和对应的剩余容量值作为训练数据,将所述起始时间点之后的所有时间点和对应的剩余容量值作为样本数据;The selecting unit is used to select a starting time point from all time points of the remaining capacity change data of the disk, to use all time points before the starting time point and the corresponding remaining capacity value as the training data, and the All time points after the start time point and the corresponding remaining capacity value are taken as sample data;
    回归单元,用于将所述训练数据输入至预设运算器中进行回归化,以得到时间点和剩余容量值相关的基准预测函数;The regression unit is used to input the training data into a preset calculator for regression to obtain a reference prediction function related to the time point and the remaining capacity value;
    迭代单元,用于通过所述样本数据对所述基准预测函数进行迭代,以在完成迭代后将迭代完成时的基准预测函数作为所述节点对应的磁盘容量预测函数。The iterative unit is configured to iterate the reference prediction function through the sample data, so as to use the reference prediction function at the completion of the iteration as the disk capacity prediction function corresponding to the node after the iteration is completed.
  8. 如权利要求7所述的区块链节点的自动扩容装置,其中,所述迭代单元包括:The automatic expansion device for blockchain nodes according to claim 7, wherein the iteration unit comprises:
    计算子单元,用于利用所述基准预测函数计算样本数据中任一时间点内所述节点对应的预测剩余容量值;The calculation subunit is configured to use the reference prediction function to calculate the predicted remaining capacity value corresponding to the node at any point in the sample data;
    比较子单元,用于从样本数据中获取计算预测剩余容量值时的时间点所对应的实际剩余容量值,并将所述预测剩余容量值和所述实际剩余容量值进行比较,以得到剩余容量误差;The comparison subunit is used to obtain the actual remaining capacity value corresponding to the time point when the predicted remaining capacity value is calculated from the sample data, and to compare the predicted remaining capacity value with the actual remaining capacity value to obtain the remaining capacity error;
    判断子单元,用于判断所述剩余容量误差是否符合预设迭代终止条件;并当所述剩余容量误差符合预设迭代终止条件时,迭代终止;The judging subunit is used to judge whether the remaining capacity error meets the preset iteration termination condition; and when the remaining capacity error meets the preset iteration termination condition, the iteration terminates;
    更新子单元,用于当所述剩余容量误差不符合预设迭代终止条件时,根据所述剩余容量误差更新所述基准预测函数。The update subunit is configured to update the reference prediction function according to the remaining capacity error when the remaining capacity error does not meet a preset iteration termination condition.
  9. 如权利要求8所述的区块链节点的自动扩容装置,其中,所述判断子单元还用于判断所述剩余容量误差是否小于预设阈值;当所述剩余容量误差小于预设阈值时,确定所述剩余容量误差符合预设迭代终止条件;当所述剩余容量误差大于或等于预设阈值时,确定所述剩余容量误差不符合预设迭代终止条件。8. The automatic expansion device for blockchain nodes according to claim 8, wherein the judging subunit is further used to judge whether the remaining capacity error is less than a preset threshold; when the remaining capacity error is less than the preset threshold, It is determined that the remaining capacity error meets a preset iteration termination condition; when the remaining capacity error is greater than or equal to a preset threshold, it is determined that the remaining capacity error does not meet the preset iteration termination condition.
  10. 如权利要求6所述的区块链节点的自动扩容装置,其中,所述装置还包括:The automatic expansion device for blockchain nodes according to claim 6, wherein the device further comprises:
    判断模块,用于判断所述节点的磁盘目标扩容容量是否大于所述节点所在硬盘的总剩余容量;并当所述节点的磁盘目标扩容容量小于或等于所述节点所在磁盘的总剩余容量时,触发所述扩容模块执行按照所述磁盘目标扩容容量对所述节点进行扩容的步骤;A judging module for judging whether the target disk capacity of the node is greater than the total remaining capacity of the hard disk where the node is located; and when the target disk capacity of the node is less than or equal to the total remaining capacity of the disk where the node is located, Trigger the expansion module to perform the step of expanding the node according to the target expansion capacity of the disk;
    发送模块,用于当所述节点的磁盘目标扩容容量大于所述节点所在磁盘的总剩余容量时,发出硬盘容量不足的提示信息。The sending module is used to send a prompt message that the hard disk capacity is insufficient when the target expansion capacity of the disk of the node is greater than the total remaining capacity of the disk where the node is located.
  11. 一种运维终端,其中,所述运维终端包括:通信模块、存储器、处理器及存储在所述存储器上并可在所述处理器上运行的计算机可读指令,所述计算机可读指令被所述处理器执行时实现以下步骤:An operation and maintenance terminal, wherein the operation and maintenance terminal includes: a communication module, a memory, a processor, and computer-readable instructions stored on the memory and capable of running on the processor, the computer-readable instructions When executed by the processor, the following steps are implemented:
    获取区块链中节点的磁盘剩余容量变化数据;Obtain the remaining disk capacity change data of the node in the blockchain;
    根据所述磁盘剩余容量变化数据,获取所述节点对应的磁盘容量预测函数,并根据所述磁盘容量预测函数获取预设时间后所述节点的磁盘剩余容量值;Obtaining the disk capacity prediction function corresponding to the node according to the disk remaining capacity change data, and obtaining the disk remaining capacity value of the node after a preset time according to the disk capacity prediction function;
    根据预设时间后所述节点的磁盘剩余容量值确定磁盘目标扩容容量,以按照所述磁盘目标扩容容量对所述节点进行扩容;Determining the target expansion capacity of the disk according to the remaining disk capacity value of the node after a preset time, so as to expand the node according to the target expansion capacity of the disk;
    所述根据预设时间后所述节点的磁盘剩余容量值确定磁盘目标扩容容量的步骤包括:The step of determining the target expansion capacity of the disk according to the remaining disk capacity value of the node after a preset time includes:
    判断预设时间后的磁盘剩余容量值α是否小于预设容量设定值δ;Determine whether the remaining disk capacity value α after the preset time is less than the preset capacity setting value δ;
    当预设时间后的磁盘剩余容量值α小于预设容量设定值δ时,获取所述节点的当前磁盘剩余容量值β,并将所述节点的当前磁盘剩余容量值β、预设容量设定值δ以及预设时间后的磁盘剩余容量值α输入至包括公式γ=β+δ-α的运算器中,得到所述节点的磁盘目标扩容容量γ;When the remaining disk capacity value α after the preset time is less than the preset capacity setting value δ, the current disk remaining capacity value β of the node is obtained, and the current disk remaining capacity value β of the node is set to the preset capacity value. The fixed value δ and the disk remaining capacity value α after the preset time are input into the arithmetic unit including the formula γ=β+δ-α to obtain the target disk capacity expansion γ of the node;
    当预设时间后的磁盘剩余容量值α大于或等于预设容量设定值δ时,将预设时间后的磁盘剩余容量值α作为所述节点的磁盘目标扩容容量γ。When the remaining disk capacity value α after the preset time is greater than or equal to the preset capacity setting value δ, the remaining disk capacity value α after the preset time is used as the target disk capacity expansion γ of the node.
  12. 如权利要求11所述的运维终端,其中,所述磁盘剩余容量变化数据包括时间点和对应的剩余容量值;所述计算机可读指令被所述处理器执行时实现以下步骤:The operation and maintenance terminal according to claim 11, wherein the remaining capacity change data of the disk includes a point in time and a corresponding remaining capacity value; the computer-readable instructions implement the following steps when executed by the processor:
    从所述磁盘剩余容量变化数据的所有时间点中选取一起始时间点,以将所述起始时间点之前的所有时间点和对应的剩余容量值作为训练数据,将所述起始时间点之后的所有时间点和对应的剩余容量值作为样本数据;A starting time point is selected from all time points of the remaining capacity change data of the disk, and all time points before the starting time point and the corresponding remaining capacity value are used as training data, and after the starting time point All time points and the corresponding remaining capacity value as sample data;
    将所述训练数据输入至预设运算器中进行回归化,以得到时间点和剩余容量值相关的基准预测函数;Input the training data into a preset calculator for regression to obtain a reference prediction function related to the time point and the remaining capacity value;
    通过所述样本数据对所述基准预测函数进行迭代,以在完成迭代后将迭代完成时的基准预测函数作为所述节点对应的磁盘容量预测函数。The reference prediction function is iterated through the sample data, and the reference prediction function at the completion of the iteration is used as the disk capacity prediction function corresponding to the node after the iteration is completed.
  13. 如权利要求12所述的运维终端,其中,所述计算机可读指令被所述处理器执行时实现以下步骤:The operation and maintenance terminal according to claim 12, wherein the following steps are implemented when the computer-readable instructions are executed by the processor:
    利用所述基准预测函数计算样本数据中任一时间点内所述节点对应的预测剩余容量值;Using the reference prediction function to calculate the predicted remaining capacity value corresponding to the node at any point in the sample data;
    从样本数据中获取计算预测剩余容量值时的时间点所对应的实际剩余容量值,并将所述预测剩余容量值和所述实际剩余容量值进行比较,以得到剩余容量误差;Obtain the actual remaining capacity value corresponding to the time point when the predicted remaining capacity value is calculated from the sample data, and compare the predicted remaining capacity value with the actual remaining capacity value to obtain the remaining capacity error;
    判断所述剩余容量误差是否符合预设迭代终止条件;Determine whether the remaining capacity error meets the preset iteration termination condition;
    当所述剩余容量误差符合预设迭代终止条件时,迭代终止;When the remaining capacity error meets the preset iteration termination condition, the iteration terminates;
    当所述剩余容量误差不符合预设迭代终止条件时,根据所述剩余容量误差更新所述基准预测函数。When the remaining capacity error does not meet the preset iteration termination condition, the reference prediction function is updated according to the remaining capacity error.
  14. 如权利要求13所述的运维终端,其中,所述计算机可读指令被所述处理器执行时实现以下步骤:The operation and maintenance terminal according to claim 13, wherein the following steps are implemented when the computer-readable instructions are executed by the processor:
    判断所述剩余容量误差是否小于预设阈值;Determining whether the remaining capacity error is less than a preset threshold;
    当所述剩余容量误差小于预设阈值时,确定所述剩余容量误差符合预设迭代终止条件;When the remaining capacity error is less than a preset threshold, determining that the remaining capacity error meets a preset iteration termination condition;
    当所述剩余容量误差大于或等于预设阈值时,确定所述剩余容量误差不符合预设迭代终止条件。When the remaining capacity error is greater than or equal to the preset threshold, it is determined that the remaining capacity error does not meet the preset iteration termination condition.
  15. 如权利要求11所述的运维终端,其中,所述计算机可读指令被所述处理器执行时实现以下步骤:The operation and maintenance terminal according to claim 11, wherein the following steps are implemented when the computer-readable instructions are executed by the processor:
    判断所述节点的磁盘目标扩容容量是否大于所述节点所在硬盘的总剩余容量;Determining whether the target expansion capacity of the disk of the node is greater than the total remaining capacity of the hard disk where the node is located;
    当所述节点的磁盘目标扩容容量大于所述节点所在磁盘的总剩余容量时,发出硬盘容量不足的提示信息;When the target expansion capacity of the disk of the node is greater than the total remaining capacity of the disk where the node is located, a prompt message of insufficient hard disk capacity is issued;
    当所述节点的磁盘目标扩容容量小于或等于所述节点所在磁盘的总剩余容量时,执行按照所述磁盘目标扩容容量对所述节点进行扩容的步骤。When the target disk capacity expansion of the node is less than or equal to the total remaining capacity of the disk where the node is located, the step of performing capacity expansion of the node according to the target disk capacity expansion is performed.
  16. 一种计算机可读存储介质,其中,所述计算机可读存储介质上存储有计算机可读指令,所述计算机可读指令被处理器执行时实现以下步骤:A computer-readable storage medium, wherein computer-readable instructions are stored on the computer-readable storage medium, and the computer-readable instructions implement the following steps when executed by a processor:
    获取区块链中节点的磁盘剩余容量变化数据;Obtain the remaining disk capacity change data of the node in the blockchain;
    根据所述磁盘剩余容量变化数据,获取所述节点对应的磁盘容量预测函数,并根据所述磁盘容量预测函数获取预设时间后所述节点的磁盘剩余容量值;Obtaining the disk capacity prediction function corresponding to the node according to the disk remaining capacity change data, and obtaining the disk remaining capacity value of the node after a preset time according to the disk capacity prediction function;
    根据预设时间后所述节点的磁盘剩余容量值确定磁盘目标扩容容量,以按照所述磁盘目标扩容容量对所述节点进行扩容;Determining the target expansion capacity of the disk according to the remaining disk capacity value of the node after a preset time, so as to expand the node according to the target expansion capacity of the disk;
    所述根据预设时间后所述节点的磁盘剩余容量值确定磁盘目标扩容容量的步骤包括:The step of determining the target expansion capacity of the disk according to the remaining disk capacity value of the node after a preset time includes:
    判断预设时间后的磁盘剩余容量值α是否小于预设容量设定值δ;Determine whether the remaining disk capacity value α after the preset time is less than the preset capacity setting value δ;
    当预设时间后的磁盘剩余容量值α小于预设容量设定值δ时,获取所述节点的当前磁盘剩余容量值β,并将所述节点的当前磁盘剩余容量值β、预设容量设定值δ以及预设时间后的磁盘剩余容量值α输入至包括公式γ=β+δ-α的运算器中,得到所述节点的磁盘目标扩容容量γ;When the remaining disk capacity value α after the preset time is less than the preset capacity setting value δ, the current disk remaining capacity value β of the node is obtained, and the current disk remaining capacity value β of the node is set to the preset capacity value. The fixed value δ and the disk remaining capacity value α after the preset time are input into the arithmetic unit including the formula γ=β+δ-α to obtain the target disk capacity expansion γ of the node;
    当预设时间后的磁盘剩余容量值α大于或等于预设容量设定值δ时,将预设时间后的磁盘剩余容量值α作为所述节点的磁盘目标扩容容量γ。When the remaining disk capacity value α after the preset time is greater than or equal to the preset capacity setting value δ, the remaining disk capacity value α after the preset time is used as the target disk capacity expansion γ of the node.
  17. 如权利要求16所述的计算机可读存储介质,其中,所述磁盘剩余容量变化数据包括时间点和对应的剩余容量值;所述计算机可读存储介质上存储有计算机可读指令,所述计算机可读指令被处理器执行时以下步骤:The computer-readable storage medium according to claim 16, wherein the remaining capacity change data of the disk includes a time point and a corresponding remaining capacity value; the computer-readable storage medium stores computer-readable instructions, and the computer The following steps when the readable instruction is executed by the processor:
    从所述磁盘剩余容量变化数据的所有时间点中选取一起始时间点,以将所述起始时间点之前的所有时间点和对应的剩余容量值作为训练数据,将所述起始时间点之后的所有时间点和对应的剩余容量值作为样本数据;A starting time point is selected from all time points of the remaining capacity change data of the disk, and all time points before the starting time point and the corresponding remaining capacity value are used as training data, and after the starting time point All time points and the corresponding remaining capacity value as sample data;
    将所述训练数据输入至预设运算器中进行回归化,以得到时间点和剩余容量值相关的基准预测函数;Input the training data into a preset calculator for regression to obtain a reference prediction function related to the time point and the remaining capacity value;
    通过所述样本数据对所述基准预测函数进行迭代,以在完成迭代后将迭代完成时的基准预测函数作为所述节点对应的磁盘容量预测函数。The reference prediction function is iterated through the sample data, and the reference prediction function at the completion of the iteration is used as the disk capacity prediction function corresponding to the node after the iteration is completed.
  18. 如权利要求17所述的计算机可读存储介质,其中,所述计算机可读指令被处理器执行时还实现以下步骤:18. The computer-readable storage medium of claim 17, wherein the computer-readable instructions further implement the following steps when executed by the processor:
    利用所述基准预测函数计算样本数据中任一时间点内所述节点对应的预测剩余容量值;Using the reference prediction function to calculate the predicted remaining capacity value corresponding to the node at any point in the sample data;
    从样本数据中获取计算预测剩余容量值时的时间点所对应的实际剩余容量值,并将所述预测剩余容量值和所述实际剩余容量值进行比较,以得到剩余容量误差;Obtain the actual remaining capacity value corresponding to the time point when the predicted remaining capacity value is calculated from the sample data, and compare the predicted remaining capacity value with the actual remaining capacity value to obtain the remaining capacity error;
    判断所述剩余容量误差是否符合预设迭代终止条件;Determine whether the remaining capacity error meets the preset iteration termination condition;
    当所述剩余容量误差符合预设迭代终止条件时,迭代终止;When the remaining capacity error meets the preset iteration termination condition, the iteration terminates;
    当所述剩余容量误差不符合预设迭代终止条件时,根据所述剩余容量误差更新所述基准预测函数。When the remaining capacity error does not meet the preset iteration termination condition, the reference prediction function is updated according to the remaining capacity error.
  19. 如权利要求18所述的计算机可读存储介质,其中,所述计算机可读指令被处理器执行时还实现以下步骤:17. The computer-readable storage medium of claim 18, wherein the computer-readable instructions further implement the following steps when executed by the processor:
    判断所述剩余容量误差是否小于预设阈值;Determining whether the remaining capacity error is less than a preset threshold;
    当所述剩余容量误差小于预设阈值时,确定所述剩余容量误差符合预设迭代终止条件;When the remaining capacity error is less than a preset threshold, determining that the remaining capacity error meets a preset iteration termination condition;
    当所述剩余容量误差大于或等于预设阈值时,确定所述剩余容量误差不符合预设迭代终止条件。When the remaining capacity error is greater than or equal to the preset threshold, it is determined that the remaining capacity error does not meet the preset iteration termination condition.
  20. 如权利要求16所述的计算机可读存储介质,其中,所述计算机可读指令被处理器执行时还实现以下步骤:16. The computer-readable storage medium of claim 16, wherein the computer-readable instructions further implement the following steps when executed by the processor:
    判断所述节点的磁盘目标扩容容量是否大于所述节点所在硬盘的总剩余容量;Determining whether the target expansion capacity of the disk of the node is greater than the total remaining capacity of the hard disk where the node is located;
    当所述节点的磁盘目标扩容容量大于所述节点所在磁盘的总剩余容量时,发出硬盘容量不足的提示信息;When the target expansion capacity of the disk of the node is greater than the total remaining capacity of the disk where the node is located, a prompt message of insufficient hard disk capacity is issued;
    当所述节点的磁盘目标扩容容量小于或等于所述节点所在磁盘的总剩余容量时,执行按照所述磁盘目标扩容容量对所述节点进行扩容的步骤。When the target disk capacity expansion of the node is less than or equal to the total remaining capacity of the disk where the node is located, the step of performing capacity expansion of the node according to the target disk capacity expansion is performed.
PCT/CN2019/120904 2019-06-19 2019-11-26 Automatic expansion method and apparatus for blockchain node, and operation and maintenance terminal and storage medium WO2020253111A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201910532942.7 2019-06-19
CN201910532942.7A CN110377228A (en) 2019-06-19 2019-06-19 Automatic expansion method, device, O&M terminal and the storage medium of block chain node

Publications (1)

Publication Number Publication Date
WO2020253111A1 true WO2020253111A1 (en) 2020-12-24

Family

ID=68248977

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2019/120904 WO2020253111A1 (en) 2019-06-19 2019-11-26 Automatic expansion method and apparatus for blockchain node, and operation and maintenance terminal and storage medium

Country Status (2)

Country Link
CN (1) CN110377228A (en)
WO (1) WO2020253111A1 (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112988071A (en) * 2021-03-15 2021-06-18 中国建设银行股份有限公司 Distributed storage capacity expansion method and device, storage medium and equipment
CN117422542A (en) * 2023-10-31 2024-01-19 苏银凯基消费金融有限公司 System and method for storing and verifying consumption financial business based on blockchain technology
WO2024016766A1 (en) * 2022-07-19 2024-01-25 腾讯科技(深圳)有限公司 Transaction processing method and apparatus, device, storage medium, and program product

Families Citing this family (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110377228A (en) * 2019-06-19 2019-10-25 深圳壹账通智能科技有限公司 Automatic expansion method, device, O&M terminal and the storage medium of block chain node
CN111258506A (en) * 2020-02-07 2020-06-09 汉海信息技术(上海)有限公司 Data storage method and device
CN111625189B (en) * 2020-05-19 2023-07-28 华云数据控股集团有限公司 Method, device, equipment and medium for detecting data re-balance state
CN111625196A (en) * 2020-05-26 2020-09-04 北京海益同展信息科技有限公司 Block chain node capacity expansion method and device, computer equipment and storage medium
CN111737361B (en) * 2020-07-22 2021-01-15 百度在线网络技术(北京)有限公司 Block chain processing method, device, equipment and storage medium
CN111984190B (en) * 2020-07-26 2023-01-06 苏州浪潮智能科技有限公司 Storage pool capacity expansion method and system for mass storage device
CN113655965A (en) * 2021-08-20 2021-11-16 湖北央中巨石信息技术有限公司 Capacity expansion method of block chain network, block chain network system and block chain network operation method
CN115390752B (en) * 2022-08-10 2023-04-18 中科豪联(杭州)技术有限公司 Multi-disk cache file management method

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104866408A (en) * 2014-02-20 2015-08-26 阿里巴巴集团控股有限公司 Capacity prediction method and device for application system
CN107832139A (en) * 2017-09-26 2018-03-23 上海点融信息科技有限责任公司 For the method, apparatus and system for the computing resource for managing block chain link point
CN108845881A (en) * 2018-05-30 2018-11-20 有米科技股份有限公司 The method and device of server capacity dynamic adjustment
CN109189323A (en) * 2018-07-06 2019-01-11 华为技术有限公司 Expansion method and equipment
CN109885469A (en) * 2019-02-27 2019-06-14 深信服科技股份有限公司 A kind of expansion method, prediction model creation method, device, equipment and medium
CN110377228A (en) * 2019-06-19 2019-10-25 深圳壹账通智能科技有限公司 Automatic expansion method, device, O&M terminal and the storage medium of block chain node

Family Cites Families (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100356729C (en) * 2004-03-31 2007-12-19 华为技术有限公司 Method and system for monitoring network service performance
CN1991778A (en) * 2005-12-29 2007-07-04 英业达股份有限公司 Snapshot extending system and method
CN103365781B (en) * 2012-03-29 2016-05-04 国际商业机器公司 For dynamically reconfiguring the method and apparatus of storage system
CN104951245B (en) * 2014-03-31 2019-05-31 伊姆西公司 Method and apparatus for dynamic memory layering
CN103970641A (en) * 2014-05-15 2014-08-06 浪潮电子信息产业股份有限公司 Equipment expansion method based on capacity prediction technology
CN104202435B (en) * 2014-09-28 2017-10-31 北京奇虎科技有限公司 Data drag the method and apparatus taken
CN104317638A (en) * 2014-10-17 2015-01-28 华为技术有限公司 Application stretching management method and device
CN107092442B (en) * 2017-04-24 2020-08-18 杭州宏杉科技股份有限公司 Storage system resource allocation method and device
CN107480028B (en) * 2017-07-21 2020-09-18 东软集团股份有限公司 Method and device for acquiring usable residual time of disk
CN109766234A (en) * 2018-12-11 2019-05-17 国网甘肃省电力公司信息通信公司 Disk storage capacity prediction technique based on time series models

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104866408A (en) * 2014-02-20 2015-08-26 阿里巴巴集团控股有限公司 Capacity prediction method and device for application system
CN107832139A (en) * 2017-09-26 2018-03-23 上海点融信息科技有限责任公司 For the method, apparatus and system for the computing resource for managing block chain link point
CN108845881A (en) * 2018-05-30 2018-11-20 有米科技股份有限公司 The method and device of server capacity dynamic adjustment
CN109189323A (en) * 2018-07-06 2019-01-11 华为技术有限公司 Expansion method and equipment
CN109885469A (en) * 2019-02-27 2019-06-14 深信服科技股份有限公司 A kind of expansion method, prediction model creation method, device, equipment and medium
CN110377228A (en) * 2019-06-19 2019-10-25 深圳壹账通智能科技有限公司 Automatic expansion method, device, O&M terminal and the storage medium of block chain node

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112988071A (en) * 2021-03-15 2021-06-18 中国建设银行股份有限公司 Distributed storage capacity expansion method and device, storage medium and equipment
WO2024016766A1 (en) * 2022-07-19 2024-01-25 腾讯科技(深圳)有限公司 Transaction processing method and apparatus, device, storage medium, and program product
CN117422542A (en) * 2023-10-31 2024-01-19 苏银凯基消费金融有限公司 System and method for storing and verifying consumption financial business based on blockchain technology

Also Published As

Publication number Publication date
CN110377228A (en) 2019-10-25

Similar Documents

Publication Publication Date Title
WO2020253111A1 (en) Automatic expansion method and apparatus for blockchain node, and operation and maintenance terminal and storage medium
CN102546256B (en) System and method used for monitoring cloud computation service
CN102882909B (en) Cloud computing service monitoring system and method thereof
CN109144559B (en) Update data packet pushing method and server
CN110289994B (en) Cluster capacity adjusting method and device
CN111966289B (en) Partition optimization method and system based on Kafka cluster
CN106776288B (en) A kind of health metric method of the distributed system based on Hadoop
CN103631894A (en) Dynamic copy management method based on HDFS
CN111277640B (en) User request processing method, device, system, computer equipment and storage medium
CN107656807A (en) The automatic elastic telescopic method and device of a kind of virtual resource
US20180107503A1 (en) Computer procurement predicting device, computer procurement predicting method, and recording medium
CN109684320B (en) Method and equipment for online cleaning of monitoring data
CN109446225B (en) Data caching method and device, computer equipment and storage medium
CN116418653A (en) Fault positioning method and device based on multi-index root cause positioning algorithm
CN106973091B (en) Distributed memory data redistribution method and system, and master control server
CN116467082A (en) Big data-based resource allocation method and system
CN112416568A (en) Duration estimation method and duration estimation device for audio and video transcoding task
CN109889456B (en) Data transmission method, device, equipment, system and storage medium
CN114791818B (en) Storage controller system update method, system, computer device and storage medium
CN112367384B (en) Kafka cluster-based dynamic speed limiting method and device and computer equipment
CN112732765B (en) Method and device for determining experimental path and electronic equipment
CN115469966A (en) Elastic expansion method and device for container cloud service
CN112800089B (en) Intermediate data storage level adjusting method, storage medium and computer equipment
CN114666375A (en) Beidou satellite-based smart agriculture Internet of things method and system and cloud platform
JP2023511139A (en) MEDIA INFORMATION DISTRIBUTION MANAGEMENT METHOD AND SYSTEM

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 19933676

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 19933676

Country of ref document: EP

Kind code of ref document: A1

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 29.03.2022)

122 Ep: pct application non-entry in european phase

Ref document number: 19933676

Country of ref document: EP

Kind code of ref document: A1