Photovoltaic energy storage system service file management method and related product

By collecting and managing service files in the photovoltaic energy storage system, automatically deleting backup files and adjusting disk space, the problem of excessive service files in the photovoltaic energy storage system is solved, the system stability and security are improved, and manual participation is reduced and the risk of mistaken deletion.

CN118916333AActive Publication Date: 2024-11-08HAIER ENERGY TECHNOLOGY CO LTD
View PDF 9 Cites 0 Cited by

Patent Information

Application Number
CN202411054205.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-01
Publication Date
2024-11-08
Estimated Expiration
2044-08-01

AI Technical Summary

Technical Problem

The number of service files in photovoltaic energy storage systems has increased sharply, resulting in excessive storage space occupied and affecting system performance. Traditional manual cleaning methods are inefficient and easy to delete important files by mistake, and an intelligent backup file cleaning method is needed.

Method used

Provide a service file management method for photovoltaic energy storage system. By collecting engineering service collection and service files, calculating the number of backup files, determining whether it exceeds the threshold, sorting and deleting backup files according to preset sorting rules, and detecting whether the disk storage space is sufficient. If it is insufficient, expand it to realize automated management and reduce manual participation.

Benefits of technology

It improves the stability and security of the photovoltaic energy storage system, avoids the mistaken deletion of important files, improves the execution efficiency, realizes the automated management of service files of the photovoltaic energy storage system, and ensures sufficient disk space.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118916333A_ABST
    Figure CN118916333A_ABST
Patent Text Reader

Abstract

The invention provides a photovoltaic energy storage system service file management method and related products. The method comprises the following steps: collecting an engineering service set and a corresponding service file in the photovoltaic energy storage system; calculating the number of backup files corresponding to each item of target engineering service in the engineering service set one by one; judging whether the number of the backup files exceeds a preset threshold value corresponding to the target engineering service or not; if yes, the number of backup files to be deleted in the target engineering service is calculated; sorting the backup files according to a preset sorting rule to obtain a file list; deleting a corresponding number of backup files in the file list according to the to-be-deleted number; detecting whether a preset disk storage space corresponding to the photovoltaic energy storage system is sufficient or not; and if not, expanding the storage space of the preset disk. Through the method, manual participation in service file management can be reduced, and the execution efficiency is improved, so that automatic management of the service file of the photovoltaic energy storage system is realized, and the stability and the safety of the photovoltaic energy storage system are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of photovoltaic energy storage, and in particular to a photovoltaic energy storage system service file management method and related products. Background Art

[0002] With the widespread application of photovoltaic energy storage systems, the number of service files generated by them has increased dramatically. These files are crucial to the stable operation and fault recovery of the system, especially backup files and log files. Too many backup files will take up a lot of storage space, affect system performance, and even cause data redundancy and confusion. Traditional manual cleaning methods are not only inefficient, but also easy to accidentally delete important files. Therefore, an intelligent backup file cleaning method is needed. Summary of the invention

[0003] In view of the above problems, the present invention proposes a photovoltaic energy storage system service file management method and related products that overcome the above problems or at least partially solve the above problems.

[0004] An object of the present invention is to improve the stability and safety of a photovoltaic energy storage system.

[0005] A further object of the present invention is to realize the automated management of service files of photovoltaic energy storage systems and reduce manual involvement.

[0006] In particular, the present invention provides a photovoltaic energy storage system service file management method, comprising:

[0007] Collect engineering service sets and corresponding service files in the photovoltaic energy storage system. The service files include backup files and log files.

[0008] Calculate the number of backup files corresponding to each target engineering service in the engineering service set one by one;

[0009] Determine whether the number of backup files exceeds a preset threshold corresponding to the target engineering service;

[0010] If yes, then calculate the number of backup files to be deleted in the target engineering service;

[0011] Sort the backup files according to the preset sorting rules to obtain a file list;

[0012] Delete the corresponding number of backup files in the file list according to the number to be deleted;

[0013] Check whether the preset disk storage space corresponding to the photovoltaic energy storage system is sufficient;

[0014] If not, expand the storage space of the default disk.

[0015] Optionally, the step of sorting the backup files according to a preset sorting rule to obtain a file list includes:

[0016] Calculate the sorting score of the backup files according to the preset sorting rules;

[0017] The backup files are sorted in reverse order according to the sorting scores to obtain a file list, and the backup files ranked first in the file list are deleted first.

