CN112328327B - Configuration partition arrangement method and device - Google Patents

Configuration partition arrangement method and device Download PDF

Info

Publication number
CN112328327B
CN112328327B CN202011313497.4A CN202011313497A CN112328327B CN 112328327 B CN112328327 B CN 112328327B CN 202011313497 A CN202011313497 A CN 202011313497A CN 112328327 B CN112328327 B CN 112328327B
Authority
CN
China
Prior art keywords
configuration
list
partition
files
configuration partition
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202011313497.4A
Other languages
Chinese (zh)
Other versions
CN112328327A (en
Inventor
吴庆
张长顺
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Hangzhou DPTech Technologies Co Ltd
Original Assignee
Hangzhou DPTech Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hangzhou DPTech Technologies Co Ltd filed Critical Hangzhou DPTech Technologies Co Ltd
Priority to CN202011313497.4A priority Critical patent/CN112328327B/en
Publication of CN112328327A publication Critical patent/CN112328327A/en
Application granted granted Critical
Publication of CN112328327B publication Critical patent/CN112328327B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/445Program loading or initiating
    • G06F9/44505Configuring for program initiating, e.g. using registry, configuration files
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • G06F9/5005Allocation of resources, e.g. of the central processing unit [CPU] to service a request
    • G06F9/5027Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resource being a machine, e.g. CPUs, Servers, Terminals
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The specification provides a configuration partition arrangement method, a device, a medium and equipment, wherein when a system version is upgraded, a list of configuration files required by the upgraded version is recorded; the method comprises the following steps: judging whether preset configuration partition arrangement conditions are met or not according to the occupation of the storage space of the configuration partition; the configuration partition is used for storing configuration files; acquiring a pre-recorded list under the condition that the finishing condition is met; and deleting files stored in the current configuration partition and not recorded in the list according to the acquired list. Files which are not in the configuration list file in the configuration partition of the embedded system are deleted, and the storage space is released, so that the probability that the storage space of the configuration partition is fully occupied is reduced, the writing of new configuration files in the configuration partition is ensured, and the normal operation of the system is ensured.

Description

Configuration partition arrangement method and device
Technical Field
The present disclosure relates to the field of computer applications, and in particular, to a method, an apparatus, a medium, and a device for organizing configuration partitions.
Background
In embedded systems, a single configuration partition is typically divided in its small non-volatile memory for storing configuration files. After the system version is upgraded, part of the configuration file of the previous version may become useless, but still be stored in the configuration partition, and a new configuration file may be stored in the configuration partition, so that more and more data are stored in the configuration partition. After multiple system version upgrades, the storage space of the configuration partition may be fully occupied, so that a new configuration file cannot be stored in the system version upgrade, and the system cannot operate normally.
In the prior art, in order to prevent the storage space in the configuration partition from being fully occupied, a program running in a system generally deletes a configuration file in which the program is discarded after the version of the system is upgraded. However, this deletion may still cause the storage space of the configuration partition to be fully occupied, which affects the normal operation of the system: on the one hand, after upgrading, some programs may be cut off, so that configuration files of the programs cannot be deleted, and the storage space is occupied; on the other hand, due to the problem of programming, some non-configuration files may be stored in the configuration partition, and these files cannot be identified and deleted by the program, so as to occupy the memory space.
Disclosure of Invention
In order to solve the problem that the garbage in the configuration partition occupies space in the related art, the specification provides a configuration partition arrangement method, a device, a medium and equipment.
According to a first aspect of embodiments of the present disclosure, a configuration partition sorting method is provided, and when a system version is upgraded, a list of configuration files required by the upgraded version is recorded; the method comprises the following steps:
judging whether preset configuration partition arrangement conditions are met or not according to the occupation of the storage space of the configuration partition; the configuration partition is used for storing configuration files;
acquiring a pre-recorded list under the condition that the finishing condition is met;
and deleting the configuration files stored in the current configuration partition and not recorded in the list according to the acquired list.
According to a second aspect of embodiments of the present disclosure, a configuration partition sorting device is provided, where when a system version is upgraded, a list of configuration files required by the upgraded version is recorded; the device comprises:
the arrangement condition judging unit is used for judging whether preset arrangement condition of the configuration partition is met according to the occupation of the storage space of the configuration partition; the configuration partition is used for storing configuration files;
a list acquisition unit configured to acquire a pre-recorded list in a case where it is determined that the sort condition is satisfied;
and the file deleting unit is used for deleting files which are stored in the current configuration partition and are not recorded in the list according to the acquired list.
According to a third aspect of embodiments of the present specification, there is provided a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements the configuration partition arrangement method according to any of the first aspects of the embodiments of the present specification.
According to a fourth aspect of embodiments of the present specification, there is provided a computer device comprising:
one or more processors;
a memory for storing one or more programs;
the one or more programs, when executed by the one or more processors, cause the one or more processors to implement the configuration partition grooming method as described in any one of the first aspects of the embodiments of the present specification.
Compared with the prior art, the configuration files in the configuration partition are managed uniformly by the system, files which cannot be deleted in the prior art are deleted through the pre-recorded list of the configuration partition, the probability that the storage space of the configuration partition is fully occupied is reduced, new configuration files can be written in the configuration partition, and normal operation of the system is ensured.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the disclosure.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the specification and together with the description, serve to explain the principles of the specification.
FIG. 1 is a flow chart illustrating a method of configuring partition organization according to an exemplary embodiment of the present description.
FIG. 2 is a flow chart illustrating how files may be deleted in a method of configuring partition organization according to one embodiment of the present disclosure.
FIG. 3 is a flow diagram illustrating another configuration partition consolidation method according to one embodiment of the present description.
Fig. 4 is a block diagram of a configuration partition collating device, as shown in this specification in accordance with an exemplary embodiment.
Fig. 5 is a hardware configuration diagram of a computer device where the partition arranging apparatus is configured according to the embodiment of the present disclosure.
Detailed Description
Reference will now be made in detail to exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, the same numbers in different drawings refer to the same or similar elements, unless otherwise indicated. The implementations described in the following exemplary examples do not represent all implementations consistent with the present specification. Rather, they are merely examples of apparatus and methods consistent with some aspects of the present description as detailed in the accompanying claims.
The terminology used in the description presented herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the description. As used in this specification and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It should also be understood that the term "and/or" as used herein refers to and encompasses any or all possible combinations of one or more of the associated listed items.
It should be understood that although the terms first, second, third, etc. may be used in this specification to describe various information, these information should not be limited to these terms. These terms are only used to distinguish one type of information from another. For example, the first information may also be referred to as second information, and similarly, the second information may also be referred to as first information, without departing from the scope of the present description. The word "if" as used herein may be interpreted as "at … …" or "at … …" or "responsive to a determination", depending on the context.
The configuration file is used for recording configuration information of programs in the system and is an indispensable part of normal operation of the programs. In an embedded system, since the memory space of the embedded system is small, and in order to ensure that the configuration file is not lost during shutdown or restart, the configuration file is generally stored in a configuration partition of a nonvolatile storage device of the embedded system. The nonvolatile memory device of the embedded system is generally a Flash memory card, such as a Compact Flash (CF), and the Flash memory card generally has a small memory space, and a configuration partition in the Flash memory card is also small.
When the version of the embedded system is upgraded, which programs are in the new version and the configuration files corresponding to each program are released, compared with other systems, the configuration files necessary for the system in each version of the embedded system are not changed due to the uninstallation or installation of the programs. After the system version is upgraded, configuration files which are not needed in the configuration partition may be some more, if the configuration files which are not needed in the new version in the configuration partition are not deleted in time, when the system is upgraded again, the configuration partition may have no available storage space to store the new configuration files needed in the upgraded version, so that the system cannot operate normally.
In the prior art, after the system is upgraded, each program in the system is respectively responsible for deleting the configuration files which are not needed by the program. This solution, although deleting some unnecessary configuration files, cannot delete some files in the configuration partition that are not responsible for the program, such as: some programs of the new version are cut off, and the original configuration files of the cut-off programs are not responsible for deleting the corresponding programs; in addition, some non-configuration files in the configuration partition may be wrongly stored, and the files are not responsible for deletion by the corresponding program.
Based on this, in one or more embodiments of the present invention, the scheme in the prior art that each program is responsible for managing the respective configuration files is changed to that in the configuration partition is managed by the system as a whole, and by pre-recording the list of configuration files, the pre-recorded list of configuration files is compared with the files in the configuration partition, so that when there is no redundant storage space in the configuration partition, the system can delete useless files in the configuration partition to release the space in the configuration partition. Therefore, the system can store a new configuration file when the next version is updated, so that the system can normally operate.
The embodiments of the present specification will be described in detail below from two stages, "ready" and "sort".
The preparation stage:
in order to implement the arrangement of the system configuration partitions, when the system version is upgraded, a list of configuration files required by the upgraded version is recorded.
The method for recording the list of the configuration files may be: each program provides the necessary configuration files thereof, and forms a list of the configuration files of the program; and integrating the list of the configuration files of the programs corresponding to all the programs into a total configuration file list. The list of configuration files can be stored in the configuration partition or other storage space, and when the list of configuration files is stored in the configuration partition, in order to prevent the list from being deleted when the configuration partition is arranged, the file of the list needs to be added in the list.
In the list of configuration files, a unique configuration file identification of each required file can be stored; the file may also be found for convenience, in a list of configuration files, the storage directory path of each required file is stored, that is, the list of configuration files includes the storage directory paths of the configuration files in the configuration partition.
Finishing:
based on the pre-recorded list in the preparation stage, the configuration partition can be rearranged when the arrangement needs exist, as shown in fig. 1, fig. 1 is a flowchart of a configuration partition arranging method according to an exemplary embodiment of the present specification, and specifically may include the following steps:
and step 101, judging whether preset configuration partition arrangement conditions are met or not according to the occupation of the storage space of the configuration partition.
The configuration partition is used for storing configuration files. In an embedded system, to prevent the configuration file from being lost when the device is turned off, the configuration partition is a storage space in the nonvolatile memory, such as a certain folder in the CF card.
Step 101 may be: when the specified period is reached, judging whether preset configuration partition arrangement conditions are met or not according to the occupation of the storage space of the configuration partition. The specified period can be selected to be a proper value according to practical situations, for example, the configuration partition can be stored in some non-configuration files frequently, the specified period can be shortened, or the configuration partition is smaller, and the configuration partition can be cleaned frequently. The specified period can be selected as small as possible to realize real-time monitoring of the occupation of the storage space of the configuration partition.
Step 101 may also be: before each system upgrade, judging whether preset arrangement conditions of the configuration partition are met or not according to the storage space occupation of the configuration partition. The arrangement condition of the configuration partition may be whether the occupancy rate of the configuration partition reaches a preset threshold value or whether the size of the space occupied by all files in the configuration partition reaches a preset value. In practice, the preset threshold or preset value may be selected according to practical situations, such as the configuration partition being smaller, and the preset threshold may be set to be smaller, so as to prevent that no space is reserved for storing new configuration files when the system is updated.
In addition, besides judging whether the preset configuration partition arrangement condition is met according to the storage space occupation of the configuration partition, the method can also comprise the following steps: when a user inputs a configuration partition sorting instruction, the configuration partitions are sorted, or after each system upgrade, the configuration partitions are sorted.
Step 102, in the case that the finishing condition is determined to be satisfied, a pre-recorded list is acquired.
In case it is determined that the sort condition is not satisfied, the next execution of step 101 is waited. If step 101 is performed until a specified period is reached, in the event that it is determined that the sort condition is not satisfied, waiting for the arrival of the next specified period.
And step 103, deleting files stored in the current configuration partition and not recorded in the list according to the acquired list.
After step 103 is performed, the next condition triggering the execution of step 101 is waited. If step 101 is performed until a specified period is reached, then the arrival of the next specified period is awaited after completion of step 103.
According to the acquired list, deleting files stored in the current configuration partition and not recorded in the list, wherein the method specifically comprises the following steps: comparing the files stored in the configuration partition with the configuration files in the list, and adding a deletion mark in the files stored in the current configuration partition and not recorded in the list; files stored in the configuration partition that are not recorded in the list are deleted according to the deletion flag.
After each version upgrade of the system, the list of configuration files of the previous version may be deleted. In the case that the list of configuration files is in the configuration partition, after each version upgrade of the system, the list of configuration files of the previous version may not be deleted.
Specifically, as shown in fig. 2, fig. 2 is a flowchart illustrating how to delete a file in a configuration partition sorting method according to an embodiment of the present disclosure, step 103 may include the following steps:
step 1031, obtain all file lists of the configuration partition.
Step 1032, compare the list of all files of the configuration partition with the list of configuration files, add delete markers to files that do not exist in the list of configuration files and exist in the list of all files of the configuration partition.
Step 1033, each file in the configuration partition is processed item by item.
Step 1034, determining whether the file has a delete marker.
If the result of the determination is yes, that is, if the file has a deletion flag, the process goes to step 1035, and if the result of the determination is no, that is, if the file has no deletion flag, the process goes to step 1033.
Step 1035, delete the file.
Step 1036, determining whether to traverse all files of the configuration partition.
If the result of the determination is yes, that is, all the files in the configuration partition have been traversed, the configuration partition is finished, the configuration partition finishing process is finished, and if the result of the determination is no, that is, all the files in the configuration partition have not been traversed, the process goes to 1033.
When the version is updated, the system records the necessary configuration files of the updated version in advance to form a list of the configuration files. When the configuration partition needs to be arranged, the system uniformly deletes files which are not necessary for the version in the configuration partition through the recorded list of the configuration files, and the problem that the configuration files of the program which is cut down in the new version cannot be deleted in the prior art is solved through the system overall management of the configuration partition, so that the probability that the storage space of the configuration partition is fully occupied is reduced, the new configuration files can be written in the configuration partition, and the normal operation of the system after updating is ensured.
For example, as shown in fig. 3, fig. 3 is a flowchart illustrating another configuration partition sorting method according to an embodiment of the present disclosure. In the embedded system, an entry directory of the configuration partition is a/config path, and a list of configuration files is stored in the configuration partition. There are two programs A1 and A2 in the old version, wherein the storage directory path of the configuration file of A1 is/config/A1/1 and/config/A1/2, respectively, the storage directory path of the configuration file of A2 is/config/A2/3, the storage directory path of the list of configuration files of this version is/config/cfg. Before the system version is upgraded, the configuration partition has no unnecessary configuration files and other files, and the files in the list of the configuration partition and the configuration files before the system version is upgraded are the same, wherein the list of the configuration files comprises: the term "config/A1/1,/config/A1/2,/config/A2/3 and/config/cfg.
After the system version is upgraded, A2 is cut off in the new version system, the new version system only has two programs A1 and A3, the storage directory paths of the configuration files required by A1 are/config/A1/1 and/config/A1/4 respectively, and the storage directory paths of the configuration files required by A3 are/config/A3/5. And when the version is upgraded, the list of the configuration files of the new version is replaced by the list of the configuration files of the old version.
After release of the new version, the method comprises the following steps:
in step 301, when the system version is upgraded, a list of configuration files required by the upgraded version is recorded.
When the version is upgraded, recording a list of configuration files required by the upgraded version, and replacing the list of the configuration files with the list of the original configuration files in the configuration partition, wherein the name of the list of the configuration files is cfg. The list of the new version of the configuration file includes the following: the ratio of/config/A1/1,/config/A1/4,/config/A3/5 and/config/cfg. List.
Step 302, after the system version is upgraded, the system is started.
Step 303, it is detected whether a specified period is reached.
After the system version is upgraded, the system is started, and when a specified period is reached, configuration partition arrangement is carried out according to the occupation condition of the configuration partition.
Step 304, judging whether a preset configuration partition arrangement condition is met according to the occupation of the storage space of the configuration partition.
If the determination result is yes, that is, after the preset configuration partition arrangement condition is satisfied, step 305 is executed, and if the determination result is no, step 303 is skipped.
Monitoring whether the occupancy of the configured partition reaches a specified threshold. After the system is upgraded, when the first specified period is reached, the storage directory path of the files in the configuration partition is: the six files enable the configuration partition to reach the preset configuration partition arrangement condition. Then execution continues with step 305.
In step 305, a pre-recorded list is obtained.
In the configuration partition, a list cfg.list of configuration files is obtained by storing directory paths/config/cfg.list.
And 306, deleting files stored in the current configuration partition and not recorded in the list according to the acquired list.
After step 306 is performed, the process jumps to step 303, where the arrival of the next specified period is awaited.
Based on comparing all files in the configuration partition with the list of acquired configuration files, the following unnecessary configuration files are found: a1 has not needed the configuration file/config/A1/2, and cut the original configuration file/config/A2/3 of A2, delete these two files. After deletion, the files in the configuration partition are: the storage space occupancy rate in the configuration partition can not reach the preset configuration partition arrangement condition, and the arrangement of the configuration partition is realized.
In one or more embodiments of the present invention, the scheme in the prior art that each program is responsible for the configuration file management of its own program is changed, files in the configuration partition are managed by the system as a whole, and by pre-recording a list of configuration files, the pre-recorded list of configuration files is compared with the files in the configuration partition, so that when the system has no redundant storage space in the configuration partition, useless files in the configuration partition can be deleted to release the space in the configuration partition. Therefore, the system can store a new configuration file when the next version is updated, so that the system can normally operate.
Corresponding to the embodiment of the method, the present specification also provides an embodiment of configuring the partition arranging device and the terminal to which the partition arranging device is applied.
As shown in fig. 4, fig. 4 is a block diagram of a configuration partition grooming device according to an exemplary embodiment of the present disclosure, the device comprising:
a sorting condition judging unit 410, configured to judge whether a preset sorting condition of the configuration partition is satisfied according to the storage space occupation of the configuration partition; the configuration partition is used for storing configuration files.
A list acquisition unit 420 for acquiring a pre-recorded list in case it is determined that the sort condition is satisfied.
And a file deleting unit 430, configured to delete files stored in the current configuration partition and not recorded in the list according to the acquired list.
The implementation process of the functions and roles of each module in the above device is specifically shown in the implementation process of the corresponding steps in the above method, and will not be described herein again.
Further, the list of configuration files includes a storage directory path for the configuration files in the configuration partition.
Further, the arrangement condition judgment unit is specifically configured to: when the specified period is reached, judging whether preset configuration partition arrangement conditions are met or not according to the occupation of the storage space of the configuration partition.
Further, the file deleting unit specifically includes: a deletion mark adding subunit, configured to compare the file stored in the configuration partition with the configuration file in the list, and add a deletion mark to the file stored in the current configuration partition and not recorded in the list; and the file deleting subunit is used for deleting files stored in the configuration partition and not recorded in the list according to the deleting mark.
For the device embodiments, reference is made to the description of the method embodiments for the relevant points, since they essentially correspond to the method embodiments. The apparatus embodiments described above are merely illustrative, wherein the modules illustrated as separate components may or may not be physically separate, and the components shown as modules may or may not be physical, i.e., may be located in one place, or may be distributed over a plurality of network modules. Some or all of the modules may be selected according to actual needs to achieve the purposes of the present description. Those of ordinary skill in the art will understand and implement the present invention without undue burden.
As shown in fig. 5, fig. 5 shows a hardware configuration diagram of a computer device where the partition sort device is configured, where the device may include: processor 510, memory 520, input/output interface 530, communication interface 540, and bus 550. Wherein processor 510, memory 520, input/output interface 530, and communication interface 540 enable a communication connection within the device between each other via bus 550.
The processor 510 may be implemented by a general-purpose CPU (Central Processing Unit ), a microprocessor, an application-specific integrated circuit (Application Specific Integrated Circuit, ASIC), or one or more integrated circuits, etc. for executing relevant programs to implement the technical solutions provided in the embodiments of the present disclosure.
The Memory 520 may be implemented in the form of ROM (Read Only Memory), RAM (Random Access Memory ), static storage device, dynamic storage device, or the like. Memory 520 may store an operating system and other application programs, and when the embodiments of the present disclosure are implemented in software or firmware, the associated program code is stored in memory 520 and executed by processor 510.
The input/output interface 530 is used for connecting with an input/output module to realize information input and output. The input/output module may be configured as a component in a device (not shown) or may be external to the device to provide corresponding functionality. Wherein the input devices may include a keyboard, mouse, touch screen, microphone, various types of sensors, etc., and the output devices may include a display, speaker, vibrator, indicator lights, etc.
The communication interface 540 is used to connect with a communication module (not shown in the figure) to enable communication interaction between the present device and other devices. The communication module may implement communication through a wired manner (such as USB, network cable, etc.), or may implement communication through a wireless manner (such as mobile network, WIFI, bluetooth, etc.).
Bus 550 includes a path to transfer information between elements of the device (e.g., processor 510, memory 520, input/output interface 530, and communication interface 540).
It should be noted that although the above device only shows the processor 510, the memory 520, the input/output interface 530, the communication interface 540, and the bus 550, in the implementation, the device may further include other components necessary for achieving normal operation. Furthermore, it will be understood by those skilled in the art that the above-described apparatus may include only the components necessary to implement the embodiments of the present description, and not all the components shown in the drawings.
The present description embodiment also provides a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements the configuration partition arrangement method according to any one of the first aspects of the present description embodiments.
Computer readable media, including both non-transitory and non-transitory, removable and non-removable media, may implement information storage by any method or technology. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of storage media for a computer include, but are not limited to, phase change memory (PRAM), static Random Access Memory (SRAM), dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), read Only Memory (ROM), electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), digital Versatile Discs (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices, or any other non-transmission medium, which can be used to store information that can be accessed by a computing device. Computer-readable media, as defined herein, does not include transitory computer-readable media (transmission media), such as modulated data signals and carrier waves.
The foregoing describes specific embodiments of the present disclosure. Other embodiments are within the scope of the following claims. In some cases, the actions or steps recited in the claims can be performed in a different order than in the embodiments and still achieve desirable results. In addition, the processes depicted in the accompanying figures do not necessarily require the particular order shown, or sequential order, to achieve desirable results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.
Other embodiments of the present description will be apparent to those skilled in the art from consideration of the specification and practice of the invention disclosed herein. This specification is intended to cover any variations, uses, or adaptations of the specification following, in general, the principles of the specification and including such departures from the present disclosure as come within known or customary practice within the art to which the specification pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the specification being indicated by the following claims.
It is to be understood that the present description is not limited to the precise arrangements and instrumentalities shown in the drawings, which have been described above, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present description is limited only by the appended claims.
The foregoing description of the preferred embodiments is provided for the purpose of illustration only, and is not intended to limit the scope of the disclosure, since any modifications, equivalents, improvements, etc. that fall within the spirit and principles of the disclosure are intended to be included within the scope of the disclosure.

Claims (10)

1. A configuration partition arrangement method is characterized in that when a system version is upgraded, a list of configuration files required by the upgraded version is recorded; the method comprises the following steps:
judging whether preset configuration partition arrangement conditions are met or not according to the occupation of the storage space of the configuration partition; the configuration partition is a nonvolatile memory of the embedded system; the configuration partition is used for storing configuration files;
acquiring a pre-recorded list under the condition that the finishing condition is met;
and deleting files stored in the current configuration partition and not recorded in the list according to the acquired list.
2. The method of claim 1, wherein the list of configuration files includes a storage directory path for the configuration files in the configuration partition.
3. The method of claim 1, wherein determining whether a preset configuration partition arrangement condition is satisfied according to a storage space occupation of a configuration partition, specifically comprises:
when the specified period is reached, judging whether preset configuration partition arrangement conditions are met or not according to the occupation of the storage space of the configuration partition.
4. The method according to claim 1, wherein deleting files stored in the currently configured partition that are not recorded in the list according to the acquired list, specifically comprises:
comparing the files stored in the configuration partition with the configuration files in the list, and adding a deletion mark in the files stored in the current configuration partition and not recorded in the list;
files stored in the configuration partition that are not recorded in the list are deleted according to the deletion flag.
5. The configuration partition sorting device is characterized in that when a system version is upgraded, a list of configuration files required by the upgraded version is recorded; the device comprises:
the arrangement condition judging unit is used for judging whether preset arrangement condition of the configuration partition is met according to the occupation of the storage space of the configuration partition; the configuration partition is a nonvolatile memory of the embedded system; the configuration partition is used for storing configuration files;
a list acquisition unit configured to acquire a pre-recorded list in a case where it is determined that the sort condition is satisfied;
and the file deleting unit is used for deleting files which are stored in the current configuration partition and are not recorded in the list according to the acquired list.
6. The apparatus of claim 5, wherein the list of configuration files includes a storage directory path for the configuration files in the configuration partition.
7. The device according to claim 5, wherein the arrangement condition judging unit is specifically configured to:
when the specified period is reached, judging whether preset configuration partition arrangement conditions are met or not according to the occupation of the storage space of the configuration partition.
8. The apparatus of claim 5, wherein the file deletion unit specifically includes:
a deletion mark adding subunit, configured to compare the file stored in the configuration partition with the configuration file in the list, and add a deletion mark to the file stored in the current configuration partition and not recorded in the list;
and the file deleting subunit is used for deleting files stored in the configuration partition and not recorded in the list according to the deleting mark.
9. A computer readable storage medium, wherein a computer program is stored on the readable storage medium, which when executed by a processor, implements the configuration partition arrangement method according to any one of claims 1 to 4.
10. A computer device, the computer device comprising:
one or more processors;
a memory for storing one or more programs;
the one or more programs, when executed by the one or more processors, cause the one or more processors to implement the configuration partition grooming method of any of claims 1 to 4.
CN202011313497.4A 2020-11-20 2020-11-20 Configuration partition arrangement method and device Active CN112328327B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011313497.4A CN112328327B (en) 2020-11-20 2020-11-20 Configuration partition arrangement method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011313497.4A CN112328327B (en) 2020-11-20 2020-11-20 Configuration partition arrangement method and device

Publications (2)

Publication Number Publication Date
CN112328327A CN112328327A (en) 2021-02-05
CN112328327B true CN112328327B (en) 2023-10-27

Family

ID=74321828

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011313497.4A Active CN112328327B (en) 2020-11-20 2020-11-20 Configuration partition arrangement method and device

Country Status (1)

Country Link
CN (1) CN112328327B (en)

Citations (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101782859A (en) * 2010-03-18 2010-07-21 上海乐毅信息科技有限公司 Upgrading method of embedded system in application
CN102609495A (en) * 2012-01-29 2012-07-25 奇智软件(北京)有限公司 Method for deleting file and system
CN102654872A (en) * 2011-03-03 2012-09-05 腾讯科技(深圳)有限公司 Method and device for cleaning junk files generated by application programs
CN103646087A (en) * 2013-12-13 2014-03-19 北京奇虎科技有限公司 Junk file data cleaning method and device
CN104391850A (en) * 2014-07-31 2015-03-04 珠海市君天电子科技有限公司 Method and device for cleaning garbage files of disks, and terminal device
CN105867845A (en) * 2016-03-28 2016-08-17 乐视控股(北京)有限公司 Application storage space management method and device
CN106325942A (en) * 2016-08-25 2017-01-11 维沃移动通信有限公司 Application program data processing method and mobile terminal
CN106339209A (en) * 2015-07-17 2017-01-18 阿里巴巴集团控股有限公司 Data processing method and equipment
CN106557500A (en) * 2015-09-28 2017-04-05 北京金山安全软件有限公司 Method and device for cleaning uninstalled residual file and terminal
CN108121783A (en) * 2017-12-19 2018-06-05 深圳创维数字技术有限公司 A kind of automatic cleaning method, device, computer and storage medium for storing data
CN109656881A (en) * 2018-12-26 2019-04-19 山东华辰泰尔信息科技股份有限公司 A kind of method and system for realizing file dynamic management based on FAT16 technology
CN109902078A (en) * 2019-01-10 2019-06-18 杭州迪普科技股份有限公司 Database upgrade compatible method, apparatus, equipment and storage medium
CN110471764A (en) * 2019-08-01 2019-11-19 郑州阿帕斯科技有限公司 A kind of processing method and processing device of memory cleaning
CN111427598A (en) * 2020-03-16 2020-07-17 深圳震有科技股份有限公司 Control method and system of software upgrading file and intelligent terminal

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4908849B2 (en) * 2006-01-11 2012-04-04 富士通セミコンダクター株式会社 File deletion method, file opening method, file deletion program, and file opening program
CN105867947B (en) * 2016-04-25 2019-03-26 青岛海信电器股份有限公司 Data processing method and device after preset application program updating
CN105955781B (en) * 2016-05-09 2024-03-12 京东方科技集团股份有限公司 EMMC upgrading method, upgrading device and terminal

Patent Citations (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101782859A (en) * 2010-03-18 2010-07-21 上海乐毅信息科技有限公司 Upgrading method of embedded system in application
CN102654872A (en) * 2011-03-03 2012-09-05 腾讯科技(深圳)有限公司 Method and device for cleaning junk files generated by application programs
CN102609495A (en) * 2012-01-29 2012-07-25 奇智软件(北京)有限公司 Method for deleting file and system
CN103646087A (en) * 2013-12-13 2014-03-19 北京奇虎科技有限公司 Junk file data cleaning method and device
CN104391850A (en) * 2014-07-31 2015-03-04 珠海市君天电子科技有限公司 Method and device for cleaning garbage files of disks, and terminal device
CN106339209A (en) * 2015-07-17 2017-01-18 阿里巴巴集团控股有限公司 Data processing method and equipment
CN106557500A (en) * 2015-09-28 2017-04-05 北京金山安全软件有限公司 Method and device for cleaning uninstalled residual file and terminal
WO2017166679A1 (en) * 2016-03-28 2017-10-05 乐视控股(北京)有限公司 Method and apparatus for managing storage space of applications, and electronic device
CN105867845A (en) * 2016-03-28 2016-08-17 乐视控股(北京)有限公司 Application storage space management method and device
CN106325942A (en) * 2016-08-25 2017-01-11 维沃移动通信有限公司 Application program data processing method and mobile terminal
CN108121783A (en) * 2017-12-19 2018-06-05 深圳创维数字技术有限公司 A kind of automatic cleaning method, device, computer and storage medium for storing data
CN109656881A (en) * 2018-12-26 2019-04-19 山东华辰泰尔信息科技股份有限公司 A kind of method and system for realizing file dynamic management based on FAT16 technology
CN109902078A (en) * 2019-01-10 2019-06-18 杭州迪普科技股份有限公司 Database upgrade compatible method, apparatus, equipment and storage medium
CN110471764A (en) * 2019-08-01 2019-11-19 郑州阿帕斯科技有限公司 A kind of processing method and processing device of memory cleaning
CN111427598A (en) * 2020-03-16 2020-07-17 深圳震有科技股份有限公司 Control method and system of software upgrading file and intelligent terminal

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
An Efficient Directory Entry Lookup Cache With Prefix-Awareness for Mobile Devices;Zhaoyan Shen;Lei Han; Renhai Chen;《 IEEE Transactions on Computer-Aided Design of Integrated Circuits and Systems》;第39卷(第12期);4575 - 4586 *
GFUAeD:一种嵌入式设备的通用固件升级方法;纪大峣;福建电脑;第34卷(06);122-128 *
类Unix系统服务器文件夹磁盘空间监视及自动维护软件的研制;李挺; 邓科; 张焕青; 蔡昂; 冯凝; 刘晓华; 李炜; 洪叶;《重庆理工大学学报(自然科学)》;第31卷(第12期);151-155+207 *

Also Published As

Publication number Publication date
CN112328327A (en) 2021-02-05

Similar Documents

Publication Publication Date Title
CN109240886B (en) Exception handling method, exception handling device, computer equipment and storage medium
CN105893084B (en) Version upgrading method and terminal device
EP3516511B1 (en) Update migration system and method
US20140344536A1 (en) Storage systems that create snapshot queues
CN102567053A (en) Method and device for downgrading software version
EP1679599B1 (en) File update system and boot management system of mobile communication terminal, and corresponding methods
CN112182010B (en) Dirty page refreshing method and device, storage medium and electronic equipment
CN109710286B (en) System upgrading method, device, equipment and storage medium
CN114443058A (en) Method for creating private mirror image in public cloud and related equipment
CN109313537B (en) Method and apparatus for managing storage area of control device of vehicle
US20160085456A1 (en) Data read apparatus, data read method, and storage medium storing data read program
CN112148337A (en) Firmware upgrading method and device
CN114780019A (en) Electronic device management method and device, electronic device and storage medium
CN112328327B (en) Configuration partition arrangement method and device
CN113190325A (en) Container creation method and device
CN112433669A (en) Method, system, equipment and medium for online migration of distributed storage volume
CN107643959B (en) Mirror image file processing method and device
CN115328851A (en) Data protection method, device, equipment and medium
CN114679465A (en) Resource operation method and device, electronic equipment and storage medium
US9418175B2 (en) Enumeration of a concurrent data structure
CN108427678B (en) Method for searching application resource file by android system
CN114020308A (en) Camera equipment upgrading method, device, equipment and medium
JP2006031203A (en) On-vehicle information terminal
CN111858018B (en) Cgroup configuration method and device, computer equipment and storage medium
CN106959888B (en) Task processing method and device in cloud storage system

Legal Events

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