CN106503138A - A kind of journal file processing method and processing device - Google Patents
A kind of journal file processing method and processing device Download PDFInfo
- Publication number
- CN106503138A CN106503138A CN201610915695.5A CN201610915695A CN106503138A CN 106503138 A CN106503138 A CN 106503138A CN 201610915695 A CN201610915695 A CN 201610915695A CN 106503138 A CN106503138 A CN 106503138A
- Authority
- CN
- China
- Prior art keywords
- journal file
- disk
- predetermined condition
- status information
- journal
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/10—File systems; File servers
- G06F16/18—File system types
- G06F16/1805—Append-only file systems, e.g. using logs or journals to store data
- G06F16/1815—Journaling file systems
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/10—File systems; File servers
- G06F16/16—File or folder operations, e.g. details of user interfaces specifically adapted to file systems
- G06F16/162—Delete operations
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/06—Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
- G06F3/0601—Interfaces specially adapted for storage systems
- G06F3/0602—Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
- G06F3/0608—Saving storage space on storage systems
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/06—Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
- G06F3/0601—Interfaces specially adapted for storage systems
- G06F3/0668—Interfaces specially adapted for storage systems adopting a particular infrastructure
- G06F3/0671—In-line storage system
- G06F3/0673—Single storage device
- G06F3/0674—Disk device
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Human Computer Interaction (AREA)
- Data Mining & Analysis (AREA)
- Databases & Information Systems (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
The invention discloses a kind of journal file processing method, including:Journal file is set and is retained in the predetermined condition in disk;The triggered time that journal file processes thread is set;After the triggered time is reached, triggering journal file processes thread;Obtain the status information for being stored in all journal files in disk;Judge whether the status information of each journal file meets the predetermined condition;When the status information of journal file conforms to a predetermined condition, then the journal file is retained in disk;When the status information of journal file does not meet predetermined condition, the journal file is stored to compressed package, and the journal file is deleted in the disk;Terminate the journal file and process thread.Therefore, by this method saving the memory space in disk, and when statistical analysis is carried out to journal file in the later stage, corresponding journal file can be found in compressed package.
Description
Technical field
The present invention relates to electronic information technical field, more particularly to a kind of journal file processing method and processing device.
Background technology
As the electronic equipments such as the development of electronic information technology, computer and server are applied more and more in routine duties
Extensively, the operation of electronic equipment all be unable to do without application program.
Application program can produce journal file in running, journal file be for records application program operationally
The status information of generation, Debugging message, the error message for executing temporal information and producing when running etc., journal file is stored in magnetic
In disk, the journal file of the certain format that application program was produced after operation a period of time is referred to as history log file.
In any case, application program needs to realize daily record rolling function, i.e., according to certain strategy such as time or file
Size, produces new journal file, and the personnel of maintaining easily are checked, after application program realizes daily record rolling function, with
Time and the increase of accessed number of times, can produce substantial amounts of history log file.Therefore, it is necessary to carry out to history log file
Cleaning, saves the space of disk, is also convenient for operation maintenance personnel and checks recent history log file information.
Prior art has two kinds of processing methods, first method to history log file:To application program in running
A large amount of history log files of middle generation are not processed, and when process in need, carry out manual handle, this side by attendant
After application program operation a period of time, a large amount of history log files of generation can cause disk space to waste to method, make disk empty
Between utilization rate decline, and need attendant's manual handle, reduce the operating efficiency of attendant's maintenance;Another kind side
Method:The number of disk storage history log file is set, when history log file is beyond the number for arranging, is entered by application program
Row operation, directly deletes the history log file of oldest stored, and do not backup reservation, and although the method saves disk space,
But to directly deleting beyond the history log file for arranging storage number, cause the later stage unite history log file
Meter analysis.
Therefore, a large amount of history log files of application program long-play generation how are processed, disk can be saved empty
Between, and avoid history log file from directly deleting, cause the later stage statistical analysis cannot be carried out to history log file, be this area
Technical staff's technical problem urgently to be resolved hurrily.
Content of the invention
It is an object of the invention to provide a kind of journal file processing method and processing device, produces in application program long-play
During a large amount of journal files, by the journal file of the method process generation, the space that can be saved in disk, and do not affect to tie up
Statistical analysis of the shield personnel's later stage to journal file.
For achieving the above object, the present invention provides a kind of journal file processing method, including:
Journal file is set and is retained in the predetermined condition in disk;
The triggered time that journal file processes thread is set;
After the triggered time is reached, trigger the journal file and process thread;
Obtain the status information for being stored in all journal files in the disk;
Judge whether the status information of each journal file meets the predetermined condition;
When the status information of journal file meets the predetermined condition, then the journal file is retained in the disk;
When the status information of journal file does not meet the predetermined condition, the journal file is stored to compressed package, and
The journal file is deleted in the disk;
Terminate the journal file and process thread.
Preferably, the predetermined condition is the generation number of days of journal file within the predetermined number of days, then the status information is
The temporal information of journal file is generated, it is concrete whether the status information for judging each journal file meets the predetermined condition
For:
Judge to generate the temporal information of each journal file whether within the predetermined number of days;
Wherein, when the temporal information of journal file is generated within predetermined number of days, then the status information of the journal file is accorded with
Close the predetermined condition;
When generate journal file temporal information not within predetermined number of days when, then the status information of the journal file does not meet
The predetermined condition.
Preferably, the predetermined condition be the currently stored total amount of the disk in predetermined amount of storage, then the state
Information is the currently stored total amount of the disk, and whether the status information for judging each journal file meet the predetermined condition
Specially:
Judge the currently stored total amount of the disk whether in the predetermined amount of storage;
Wherein, when the currently stored total amount of the disk is in the predetermined amount of storage, then in the disk, all daily records are literary
Part meets the predetermined condition;
When the currently stored total amount of the disk exceeds in the predetermined amount of storage, then in the disk, all journal files are equal
The predetermined condition is not met.
Preferably, the predetermined condition for journal file sequence label in predetermined number, then the status information is
Journal file sequence label, whether the status information for judging each journal file meets the predetermined condition is specially:
Judge each journal file sequence label whether in the predetermined number;
When daily record file ordering label is in predetermined number, then the status information of the journal file meets the predetermined bar
Part;
When daily record file ordering label not in predetermined number when, then the status information of the journal file does not meet described pre-
Fixed condition.
Preferably, described the journal file is stored to compressed package, specifically include:
Judge to whether there is the compressed package under fixed catalogue;
If there is the compressed package, then during store the journal file to the compressed package;
If there is no the compressed package, then newly-built compressed package under the fixed catalogue, and the journal file is deposited
In storing up to the newly-built compressed package.
Preferably, after the end journal file processes thread, also include:Dormancy is entered, waits next time described tactile
The time of sending out reaches.
Preferably, the triggered time is 7 days.
Present invention also offers a kind of journal file processing meanss, including:
Arranging unit, for arranging predetermined condition and the setting journal file process thread that journal file is retained in disk
Triggered time;
Trigger element, processes thread for after the triggered time is reached, triggering the journal file;
Acquiring unit, for obtaining the status information for being stored in all journal files in the disk;
Judging unit, for judging whether the status information of each journal file meets the predetermined condition;Wherein, the same day
When the status information of will file meets the predetermined condition, then the journal file is retained in the disk;When journal file
When status information does not meet the predetermined condition, memory cell is triggered;
Memory cell, for when the status information of journal file does not meet the predetermined condition, the journal file being deposited
Store up to compressed package, and the journal file is deleted in the disk.
A kind of journal file processing method and processing device provided by the present invention, the method include:Arrange journal file to retain
Predetermined condition in disk;The triggered time that journal file processes thread is set;After the triggered time is reached, institute is triggered
State journal file and process thread;Obtain the status information for being stored in all journal files in the disk;Judge each daily record text
Whether the status information of part meets the predetermined condition;When the status information of journal file meets the predetermined condition, then should
Journal file is retained in the disk;When the status information of journal file does not meet the predetermined condition, by the daily record text
Part is stored to compressed package, and deletes the journal file in the disk;Terminate the journal file and process thread.
The method arranges the condition being retained in disk first, then obtains the state letter of all journal files in disk
Breath, then judge whether status information meets the condition of setting, qualified journal file is retained in disk, bar is not met
The journal file of part is stored in compressed package, and deletes the former journal file existed in disk, therefore, by this method saving
Memory space in disk, and when statistical analysis is carried out to journal file in the later stage, can find in compressed package corresponding
Journal file.
Description of the drawings
In order to be illustrated more clearly that the embodiment of the present invention, accompanying drawing to be used needed for embodiment will be done simply below
Introduce, it should be apparent that, drawings in the following description are only some embodiments of the present invention, for ordinary skill people
For member, on the premise of not paying creative work, can be with according to these other accompanying drawings of accompanying drawings acquisition.
Fig. 1 is a kind of flow chart of journal file processing method disclosed in the embodiment of the present invention;
Fig. 2 is the embodiment of the invention discloses the flow chart of another kind of journal file processing method;
Fig. 3 is the embodiment of the invention discloses the flow chart of another kind of journal file processing method;
Fig. 4 is a kind of structure chart of journal file processing meanss disclosed in the embodiment of the present invention.
Specific embodiment
Accompanying drawing in below in conjunction with the embodiment of the present invention, to the embodiment of the present invention in technical scheme carry out clear, complete
Site preparation is described, it is clear that described embodiment is only a part of embodiment of the invention, rather than whole embodiments.Based on this
Embodiment in invention, under the premise of creative work is not made, obtained is every other for those of ordinary skill in the art
Embodiment, belongs to the scope of the present invention.
The core of the present invention is to provide a kind of journal file processing method and processing device, transports for processing application program long-time
A large amount of journal files produced by row, the method is by arranging the condition in disk of being retained in, then obtains and be stored in institute in disk
There is the status information of journal file, then according to the condition for arranging, judge whether journal file is remained in disk, will not
The journal file for meeting setting condition is stored in compressed package, and the journal file in disk is deleted.
In order that those skilled in the art more fully understand the present invention program, with reference to the accompanying drawings and detailed description
The present invention is described in further detail.
Fig. 1 is a kind of flow chart of journal file processing method disclosed in the embodiment of the present invention, and wherein, the method is specifically walked
Suddenly include:
Step 101:Journal file is set and is retained in the predetermined condition in disk.
Step 102:The triggered time that journal file processes thread is set.
In the specific implementation, when operation maintenance personnel can be configured predetermined condition and be arranged triggering with different input modes
Between, the mode of such as input can be to be manually entered, the various ways such as phonetic entry.Predetermined condition and triggered time are being arranged
When, can be according to actual conditions, the parameter different with triggered time setting to predetermined condition.For example:Due to cause specific, application
Program is repeatedly accessed, and therefore can produce substantial amounts of journal file, in such a case, it is possible to predetermined condition is set to daily record
In predetermined number, the triggered time is 1 day to the sequence label of file.
It should be noted that step 101 and step 102 do not have priority execution sequence, the present embodiment is not limited, is first held
In execution step 101 or simultaneously, execution step 101 and step 102 do not affect the realization of the present invention to row step 102.
Step 103:After the triggered time is reached, triggering journal file processes thread.
In the specific implementation, after setting up the triggered time, the countdown for carrying out the triggered time, now, daily record are automatically begun to
File process thread in a dormant state, when countdown terminates, that is, is reached in non-triggering state, i.e. daily record file process thread
Triggered time, triggering journal file process thread, even if journal file process thread is in running order.
For example:Triggered time was set for 7 days, then proceeds by the countdown of 7 days, now, journal file is processed at thread
In non-triggering state, when countdown terminates, that is, reach 7 days, trigger journal file immediately and process thread.
Step 104:Obtain the status information for being stored in all journal files in disk.
In the specific implementation, the status information of corresponding journal file can be obtained, such as set according to the predetermined condition for arranging
The predetermined condition that puts for journal file generation number of days within the predetermined number of days, then just obtain the status information of journal file for generating
The temporal information of journal file.
Step 105:Judge whether the status information of each journal file conforms to a predetermined condition, when the state of journal file is believed
When breath conforms to a predetermined condition, step 106 is entered, when the status information of journal file does not meet predetermined condition, enter step
107.
In the specific implementation, according to the predetermined condition for arranging, judging unit is to each journal file for being stored in disk
Status information judged, and draw judged result.
Step 106:The journal file is retained in disk.
It is to be understood that not taking any measure to the journal file being stored in disk, will still conform to a predetermined condition
Journal file be retained in disk.
Step 107:The journal file is stored to compressed package, and the journal file is deleted in disk;
In the specific implementation, according to the result for judging, predetermined condition journal file will not met and will be stored in compressed package.
Step 108:Terminate the journal file and process thread.
In embodiments of the present invention, the condition being retained in disk is set first, all daily record texts in disk are then obtained
The status information of part, then judge whether status information meets the condition of setting, qualified journal file is retained in disk
In, ineligible journal file is stored in compressed package, and deletes the former journal file existed in disk, therefore, is passed through
The memory space in disk is this method saved, and when statistical analysis is carried out to journal file in the later stage, can be in compressed package
In find corresponding journal file.
Operation maintenance personnel finds corresponding journal file when statistical analysis is carried out, quickly in the future for convenience, the present invention
The flow chart that embodiment discloses another kind of journal file processing method, as shown in Fig. 2 Fig. 2 be the embodiment of the invention discloses
The flow chart of another kind of journal file processing method.The method is comprised the following steps:
Step 201:The generation number of days that predetermined condition is arranged for journal file is within the predetermined number of days;
Step 202:The triggered time that journal file processes thread is set;
In the specific implementation, for example:Generation number of days that predetermined condition is journal file can be set in predetermined 7 days, if
The triggered time for putting journal file process thread is 3 days.Certainly predetermined number of days and triggered time can also be the day of other numerical value
Number.
Step 203:After the triggered time is reached, triggering journal file processes thread.
In the specific implementation, after reaching the 3rd day, triggering journal file processes thread immediately.
Step 204:Obtain and be stored in all temporal informations for generating journal file in disk.
It should be noted that the predetermined condition arranged in this enforcement for journal file generation number of days within the predetermined number of days,
It is the temporal information for generating journal file then to need the log file status information for obtaining.
Step 205:Judge to generate the temporal information of each journal file whether within the predetermined number of days, in predetermined number of days
When interior, step 206 is entered, when not within the predetermined number of days, enter step 207.
In the specific implementation, as arranged generation number of days of the condition for journal file when making a reservation in 7 days, journal file is generated
Temporal information be 3 days, then the journal file enters step 206 within the predetermined number of days;Generate journal file temporal information be
9 days, then, in the journal file no longer predetermined number of days, enter step 207.
Step 206:Journal file is retained in disk.
Step 207:Judge to whether there is compressed package under fixed catalogue, if it does, step 208 is entered, if it does not,
Enter step 209.
Step 208:During journal file is stored to compressed package.
Step 209:Newly-built compressed package under fixed catalogue, during journal file is stored to newly-built compressed package, and in disk
Middle deletion journal file.
In the specific implementation, if fixed catalogue is the compressed package during D disks/storage history log file is pressed from both sides, then judge D disks/
Compressed package in storage history log file folder whether there is, if it is present the journal file not within the predetermined number of days is entered
Row compression, is stored in the compressed package in D disks/storage history log file folder, if it does not exist, then in D disks/storage history log
A newly-built compressed package in file, the journal file not within the predetermined number of days is compressed, the newly-built compressed package is stored in
In, and the journal file is deleted in disk.
It should be noted that step 207 to step 209 suitable for the present invention all embodiments, other embodiments are not
Repeat again.
Step 210:End log file process thread, return to step 203.
In the present embodiment, predetermined condition is set to the generation number of days of journal file within the predetermined number of days, will not be predetermined
Journal file in number of days is compressed in storing to compressed package, so, operation maintenance personnel when needing to check recent journal file,
In disk can extracting directly check, need not go to extract in compressed package, then can just check after decompressing, facilitate operation maintenance personnel
Carry out the work of the journal file of statistical.
In order to shorten the time of journal file process, the embodiment of the invention discloses another kind of journal file processing method
Flow chart, as shown in figure 3, Fig. 3 is the embodiment of the invention discloses the flow chart of another kind of journal file processing method.Method bag
Include following steps:
Step 301:The currently stored total amount that predetermined condition is arranged for disk is in predetermined amount of storage.
Step 302:The triggered time that journal file processes thread is set.
In the specific implementation, as arrange predetermined condition be currently stored total amount in 200M, of course, it is possible to according to actual feelings
Condition, is set in other numerical value amount of storage.
Step 303:After the triggered time is reached, trigger the journal file and process thread.
Step 304:Obtain the currently stored total amount of disk.
Step 305:The currently stored total amount of the disk is judged whether in predetermined amount of storage, if in amount of storage, entered
Enter step 306, if not in amount of storage, entering step 307.
In the specific implementation, as arrange predetermined condition be currently stored total amount in 200M amount of storage, obtain disk current
Storage total amount is 150M, then in disk, all journal files are eligible;It is 300M to obtain the currently stored total amount of disk, then magnetic
In disk, all journal files are ineligible.
Step 306:Whole journal files are retained in disk.
Step 307:Whole journal files are stored to compressed package, and the journal file is deleted in disk.
Step 308:End log file process thread.
In the present embodiment, judging unit only need to once judgement action, i.e., need to only judge currently stored total amount whether pre-
Determine in amount of storage, reduce the judgement action of judging unit repetition, therefore shorten the process time of journal file, improve place
Reason efficiency.
Referring to Fig. 4, Fig. 4 is a kind of structure chart of journal file processing meanss, the device bag disclosed in the embodiment of the present invention
Include:
Arranging unit 401, for arranging predetermined condition and the setting journal file process that journal file is retained in disk
The triggered time of thread;
Trigger element 402, for, after the triggered time is reached, triggering journal file processes thread;
Acquiring unit 403, for obtaining the status information for being stored in all journal files in disk;
Judging unit 404, for judging whether the status information of each journal file conforms to a predetermined condition;
Wherein, when the status information of journal file conforms to a predetermined condition, then the journal file is retained in disk;The same day
When the status information of will file does not meet the predetermined condition, memory cell is triggered;
Memory cell 405, for when the status information of journal file does not meet predetermined condition, by the journal file storage
To compressed package, and the journal file is deleted in disk.
In the specific implementation, predetermined condition and triggered time are arranged by arranging unit 401, after the setup, automatically
Start the countdown in triggered time, now, journal file processes thread in non-triggering state, when countdown terminates, that is, reaches
Triggered time, the triggering journal file of trigger element 402 process thread.
After journal file processes thread triggering, acquiring unit 403 starts the status information for obtaining journal file, acquiring unit
403 can obtain the status information of corresponding journal file according to the predetermined condition for arranging, and the predetermined condition for such as arranging is daily record
The generation number of days of file just then obtains the status information of journal file for generating the time letter of journal file within the predetermined number of days
Breath.
After acquiring unit 403 gets the status information of journal file, judging unit 404 is opened according to the predetermined condition for arranging
Begin to judge the status information of each journal file, when journal file conforms to a predetermined condition, be then retained in disk, when
When journal file does not conform to symbol predetermined condition, judging unit 404 triggers memory cell 405, and memory cell 405 is by the journal file pressure
Contracting is stored in compressed package, and the journal file is deleted in disk.
It can be seen that utilizing this device, the condition being retained in disk is set first, all daily records in disk are then obtained
The status information of file, then judge whether status information meets the condition of setting, qualified journal file is retained in magnetic
In disk, ineligible journal file is stored in compressed package, and deletes the former journal file existed in disk, therefore, is led to
The memory space this method saved in disk is crossed, and when statistical analysis is carried out to journal file in the later stage, can be in compression
Corresponding journal file is found in bag
As the embodiment of device part is mutually corresponding with the embodiment of method part, therefore the embodiment of device part please
Referring to the description of the embodiment of method part, wouldn't repeat here.
Above a kind of journal file processing method and processing device provided by the present invention is described in detail.In specification
Each embodiment is described by the way of going forward one by one, and what each embodiment was stressed is the difference with other embodiment,
Between each embodiment identical similar portion mutually referring to.For device disclosed in embodiment, due to itself and enforcement
Method disclosed in example is corresponding, so description is fairly simple, related part is referring to method part illustration.It should be pointed out that
For those skilled in the art, under the premise without departing from the principles of the invention, the present invention can also be entered
The some improvement of row and modification, these improvement and modification are also fallen in the protection domain of the claims in the present invention.
Professional further appreciates that, in conjunction with the unit of each example of the embodiments described herein description
And algorithm steps, can with electronic hardware, computer software or the two be implemented in combination in, in order to clearly demonstrate hardware and
The interchangeability of software, generally describes composition and the step of each example in the above description according to function.These
Function is executed with hardware or software mode actually, the application-specific and design constraint depending on technical scheme.Specialty
Technical staff can use different methods to realize described function to each specific application, but this realization should
Think beyond the scope of this invention.
The step of method described in conjunction with the embodiments described herein or algorithm, directly can be held with hardware, processor
Capable software module, or the combination of the two is implementing.Software module can be placed in random access memory (RAM), internal memory, read-only deposit
Reservoir (ROM), electrically programmable ROM, electrically erasable ROM, register, hard disk, moveable magnetic disc, CD-ROM or technology
In any other form of storage medium well known in field.
Claims (8)
1. a kind of journal file processing method, it is characterised in that include:
Journal file is set and is retained in the predetermined condition in disk;
The triggered time that journal file processes thread is set;
After the triggered time is reached, trigger the journal file and process thread;
Obtain the status information for being stored in all journal files in the disk;
Judge whether the status information of each journal file meets the predetermined condition;
When the status information of journal file meets the predetermined condition, then the journal file is retained in the disk;
When the status information of journal file does not meet the predetermined condition, the journal file is stored to compressed package, and in institute
State;
Terminate the journal file and process thread.
2. method according to claim 1, it is characterised in that the predetermined condition for journal file generation number of days pre-
Determine in number of days, then the status information be generate journal file temporal information, each journal file of judgement state letter
Whether breath meets the predetermined condition is specially:
Judge to generate the temporal information of each journal file whether within the predetermined number of days;
Wherein, when the temporal information of journal file is generated within predetermined number of days, then the status information of the journal file meets institute
State predetermined condition;
When generate the temporal information of journal file not within predetermined number of days when, then the status information of the journal file does not meet described
Predetermined condition.
3. method according to claim 1, it is characterised in that the predetermined condition is the currently stored total amount of the disk
In predetermined amount of storage, then the status information be the currently stored total amount of the disk, the shape of each journal file of judgement
Whether state information meets the predetermined condition is specially:
Judge the currently stored total amount of the disk whether in the predetermined amount of storage;
Wherein, when the currently stored total amount of the disk is in the predetermined amount of storage, then in the disk, all journal files are equal
Meet the predetermined condition;
When the currently stored total amount of the disk exceeds in the predetermined amount of storage, then in the disk, all journal files are not inconsistent
Close the predetermined condition.
4. method according to claim 1, it is characterised in that the predetermined condition for journal file sequence label pre-
In fixed number mesh, then the status information is journal file sequence label, and whether the status information for judging each journal file
Meet the predetermined condition to be specially:
Judge each journal file sequence label whether in the predetermined number;
When daily record file ordering label is in predetermined number, then the status information of the journal file meets the predetermined condition;
When daily record file ordering label not in predetermined number when, then the status information of the journal file does not meet the predetermined bar
Part.
5. the method according to any one of claim 1-4, it is characterised in that described store the journal file to compression
Bag, specifically includes:
Judge to whether there is the compressed package under fixed catalogue;
If there is the compressed package, then during store the journal file to the compressed package;
If there is no the compressed package, then newly-built compressed package under the fixed catalogue, and by the journal file store to
In the newly-built compressed package.
6. method according to claim 1, it is characterised in that after the end journal file processes thread, also wrap
Include:Dormancy is entered, waits the next triggered time to reach.
7. method according to claim 1, it is characterised in that the triggered time is 7 days.
8. a kind of journal file processing meanss, it is characterised in that include:
Arranging unit, processes touching for thread for arranging the predetermined condition that journal file is retained in disk with journal file is arranged
The time of sending out;
Trigger element, processes thread for after the triggered time is reached, triggering the journal file;
Acquiring unit, for obtaining the status information for being stored in all journal files in the disk;
Judging unit, for judging whether the status information of each journal file meets the predetermined condition;Wherein, when daily record text
When the status information of part meets the predetermined condition, then the journal file is retained in the disk;State when journal file
When information does not meet the predetermined condition, memory cell is triggered;
Memory cell, for when the status information of journal file does not meet the predetermined condition, by the journal file store to
Compressed package, and the journal file is deleted in the disk.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610915695.5A CN106503138A (en) | 2016-10-20 | 2016-10-20 | A kind of journal file processing method and processing device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610915695.5A CN106503138A (en) | 2016-10-20 | 2016-10-20 | A kind of journal file processing method and processing device |
Publications (1)
Publication Number | Publication Date |
---|---|
CN106503138A true CN106503138A (en) | 2017-03-15 |
Family
ID=58318190
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201610915695.5A Pending CN106503138A (en) | 2016-10-20 | 2016-10-20 | A kind of journal file processing method and processing device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106503138A (en) |
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107145434A (en) * | 2017-05-09 | 2017-09-08 | 郑州云海信息技术有限公司 | A kind of operating system information recording method and device |
CN108197148A (en) * | 2017-11-30 | 2018-06-22 | 中国电子科技集团公司电子科学研究院 | A kind of file clean-up method, equipment and computer readable storage medium |
WO2019161551A1 (en) * | 2018-02-24 | 2019-08-29 | 黄裕才 | Method for processing log based on logrotate technology |
CN111045885A (en) * | 2019-11-11 | 2020-04-21 | 网联清算有限公司 | Database log file processing method and device and computer equipment |
CN113656358A (en) * | 2020-05-12 | 2021-11-16 | 网联清算有限公司 | Database log file processing method and system |
CN115174368A (en) * | 2022-06-30 | 2022-10-11 | 南斗六星系统集成有限公司 | Method and system for generating and acquiring logs of terminal equipment in Internet of vehicles |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103593351A (en) * | 2012-08-15 | 2014-02-19 | 中国银联股份有限公司 | Electronic file filing method and system |
CN104102737A (en) * | 2014-07-28 | 2014-10-15 | 中国农业银行股份有限公司 | Historical data storage method and system |
CN105117411A (en) * | 2015-07-29 | 2015-12-02 | 上海斐讯数据通信技术有限公司 | Server log file management system and method |
-
2016
- 2016-10-20 CN CN201610915695.5A patent/CN106503138A/en active Pending
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103593351A (en) * | 2012-08-15 | 2014-02-19 | 中国银联股份有限公司 | Electronic file filing method and system |
CN104102737A (en) * | 2014-07-28 | 2014-10-15 | 中国农业银行股份有限公司 | Historical data storage method and system |
CN105117411A (en) * | 2015-07-29 | 2015-12-02 | 上海斐讯数据通信技术有限公司 | Server log file management system and method |
Non-Patent Citations (1)
Title |
---|
杜春燕: "操作系统日志自动备份机制的实现", 《电脑与电信》 * |
Cited By (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107145434A (en) * | 2017-05-09 | 2017-09-08 | 郑州云海信息技术有限公司 | A kind of operating system information recording method and device |
CN108197148A (en) * | 2017-11-30 | 2018-06-22 | 中国电子科技集团公司电子科学研究院 | A kind of file clean-up method, equipment and computer readable storage medium |
WO2019161551A1 (en) * | 2018-02-24 | 2019-08-29 | 黄裕才 | Method for processing log based on logrotate technology |
CN111045885A (en) * | 2019-11-11 | 2020-04-21 | 网联清算有限公司 | Database log file processing method and device and computer equipment |
CN113656358A (en) * | 2020-05-12 | 2021-11-16 | 网联清算有限公司 | Database log file processing method and system |
CN115174368A (en) * | 2022-06-30 | 2022-10-11 | 南斗六星系统集成有限公司 | Method and system for generating and acquiring logs of terminal equipment in Internet of vehicles |
CN115174368B (en) * | 2022-06-30 | 2024-04-02 | 南斗六星系统集成有限公司 | Method and system for generating and acquiring logs of terminal equipment of Internet of vehicles |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106503138A (en) | A kind of journal file processing method and processing device | |
EP2503733B1 (en) | Data collecting method, data collecting apparatus and network management device | |
US9009850B2 (en) | Database management by analyzing usage of database fields | |
CN111625535B (en) | Method, device and storage medium for realizing business data association | |
CN104636240B (en) | A kind of acquisition methods and terminal of information report | |
CN106599295A (en) | Multi-track visual analyzing evidence-collecting method for user behaviors and system | |
CN103353860B (en) | EMS memory management process and device | |
CN105528264B (en) | Fool proof data reconstruction method and its system | |
CN111597158B (en) | Rolling method and device for log files, storage medium and terminal | |
WO2019227624A1 (en) | Monitoring method for call center, electronic apparatus, computer device and storage medium | |
CN106209495A (en) | The report form generation method of a kind of cloud monitoring system and device | |
CN107402871A (en) | Terminal capabilities monitoring method and device, monitoring document handling method and device | |
CN111782486A (en) | Alarm implementation method and system based on dynamic configuration | |
CN109684332A (en) | A kind of wide table generating method of data, apparatus and system | |
CN104239178A (en) | Monitoring system and monitoring method | |
WO2019140738A1 (en) | Method for avoiding excess return visits, and electronic apparatus and computer-readable storage medium | |
CN107644382A (en) | Policy information statistical method and device | |
CN109241031A (en) | Model generating method, model application method, device, system and storage medium | |
CN107526627A (en) | A kind of virtual resource life cycle information management method and device | |
CN107943912B (en) | A kind of response type Resource TOC data visualization management method, terminal and device | |
DE102010053333A1 (en) | Highly compressed program trace | |
CN111324485A (en) | Data information backup method, device, equipment and storage medium of data table | |
CN116541403A (en) | Method, system, electronic device and storage medium for capturing database data change in real time | |
CN109271431A (en) | Data pick-up method, apparatus, computer equipment and storage medium | |
CN115576973A (en) | Service deployment method, device, computer equipment and readable storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20170315 |