[0018] Optionally, the step of calculating the sorting score of the backup file according to the preset sorting rule includes:

[0019] Determine an evaluation type of a preset sorting rule, the evaluation type including any one or more of importance level, timeliness level, and redundancy level;

[0020] Collect attribute information of backup files;

[0021] Evaluate the backup files according to the attribute information to obtain evaluation results of different evaluation types;

[0022] The ranking scores of the backup files are calculated based on the evaluation results.

[0023] Optionally, the step of evaluating the backup file according to the attribute information to obtain evaluation results of different evaluation types includes:

[0024] Obtaining the importance level of the backup file according to a preset importance evaluation rule combined with the attribute information evaluation, wherein the preset importance evaluation rule includes evaluating according to the service association, data type and most recent access time in the attribute information;

[0025] The timeliness level of the backup file is obtained by evaluating the preset timeliness evaluation rules in combination with the attribute information, wherein the preset timeliness evaluation rules include evaluating the creation time, modification frequency and business requirements of the target engineering service in the attribute information;

[0026] The redundancy level of the backup file is obtained by evaluating the attribute information according to the preset redundancy evaluation rules, wherein the preset redundancy evaluation rules include evaluating the data integrity and time span in the attribute information in combination with the recovery test;

[0027] Any one or more of the importance level, timeliness level, and redundancy level are used as evaluation results.

[0028] Optionally, the step of calculating the number of backup files corresponding to each target engineering service in the engineering service set one by one includes:

[0029] Get the target name of the target engineering service according to the engineering service set;

[0030] Get the backup file corresponding to the target engineering service by matching the target name with a regular expression;

[0031] Calculate the number of backup files corresponding to the target engineering services one by one.

[0032] Optionally, the step of detecting whether the preset disk storage space corresponding to the photovoltaic energy storage system is sufficient includes:

[0033] Get the detection instructions of the preset disk;

[0034] Determine the retention time of the log files corresponding to each target engineering service according to the detection instructions;

[0035] Determine the business volume of each target engineering service per unit time and the average log generation volume of the business corresponding to each target engineering service per unit time according to the detection instruction;

[0036] Calculate the log generation volume per unit time for each target engineering service based on the business volume and the average log generation volume;

[0037] Combine the log generation volume per unit time of each target engineering service to obtain the total log generation volume per unit time of all engineering services in the engineering service set;

[0038] The disk size required for storing log files of the photovoltaic energy storage system is calculated based on the retention time and the total log generation per unit time;

[0039] Determine whether the storage space of the preset disk meets the disk size.

[0040] Optionally, after the step of detecting whether the preset disk storage space corresponding to the photovoltaic energy storage system is sufficient, the step further includes:

[0041] When the preset disk storage space corresponding to the photovoltaic energy storage system is sufficient, a log storage strategy is set for the preset disk. The log storage strategy includes: the retention time of the log file, the storage location of the log file, and the log generation volume per unit time for each target engineering service.

[0042] According to another aspect of the present invention, there is also provided a computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, the steps of any of the above-mentioned photovoltaic energy storage system service file management methods are implemented.

[0043] According to another aspect of the present invention, a computer program product is provided, which includes a computer program, and when the computer program is executed by a processor, the steps of any one of the above-mentioned photovoltaic energy storage system service file management methods are implemented.

[0044] According to another aspect of the present invention, a computer device is provided, comprising a memory, a processor, and a machine executable program stored in the memory and running on the processor, and the processor implements any of the steps of the above-mentioned photovoltaic energy storage system service file management method when executing the machine executable program.

[0045] The photovoltaic energy storage system service file management method of the present invention includes the following steps: a) collecting a certain number of backup files; b) detecting whether the preset disk storage space corresponding to the photovoltaic energy storage system is sufficient; c) expanding the preset disk to collect the engineering service set and the corresponding service files in the photovoltaic energy storage system, and the service files include backup files and log files; d) calculating the number of backup files corresponding to each target engineering service in the engineering service set one by one; d) judging whether the number of backup files exceeds the preset threshold corresponding to the target engineering service; d) calculating the number of backup files to be deleted in the target engineering service; d) sorting the backup files according to the preset sorting rules to obtain a file list; d) deleting the corresponding storage space in the file list according to the number to be deleted. This method can reduce manual participation in service file management, avoid accidental deletion of important files, and improve execution efficiency without considering the issue of personnel access rights, thereby realizing the automated management of photovoltaic energy storage system service files and improving the stability and security of the photovoltaic energy storage system.

