CN109840178A - A kind of method, mobile terminal and the device of monitoring journal information - Google Patents

A kind of method, mobile terminal and the device of monitoring journal information Download PDF

Info

Publication number
CN109840178A
CN109840178A CN201711223041.7A CN201711223041A CN109840178A CN 109840178 A CN109840178 A CN 109840178A CN 201711223041 A CN201711223041 A CN 201711223041A CN 109840178 A CN109840178 A CN 109840178A
Authority
CN
China
Prior art keywords
information
output
log information
log
preset
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.)
Granted
Application number
CN201711223041.7A
Other languages
Chinese (zh)
Other versions
CN109840178B (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.)
Hefei Jie Fa Technology Co Ltd
Original Assignee
Hefei Jie Fa Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hefei Jie Fa Technology Co Ltd filed Critical Hefei Jie Fa Technology Co Ltd
Priority to CN201711223041.7A priority Critical patent/CN109840178B/en
Publication of CN109840178A publication Critical patent/CN109840178A/en
Application granted granted Critical
Publication of CN109840178B publication Critical patent/CN109840178B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • 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

Abstract

The invention discloses method, mobile terminal and the devices of a kind of monitoring journal information, this method comprises: the log information of the system of reading output;Judge whether the output speed of the log information is greater than preset threshold;If the output speed is greater than the preset threshold, the first notification information is issued.Through the above way, the present invention can set up log formation speed monitoring mechanism, to putting up a notice when log information formation speed in systems is greater than preset threshold, so that reducing log information expands the probability that the case where causing CPU usage high and information redundancy occurs.

Description