[0046] Furthermore, the photovoltaic energy storage system service file management method of the present invention calculates the log generation volume per unit time of each target engineering service in the photovoltaic energy storage system and combines them to obtain the total log generation volume per unit time of the photovoltaic energy storage system, and then calculates the disk size required for storing log files of the photovoltaic energy storage system according to the retention time and the total log generation volume per unit time, thereby estimating the disk size required for storing log files of the photovoltaic energy storage system. This method can modify the disk size in real time according to the estimation result, avoiding the situation where the log file cannot be stored due to insufficient disk space.

[0047] Based on the following detailed description of specific embodiments of the present invention in conjunction with the accompanying drawings, those skilled in the art will become more aware of the above and other objects, advantages and features of the present invention. BRIEF DESCRIPTION OF THE DRAWINGS

[0048] Hereinafter, some specific embodiments of the present invention will be described in detail in an exemplary and non-limiting manner with reference to the accompanying drawings. The same reference numerals in the accompanying drawings indicate the same or similar components or parts. It should be understood by those skilled in the art that these drawings are not necessarily drawn to scale. In the accompanying drawings:

[0049] Figure 1 is a flow chart of a method for managing service files of a photovoltaic energy storage system according to an embodiment of the present invention;

[0050] Figure 2It is a schematic diagram of the process of managing backup files of a photovoltaic energy storage system service file management method according to an embodiment of the present invention;

[0051] Figure 3 is a schematic diagram of a process flow of managing log files according to a method for managing service files of a photovoltaic energy storage system according to an embodiment of the present invention;

[0052] Figure 4 is a schematic diagram of a computer program product according to an embodiment of the present invention;

[0053] Figure 5 is a schematic diagram of a computer-readable storage medium according to an embodiment of the present invention; and

[0054] Figure 6 is a schematic diagram of a computer device according to an embodiment of the present invention. DETAILED DESCRIPTION

[0055] It should be understood by those skilled in the art that the embodiments described below are only some embodiments of the present invention, rather than all embodiments of the present invention, and these embodiments are intended to explain the technical principles of the present invention, rather than to limit the protection scope of the present invention. Based on the embodiments provided by the present invention, all other embodiments obtained by ordinary technicians in this field without creative work should still fall within the protection scope of the present invention.

[0056] It should be noted that the logic and / or steps represented in the flowchart or described in other ways herein, for example, can be considered as a sequenced list of executable instructions for implementing logical functions, and can be specifically implemented in any computer-readable medium for use by an instruction execution system, device or equipment (such as a computer-based system, a system including a processor, or other system that can fetch instructions from an instruction execution system, device or equipment and execute instructions), or used in combination with these instruction execution systems, devices or equipment.

[0057] During the deployment and operation of the photovoltaic energy storage system service, additional redundant files are generally generated, which are mainly divided into two categories: service executable backup files (referred to as backup files) and log files generated during the service operation. However, in the actual use of the photovoltaic energy storage system, the expired backup files and log files have lost their recovery or traceability value, so they can be deleted and cleaned up.

[0058] For such files, the usual way to handle them is to manually process them or set up a scheduled task. Manual processing means: regularly manually checking the number of backup files of each service and the size of the system operation log, and deleting a certain number of redundant files. However, the disadvantages of this method are: manual processing is time-consuming and labor-intensive, costly, and it is easy to delete files less, delete them by mistake, delete more, etc.; whether it is a week or a month, it cannot be completely guaranteed that the system disk will be full.

[0059] For scheduled tasks: the usual practice is to create a scheduled task script in the Linux operating system to regularly clean up redundant files in each service and directory. However, this method can only clean up files, and cannot always guarantee that the system disk is not full. In addition, every time a new service is added to the server of the photovoltaic energy storage system, the scheduled task script needs to be updated, which increases the cost of service operation and maintenance deployment.

[0060] In order to solve the above problems, Figure 1 FIG. 1 is a flow chart of a method for managing service files of a photovoltaic energy storage system according to an embodiment of the present invention. Figure 1 As shown, the photovoltaic energy storage system service file management method at least includes the following steps S101 to S108.

[0061] Step S101, collect the engineering service set and corresponding service files in the photovoltaic energy storage system. Service files generally include backup files and log files. The engineering service set in the photovoltaic energy storage system is a comprehensive service package, covering multiple stages from project planning, design, construction to operation and maintenance. For each engineering service, a corresponding directory will be established to store the backup files of the corresponding engineering service. The backup file is generally a comprehensive data set, covering multiple aspects such as system design, equipment, operation and maintenance, software programs, and important data. For example, photovoltaic energy storage system design and configuration files, equipment files, operation and maintenance files, program files, and other important data files. Therefore, backup files are usually of various types and large in number, and manual maintenance often has problems, so automatic processing of backup files is chosen.

[0062] Step S102, calculating the number of backup files corresponding to each target engineering service in the engineering service set one by one. In some optional embodiments, the step of calculating the number of backup files corresponding to each target engineering service in the engineering service set one by one may generally include: obtaining a target name of the target engineering service according to the engineering service set; obtaining a backup file corresponding to the target engineering service according to the target name by matching a regular expression; and calculating the number of backup files corresponding to the target engineering service one by one.

[0063] In the photovoltaic energy storage system of this embodiment, in order to clearly distinguish each engineering service, the directory of the subsequent files to be stored (such as backup files) is generally established by the name or alias of each target engineering service. Therefore, the target name of the target engineering service exists in the path string corresponding to each backup file. Based on this storage logic, the present invention chooses to obtain the backup file corresponding to the target engineering service by matching the target name through a regular expression; and calculates the number of backup files corresponding to the target engineering service one by one.

[0064] Step S103, determining whether the number of backup files exceeds a preset threshold value corresponding to the target engineering service. In some optional embodiments, the preset threshold value refers to the number of backup files corresponding to different target engineering services that are preset. Those skilled in the art can set the specific threshold value of the number of backup files according to the actual engineering service.

[0065] Step S104, if the judgment in step S103 is yes, the number of backup files to be deleted in the target engineering service is calculated. In some optional embodiments, when the number of backup files in the target engineering service is calculated and the preset threshold is known, the number to be deleted can be determined by subtracting the preset threshold from the number of backup files.

[0066] Step S105, sorting the backup files according to the preset sorting rule to obtain a file list. In some optional embodiments, the preset sorting rule can be sorting according to the creation time of the backup files, so that the backup files created earlier are deleted during the subsequent deletion process. Those skilled in the art can set the preset sorting rule according to actual conditions.

[0067] Step S106, deleting a corresponding number of backup files in the file list according to the number of files to be deleted.

[0068] Step S107, detecting whether the preset disk storage space corresponding to the photovoltaic energy storage system service is sufficient.

[0069] Step S108: if the answer in step S107 is no, expand the default disk.

[0070] This method can reduce manual participation in service file management, avoid accidental deletion of important files, and improve execution efficiency without considering personnel access rights, thereby realizing automated management of photovoltaic energy storage system service files and improving the stability and security of the photovoltaic energy storage system.

[0071] In some optional embodiments, the backup files are sorted according to a preset sorting rule, and the step of obtaining a file list includes: calculating the sorting score of the backup files according to the preset sorting rule; sorting the backup files in reverse order according to the sorting score to obtain a file list, and the backup files ranked first in the file list are deleted first. The reverse sorting and priority deletion correspond to each other. For example, in the case of reverse sorting, the highest ranking is the smallest ranking, that is, it needs to be deleted, so the backup files ranked first are selected for deletion in subsequent steps. Conversely, if the backup files ranked first in the file list have a higher sorting score, the backup files ranked later are deleted first.

[0072] In other optional embodiments, the step of calculating the sorting score of the backup file according to the preset sorting rule may generally include: determining the evaluation type of the preset sorting rule, the evaluation type including any one or more of the importance level, timeliness level and redundancy level; collecting the attribute information of the backup file; performing an evaluation based on the attribute information to obtain the evaluation results of different evaluation types of the backup file; and calculating the sorting score of the backup file based on the evaluation results.

[0073] Among them, the steps of obtaining evaluation results of different evaluation types of backup files according to attribute information generally include: obtaining the importance level of the backup file according to preset importance evaluation rules combined with attribute information evaluation, and the preset importance evaluation rules generally can include evaluation based on service relevance, data type and last access time in the attribute information.