A kind of method, mobile terminal and the device of monitoring journal information
Technical field
The present invention relates to monitoring server technical fields, whole more particularly to a kind of method of monitoring journal information, movement End and device.
Background technique
It is convenient in order to debug tracking, when embedded system (such as linux system) exploitation or maintenance would generally in kernel, be System, program etc. add print statement (such as printk, syslog, printf, echo etc.) so as to output information, and user can pass through Serial ports or network connection tool (such as SSH, serial port tool) are connect with target platform, then are connect by these fastening means The log information (as saved file or in real time viewing) of output is received, so that observation system runs and capture debugging, and kernel day Will information, system log message, program log information are independent of each other, not together by output sequence integration.
For embedded device, since the output of log information is carried out by CPU, the output speed of log information Strong correlation between (frequency line number, capacity byte number in such as unit time) and its CPU usage.If log information is frequently sent out It send, CPU does not stop to be exported to interrupt by log information to seize, then the scheduling time for distributing to other programs is reduced.If there is day Will information expansion (output for being higher than normal speed), CPU usage will significantly improve, and a large amount of log informations exported can be made At information redundancy.
Summary of the invention
The present invention provides method, mobile terminal and the device of a kind of monitoring journal information, is able to solve in the prior art The problem of log information expansion causes CPU usage high and information redundancy.
In order to solve the above technical problems, one technical scheme adopted by the invention is that: a kind of monitoring journal information is provided Method, comprising:
The log information of reading system output;
Judge whether the output speed of the log information is greater than preset threshold;
If the output speed is greater than the preset threshold, the first notification information is issued.
In order to solve the above technical problems, another technical solution used in the present invention is: a kind of mobile terminal is provided, it is described Mobile terminal includes: processor, telecommunication circuit, display and memory, and the processor is respectively coupled to the telecommunication circuit, institute Display and the memory are stated, the processor, the telecommunication circuit, the display and the memory at work can Enough realize the step in method described above.
In order to solve the above technical problems, another technical solution that the present invention uses is: providing a kind of with store function Device, be stored thereon with program data, described program data realize the step in method described above when being executed by processor.
The beneficial effects of the present invention are: be in contrast to the prior art, the present invention provides a kind of monitoring journal information Method, comprising: read the log information of system output;Judge whether the output speed of the log information is greater than preset threshold; If the output speed is greater than the preset threshold, the first notification information is issued.The present invention can set up log and generate speed Monitoring mechanism is spent, to putting up a notice when log information formation speed in systems is greater than preset threshold, to reduce log information The probability that the case where expansion causes CPU usage high and information redundancy occurs.
Detailed description of the invention
To describe the technical solutions in the embodiments of the present invention more clearly, make required in being described below to embodiment Attached drawing is briefly described, it should be apparent that, drawings in the following description are only some embodiments of the invention, for For those of ordinary skill in the art, without creative efforts, it can also be obtained according to these attached drawings other Attached drawing.Wherein:
Fig. 1 is the flow diagram of the method first embodiment of monitoring journal information of the present invention;
Fig. 2 is the flow diagram of the method second embodiment of monitoring journal information of the present invention;
Fig. 3 is the flow diagram of step S201 in the method second embodiment of monitoring journal information of the present invention;
Fig. 4 is the flow diagram of the method third embodiment of monitoring journal information of the present invention;
Fig. 5 is the flow diagram of step S301 in the method third embodiment of monitoring journal information of the present invention;
Fig. 6 is the flow diagram of the 4th embodiment of method of monitoring journal information of the present invention;
Fig. 7 is the flow diagram of the 5th embodiment of method of monitoring journal information of the present invention;
Fig. 8 is the flow diagram of step S502 in the 5th embodiment of method of monitoring journal information of the present invention;
Fig. 9 is the flow diagram of the method sixth embodiment of monitoring journal information of the present invention;
Figure 10 is the flow diagram of the 7th embodiment of method of monitoring journal information of the present invention;
Figure 11 is the flow diagram of the 8th embodiment of method of monitoring journal information of the present invention;
Figure 12 is the structural schematic diagram of one embodiment of mobile terminal of the present invention;
Figure 13 is the structural schematic diagram of one embodiment of apparatus of the present invention.
Specific embodiment
Following will be combined with the drawings in the embodiments of the present invention, and technical solution in the embodiment of the present invention carries out clear, complete Site preparation description, it is clear that described embodiments are only a part of the embodiments of the present invention, rather than whole embodiments.Based on this Embodiment in invention, those of ordinary skill in the art are obtained every other under the premise of not making creative labor Embodiment shall fall within the protection scope of the present invention.
Referring to Fig. 1, Fig. 1 is the process signal of the method first embodiment of monitoring journal information provided by the invention Figure, this method comprises:
Step S101: the log information of system output is read.
When receiving reading instruction, the log information of system output is just read, specifically, after system starts, is monitored All kinds of log informations export corresponding socket, whether device node file has output to change, successively in chronological order from Log information is read in the buffer culture of socket and device node file.Log information includes kernel log information, system day At least one of will information, program log information information log information.Wherein, program log information includes that program standard is defeated Out, the log information of standard error information.In present embodiment, log information incorporates kernel log information, system log letter Breath and program log information.Certainly, in other embodiments, log information, which can be, incorporates kernel log information and system The log information of log information.
Wherein, kernel log information is the dev/kmsg letter that kernel (kenerl) is output to kernel log device node file Breath, system log message is the information that application program is output to dev/log socket, and program log information is that program is output to mark Information in quasi- output file stdout/stderr further includes certainly the log for calling other log system function interfaces to provide The information of api function output.
Wherein, the mode of the log information of reading system output may include two kinds, and one is the outputs of active inquiry system The quantity of at least one of kernel log information, system log message and program log information log information whether have change Change, obtains the output quantity and correspondent time of log information;And another way is to establish the socket of monitoring, it will be interior Core log information, program log information, system log message and the corresponding socket of other log information API, device node Filec descriptor is added in the respective file descriptor set of monitoring socket, monitors above-mentioned filec descriptor using socket PULLIN/PULLOUT update event when monitoring has log information more kainogenesis, then obtains the buffering for reading respective file description Area, and obtain log information the number of output and correspondent time.In present embodiment, log information can be the log in memory Information.
Step S102, judges whether the output speed of log information is greater than preset threshold.
It is appreciated that add up the number of output and the output time of log information during reading log information, according to The ratio of the number of output and output time obtain the output speed of log information, thus by the output speed obtained and preset threshold It is compared.Certainly, the number of output of log information can be the line number of log information or the byte number of log information.This implementation In mode, the number of output of log information refers to the line number of log information.
In addition, further including the value for reading preset threshold in configuration file before the step of reading log information.
Step S103 issues the first notification information if output speed is greater than preset threshold.
It is appreciated that the larger workload when system just starts, the number of output of log information is also more, therefore, at this In embodiment, the value of preset threshold is default more than or equal to after system starting first within the first preset duration after system starting The value of preset threshold after duration.Certainly, in other embodiments, the value of preset threshold can be constant.
It is appreciated that the time of the first preset duration and preset threshold can be adjusted according to demand.For example, first is pre- If when a length of 1s, the value of the preset threshold after system starting within the first preset duration is 600 rows/s, after the first preset duration Preset threshold be 300 rows/s.
Information in first notification information can be adjusted according to demand, for example, " log much ", " too much Log ", log quantity are excessive etc..
In an application scenarios, in the process of development, debugged after newly-increased module, in this way, this can be passed through Method statistic increases the variation of log information the number of output after module, to judge whether the number of output of log information in system closes Reason.
In another application scene, the test before deployment or software publication is carried out to system, can be obtained by such method Log information the number of output when the system or software being taken to run, and judge whether rationally, if the log letter of additions and deletions output Breath.
It is different from the prior art, in the method for the monitoring journal information that embodiment of the present invention provides, day can be set up Will formation speed monitoring mechanism, to putting up a notice when log information formation speed in systems is greater than preset threshold, to reduce The probability that the case where log information expansion causes CPU usage high and information redundancy occurs.
Referring to Fig. 2, in the method second embodiment of monitoring journal information of the present invention, on the basis of first embodiment On, judge log information output speed whether greater than preset threshold include:
Step S201, judges whether the number of output of log information in preset period of time is greater than preset quantity threshold value.
Specifically, please referring to Fig. 3, include the following steps:
Step S2011 records the first output time of the first trip log information in preset period of time;
Step S2012, obtains the second output time of non-first trip log information in identical preset period of time, and obtains the Time interval between two output times and the first output time;
Step S2013, judges whether the duration of time interval reaches the duration of preset period of time, if time interval when The long duration for reaching preset period of time, then judge whether the number of output in preset period of time is greater than preset quantity threshold value;
The second output time of current non-first trip log information is updated to next preset period of time by step S2014 The first output time of first trip log information, and enter step S2011.
Certainly, if the duration of time interval is not up to the duration of preset period of time, continue to obtain preset period of time The second output time of interior non-first trip log information, until the duration of time interval reaches the duration of preset period of time.
Wherein, the duration of preset period of time can be modified accordingly according to demand, such as 1s, 1ms or 1min etc..
Step S202 determines day if the number of output of log information is greater than preset quantity threshold value in preset period of time The output speed of will information is greater than preset threshold.
For example, preset quantity threshold value is 400 rows in the when a length of 1s of preset period of time, 1s, i.e. preset threshold is 400 rows/s.Under certain conditions, when the duration of the output of log information reaches 1s, the number of output of log information reaches 600 Row, the i.e. the number of output of log information are greater than preset quantity threshold value, at this point, the output speed of log information is 600 rows/s, then sentence The output speed for determining log information is greater than preset threshold.
In present embodiment, the value of preset quantity threshold value is greater than within the duration of the first preset period of time after system starting System starting after the first preset period of time duration after preset quantity threshold value value.For example, the first preset period of time Shi Changwei 1s, the value of preset quantity threshold value is 600 rows within the duration of the first preset period of time, and the first preset period of time Duration after preset quantity threshold value value be 300 rows.Certainly, in other embodiments, every one first after system starting Preset quantity threshold value within the duration of preset period of time is all equal.
It is different from the prior art, it is default by judging in the method for the monitoring journal information that embodiment of the present invention provides The number of output of log information in time cycle is judged, and then the output speed of log information and preset threshold are carried out Compare, and in the case where output speed is greater than preset threshold, the first notification information is issued, to remind user, to reduce day The probability that the case where will information expansion causes CPU usage high and information redundancy occurs.
Referring to Fig. 4, in the method third embodiment of monitoring journal information of the present invention, on the basis of first embodiment On, wherein judge log information output speed whether greater than preset threshold include:
Step S301, when judging that the number of output of log information reaches the output time used in preset value and whether is less than default It is long.
Specifically, please referring to Fig. 5, include the following steps:
Step S3011 records the output time of every row log information output;
Step S3012, adds up the quantity of log information, and judges whether the number of output of log information is greater than preset quantity Threshold value;
Step S3013 judges the output number of log information if the number of output of log information is greater than preset quantity threshold value Whether the amount output time used when reaching preset value is less than preset duration.
Wherein, the number of output of log information reaches used in preset value what the output time referred to exporting in preset duration The time interval of the output time of first trip log information and footline log information.
Step S302 determines that the output speed of log information is greater than preset threshold if the output time is less than preset duration.
For example, preset quantity threshold value is 400 rows in preset duration 1s, 1s, i.e., preset threshold is 400 rows/s.When When the number of output for counting on log information is 401 row, that is, when being greater than preset quantity, then judge the log letter for exporting 401 row Whether the time spent in breath is greater than 1s, if being less than 1s, determines that the output speed of log information is greater than preset threshold, meanwhile, it will The number of output of statistical log information is updated to 0, and the initial time of statistics is also updated to the current log output time, in order into The calculating of the number of output of log information in the next preset duration of row.Certainly, the initial time of statistics can also remain adjacent Last time time value calculates initial time and this counts end when the number of output of log information reaches preset quantity threshold value The output time interval of row log information, the time spent in obtaining epicycle statistical log information, and be compared with preset duration.
In present embodiment, preset duration corresponding to the quantity of the preset quantity threshold value exported after system starting is less than defeated The preset duration of the log information of equivalent after preset quantity threshold value out.For example, preset duration is 1s, it is first after system starting The preset quantity threshold value of the log information exported in a preset duration is 600 rows, the log exported in the preset duration after 1s The preset quantity threshold value of information is 400 rows.
It is different from the prior art, in the method for the monitoring journal information that embodiment of the present invention provides, by believing in log The number of output of breath reaches in the case of preset value obtains, and is judged in conjunction with the time it takes for exporting these log informations, To obtain the output speed of log information, and in the case where output speed is greater than preset threshold, the first notification information is issued, with User's adjustment is reminded, so that reducing log information expands the probability that the case where causing CPU usage high and information redundancy occurs.
Referring to Fig. 6, in the 4th embodiment of method of monitoring journal information of the present invention, on the basis of first embodiment On, further comprise:
Step S401 judges whether contain designated key word in the log information of output.
Wherein, designated key word can be exception error keyword or user needed for keyword, judgement output Whether containing that before designated key word, can also include reading configuration file in log information, to obtain the letter of designated key word Breath.
Step S402 issues the second notification information if containing designated key word.
Wherein, designated key word can be the keyword character string Feature Words comprising error message, in the second notification information Information may include designated key word log information of the row.Further, the information in the second notification information can wrap Include at least a line log information before and after designated key word log information of the row and the log information, in order to user according to The context of designated key word log information of the row carries out more accurate analysis to exception error etc..
Wherein, designated key word can be configured in configuration file.
In the prior art in general, crash blue screen occurs in Windows when can not operate, it is only limited to just have phase crashing The error message answered is output to display, and in present embodiment, when monitoring designated key word, shown normally even if system Energy normal response user's operation, and issue the second notification information.
Currently, be to send log information on remote analysis server to analyze when exception error occurs in system, Real-time is insufficient, has certain hysteresis quality, and need to configure remote server, at high cost, and maintenance is complicated, and prolonged Operation, the quantity of log information is more, and preservation file is larger, and log information is costly and inefficient during analyzing, and this Embodiment includes that designated key word will send the second notification information in monitoring log information, easy and high-efficient.
It is different from the prior art, in the method for the monitoring journal information that embodiment of the present invention provides, by reading system The log information of output, and by the way that the output speed of log information to be compared with preset threshold, and be greater than in output speed In the case where preset threshold, the first notification information is issued, to remind user, causes CPU to occupy to reduce log information expansion The probability that the case where rate height and information redundancy occurs;Further, abnormal for the exception error in system, especially low probability It, can be quickly from nearest after mistake (for example, the exception errors such as operation test ten thousand times or more system freeze just occurred) occurs Pick out the keyword character string Feature Words exported extremely in time log information, subsequent manual analysis correlation log information is into one Step extracts keyword character string Feature Words, and the keyword character string Feature Words extracted from correlation log information are written to Configuration file reruns test, and Analysis Service process is allowed to do string matching comparison, while can also allow service routine Related context information (as saved front and back multirow relevant information) is cached so as to subsequent debugging, compared to artificial tracking, Neng Gouyou Simplified analysis process is imitated, is easy to replicate simultaneously Trapped problems, to improve efficiency.
Referring to Fig. 7, in the 5th embodiment of method of monitoring journal information of the present invention, in first embodiment or On the basis of five embodiments, further comprise:
Step S501 receives the first notification information or/and the second notification information;
The information of first notification information or/and the second notification information is transmitted to user by man-machine interface by step S502.
Wherein, the mode of communication of man-machine interface can be but be not limited to display interface, audio alarm, the end in log information Ending tool and serial communication are conveyed in real time or are conveyed on webpage, in present embodiment, are conveyed by the display interface of display, Redundant logs information content, designated key word information, time of origin of exception error etc. can be shown in display interface.
Specifically, please referring to Fig. 8, include the following steps: in such a way that display interface is conveyed
Step S5021 obtains the display video memory of system when receiving the first notification information or/and the second notification information;
Information in first notification information or/and the second notification information is written to corresponding and shows video memory by step S5022 In, and export in the top of display interface.
It is appreciated that the information of the first notification information or/and the second notification information is to check convenient for user, with coverage mode It is shown in the top of graphic display interface, for the operating status for checking its lower level processes display interface convenient for user, information institute Boundary layer can be it is translucent.Certainly, in other embodiments, the boundary layer where information can also configure user Like or facilitate the color of identification, such as yellow, blue, flashing display can also be done to specified region or key area.In addition, Font in information may be set to be it is translucent and configured with facilitate identification color or it is nontransparent or/and configured with side Just the color identified.
It is different from the prior art, by reading the log information of system output, and by by the output speed of log information It is compared with preset threshold, and in the case where output speed is greater than preset threshold, issues the first notification information, monitoring In the case where designated key word, the second notification information is issued, and receiving the first notification information or/and the second notification information When, relevant notification information is checked for user by intuitive mode of communication and can check in time the warning information of needs (such as Log much, designated key word and related advantages are in information of program debugging etc.), so that user is in time to the quantity of log information And exception error is handled, to reduce the case where log information expansion causes CPU usage high and information redundancy appearance And the reliable and stability of lifting system.
Referring to Fig. 9, in the method sixth embodiment of monitoring journal information of the present invention, in the base of first embodiment On plinth, further comprise:
Step S601 obtains process contained in the log information of output in the corresponding library function of system log message Id information;
Wherein, id information also refers to pid information.
Step S602 passes through the corresponding program name of process ID acquisition of information;
Step S603 counts the number of output of the log information of corresponding program according to program name, and by the day of multiple programs The number of output of will information carries out ranking.
It is appreciated that process id information and program name correspond, corresponding journey can be obtained according to process id information Sequence name, and then obtain the number of output of the log information of corresponding program.Wherein, in order to quickly access, multiple program log letters The statistical result for ceasing the number of output can be saved in memory using orderly Hash table, periodically notify user (as schemed Shape interface manner is shown or is exported in the text of designated position), it certainly, in other embodiments, can be by others side Formula ranking.
In the method for the monitoring journal information that embodiment of the present invention provides, reached by the number of output in log information In the case of preset value obtains, judged in conjunction with the time it takes for exporting these log informations, to obtain log information Output speed, and in the case where output speed is greater than preset threshold, the first notification information is issued, to remind user, to subtract The probability that the case where few log information expansion causes CPU usage high and information redundancy occurs.In addition, process id information and program Name corresponds, and can obtain corresponding program name according to process id information, and then can intuitively export operation program name And the number of output ranking of correlation log information, it is convenient for subsequent additions and deletions or other developments.
Referring to Fig. 10, in the 7th embodiment of method of monitoring journal information of the present invention, in first embodiment or On the basis of sixth embodiment, further comprise:
Step S701, when monitoring that configuration file updates, system or the restarting of log monitoring program;
Step S702, read configuration file, and obtain needed in configuration file shielding log information output program name or/and Service processes name;
Step S703 will need to shield the program name or/and the corresponding program of service processes name or/and clothes that log information exports The log information of business process shields.
It is appreciated that receive the first notification information or view multiple programs log information the number of output ranking After table, it is corresponding that the stability that user can run according to the program output journal quantity ranking or program of statistics decides whether to shielding The sunrise of program exports, and program name is added in configuration file, the day of at least one program or service processes that will select Will information screen falls, so that the log information of selected at least one program or service processes no longer exports, for example, configuring " filter=prog1progn ... " is added in file, wherein progn is the title of selected program or service processes.Certainly, Can also the log information of recovery routine or service processes according to demand output.
It is appreciated that system is after restarting, read the information in configuration file, using hash algorithm by program name or Service processes name is converted into Hash coding, utilizes<Hash coding><log closing output>key-value pair to establish closing journal information defeated Hash table out.
Syslog library function obtains the program name of operation program or the service processes of service processes from current calling process Name, by program name or service processes name be converted into Hash coding in the way of, and in above-mentioned Hash table inquire above procedure name Or service processes name does not export the corresponding log of corresponding program or service processes if finding corresponding informance in Hash table Information.
It is different from the prior art, what embodiment of the present invention provided reaches preset value by the number of output in log information In the case of obtaining, judged in conjunction with the time it takes for exporting these log informations, to obtain the output speed of log information Degree, and in the case where output speed is greater than preset threshold, the first notification information is issued, to remind user, to reduce log The probability that the case where information expansion causes CPU usage high and information redundancy occurs.In addition, obtaining the first notification information or knowing Know service processes log information output ranking after, can according to demand the log information of option program or service processes it is no longer defeated Out, to reduce the number of output of log information;It equally can also the log information of recovery routine or service processes according to demand Output.It is different from traditional concordance list storage mode, access speed can be greatly promoted using Hash storage or access mode, subtracted System load spent by few log monitoring program.
Figure 11 is please referred to, in the 7th embodiment of method of monitoring journal information of the present invention, with a specific embodiment For be illustrated, comprising:
Step S801, activation system.
Wherein, after system starting, the instruction for reading log information will be received.
Step S802, the configuration file in reading system obtain the first amount threshold, the second amount threshold, designated key Word, displaying information on screen, and read the initialization information of log information monitoring.
Wherein, whether the displaying information on screen of acquisition is the information of the first notification information or/and the second notification information is real When display over the display, if without real-time display in the display, can pass through output alarm (such as feature string, it is special Determine sound etc.), in the tool terminal and serial communication of log information convey or be communicated on the webpage of network receiving terminal in real time User;Initialization information refers to system in the process of running, and the number of output and output time to the log information carry out just Beginningization.
Further comprise reading device node information in Android system, in Android system, creates device node, it should Device node is existed in a manner of file, and buffer culture can be obtained by reading device node, and then obtain log information.
Configuration file can be conf file or xml configuration file, by taking following configuration files as an example,
[filter]
Linecnt=100;
Bootlogcnt=400;
TimePrefer=yes;
Dalenable=no;
Eestype=error;
Eestring=dbus-faliure.
Wherein, bootlogcnt=400 indicates that the first amount threshold is 400 rows;Linecnt=100 indicates the second quantity The value of threshold value is 100 rows;TimePrefer=yes indicates time priority, i.e., when preferentially judging whether time interval reaches default It is long, judge in the case where time interval reaches preset duration, then to the number of output of log information;Dalenable= No expression does not appear on display;The designated key part of speech type that Eetype=error is monitored needed for indicating is exception error Relevant keyword;Eestring=dbus-faliure indicates that designated key word is " dbus-faliure ".
Step S803 reads the log information of output.
Step S804, the first output time of record first trip log information output.
Step S805, when adding up the number of output of log information and obtaining the second output of non-first trip log information output Between.
Step S806, when whether the time interval between the first output time of calculating and the second output time reaches default It is long, if time interval reaches preset duration, S807 is entered step, if time interval is not up to preset duration, returns to step S805。
Step S807, judges whether the number of output of log information reaches the first amount threshold, if the output of log information Quantity reaches the first amount threshold, then issues the first notification information.
The number of output of log information is updated to 0 by step S808, and current log information is exported the second output when Between be updated to the first output time of first trip log information output in next preset duration, while entering step S805 and step Rapid S809.
Step S809 judges whether contain designated key word in the log information of output.
Step S810 issues the second notification information if containing designated key word in the log information of output.
Step S811 receives the first notification information or/and the second notification information, and shows the first notification information or/and the Information in two notification informations.
Figure 12 is please referred to, Figure 11 is the structural schematic diagram of one embodiment of mobile terminal of the present invention.The mobile terminal includes: Processor 201, memory 202, telecommunication circuit 203 and display 204, wherein processor 201 be respectively coupled to memory 202, Telecommunication circuit 203 and display 204, processor 201, memory 202, telecommunication circuit 203 and display 204 are at work It can be realized the step in contact person's processing method in any of the above-described embodiment.
Figure 13 is please referred to, Figure 12 is the structural schematic diagram for one embodiment of device that the present invention has store function, the dress It sets 30 and is stored with program data 301, which can be mobile terminal, server etc., and program data 301 can be by processor The step in contact person's processing method in any of the above-described embodiment is realized when execution.
Mode the above is only the implementation of the present invention is not intended to limit the scope of the invention, all to utilize this Equivalent structure or equivalent flow shift made by description of the invention and accompanying drawing content, it is relevant to be applied directly or indirectly in other Technical field is included within the scope of the present invention.