[0074] Service relevance refers to the degree of relevance between the backup file and the engineering service in the photovoltaic energy storage system. A backup file with high service relevance is usually critical to the operation of the system because it contains configurations, logs or other important data required for the normal operation of the service. Data type refers to the type of data in the backup file. Different types of data may have different importance and value to the system. For example, data types may include database backups, system snapshots, etc. Different types of files have different meanings for system operation, so the importance level will also be different. The last access time refers to the time when the backup file was last accessed or modified. This is an indicator to measure the activity of the file. Generally speaking, files that have been accessed recently are more likely to be important. The closer the last access time, the more likely the file is frequently used or modified, so its importance is relatively high. By comprehensively evaluating the above three types of attribute information, the importance level of the backup file can be determined more reasonably. Those skilled in the art can set the preset importance evaluation rules according to the actual situation of different engineering services.

[0075] Secondly, the timeliness level of the backup file can also be obtained according to preset timeliness evaluation rules combined with attribute information evaluation. The preset timeliness evaluation rules can generally include evaluation based on the creation time, modification frequency in the attribute information and the business needs of the target engineering service.

[0076] Creation time refers to the date and time when the backup file was originally created. This time point can be used to determine the newness of the file and thus evaluate its timeliness. Newer backup files usually contain the latest data and configuration information, so they are more timely than older backup files. Modification frequency refers to the frequency with which the backup file is updated. Frequently updated files usually contain the latest information and therefore have higher timeliness. Some engineering services may need to frequently update configurations or data to adapt to business changes, so the backup files of these engineering services have higher timeliness; while some engineering services may rarely change, so their backup files have lower timeliness. By comprehensively evaluating the above three types of attribute information, the timeliness level of the backup file can be determined more reasonably. Technicians in this field can set the preset timeliness evaluation rules according to the actual situation of different engineering services.

[0077] In addition, the redundancy level of the backup file can be obtained according to preset redundancy evaluation rules combined with attribute information evaluation. The preset redundancy evaluation rules can generally include evaluation based on data integrity and time span in the attribute information combined with recovery testing; taking any one or more of the importance level, timeliness level and redundancy level as the evaluation result.

[0078] Data integrity refers to the completeness of the data in the backup file, that is, whether the backup file contains all the necessary data completely without any missing or damaged parts. Time span refers to the time range covered by the backup file, that is, from the earliest backup time to the most recent backup time. Time span can be used to evaluate the coverage and continuity of the backup file. A wider time span means that the backup file covers data for a longer period of time, so more time points can be selected during data recovery. Recovery testing refers to the recovery of backup files in a simulated environment to verify the validity of the backup files and the reliability of the recovery process. The performance of the backup file in the actual recovery process can be evaluated through recovery testing, including the success rate of recovery, recovery time, and accuracy of the recovered data. By comprehensively evaluating the above three types of attribute information, the redundancy level of the backup file can be determined more reasonably. Technicians in this field can set the preset redundancy evaluation rules according to the actual situation of different engineering services.

[0079] In some other optional embodiments, the step of detecting whether the preset disk storage space corresponding to the photovoltaic energy storage system service is sufficient may generally include: the step of detecting whether the preset disk storage space corresponding to the photovoltaic energy storage system is sufficient includes: obtaining a detection instruction of the preset disk; determining the retention time of the log file corresponding to each target engineering service according to the detection instruction; determining the business volume of each target engineering service per unit time and the average log generation volume of the business corresponding to each target engineering service per unit time according to the detection instruction; calculating the log generation volume of each target engineering service per unit time according to the business volume and the average log generation volume; merging the log generation volume of each target engineering service per unit time to obtain the total log generation volume of all engineering services in the engineering service set per unit time; calculating the disk size required for the photovoltaic energy storage system to store log files according to the retention time and the total log generation volume per unit time; and judging whether the storage space of the preset disk meets the disk size.

[0080] This solution can calculate the total amount of logs generated by the target engineering service and the required disk size within the retention time according to the preset retention time, business volume, and the average log generation volume of each business per unit time. The log retention time and unit time are generally determined in days. Those skilled in the art can set them according to the actual configuration.

[0081] After the step of detecting whether the preset disk storage space corresponding to the target engineering service is sufficient, the following step may generally be included: when the preset disk storage space corresponding to the photovoltaic energy storage system is sufficient, a log storage strategy is set for the preset disk, and the log storage strategy includes: the retention time of the log file, the storage location of the log file, and the log generation volume per unit time for each target engineering service.

[0082] Figure 2 FIG. 1 is a schematic diagram of a process for managing backup files of a photovoltaic energy storage system service file management method according to an embodiment of the present invention; Figure 2 As shown, the process of managing backup files in the photovoltaic energy storage system service file management method at least includes the following steps S201 to S207.

[0083] Step S201, enter the backup file directory. First, enter the directory where the engineering service backup file is located. This directory is unified for a certain engineering service, that is, all files stored in this directory are corresponding to the engineering service.

[0084] Step S202, obtaining the target name of the target engineering service.

[0085] Step S203, calculating the number of backup files. In some optional embodiments, the engineering service name is confirmed as a keyword for searching files, and the number of backup files T of the engineering service is matched through a regular expression;

[0086] Step S204, determine whether the number of backup files exceeds a preset threshold. In some optional embodiments, the preset threshold is set to N. If the number of backup files does not exceed the preset threshold N, it means that there is no need to delete the backup files, and the operation can be terminated.

[0087] Step S205: If the judgment in step S204 is yes, the number of backup files to be deleted in the target engineering service is calculated. An optional algorithm example is: set the number to be deleted to M, then M=TN.

[0088] Step S206, sorting the backup files in reverse order according to the preset sorting rule to obtain a file list. An optional example of the preset sorting rule is: sorting the backup files in reverse order according to the creation time, and the first part of the obtained file list represents the backup files with an earlier creation time.

[0089] In addition, the preset sorting rule may also be to sort according to any one or more of the importance level, timeliness level and redundancy level. Those skilled in the art may set the preset sorting rule according to actual conditions.

[0090] Step S207, deleting a corresponding number of backup files in the file list. In this embodiment, the first M files can be deleted from the file list.

[0091] Through this method, the backup files in the photovoltaic energy storage system can be automatically deleted through the program, avoiding the risks of server access rights and misoperation caused by manual operations, and improving the stability and security of the system.

[0092] Figure 3 1 is a flow chart of a management log file of a photovoltaic energy storage system service file management method according to an embodiment of the present invention; Figure 3 As shown, the process of managing backup files in the photovoltaic energy storage system service file management method includes at least the following steps S301 to S309.

[0093] Step S301, determine the log retention time and unit time. In some optional embodiments, the photovoltaic energy storage system can use the springboot framework to generate engineering services in the Linux system, and use the logback component for log management, and set the log retention time to T, which is usually calculated in days, that is, T days, and the unit time is days.

[0094] Step S302, determining the business volume of the target engineering service per unit time.

[0095] Step S303: determine the average log generation volume of each business per unit time.

[0096] Step S304: Calculate the log generation volume per unit time of each target engineering service based on the business volume and the average log generation volume. In some optional embodiments, the business volume per unit time is set to m, and the log generation volume per unit time is set to n. Then, each target engineering service S n =m*n.

[0097] Step S305 , combining the log generation volume per unit time of each target engineering service to obtain the total log generation volume per unit time of all engineering services in the engineering service set.

[0098] Step S306: Calculate the total log volume based on the retention time and the total log generation volume per unit time. Set the total log volume to d, then d = (S 1 +…+S n )*T.

[0099] Step S307, determining whether the storage space of the preset disk satisfies the disk size of the total log volume.

[0100] Step S308, when the judgment in step S307 is yes, expand the preset disk to a disk size that satisfies the total log volume.

[0101] Step S309: If the result of step S307 is negative, a log storage strategy is set for the preset disk. In some optional embodiments, the log storage strategy may generally include the following aspects: the retention time T of the log file, the storage location of the log file, and the log generation volume S per unit time of each target engineering service. n The storage location of the log file can generally be set to the data disk, thereby preventing the log file from being stored in the system disk and affecting the normal operation of the photovoltaic energy storage system. n You can monitor the log generation of each engineering service. For example, if the log generation volume on a certain day is greater than S n A prompt message can be issued to remind maintenance personnel to make adjustments to avoid log file storage failure.

[0102] Through this method, automated equipment can be relied upon to ensure that the system's disk meets the file storage conditions at all times, keeping the server in a controllable state. This can prevent the server disk from being filled up by abnormal traffic, ensure that the service operation history information is traceable, and improve the efficiency of system operation and maintenance.

[0103] The flow chart provided by the present embodiment is not intended to indicate that the operation of the method will be performed in any particular order, or that all operations of the method are included in all every case. In addition, the method may include additional operations. Within the scope of the technical ideas provided by the present embodiment method, additional changes may be made to the above method.

[0104] It should be understood that in some embodiments, each part can be implemented by hardware, software, firmware or a combination thereof. In the above embodiments, multiple steps or methods can be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system.