Claims (10)

1. a kind of method of monitoring journal information characterized by comprising
The log information of reading system output;
Judge whether the output speed of the log information is greater than preset threshold;
If the output speed is greater than the preset threshold, the first notification information is issued.
2. the method according to claim 1, wherein
The output speed for judging the log information whether greater than preset threshold include:
Judge whether the number of output of the log information in preset period of time is greater than preset quantity threshold value;
If in the preset period of time the number of output of the log information be greater than the preset quantity threshold value, determine described in The output speed of log information is greater than the preset threshold;
Alternatively,
Judge that the number of output of the log information reaches whether the output time used in preset value is less than preset duration;
If the output time is less than the preset duration, determine that the output speed of the log information is greater than the default threshold Value.
3. the method according to claim 1, wherein described pre- within the first preset duration after system starting If the value of threshold value is greater than the value of the preset threshold after first preset duration after the system starts.
4. the method according to claim 1, wherein the method also includes:
Judge whether contain designated key word in the log information of output;
If containing the designated key word in the log information of output, the second notification information is issued.
5. according to the method described in claim 4, it is characterized in that, the method also includes:
When receiving first notification information or/and second notification information, by first notification information or/and institute The information stated in the second notification information is transmitted to user by man-machine interface.
6. according to the method described in claim 5, it is characterized in that, first notification information or/and the second notice letter The information in breath is shown by the display interface in the system, wherein the boundary layer where the information is translucent 's.
7. the method according to claim 1, wherein the method further includes:
Process id information contained in the log information of output is obtained in the corresponding library function of system log message;
Pass through the corresponding program name of process ID acquisition of information;
The number of output of the log information of corresponding program is counted according to described program name, and by the log information of multiple programs The number of output carry out ranking.
8. the method according to the description of claim 7 is characterized in that
When monitoring that configuration file updates, system or the restarting of log monitoring program;
Configuration file is read, and obtains the program name or/and service processes for needing shielding log information output in the configuration file Name;
It will need to shield the described program name or/and the corresponding described program of the service processes name or/and institute that log information exports State the log information shielding of service processes.
9. a kind of mobile terminal, which is characterized in that the mobile terminal includes: processor, telecommunication circuit, display and storage Device, the processor are respectively coupled to the telecommunication circuit, the display and the memory, the processor, the communication Circuit, the display and the memory can be realized the step in any one of claim 1-8 the method at work.
10. a kind of device with store function, is stored thereon with program data, which is characterized in that described program data are located Manage the step realized in any one of claim 1-8 the method when device executes.
CN201711223041.7A 2017-11-28 2017-11-28 Method, mobile terminal and device for monitoring log information Active CN109840178B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201711223041.7A CN109840178B (en) 2017-11-28 2017-11-28 Method, mobile terminal and device for monitoring log information

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201711223041.7A CN109840178B (en) 2017-11-28 2017-11-28 Method, mobile terminal and device for monitoring log information