[0105] This embodiment also provides a computer program product 10 , a computer readable storage medium 20 , and a computer device 30 . Figure 4 is a schematic diagram of a computer program product 10 according to an embodiment of the present invention, Figure 5 is a schematic diagram of a computer-readable storage medium 20 according to an embodiment of the present invention, Figure 6 is a schematic diagram of a computer device 30 according to an embodiment of the present invention. The computer program product 10 includes a computer program 11, which implements the steps of any of the above-mentioned methods for managing service files of a photovoltaic energy storage system when executed by a processor 32. The computer-readable storage medium 20 stores the above-mentioned computer program 11, which implements the steps of any of the above-mentioned methods for managing service files of a photovoltaic energy storage system when executed by a processor 32. The computer device 30 may include a memory 31, a processor 32, and a computer program 11 stored in the memory 31 and running on the processor 32.

[0106] The computer program 11 for performing the operation of the present invention may be an assembly instruction, an instruction set architecture (ISA) instruction, a machine instruction, a machine-related instruction, a microcode, a firmware instruction, a state setting data, a configuration data of an integrated circuit, or a source code or an object code written in any combination of one or more programming languages ​​and process programming languages. The computer program 11 may be executed entirely on the user's computer, partially on the user's computer, as an independent software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the latter case, the remote computer may be connected to the user's computer via any type of network (including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., using an Internet service provider via the Internet). In some embodiments, in order to perform various aspects of the present invention, an electronic circuit including, for example, a programmable logic circuit, a field programmable gate array (FPGA) or a programmable logic array (PLA) may execute computer-readable program instructions by utilizing the state information of the computer-readable program instructions to personalize the electronic circuit.

[0107] In the description of this embodiment, the computer program product 10 is a related product including the computer program 11 .

[0108] For the purposes of the description of this embodiment, the computer-readable storage medium 20 is a tangible device capable of retaining and storing the computer program 11, which may be any device that can contain, store, communicate, propagate or transmit the program 11 for use with or in conjunction with an instruction execution system, device or apparatus. More specific examples (a non-exhaustive list) of the computer-readable storage medium 20 include the following: a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a static random access memory (SRAM), a portable compact disk read-only memory (CD-ROM), a digital versatile disk (DVD), a memory stick, a floppy disk, a mechanical encoding device, and any suitable combination of the foregoing.

[0109] The computer device 30 may be, for example, a server, a desktop computer, a notebook computer, a tablet computer, or a smart phone. In some examples, the computer device 30 may be a cloud computing node. The computer device 30 may be described in the general context of computer system executable instructions (such as program modules) executed by a computer system. Typically, a program module may include routines, programs, target programs, components, logic, data structures, etc. that perform specific tasks or implement specific abstract data types. The computer device 30 may be implemented in a distributed cloud computing environment where remote processing devices linked through a communication network perform tasks. In a distributed cloud computing environment, program modules may be located on a local or remote computing system storage medium including a storage device.

[0110] The computer device 30 may include a processor 32 adapted to execute stored instructions, and a memory 31 providing temporary storage space for the operation of the instructions during operation. The processor 32 may be a single-core processor, a multi-core processor, a computing cluster, or any number of other configurations. The memory 31 may include a random access memory (RAM), a read-only memory, a flash memory, or any other suitable storage system.

[0111] The computer device 30 may also include a network adapter / interface and an input / output (I / O) interface. The I / O interface allows data to be input and output with external devices that may be connected to the computer device. The network adapter / interface may provide communication between the computer device and a network, which is typically shown as a communication network.

[0112] At this point, those skilled in the art should recognize that, although multiple exemplary embodiments of the present invention have been shown and described in detail herein, many other variations or modifications that conform to the principles of the present invention can still be directly determined or derived based on the content disclosed in the present invention without departing from the spirit and scope of the present invention. Therefore, the scope of the present invention should be understood and recognized as covering all these other variations or modifications.

Claims

1. A photovoltaic energy storage system service file management method, include: Collecting the engineering service set and corresponding service files in the photovoltaic energy storage system, wherein the service files include backup files and log files; Calculate the number of backup files corresponding to each target engineering service in the engineering service set one by one; Determining whether the number of backup files exceeds a preset threshold corresponding to the target engineering service; If so, the number of backup files to be deleted in the target engineering service is calculated; Sorting the backup files according to a preset sorting rule to obtain a file list; Deleting a corresponding number of the backup files in the file list according to the number to be deleted; Detecting whether the preset disk storage space corresponding to the photovoltaic energy storage system is sufficient; If not, the storage space of the preset disk is expanded.

2. The photovoltaic energy storage system service file management method according to claim 1, in, The step of sorting the backup files according to a preset sorting rule to obtain a file list comprises: Calculate the sorting score of the backup file according to the preset sorting rule; The backup files are sorted in reverse order according to the sorting scores to obtain the file list, and the backup files ranked first in the file list are deleted first.

3. The photovoltaic energy storage system service file management method according to claim 2, in, The step of calculating the sorting score of the backup file according to the preset sorting rule comprises: Determining an evaluation type of the preset sorting rule, the evaluation type including any one or more of importance level, timeliness level and redundancy level; Collecting attribute information of the backup file; Evaluate the backup file according to the attribute information to obtain evaluation results of different evaluation types; The ranking score of the backup file is calculated according to the evaluation result.

4. The photovoltaic energy storage system service file management method according to claim 3, in, The step of evaluating the backup file according to the attribute information to obtain evaluation results of different evaluation types includes: Obtaining the importance level of the backup file according to a preset importance evaluation rule combined with the attribute information, wherein the preset importance evaluation rule includes evaluating according to the service association, data type, and last access time in the attribute information; Obtaining the timeliness level of the backup file according to a preset timeliness evaluation rule combined with the attribute information, wherein the preset timeliness evaluation rule includes evaluating according to the creation time, modification frequency in the attribute information and the business requirements of the target engineering service; Obtaining the redundancy level of the backup file according to a preset redundancy evaluation rule combined with the attribute information, wherein the preset redundancy evaluation rule includes evaluating according to data integrity and time span in the attribute information combined with a recovery test; Any one or more of the importance level, the timeliness level, and the redundancy level are used as the evaluation result.

5. The photovoltaic energy storage system service file management method according to claim 1, in, The step of calculating the number of backup files corresponding to each target engineering service in the engineering service set one by one includes: Acquire the target name of the target engineering service according to the engineering service set; Obtaining a backup file corresponding to the target engineering service by matching the target name with a regular expression; The number of backup files corresponding to the target engineering service is calculated one by one.

6. The photovoltaic energy storage system service file management method according to claim 1, in, The step of detecting whether the preset disk storage space corresponding to the photovoltaic energy storage system is sufficient comprises: Obtaining a detection instruction for the preset disk; Determine the retention time of the log file corresponding to each target engineering service according to the detection instruction; Determine the business volume of each target engineering service in a unit time and the average log generation volume of the business corresponding to each target engineering service in the unit time according to the detection instruction; Calculate the log generation amount of each target engineering service in the unit time according to the business volume and the average log generation amount; Combining the log generation amount of each target engineering service in the unit time to obtain the total log generation amount of all the engineering services in the engineering service set in the unit time; Calculate the disk size required by the photovoltaic energy storage system to store the log file according to the retention time and the total log generation amount per unit time; Determine whether the storage space of the preset disk satisfies the disk size.

7. The photovoltaic energy storage system service file management method according to claim 6, in, After the step of detecting whether the preset disk storage space corresponding to the photovoltaic energy storage system is sufficient, the following step is further performed: When the preset disk storage space corresponding to the photovoltaic energy storage system is sufficient, a log storage strategy is set for the preset disk, and the log storage strategy includes: the retention time of the log file, the storage location of the log file, and the log generation volume of each target engineering service in the unit time.

8. A computer-readable storage medium having a computer program stored thereon, wherein when the computer program is executed by a processor, the steps of the photovoltaic energy storage system service file management method according to any one of claims 1 to 7 are implemented.

9. A computer program product, comprising a computer program, which, when executed by a processor, implements the steps of the photovoltaic energy storage system service file management method according to any one of claims 1 to 7.

10. A computer device comprising a memory, a processor, and a machine executable program stored in the memory and running on the processor, wherein the processor implements the steps of the photovoltaic energy storage system service file management method according to any one of claims 1 to 7 when executing the machine executable program.

Citation Information

Patent Citations

  • Capacity monitoring method and device, computer equipment and storage medium

    CN110113224A

  • Equipment access method and device

    CN113157518A

  • Backup management method for continuous data protection, computer equipment and storage medium

    CN114579368A

  • Log file management method and system, storage medium and equipment

    CN116010366A

  • Log management method, log management device, storage medium and log management system

    CN117076412A