Publications (2)

Publication Number Publication Date
CN109840178A true CN109840178A (en) 2019-06-04
CN109840178B CN109840178B (en) 2023-04-07

Family

ID=66881792

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201711223041.7A Active CN109840178B (en) 2017-11-28 2017-11-28 Method, mobile terminal and device for monitoring log information

Country Status (1)

Country Link
CN (1) CN109840178B (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110262939A (en) * 2019-05-14 2019-09-20 苏宁金融服务(上海)有限公司 Algorithm model operation and monitoring method, device, computer equipment and storage medium
CN112328463A (en) * 2020-11-27 2021-02-05 中国农业银行股份有限公司 Log monitoring method and device
CN112527614A (en) * 2020-12-08 2021-03-19 广东小天才科技有限公司 Intelligent device log quantity early warning system and method
CN112699015A (en) * 2020-12-29 2021-04-23 北京达佳互联信息技术有限公司 Log output method, device, server and computer readable storage medium

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101452514A (en) * 2007-12-06 2009-06-10 中国长城计算机深圳股份有限公司 User data protection method for safety computer
CN102004678A (en) * 2010-11-11 2011-04-06 青岛普加智能信息有限公司 Operation system performance analysis method and device
US20110099187A1 (en) * 2009-10-22 2011-04-28 Vmware, Inc. Method and System for Locating Update Operations in a Virtual Machine Disk Image
CN103778049A (en) * 2012-10-19 2014-05-07 北京市三希电子科技开发公司 Embedded system development log system
CN104184622A (en) * 2014-09-09 2014-12-03 福建星网视易信息系统有限公司 Log information notification method and system
CN104572411A (en) * 2013-10-10 2015-04-29 腾讯科技(深圳)有限公司 Log data processing method and device
US20170220663A1 (en) * 2016-01-29 2017-08-03 AppDynamics, Inc. Log Event Summarization for Distributed Server System
CN107135088A (en) * 2016-02-29 2017-09-05 华为技术有限公司 The method and apparatus that daily record is handled in cloud computing system

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101452514A (en) * 2007-12-06 2009-06-10 中国长城计算机深圳股份有限公司 User data protection method for safety computer
US20110099187A1 (en) * 2009-10-22 2011-04-28 Vmware, Inc. Method and System for Locating Update Operations in a Virtual Machine Disk Image
CN102004678A (en) * 2010-11-11 2011-04-06 青岛普加智能信息有限公司 Operation system performance analysis method and device
CN103778049A (en) * 2012-10-19 2014-05-07 北京市三希电子科技开发公司 Embedded system development log system
CN104572411A (en) * 2013-10-10 2015-04-29 腾讯科技(深圳)有限公司 Log data processing method and device
CN104184622A (en) * 2014-09-09 2014-12-03 福建星网视易信息系统有限公司 Log information notification method and system
US20170220663A1 (en) * 2016-01-29 2017-08-03 AppDynamics, Inc. Log Event Summarization for Distributed Server System
CN107135088A (en) * 2016-02-29 2017-09-05 华为技术有限公司 The method and apparatus that daily record is handled in cloud computing system

Non-Patent Citations (6)

* Cited by examiner, † Cited by third party
Title
RUOQING ZHANG等: "An efficient scheme for log integrity check in security monitoring system", 《IET INTERNATIONAL CONFERENCE ON SMART AND SUSTAINABLE CITY 2013 (ICSSC 2013)》 *
RUOQING ZHANG等: "An efficient scheme for log integrity check in security monitoring system", 《IET INTERNATIONAL CONFERENCE ON SMART AND SUSTAINABLE CITY 2013 (ICSSC 2013)》, 13 February 2014 (2014-02-13) *
缪嘉嘉等: "一种基于数据流的网络威胁监控框架", 《计算机工程与科学》 *
缪嘉嘉等: "一种基于数据流的网络威胁监控框架", 《计算机工程与科学》, vol. 31, no. 12, 29 January 2010 (2010-01-29) *
陈荣征: "基于日志分析的校园网监测预警平台设计与实现", 《电脑与电信》 *
陈荣征: "基于日志分析的校园网监测预警平台设计与实现", 《电脑与电信》, vol. 2016, no. 03, 10 March 2016 (2016-03-10) *

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110262939A (en) * 2019-05-14 2019-09-20 苏宁金融服务(上海)有限公司 Algorithm model operation and monitoring method, device, computer equipment and storage medium
CN110262939B (en) * 2019-05-14 2023-07-21 苏宁金融服务(上海)有限公司 Algorithm model operation monitoring method, device, computer equipment and storage medium
CN112328463A (en) * 2020-11-27 2021-02-05 中国农业银行股份有限公司 Log monitoring method and device
CN112527614A (en) * 2020-12-08 2021-03-19 广东小天才科技有限公司 Intelligent device log quantity early warning system and method
CN112699015A (en) * 2020-12-29 2021-04-23 北京达佳互联信息技术有限公司 Log output method, device, server and computer readable storage medium
CN112699015B (en) * 2020-12-29 2023-12-19 北京达佳互联信息技术有限公司 Log output method, device, server and computer readable storage medium

Also Published As

Publication number Publication date
CN109840178B (en) 2023-04-07

Similar Documents

Publication Publication Date Title
CN109840178A (en) A kind of method, mobile terminal and the device of monitoring journal information
CN109739727B (en) Service monitoring method and device in micro-service architecture
CN109284269B (en) Abnormal log analysis method and device, storage medium and server
CN105227626B (en) Content pushing method and device and terminal
CN100481021C (en) Method, system, and apparatus for identifying unresponsive portions of a computer program
US6167358A (en) System and method for remotely monitoring a plurality of computer-based systems
US8347021B1 (en) Storing application messages
CN111176960B (en) User operation behavior tracking method, device, equipment and storage medium
CN105740326A (en) Thread state monitoring method and device for browser
EP2287741A1 (en) Method of collecting information in computer system, management computer using the same, and computer system
US20240039821A1 (en) Mitigating failure in request handling
CN107357671A (en) A kind of fault handling method, relevant apparatus and computer
CN112631887A (en) Abnormality detection method, abnormality detection device, electronic apparatus, and computer-readable storage medium
CN109582536B (en) Application program non-response reporting method and device and computer equipment
CN107357731A (en) Process produces monitoring, analysis and the processing method of core dump problems
CN112202628B (en) WiFi module serial port protocol automatic test system and method
CN108197002B (en) Mobile device non-buried point data statistical method, system, terminal and medium
CN115129573A (en) Program operation monitoring method and device, electronic equipment and storage medium
CN104978212B (en) A kind of unknown crash report method and device
CN110943865A (en) Method and device for diagnosing equipment fault time and related equipment
CN110717130A (en) Dotting method, dotting device, dotting terminal and storage medium
CN106482742A (en) The acquisition methods of meter step data and device
CN111274086A (en) Computer software fault monitoring system
US7752504B2 (en) System diagnostics with dynamic contextual information of events
CN110245046A (en) It is a kind of for Android App without the data statistical approach and device buried a little

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